Active development. APIs and on-chain layouts may change. Track on GitHub.
S SolanaLM
Home / Use cases / Machine-payable inference for agents

Machine-payable inference for agents

Give an autonomous agent an OpenAI-compatible endpoint it can pay for per call in SOL — point the existing SDK at the gateway, keep your app code unchanged.

The problem

The agent economy makes far more inference calls than humans, at thinner margins, and increasingly with agents that hold their own wallets. Centralized APIs bill monthly against seat licenses and lock you to one base URL, key format, and pricing model — a poor fit for machine-to-machine payment, and expensive to unwind.

How SolanaLM does it
  • The gateway exposes /v1/chat/completions and /v1/completions matching the OpenAI schema, so existing apps and agent frameworks switch with a base-URL change.
  • Pass a Solana wallet address as the api_key — the wallet is both identity and payment, so an agent funds a session and pays per call with no human in the loop.
  • Under the hood, requests can hit local PyTorch/Transformers, llama.cpp (GGUF), or proxied OpenAI, Anthropic, Cohere, or Ollama backends — one interface, swappable backends.
  • Every call leaves an on-chain audit trail, so an agent (or its operator) can reconcile exactly what it paid for.

Try it for machine-payable inference for agents.

Read the deep dive, then run the quickstart.

Other use cases