Argus — Traceable AI Agent
A tool-calling shop agent you can replay without an API key and inspect span by span. Python/FastAPI agent core, OpenTelemetry traces, a customer storefront, and a trace-first inspector, all deployed.
Role
Creator & AI Engineer
Capacity
Solo build
Year
2026
Stack size
10 tools
Overview
Argus answers questions about Argus Field Supply, a fictional field-optics shop, and is built around one loop: prompt, agent, tool call, shop API, replayed LLM, answer, trace. The public demo runs in deterministic replay mode, so it needs no provider key and returns the same answers every time, which makes the agent testable in CI. Every request produces an OpenTelemetry trace covering the agent workflow, the LLM call, the selected tool and the downstream API call, with prompt and completion content redacted before storage. Two Next.js frontends sit on a shared contract: a customer storefront with an assistant workspace and status page, and an engineer-facing inspector that exposes tool calls, arguments, results and trace IDs. The public edge is hardened as a first-class concern: allowlisted prompts, request-size caps, per-client rate limits, a global concurrency cap, destructive tools removed, and replay misses that fail closed. The next phase adds a hybrid-retrieval RAG layer with cited answers, claim-level verification and abstention, evaluated on a hand-written golden set that is half unanswerable.
Responsibilities
- Designed the agent core: a stateless FastAPI service running a LangChain tool loop over ten typed shop tools, with a client-owned history contract and a token-budget trimmer.
- Built the deterministic replay layer (VCR-style cassettes for two model providers) so the full agent path runs offline, identically, in CI and in the public demo.
- Instrumented every request with OpenTelemetry GenAI spans, with a collector pipeline that normalizes attributes and redacts prompt and completion content.
- Hardened the public edge: prompt allowlist, 16 KiB body cap, per-client rate limit, global concurrency cap, destructive tools removed, fail-closed replay, and a bearer token between the BFFs and the backend.
- Built the Next.js customer storefront with an assistant workspace and a server-side BFF that returns only normalized customer data, plus a password-protected operations console with a span waterfall viewer.
- Built a second, trace-first Next.js client that shows tool calls, arguments, results, metrics and trace IDs for the same answers.
- Wrote a test suite of 49 tests covering the replay matcher, history trimming, determinism, public-mode guards, smoke prompts and telemetry, plus module guides documenting each design decision.
Highlights
- Agent runs deterministically offline: same prompt, same answer, no API key
- Every answer has an inspectable trace, with content redacted by default
- Public edge designed to fail closed, with the residual risks documented
- Two frontends, one backend contract: customer lens and engineer lens