Skip to main content

AgentAssert Type-C HTTP forwarding proxy — formal behavioral contracts middleware for any AI agent, any provider.

Project description

agentassert-typec-proxy

HTTP forwarding proxy — formal behavioral contracts middleware with zero code change.

This is the flagship. Drop it between any agent harness and any LLM API. Set one env var. Done.

Quickstart

pip install agentassert-typec-proxy
agentassert-proxy proxy start --contract contract.yaml

Then in your agent environment:

export ANTHROPIC_BASE_URL=http://localhost:9000/anthropic
export OPENAI_BASE_URL=http://localhost:9000/openai

Supported Providers

Provider Route Prefix Env Var
Anthropic /anthropic ANTHROPIC_BASE_URL
OpenAI /openai OPENAI_BASE_URL
Gemini /gemini GEMINI_BASE_URL
OpenRouter /openrouter OPENROUTER_BASE_URL

Endpoints

Method Path Description
GET /health Health check, returns contract name and Θ
GET /status Full status: Θ, JSD, violation count
POST /admin/reload Trigger contract hot-reload

Performance

  • p99 overhead < 30ms (excluding provider RTT)
  • All regex patterns pre-compiled at startup
  • Hot-reload via SHA256 file polling (500ms interval)
  • Fail-safe: invalid contract → keeps old monitor

License

MIT

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

agentassert_typec_proxy-0.4.1.tar.gz (8.4 kB view details)

Uploaded Source

Built Distribution

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

agentassert_typec_proxy-0.4.1-py3-none-any.whl (13.6 kB view details)

Uploaded Python 3

File details

Details for the file agentassert_typec_proxy-0.4.1.tar.gz.

File metadata

  • Download URL: agentassert_typec_proxy-0.4.1.tar.gz
  • Upload date:
  • Size: 8.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.5

File hashes

Hashes for agentassert_typec_proxy-0.4.1.tar.gz
Algorithm Hash digest
SHA256 2f6bfe438c0c638c542a79e7cc927c07ac031eb8eb36573bd37ccb5d8520ac3e
MD5 df92edb8fa1dfda19fc126ca1b14e8a9
BLAKE2b-256 bdc91e565a9e41def262d7ee0173588e3708f003ac2a183f6e172bb07615430f

See more details on using hashes here.

File details

Details for the file agentassert_typec_proxy-0.4.1-py3-none-any.whl.

File metadata

File hashes

Hashes for agentassert_typec_proxy-0.4.1-py3-none-any.whl
Algorithm Hash digest
SHA256 0bc3efb1d1c6fca308e872631e1e2fd63e2a2ceb5742f6c67939e6e8d9949180
MD5 726cc0b4f1be1e86c608d5dfded84960
BLAKE2b-256 7c14efd65d99ceee282416cc4b8e20f3a7b96056d4871362897751666dd4dfbb

See more details on using hashes here.

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