Axiom¶
Constructor¶
new Axiom(config: AxiomConfig)
Creates a new SDK instance. Configuration is required and validated. The SDK does not apply defaults.
reason()¶
axiom.reason({
context: string | string[],
task: string,
model?: string
}): Promise<ReasonResult>
Transforms raw context into a de-identified semantic structure and enforces boundary rules. In attested tier, the method also returns evidence suitable for verification.
ReasonResult¶
transformedContext: de-identified semantic outputrenderedPrompt: optional prompt output (currently undefined)attestationEvidence: present in attested tierverificationHint: expected measurement hint
Errors¶
The SDK throws:
ConfigurationErrorwhen configuration or input is invalidBoundaryViolationErrorwhen raw data attempts to cross the boundaryTransformationErrorwhen the pipeline failsSecurityInvariantErrorwhen security assumptions are violated
Notes¶
modelis a hint only; the SDK makes no network calls.- Attested tier returns evidence + hint for verification.
Example (standard tier)¶
import { Axiom } from "@axiom-infra/core";
const axiom = new Axiom({
securityTier: "standard",
enclave: "none",
policyVersion: "v1",
});
const result = await axiom.reason({
context: "Vendor signed a contract for $250,000",
task: "Summarize obligations",
});
Example (attested tier, preview)¶
const axiom = new Axiom({
securityTier: "attested",
enclave: "auto",
policyVersion: "v1",
platform: { type: "sev-snp", verificationMode: "permissive" },
});
Prev: Release Notes | Next: Attestation API