Commit 8d92e37
chore(faithfulness): smoke-test helper + enable judge for self-dogfood (#38)
Follow-up to the polish-fact-check Phase 3 PR (#36) that landed
the faithfulness judge. This commit adds the local helpers used
to smoke-test the judge end-to-end without paying for a full
attune-author regenerate cycle.
Two changes:
1. scripts/test_faithfulness.py
Tiny harness that picks the smallest feature in features.yaml
(fewest source files) and regenerates its 3 core kinds
(concept/task/reference) with telemetry-reset + summary-print
+ review-block detection. Cost on Haiku 4.5 ≈ $0.03 per run.
Refuses to run without ANTHROPIC_API_KEY in env.
Usage:
uv run python scripts/test_faithfulness.py
uv run python scripts/test_faithfulness.py <feature_name>
2. pyproject.toml: enable the judge for attune-author's own
self-dogfood help regeneration. With this, anyone running
`attune-author regenerate` against attune-author with auth
available exercises the Phase 3 pipeline end-to-end —
matches the pattern attune-author already uses for the
polish pass (live API calls during dogfood).
Configured on Haiku 4.5 (~1/3 the cost of Sonnet 4.6) since
the threshold + budget defaults are pre-calibration and a
cheaper model is fine for the initial measurement pass.
Why ship this as a follow-up rather than baking it into #36:
the Phase 3 PR was scoped to the implementation + tests; the
spec defines `enabled=false` as the global default (opt-in,
since the judge makes real API calls). Flipping it on for the
attune-author repo itself is a per-project preference, not a
default change. Same shape as how attune-author has always
defaulted polish-strict on for its own dogfood while the
package default is lenient.
Post-Phase-0 of the sibling-subscription-auth spec
(attune-ai PR #406), this also exercises the subscription-
routing path for Claude Code users — though the wire-up to
actually use claude_agent_sdk lives in Phase 1, which hasn't
shipped yet, so today this still requires ANTHROPIC_API_KEY.
Co-authored-by: Claude Opus 4.7 <noreply@anthropic.com>1 parent 829f03f commit 8d92e37
2 files changed
Lines changed: 140 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
115 | 115 | | |
116 | 116 | | |
117 | 117 | | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
118 | 126 | | |
119 | 127 | | |
120 | 128 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
0 commit comments