Skip to main content

Prime inference for AI agents. Signed AgentCards, x402-ready wallets, hash-chained audit logs — out of the box.

Project description

ainfera — Python SDK for Ainfera

PyPI version Python versions CI License: Apache 2.0

Prime inference for AI agents. Signed AgentCards, x402-ready Wallets, hash-chained AuditChains — out of the box.

Install

pip install ainfera

Requires Python 3.10+.

Quickstart

from ainfera import AinferaClient

# api_key also reads from the AINFERA_API_KEY environment variable
client = AinferaClient(api_key="ak_...")
agent = client.agents.register(name="my-agent")
agent.wallet.topup(amount_usd=10)

response = agent.inference(
    model="claude-opus-4-7",
    messages=[{"role": "user", "content": "Hello"}],
)
print(response.text)
print(response.receipt.audit_url)

What is Ainfera?

Ainfera is prime inference infrastructure for AI agents. Every call your agent makes is signed, settled, and tamper-evidently logged — without you wiring any of that yourself. See ainfera.ai.

Features

  • Signed AgentCards per Agent (JWS, RFC 7515)
  • Provider-neutral routing across Anthropic, OpenAI, Together (more soon)
  • Atomic per-call settlement out of an Agent-scoped Wallet
  • Tamper-evident hash-chained AuditChain for every Agent
  • Local verification — auditors can verify a chain offline, no Ainfera trust required
  • Sync + async clients sharing one resource surface

Concepts

Compose, don't invent

This SDK is a thin wrapper around the Ainfera API. The underlying primitives align with:

  • Open Agent Identity (OAI) Spec — openagentidentity.org
  • Mastercard Verifiable Intent
  • x402 Foundation (Linux Foundation)
  • NIST AI Agent Standards Initiative
  • EU AI Act Annex IV

License

Apache 2.0. See LICENSE.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ainfera-1.0.0.tar.gz (16.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

ainfera-1.0.0-py3-none-any.whl (22.7 kB view details)

Uploaded Python 3

File details

Details for the file ainfera-1.0.0.tar.gz.

File metadata

  • Download URL: ainfera-1.0.0.tar.gz
  • Upload date:
  • Size: 16.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for ainfera-1.0.0.tar.gz
Algorithm Hash digest
SHA256 995b52ef7fdf6739ba9ea38fe522001290d0d1c9f748a409d709965a2d29f307
MD5 6c8c83e2e4264cade2d32b450914716d
BLAKE2b-256 600d50087436af2b8ea1e9db38294b6649b7fd5d48b4bc7c1047d217f38ae63b

See more details on using hashes here.

Provenance

The following attestation bundles were made for ainfera-1.0.0.tar.gz:

Publisher: release.yml on ainfera-ai/sdk

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file ainfera-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: ainfera-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 22.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for ainfera-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 be15aa86d02333290f7f50c1263e1ad37ca8db448bcbc71c2d77b28214b81bf2
MD5 507ca046c7a73683b0450e7ae7bd03b8
BLAKE2b-256 60d8f5227fa83cb3cabd928cb66221d168daae6bccc5e799be686089584ef26a

See more details on using hashes here.

Provenance

The following attestation bundles were made for ainfera-1.0.0-py3-none-any.whl:

Publisher: release.yml on ainfera-ai/sdk

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page