Security News
Input Validation Vulnerabilities Dominate MITRE's 2024 CWE Top 25 List
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
Axiom unlocks observability at any scale.
For more information check out the official documentation and our community Discord.
npm install axiom-ai
Wrap your OpenAIApi
in withAxiom
to automatically send completion and
chat completion calls to Axiom:
import { Configuration, OpenAIApi } from "openai";
import { withAxiom } from "axiom-ai/openai";
(async function() {
const configuration = new Configuration({
apiKey: process.env.OPENAI_API_KEY,
});
const openai = withAxiom(new OpenAIApi(configuration), {
token: process.env.AXIOM_TOKEN,
dataset: process.env.AXIOM_DATASET,
});
const completion = await openai.createCompletion({
model: "text-davinci-003",
prompt: "Hello world",
});
console.log(completion.data.choices[0].text);
})()
This is what an event could look like.
{
"duration": 1037,
"request": {
"model": "text-davinci-003",
"prompt": "Hello world"
},
"response": {
"choices": [
{
"text": " world\n\nHello! How are you today?",
"index": 0,
"logprobs": null,
"finish_reason": "stop"
}
],
"created": "2023-03-30T09:14:07.000Z",
"id": "cmpl-6zie7fuAZQ8BwdNE5hKnDiEpnY9Bb",
"model": "text-davinci-003",
"object": "text_completion",
"usage": {
"completion_tokens": 10,
"prompt_tokens": 2,
"total_tokens": 12
}
},
"type": "completion"
}
If you pass excludePromptOrMessages: true
and/or excludeChoices: true
to
the withAxiom
options it won't send the prompt/messages or choices,
respectively.
FAQs
The official package to send events from AI libraries to Axiom.
The npm package axiom-ai receives a total of 0 weekly downloads. As such, axiom-ai popularity was classified as not popular.
We found that axiom-ai demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
Security News
In this segment of the Risky Business podcast, Feross Aboukhadijeh and Patrick Gray discuss the challenges of tracking malware discovered in open source softare.
Research
Security News
A threat actor's playbook for exploiting the npm ecosystem was exposed on the dark web, detailing how to build a blockchain-powered botnet.