What problem does it solve?
Tests that replay recorded LLM responses fail with "No memoized conversation found for the given prompt" whenever prompts or behavior change, and regenerating them incorrectly (e.g., with vitest -t) corrupts shared fixtures because deterministic ID generation depends on test execution order.
Core Features & Use Cases
- Fixture Regeneration: Re-runs model-fixture tagged suites with DX_UPDATE_MODEL_FIXTURES=1 to record fresh LLM conversations into .store/conversations/<suite>/<hash>.json.
- Correct Regeneration Scope: Enforces regenerating whole test files or packages instead of single tests, preserving the shared deterministic ID sequence across a suite.
- API Key Handling: Guides sourcing DX_ANTHROPIC_API_KEY from 1Password via pnpm -ws 1p-credentials for direct Anthropic API calls.
- Use Case: After changing a prompt in the assistant package, run DX_UPDATE_MODEL_FIXTURES=1 moon run assistant:test to refresh the cache, then commit the updated .store/conversations files so CI replays the new fixtures.
Quick Start
Regenerate the model fixture cache for the assistant package by running its tests with DX_UPDATE_MODEL_FIXTURES=1 and then commit the updated conversation files.