Skip to main content

placeboagent

A fake AG-UI agent backend for testing. Scriptable, deterministic, offline.

Status: pre-release. 0.1.0 is in active development. The full roadmap lives in docs/PLAN.md.

Part of the placebo family of test doubles: placebopay (fake payment gateway) · placeborag (fake RAG stack) · placeboagent (fake agent backend).

Why

If you build AG-UI frontends, clients, or emitters, your test target today is a real agent backend: slow, nondeterministic, token-metered, and incapable of producing the failures that actually break UIs in production. Dropped SSE connections mid-message. Malformed events. Lifecycle events out of order. A tool call that never finishes.

placeboagent speaks the AG-UI protocol with no LLM behind it. Same scenario, same byte stream, every time. All event types come from the official ag-ui-protocol package, so conformance tracks the spec.

Planned for 0.1.0

  • Scriptable fake agent. An ASGI app exposing one AG-UI SSE endpoint. Define a run as an ordered script of events with timing control: instant, fixed delay, or realistic token pacing.
  • Canned scenarios. Plain text reply, streamed tool call, state snapshot + deltas, human-in-the-loop interrupt, run error.
  • Record & replay. Capture the event stream of a real AG-UI backend to JSONL, then serve it back verbatim or at adjusted speed. Recorded sessions become fixtures you commit and replay in CI.
  • Failure injection. Drop the connection after event N, stall mid-stream, emit malformed or unknown events, violate lifecycle ordering, duplicate events.
  • pytest plugin. A placebo_agent fixture plus assertion helpers (assert_valid_run) for testing your own AG-UI emitters.

Runs standalone (placeboagent serve) for frontend developers who never touch Python, or mounts into any FastAPI/Starlette app.

Target API preview

Subject to change until 0.1.0 ships. This is the design being built, not a released interface.

from placeboagent import PlaceboAgent, scenarios

agent = PlaceboAgent(scenario=scenarios.streamed_tool_call())
app.mount("/agent", agent)   # any FastAPI/Starlette app
placeboagent serve --scenario text-reply --port 8199

Non-goals

No LLM calls, ever (that is the point). No hosted service, no UI, no per-framework integrations: the protocol is the interface.

License

MIT

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

placeboagent-0.0.1.tar.gz (5.8 kB view details)

Uploaded Source

Built Distribution

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

placeboagent-0.0.1-py3-none-any.whl (3.6 kB view details)

Uploaded Python 3

File details

Details for the file placeboagent-0.0.1.tar.gz.

File metadata

  • Download URL: placeboagent-0.0.1.tar.gz
  • Upload date:
  • Size: 5.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for placeboagent-0.0.1.tar.gz
Algorithm Hash digest
SHA256 bdaaccc7346200d7d7b0425e78f17b925dadcbf2987cb0fd42dfc5f04a9f2156
MD5 9b8963a67a5ae2a92d6b8dae8f22dfe9
BLAKE2b-256 1cdb31c611c5098ecf767484495d71fc89ae2d226412c617c4197cb2af98555b

See more details on using hashes here.

Provenance

The following attestation bundles were made for placeboagent-0.0.1.tar.gz:

Publisher: release.yml on elaz48/placeboagent

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file placeboagent-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: placeboagent-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 3.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for placeboagent-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 173e294c26f9046a20248c4cd1b1ff208da97522f6ff5524bb7219990c18e553
MD5 76dc1d534bd8244ca66bce8ccdafd1ac
BLAKE2b-256 28b8241e2cd97753135d29a07d6e013ee98af593c3988efa58daf1179b6da628

See more details on using hashes here.

Provenance

The following attestation bundles were made for placeboagent-0.0.1-py3-none-any.whl:

Publisher: release.yml on elaz48/placeboagent

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

This release

0.0.1 This release

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page