https://github.com/wtthornton/agentforge-echo-plugin
Canonical test rig for AgentForge's plugin system. Deterministic, zero-dep — the pre-release smoke gate.
https://github.com/wtthornton/agentforge-echo-plugin
agentforge plugin testing
Last synced: 23 days ago
JSON representation
Canonical test rig for AgentForge's plugin system. Deterministic, zero-dep — the pre-release smoke gate.
- Host: GitHub
- URL: https://github.com/wtthornton/agentforge-echo-plugin
- Owner: wtthornton
- License: mit
- Created: 2026-04-25T19:35:27.000Z (2 months ago)
- Default Branch: main
- Last Pushed: 2026-06-10T15:54:47.000Z (24 days ago)
- Last Synced: 2026-06-10T17:22:23.975Z (24 days ago)
- Topics: agentforge, plugin, testing
- Language: Python
- Size: 19.5 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# agentforge-echo-plugin
The canonical **test rig** for AgentForge's plugin system. Filed as [TAP-753](https://linear.app/tappscodingagents/issue/TAP-753); published to GitHub and wired into AgentForge CI under [TAP-754](https://linear.app/tappscodingagents/issue/TAP-754).
This plugin does nothing useful in production. Its only job is to exercise every plugin-system hook point — entry-point discovery, `register(app)` callback, route mounting, agent discovery, event bus — **deterministically, with zero external dependencies**. When this plugin's smoke test breaks, the plugin system broke.
## What it proves works
| Hook | How |
|------|-----|
| `[project.entry-points."agentforge.plugins"]` discovery | `pyproject.toml` declares `echo = "agentforge_echo"` |
| `register(app)` entry-point | `agentforge_echo.plugin:register` mounts the router |
| Route mounting | `GET /api/echo/status`, `POST /api/echo/echo` |
| `plugin.json` manifest | served back via `GET /api/plugins` on the host |
| Agent discovery via `AgentLoader.load_external()` | `echo-agent` under `project.echo` namespace |
| Namespace enforcement | agent namespace `project.echo.echo-agent` validated on load |
| TopicBus event publish | `POST /api/echo/echo` emits `EchoEvent` on `project.echo.echoed` |
| Deterministic runner | `EchoRunner.run(s) == s[::-1]` — no LLM, no network |
## Install
```bash
uv pip install -e /path/to/agentforge-echo-plugin
```
Then, against a running AgentForge:
```bash
curl -XPOST http://127.0.0.1:8001/api/plugins/register \
-H 'content-type: application/json' \
-d '{"package_name":"agentforge-echo-plugin"}'
```
## Verify
```bash
curl http://127.0.0.1:8001/api/echo/status
# → {"status":"ok","plugin":"echo","version":"1.0.0"}
curl -XPOST http://127.0.0.1:8001/api/echo/echo \
-H 'content-type: application/json' \
-d '{"msg":"hello"}'
# → {"echoed":"hello","reversed":"olleh"}
curl http://127.0.0.1:8001/api/plugins/echo/agents
# → { "plugin_id":"echo", "agents":[{"name":"echo-agent", ...}] }
```
## Run plugin-side tests
```bash
cd /path/to/agentforge-echo-plugin
uv sync
uv run pytest
```
## Guarantee
**This plugin will pass in any dev environment with no network access.** If it doesn't, the plugin system regressed — not your environment.
## Not covered (intentionally)
- Frontend module federation (`remote_url` is empty — manifest is served, but no JS bundle exists to load)
- Credential-vault integration (echo has no credentials)
- LLM-in-loop behaviours (would break determinism)
These belong in dedicated rigs when their smoke becomes worth writing.