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.6.1.tar.gz (12.9 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.6.1-py3-none-any.whl (16.8 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: agentassert_typec_proxy-0.6.1.tar.gz
  • Upload date:
  • Size: 12.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.8 {"installer":{"name":"uv","version":"0.11.8","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for agentassert_typec_proxy-0.6.1.tar.gz
Algorithm Hash digest
SHA256 d73e6be27e023faf5d6537fa53ecef057b30c95fcaa0a5db2bcfb4eb58c1dd7b
MD5 1c7f797eadc02cc159fd6500a84b05a9
BLAKE2b-256 937a5a10cd6ea1992dcf0b88efd6638a42c42d21c5eb3905dbae0b11ab7ff2c7

See more details on using hashes here.

File details

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

File metadata

  • Download URL: agentassert_typec_proxy-0.6.1-py3-none-any.whl
  • Upload date:
  • Size: 16.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.8 {"installer":{"name":"uv","version":"0.11.8","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for agentassert_typec_proxy-0.6.1-py3-none-any.whl
Algorithm Hash digest
SHA256 073f0f365e6e5e586070f88563b3b142a5c7e74f514d4767d51ab4780c20629b
MD5 839d49d8927b852980474f488f09bd76
BLAKE2b-256 e36e8f5e8d65da2c3161d0a5a3e748cbd1b413b15f74df9eb85c05bc2953d7e0

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