/epic:evalfrom epic
Runs quality and performance evaluation with baseline comparison across correctness, performance, quality, and regression dimensions. Outputs PASS/WARN/FAIL/SKIPPED per dimension. Use for pre-ship evaluation or regression checks.
Ships in epic. 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.
None: SKILL.md is the whole skill.
CRITICAL: Run EPIC_PROJECT_DIR=$(epic path) first. Never use .harness/ in the project directory.
/ship creates a PR (automatic if eval.yaml exists)/go completes a feature/eval commandmake eval or epic eval --json4 dimensions run in parallel where possible:
By default performance passes or fails on the command's exit status only. To gate on a measured value, name the metric in eval.yaml:
dimensions:
performance:
enabled: true
command: "node perf.mjs"
extra:
metric: latency_ms
better: lower # or higher; default lower
max_regression_pct: 20 # required with metric, in (0, 1000]
trials: 3 # 1..=50, default 3; the median is compared
metric, for example {"latency_ms": 7.67}. The last object that has the key wins. Nested keys are not searched, and the command, not eval, does the measuring. Stdout must be strict JSON: a line that mentions the metric key but is not valid JSON (Python's json.dumps writes NaN by default; pass allow_nan=False) makes the metric metric_invalid and FAILs.trials times and compares the median to the median stored in the baseline. FAIL when it is worse than max_regression_pct percent (exactly at the limit passes). A metric regression stays FAIL even when fail_on_regression is false.details.metric.status is one of compared, no_baseline, no_baseline_metric (baseline predates the metric), baseline_mismatch (metric name or direction changed), zero_baseline, command_failed, metric_missing, metric_invalid, invalid_config (metric set without max_regression_pct, or no trials ran). compared passes or fails by the limit; no_baseline, no_baseline_metric, baseline_mismatch and zero_baseline pass and print a stderr note to run epic eval --baseline-update and record a baseline median; the last four statuses fail.trials of 3 or more for timing metrics. A FAIL here loops /orbit Step 5.5, and a noisy metric can fail unchanged code.--baseline-update is not guarded: a run whose metric regressed is still saved if you request it, and becomes the new comparison point. Only update the baseline after you accept the result.EPIC_PROJECT_DIR=$(epic path)
If $EPIC_PROJECT_DIR/eval/eval.yaml does not exist, run scaffold:
epic eval --init
Read the config:
cat $EPIC_PROJECT_DIR/eval/eval.yaml
If eval.yaml has benchmarks: [] and no benchmark files are found in the project:
Generate stub files using the CLI:
epic eval --scaffold
Supported stacks (auto-detected from project markers):
| Stack | Detected by | Generated file | Output format |
|---|---|---|---|
| Rust | Cargo.toml | benches/eval_harness.rs | criterion (exit code) |
| Python | pyproject.toml / setup.py | benchmarks/eval_runner.py | JSON composite |
| TypeScript | tsconfig.json | benchmarks/eval.ts | JSON composite |
| Node.js | package.json | benchmarks/eval.mjs | JSON composite |
| Go | go.mod | benchmarks/eval_test.go | JSON composite |
| Java | pom.xml / build.gradle | benchmarks/EvalBenchmark.java | exit code |
| Kotlin | build.gradle.kts | benchmarks/EvalBenchmark.kt | exit code |
| Ruby | Gemfile | benchmarks/eval_benchmark.rb | JSON composite |
| PHP | composer.json | benchmarks/eval_benchmark.php | JSON composite |
| C# | *.csproj / *.sln | Benchmarks/EvalBenchmark.cs | JSON composite |
| Swift | Package.swift | benchmarks/EvalBenchmark.swift | JSON composite |
| Elixir | mix.exs | benchmarks/eval_benchmark.exs | JSON composite |
| C++ | CMakeLists.txt | benchmarks/eval_benchmark.cpp | exit code |
Customize the generated file — every file has # TODO / // TODO markers:
If --scaffold can't generate a useful stub (domain too complex, custom evaluation logic needed), generate a custom benchmark with LLM assistance:
{"composite": 0.0–1.0, ...}benchmarks/eval_runner.{ext} matching the project languageWire into eval.yaml:
benchmarks:
- name: eval_runner
command: python3 benchmarks/eval_runner.py full
result_type: composite # parse composite field from JSON stdout
Use result_type: exit_code for frameworks (criterion, JMH, BenchmarkDotNet) that manage their own output.
Execute the structured evaluation via the Rust binary:
epic eval --json
This runs all enabled dimensions and outputs a JSON result. Capture the output.
overall_verdict is PASS, WARN, FAIL, or SKIPPED. SKIPPED means no dimension was measured and exits 0. Report it as SKIPPED, never as PASS.
If the CLI reports llm_judge: SKIPPED (no LLM available in CLI mode), proceed to Step 2 for LLM-as-judge. Otherwise, skip to Step 3.
If the quality dimension has llm_judge: true and CLI marked it SKIPPED:
Sample 3–5 changed files from the current branch:
git diff --name-only $(git merge-base HEAD main)
For each sampled file, evaluate on a 1-10 rubric:
Average scores across files. Map to 0.0–1.0 scale.
Record results alongside CLI output.
cat $EPIC_PROJECT_DIR/eval/baselines/latest.json
Without a baseline, the regression dimension reports SKIPPED with reason no_baseline.
If no baseline exists, the current run BECOMES the first baseline. Save it:
epic eval --baseline-update
Report: "First baseline established. Future runs will compare against this."
Combine CLI output + LLM-as-judge results into a single report:
## Eval Report
- Branch: {branch}
- Commit: {commit_short}
### Correctness: [PASS/WARN/FAIL/SKIPPED], score: {score}
- Tests: {passed}/{total} passing ({pass_rate}%)
- Mutation score: {mutation_score}% (if enabled)
- Delta vs baseline: {+/-delta}
### Performance: [PASS/WARN/FAIL/SKIPPED], score: {score} (if enabled)
- Avg latency: {latency}ms (delta: {+/-delta})
- Throughput: {throughput} (delta: {+/-delta})
### Quality: [PASS/WARN/FAIL/SKIPPED], score: {score}
- Lint errors: {count}
- LLM judge: {score}/10 (if enabled)
### Regression: [PASS/FAIL/SKIPPED]
| Dimension | Baseline | Current | Delta | Verdict |
|-----------|----------|---------|-------|---------|
| correctness | {prev} | {cur} | {delta} | {pass/fail} |
| quality | {prev} | {cur} | {delta} | {pass/fail} |
### Overall: [PASS/WARN/FAIL/SKIPPED]: {overall_score}
/ship to create a PR."/orbit, WARN proceeds to Ship without asking./go, then re-run /eval."epic eval records its Overall verdict for the evolution loop itself, as a verified verdict (SKIPPED records nothing). Do not also run record-verdict --source eval: a typed eval verdict only counts half and would duplicate the measured one.
epic eval --baseline-update # if user approves this as new baseline
Results auto-saved to $EPIC_PROJECT_DIR/eval/results/EVAL-{timestamp}.json.
| Excuse | Rebuttal | What to do instead |
|---|---|---|
| "Tests pass, no need for eval" | Tests pass today but regress tomorrow without baselines | Run eval and establish a baseline |
| "Performance testing is premature" | Latency regressions are invisible until users complain | Enable performance dimension, run benchmarks now |
| "Mutation testing is too slow" | Slow mutation catches bugs fast tests miss | Run on changed modules only (--dimension correctness) |
| "LLM-as-judge is subjective" | Subjective beats absent — fixed rubric + averaging reduces variance | Use the 4-axis rubric, average across 3+ files |
| "We can add eval later" | Later never comes; regressions accumulate silently | Start with correctness+quality, add dimensions incrementally |
| "CI will catch regressions" | CI only catches build/test failures, not quality drift | Eval measures what CI misses: mutation score, LLM quality |
epic eval --json output captured (all enabled dimensions scored)$EPIC_PROJECT_DIR/eval/results/epic eval outputWhat SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
eval, regression, quality-gate, baseline-comparison, performance-testing
npx claudepluginhub epicsagas/epic-harness --plugin epic27 skills in this plugin
/agent-introspectionLoop-breaking self-diagnosis. Use when 3+ consecutive failures occur, circular retries persist, or context overwhelms the session./auditAudit phase. Parallel review: code quality + security + tests + runtime behavior probe. Read-only evaluator agents. Semantic dedup of cross-mode findings. Outputs PASS/WARN/FAIL per dimension. Validates spec coverage./commitConventional Commits 1.0 generator. Stages relevant files, infers type(scope): description, never uses --no-verify./contextWorking-state snapshot guidance. Restates task/files/decisions in one block so state survives context compaction. Compaction timing is the host's job./council4-voice parallel deliberation (Architect · Skeptic · Pragmatist · Critic) for architecture, tech selection, or design decisions with no clear answer. Anti-anchoring: each voice gets independent context. Records decision in harness-mem./_criticHarnessX Critic (Tier 2.1) — adversarial review of evolved-skill proposals against trace evidence. Detects reward hacking and manifest/evidence contradictions. Out-of-band LLM counterpart to the in-loop deterministic critic in src/evolve/critic.rs.Other plugins' skills for the same job