/mas-ai-workflows:agent-tool-replay-testfrom mas-ai-workflows
Replay recorded agent tool/LLM trajectories against deterministic fixtures to test argument validation, errors, idempotency, and side-effect boundaries—separate from live tool-selection quality.
Ships in mas-ai-workflows. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Live agents are expensive and flaky. Record/replay at the SDK or tool boundary gives deterministic CI: assert validation, error handling, and “must not call” policies without paying for tokens. Replay does not prove the model still chooses the right tools—that needs live/eval gates (@prompt-regression-gate).
Claude operates as a Principal Agent Test Architect for cassettes, contract assertions, clock/ID freezing, and unknown-outcome handling after timeouts.
┌─────────────────────────────────────────────────────────────┐
│ RECORD (once): LLM decisions ± tool results → cassette │
│ REPLAY (CI): inject recordings; optionally run real tools │
│ ASSERT: schemas, sequences, deny-lists, idempotency │
└─────────────────────────────────────────────────────────────┘
replay mode.@ai-pii-redaction-review.| Case | Expect |
|---|---|
| Success | Valid args → OK result |
| Timeout | Bounded retry policy; unknown outcome path |
| Permission denied | No side effect; surfaced error |
| Malformed tool JSON | Reject via @llm-json-contract-check |
| Partial failure | Compensating / reconcile logic |
| Unknown fields / bad IDs | Validation reject before dispatch |
| Mutating call | AuthZ + idempotency key before effect |
| Policy deny | Tool absent from allow-list never invoked |
uuid4() in recorded args).record | replay (CI; miss = fail, no network) | passthrough.After a timeout on charge/send_email, state is unknown. Blind replay can duplicate. Require: idempotency keys, reconcile-before-retry, or human handoff (@ai-human-handoff-contract).
called_with schemasFixtures + traces + “must not occur” assertions + explicit statement that selection quality is out of scope for pure replay.
@llm-json-contract-check, @prompt-regression-gate, @agent-injection-boundary-test, @llm-cost-latency-benchmark
MANDATORY: Keep replay offline in CI. Sanitize cassettes. Test validation and side-effect gates. Never blind-retry mutating calls after unknown outcomes. Separate replay coverage from model tool-selection evals.
Cassette/agentverify/pytest-agentcontract/langchain-replay patterns; industry emphasis on SDK-level record/replay and idempotent mutating tools.
What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub alivirgo/major-ai-skills --plugin mas-ai-workflows10 skills in this plugin
/agent-injection-boundary-testTest authorized agents against indirect prompt injection in retrieved docs and tool outputs using paired clean/poison fixtures, synthetic canaries, and sandboxed tools. Evidence for these cases—not a claim injection is solved./ai-citation-verificationVerify AI citations across structural schema, resolvability (registry/URL/DOI), and semantic support of each claim by the cited span—not the whole context. Use for RAG answers, research agents, and regulated audit trails./ai-evaluation-datasetBuild versioned JSONL evaluation datasets for AI workflows with golden/regression/holdout layers, leakage checks, rubrics, and provenance hashes. Use when creating or revising eval sets before comparing models, prompts, or RAG configs.Other plugins' skills for the same job
2 plugins in one repository ship this exact skill · first indexed Oct 7, 2026