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.5.0.tar.gz (10.0 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.5.0-py3-none-any.whl (15.0 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: agentassert_typec_proxy-0.5.0.tar.gz
  • Upload date:
  • Size: 10.0 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.5.0.tar.gz
Algorithm Hash digest
SHA256 e6895b411de94d6fc70d16c002bf8b98922b287871d9f565d9e337fb0527722d
MD5 7d84bc480062483a6f48661b327e325a
BLAKE2b-256 e6685ff5079f5566e69b271ead1584b71b0725616d0a41614a944233c1535cc1

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for agentassert_typec_proxy-0.5.0-py3-none-any.whl
Algorithm Hash digest
SHA256 a7ca0f51c602106c63935fdaf62ca77fd4bcba0b9e2f9fbb9f9fdf0f221f86cd
MD5 d5a5cc763c4f6648bbc52fe85134e695
BLAKE2b-256 af110477e850460e26e50ad3b7a5becc34fc86d1cad4db01eef5736623135f4a

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