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

Uploaded Python 3

File details

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

File metadata

  • Download URL: agentassert_typec_proxy-0.6.2.tar.gz
  • Upload date:
  • Size: 12.8 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.6.2.tar.gz
Algorithm Hash digest
SHA256 89c5361a669d008b1e31d1b37efb2f19687a9e421766c36dce217834c6d17e81
MD5 d3f04d95e1da9bf94982e7bc1f7238e2
BLAKE2b-256 be2580b2a9cf029d75dcb89ff5142f4280eaff25c68f2441d774ea2a6feabc2b

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for agentassert_typec_proxy-0.6.2-py3-none-any.whl
Algorithm Hash digest
SHA256 998dc766d54f95cd68a631bb9f725286aacff37c286970fd1feb95dac5ae4153
MD5 b6dd0d4a4d9235845b6af65778734fee
BLAKE2b-256 b8229822be82d1677da595eafaedff81c2e3f774653694287a49efd1c065b962

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