EditFlow is a small, public image-editing Agent built with Agno. It exists to demonstrate a real prompt-regression workflow with AgentRig: the model chooses tools, AgentRig can execute either deterministic fixtures or the public EditFlow MCP tool backend, and every tool decision is observable and repeatable without calling an image-processing service.
Prompt-regression exercise: tag
recording-baseline-v1keeps the intentionally broad routing baseline. The current working tree contains the evidence-backed candidate:retouch_photois limited to pixel adjustments and dedicated background/crop tools retain their boundaries. Use the included$prompt-regression-governanceSkill to reproduce the Before/Candidate workflow. There is no hard-coded phrase router in the HTTP layer.
agno==2.6.11runs a single ReAct-style Agent with an OpenAI-compatible model.- Five Agno tools use native
external_execution=Truepause/continue semantics. - PostgreSQL persists completed history and paused runs in one
editflow_sessionstable. - FastAPI exposes an AgentRig-compatible HTTP/SSE protocol.
- A streamable-HTTP MCP backend executes all five public tool contracts locally.
- Tool inputs and external results are validated with JSON Schema.
No image bytes are uploaded and no image API is called. Fixtures and the MCP backend return
fictional image references such as image-demo-edit-01, so image-processing cost is zero.
Requirements: Python 3.12/3.13, uv, Docker, and an
DeepSeek API key. The checked-in defaults use deepseek-v4-flash through DeepSeek's
OpenAI-compatible endpoint.
cp .env.example .env
# Edit .env and set DEEPSEEK_API_KEY. EDITFLOW_MODEL_API_KEY remains a supported override.
docker compose up -d postgres
uv sync --all-extras
uv run editflowStart the public tool backend in another terminal:
uv run editflow-tools-mcp --port 8091Or use bash scripts/start.sh after preparing .env.
The target listens on http://127.0.0.1:8090 by default:
curl http://127.0.0.1:8090/health
curl http://127.0.0.1:8090/capabilitiesSeed its public Target, three Profiles (Fixture, real-MCP capture, approved-Sample replay), and seven cases into a running AgentRig instance:
uv run editflow-seed-agentrig --recording --base-url http://127.0.0.1:8020 \
--target-endpoint http://127.0.0.1:8090--recording also verifies that the catalog starts with exactly seven Draft cases, no Sample, no
Run, and no pre-created case_editflow_one_step_mixed_chain. It fails fast when a previous rehearsal
would make the recorded “live New Case” claim untrue.
For the Sample-capture recording, start AgentRig with the checked-in safe deployment config:
cd ../agentrig
AGENTRIG_CONFIG_FILE="../editflow-demo-agent/agentrig/agentrig.capture.toml" \
uv run agentrig serve --port 8020The capture Profile calls the MCP backend once. Codex then creates a draft Sample from the persisted
tool_call event through AgentRig MCP, a user approves it in the Web UI, and the Sample-only Profile
replays it five times without calling the MCP backend again.
See docs/protocol.md, docs/evaluation.md, and docs/security.md for the public contracts and evaluation boundaries. The architecture and recording path describe the complete competition demo.
uv run ruff check .
uv run pytest -m "not live"The PostgreSQL integration tests use the same local compose database. A real-model smoke test is
opt-in and is skipped unless DEEPSEEK_API_KEY or EDITFLOW_MODEL_API_KEY is configured.
MIT. All names, schemas, prompts, IDs, and fixtures in this repository were written for this public demo and do not contain customer data or private image-agent source code.