Repository navigation
Description
Summary
/assess posts a fresh comment to each issue on every invocation without acknowledging prior assess comments. This causes two distinct problems:
- Stale assess comments accumulate — same issue ends up with multiple
→ ACTIONcomments, each potentially recommending a different workflow. Readers must scroll to find the latest one and reason about which is current. - Re-assessment churn is invisible — an issue assessed 3+ times without execution is a triage signal (hidden blocker, low priority, or thrash) but the skill never surfaces this.
Both problems share infrastructure: detecting prior <!-- assess:action= --> HTML markers in issue comments.
Motivation — concrete recent example
/assess 532 543 551 552 (today). Issue #532 already had two prior assess comments:
- Apr 17 (
PROCEED · spec → exec → qa) - Apr 23 (
PROCEED · exec → qa— superseded once feat(assess): default spec phase ON, remove bug/docs auto-skip #533 made spec default ON)
Today's invocation appended a third comment with no acknowledgment of the prior two. The Apr 23 comment is now actively misleading (recommends exec,qa which contradicts current behavior), and the assessment churn (3 sessions, 0 execution) is itself a signal.
Acceptance Criteria
- AC-1: Detect prior assess markers. Before posting,
/assessreads existing issue comments and parses any<!-- assess:action=... -->blocks. Implementation: extendassess-comment-parser.ts(already exists for marker reading) or document the gh-CLI step in SKILL.md. - AC-2: Supersession note in new comment. When prior assess markers exist, the new comment includes a one-line header:
Supersedes prior assess from <date> (<prior-action>). Multiple prior assessments → list the most recent one and note the count:Supersedes 2 prior assessments (most recent: <date>). - AC-3: Churn warning in
/assessoutput. When ≥3 prior assess comments exist on an issue, emit a⚠warning in the dashboard:⚠ #<N> Re-assessed N times since <first-date> without execution — possible blocker or low priority. - AC-4: User confirmation before posting when prior recommendation conflicts. If the new recommended action differs from the most recent prior action (e.g., prior was
PROCEED, new isPARK), prompt the user viaAskUserQuestionbefore posting. Skip the prompt when actions match — common case is the same recommendation, repeated. - AC-5: SKILL.md documents the detection step. New section "Prior Assessment Detection" in Step 1 (Context Gathering) describing the marker scan and supersession protocol. 3-dir sync.
- AC-6: Tests. In
src/lib/__tests__/assess-skill.test.ts(or a newassess-prior-markers.test.ts):- Issue with 0 prior assess comments → no supersession header
- Issue with 1 prior matching action → supersession header references that date, no churn warning
- Issue with 3+ prior comments → churn warning fires
- Issue with prior
PROCEEDand newPARK→ confirmation flow triggers (test the prompt detection, not the user response)
- AC-7: CHANGELOG entry under
[Unreleased] / ### Added.
Non-Goals
- Not auto-editing or deleting prior assess comments. The append-only history is valuable for audit. New comments add context; they don't rewrite history.
- Not detecting or de-duplicating across
/solve(deprecated alias) — markers from both invocations use the sameassess:action=prefix already.
Risks / Open Questions
- Stale-marker false-positive. A prior assess from 30+ days ago may have been correct at the time but stale now. The supersession note explicitly handles this (it's labeling the new as authoritative). The churn warning needs a "last activity" tiebreaker — if the issue body or labels were edited between assess comments, the prior assessment may have been correctly invalidated, not churn.
- Comment ordering / pagination.
gh issue view --json commentsreturns all comments. For issues with hundreds of comments (rare in this repo), parsing every comment for markers is cheap but worth a quick measurement. - AC-4 prompt fatigue. If users frequently re-assess with conflicting actions (e.g., flipping PROCEED→PARK→PROCEED on a flaky issue), the confirmation becomes annoying. Mitigation: only prompt when prior action ∈ {PROCEED, REWRITE} — skip prompts for CLOSE/PARK/CLARIFY since those are rarely "wrong" to revisit.
Complexity
medium — adds detection logic + output annotations + user-prompt flow + tests. Skill prompt + parser + 3-dir sync.
Self-assessed workflow
spec → exec → qa with -q (multi-file: skill changes + parser + tests + CHANGELOG)
Related
- Discovered during
/assess 532 543 551 552session 2026-04-26 - Related to feat(assess): emit minimal command flags — drop default --phases, prefer additive flags #554 (assess command output ergonomics)
Activity
admarble commentedon Apr 26, 2026
Spec — Implementation Plan
Complexity: Standard (7 ACs, 5 directories) · Scope:⚠️ SCOPE_WARNING (yellow on AC count + dir spread; quality loop auto-enables) · Workflow:
spec → testgen → exec → qa -qAcceptance Criteria with verification methods
findAllAssessCommentsreturns priors in chronological order. (Unit Test)buildSupersessionHeaderproducesSupersedes prior assess from <date> (<action>)for 1 prior, count form for ≥2. (Unit Test)detectChurnfires⚠ Re-assessed N times since <date>...only when ≥3 priors and no exec markers between first prior and now. (Unit Test)shouldPromptOnConflictreturns true only when prior action ∈ {PROCEED, REWRITE} AND differs from new action. (Unit Test)assess-prior-markers.test.tscovers all 4 enumerated cases. (Unit Test — itself)[Unreleased] / ### Addedentry referencing feat(assess): detect prior assess markers — supersession note + re-assessment churn warning #555 and new exports. (Manual)Implementation outline
src/lib/assess-comment-parser.ts): addfindAllAssessComments,buildSupersessionHeader,detectChurn,shouldPromptOnConflict+ types.src/lib/__tests__/assess-prior-markers.test.ts): 4 cases from AC-6. Extendassess-skill.test.tswith sub-section presence assertion.[Unreleased] / ### Addedentry.Key decisions
.sequant/state.jsonsync problem.Conflict risk
Sibling worktrees
feature/554andfeature/556also touch/assessSKILL.md (different sections). Recommend merge in numeric order or coordinate via/merger.Open questions
admarble commentedon Apr 26, 2026
--- DRAFT GITHUB ISSUE COMMENT (PROGRESS UPDATE) ---
Exec — Implementation Complete
Branch:
feature/555-feat-assess-detect-prior-assess-markers-supersessiPR: #558
Commit: e35416d
AC Coverage
findAllAssessCommentschronological ordersrc/lib/assess-comment-parser.ts:194+ testbuildSupersessionHeader1- vs N-prior formssrc/lib/assess-comment-parser.ts:520+ 4 testsdetectChurn≥3 priors w/o intervening execsrc/lib/assess-comment-parser.ts:556+ 6 testsshouldPromptOnConflictPROCEED/REWRITE onlysrc/lib/assess-comment-parser.ts:597+ 5 testsassess-prior-markers.test.tscases[Unreleased] / ### AddedCHANGELOG.md:11Files Changed
src/lib/assess-comment-parser.ts(+133 lines: 4 new exports + helpers)src/lib/__tests__/assess-prior-markers.test.ts(new, 17 tests).claude/skills/assess/SKILL.md,skills/assess/SKILL.md,templates/skills/assess/SKILL.md(each +20 lines, identical)CHANGELOG.md(1 line under[Unreleased] / ### Added)Quality Plan Alignment
formatAssessDategracefully handles missing/unparseable timestamps;shouldPromptOnConflictreturns false on undefinedChecks
npm run build— passesnpm run lint— passes (0 warnings)npx vitest run src/lib/— 1997 tests pass across 75 filesKnown Gaps / Open Questions
/qa: real issue with 1+ prior assess comments needed to verify supersession-header rendering, churn warning placement in dashboard, andAskUserQuestionflow integration. Parser-layer tests cover the predicates; the consuming SKILL.md prose is the integration path.Pre-PR Confidence Check
/assessskill's actual consumption of these functions lives in LLM-interpreted markdown, not unit-testable code. A real/assessinvocation against an issue with priors is the only way to validate the integration.admarble commentedon Apr 29, 2026
QA Review for Issue #555
Branch:
feature/555-feat-assess-detect-prior-assess-markers-supersessiPR: #558 · Commit: e35416d
AC Coverage
findAllAssessCommentsreturns priors in chronological orderassess-comment-parser.ts:200; preserves input order viafilter; tests atassess-prior-markers.test.ts:39-62buildSupersessionHeader1-prior vs ≥2-prior formatassess-comment-parser.ts:528; 4 tests including unknown-action fallbackdetectChurnfires only ≥3 priors AND no exec marker after first priorassess-comment-parser.ts:564; 6 tests including exec-before/after edge casesshouldPromptOnConflicttrue only when prior ∈ {PROCEED, REWRITE} AND differsassess-comment-parser.ts:608; 5 tests including all 4 non-prompting prior actionsdiffconfirms identical contentassess-prior-markers.test.tscovers 4 enumerated cases[Unreleased] / ### Addedentry referencing #555 + new exportsCHANGELOG.md:12; names all 4 new exports and #555Coverage: 7/7 AC items fully met
Original ACs: 7/7 met · Derived ACs: 0 (no quality plan derived ACs in spec comment)
Quality Plan Verification
Quality Plan found in exec comment (Quality Plan Alignment table):
formatAssessDatehandles missing/unparseable;shouldPromptOnConflictundefined-safe)Quality Plan Status: Complete
CI Status
build (20.x)build (22.x)typecheckvalidate-skillsvalidate-pluginPlugin Structure ValidationHooks ValidationSetup Directory CreationCI Summary: 8 passed, 0 pending, 0 failed
Quality Metrics
any) in added linesTest Coverage Analysis
src/lib/assess-comment-parser.tssrc/lib/__tests__/assess-prior-markers.test.ts(new) + siblingassess-comment-parser.test.ts.claude/skills/assess/SKILL.mdskills/assess/SKILL.mdtemplates/skills/assess/SKILL.mdCHANGELOG.mdCoverage: 1/1 changed source files have corresponding tests · Critical paths without tests: None
Local run:
npx vitest run src/lib/__tests__/assess-prior-markers.test.ts→ 17/17 passed;npx vitest run src/lib/__tests__/assess→ 22/22 passed.Code Review
Strengths:
.sequant/state.jsoncoupling) — composable and easy to test.formatAssessDatedefensively handles three failure modes (missing, unparseable, valid) with sensible fallbacks.detectChurncorrectly differentiates "true churn" from "re-assessment after exec" via timestamp comparison against the first prior.shouldPromptOnConflictpredicate scoped tightly to {PROCEED, REWRITE} priors — flipping away from PARK/CLOSE/CLARIFY/MERGE doesn't generate noisy prompts.diff— all three SKILL.md files identical.findAllAssessComments.Issues:
/assessruns depend on the LLM threading the protocol from Step 1 into the posting step many sections later.Suggestions:
SKILL.md:619block) — "IffindAllAssessCommentsreturned ≥1 prior, prependbuildSupersessionHeader(priors)immediately above the→ ACTION — reasonline." (3-dir sync.)/assess 532(which has 3 prior assess comments, per the issue body's motivating example) would be the canonical smoke test before merge.Test Quality Review
IssueComment[]fixturesIssues Found: None.
Anti-Pattern Detection
Dependency Audit
N/A —
package.jsonnot modified.Code Patterns
Critical Issues: 0 · Warnings: 0
Call-Site Review
New exported functions detected: 4 (
findAllAssessComments,buildSupersessionHeader,detectChurn,shouldPromptOnConflict)findAllAssessCommentsbuildSupersessionHeaderdetectChurnshouldPromptOnConflictFindings: This is by design per the issue body ("extend
assess-comment-parser.ts... or document the gh-CLI step in SKILL.md"). The functions are predicates that the/assessskill prose invokes mentally / vianpx tsx -epatterns. No TypeScript caller exists yet because no other Sequant feature consumes them — the predicates are the surface, the skill is the consumer.Recommendations: None for this PR. If a future skill or script needs to call these from TypeScript, the API surface is stable.
Execution Evidence
N/A — no
scripts/or CLI files modified. Parser file is library code, exercised by unit tests.npm run buildandnpm run lintpass on the worktree.Skill Command Verification
Skill files changed: 3 (all identical via 3-dir sync)
.claude/skills/assess/SKILL.md(sub-section)skills/assess/SKILL.mdtemplates/skills/assess/SKILL.mdThe new sub-section references 4 TypeScript exports (function names), not shell commands. All 4 exist at the documented locations in
src/lib/assess-comment-parser.ts:findAllAssessComments→ line 200buildSupersessionHeader→ line 528detectChurn→ line 564shouldPromptOnConflict→ line 608Verification Status: Passed
Skill Change Review
gh issue view --commentspattern already used elsewhere in the skill.Smoke Test
npm run build(in worktree)npm run lintnpx vitest run src/lib/__tests__/assess-prior-markers.test.tsnpx vitest run src/lib/__tests__/assessassess-comment-parser.test.tsorassess-skill.test.tsdiffacross.claude/skills/,skills/,templates/skills//assessagainst issue with priors/assess 532(3 priors per the motivating example) before merge.Smoke Test Status: Partial — code-level checks complete; live
/assessdogfooding deferred.Manual Test ACs
AC-5 was tagged (Manual + smoke test) and AC-7 was tagged (Manual) in the spec.
/assesssmoke deferreddiff; live invocation against an issue with priors not runCHANGELOG.md:12reviewed — entry under[Unreleased] / ### Added, references #555 and all 4 new exportsManual Test Override (AC-7 only)
AC: AC-7
Requirement: Manual review of CHANGELOG entry
Override: No — verified statically (CHANGELOG entries have no runtime surface)
Risk Assessment: None
AC-5 is not overridden — the live
/assesssmoke test is recommended before merge but does not strictly block it because the AC text only requires the sub-section + 3-dir sync, both of which are verified.CHANGELOG Verification
feat:commit)[Unreleased]entryResult: CHANGELOG requirements met.
Risk Assessment
/assessinvocation against an issue with priors does not prepend the supersession header, because the LLM read Step 1 as descriptive context but never threaded it into the Persist Analysis step many sections away. The Output Verification checklist also has no item asserting the header was applied. Predicate logic is correct; the integration risk is markdown comprehension under long-context skill execution./assessdogfooding against an issue with ≥1 prior assess comment (e.g., docs: document force-push handoff pattern when pre-tool hook blocks #532). The 17 unit tests cover the predicates; nothing covers the LLM-prose integration path. This was acknowledged as the weakest part in the exec comment's Pre-PR Confidence Check.Verdict: AC_MET_BUT_NOT_A_PLUS
All 7 ACs are literally satisfied: predicates exist with correct semantics, tests pass (17 new + 22 in assess suite, 8/8 CI green), 3-directory skill sync preserved, CHANGELOG entry present, no
anytypes or deleted tests, build & lint clean. Quality plan dimensions (error handling, test coverage, code quality, best practices) are all complete.The verdict is held back from
READY_FOR_MERGEby two related, low-cost gaps:/assessdogfooding. Running/assess 532(the motivating example, with 3 prior assess comments) is the canonical smoke test for AC-5's (Manual + smoke test) tag. The exec author flagged this explicitly.Either tightening the Persist Analysis cross-reference or completing the dogfooding would lift this to
READY_FOR_MERGE.Documentation
[Unreleased] / ### Added)Documentation: Before merging, run
/docs 555if a public-facing documentation page is desired (likely not required — this is an internal skill enhancement).Next Steps
SKILL.mdfiles: "IffindAllAssessCommentsreturned ≥1 prior, prependbuildSupersessionHeader(priors)immediately above the→ ACTION — reasonline; emit a⚠ Re-assessed N times since <firstDate>...warning whendetectChurn(...).isChurn === true."/assess 532(3 priors, per the issue body) and confirming: supersession header rendered, churn warning fires, conflict prompt does not falsely trigger./qa 555after the above; verdict should reachREADY_FOR_MERGE.docs(#555): cross-reference supersession protocol in Persist Analysis…
admarble commentedon Apr 29, 2026
/fullsolve Complete
Issue: #555
PR: #558 · Branch:
feature/555-feat-assess-detect-prior-assess-markers-supersessiLatest commit:
1c9b24aPhase Progress
AC Coverage
findAllAssessCommentschronologicalassess-comment-parser.ts:200+ 4 testsbuildSupersessionHeader1- vs N-priorassess-comment-parser.ts:528+ 4 testsdetectChurn≥3 priors w/o execassess-comment-parser.ts:564+ 6 testsshouldPromptOnConflictPROCEED/REWRITEassess-comment-parser.ts:608+ 5 testsassess-prior-markers.test.tscases[Unreleased] / ### AddedCHANGELOG.md:12Coverage: 7/7 AC fully met
Quality Loop Resolution
The prior QA noted two gaps blocking READY_FOR_MERGE:
buildSupersessionHeader,detectChurn, andshouldPromptOnConflictwith link back to Step 1.3-dir sync verified via
diffacross.claude/skills/,skills/,templates/skills/. Lint, build, and 22 assess tests all pass on the new commit.Quality Metrics
anyintroducednpx skills-ref validatepassesRisk Assessment
/assessinvocation might not prepend the supersession header because the LLM only saw the protocol in Step 1's context-gathering section, far from where the comment is constructed. The new commit threads the protocol through Persist Analysis and Output Verification, closing the integration loop./assessdogfooding against an issue with ≥1 prior assess comment (e.g., docs: document force-push handoff pattern when pre-tool hook blocks #532). Parser predicates are 100% unit-tested; the LLM-prose integration is now documented at three call-sites instead of one. Recommend a real-issue smoke test before declaring the feature dogfooded — but the SKILL.md cross-references give the next reader explicit instructions.CI Status
8/8 checks were SUCCESS on
e35416d. New commit1c9b24a(docs-only, 9 line additions) is running CI now; expected to pass given no source/test code changed.Final Verdict: READY_FOR_MERGE
All 7 ACs literally satisfied, both QA gaps closed, CI green on prior commit, no source-level changes in the loop fix. PR #558 ready for human review and merge.
fix(#555): detect dashboard-format assess comments via HTML action ma…
admarble commentedon Apr 30, 2026
QA Review for Issue #555 — Fresh Run
Branch:
feature/555-feat-assess-detect-prior-assess-markers-supersessiPR: #558 · Commit:
caec418· CI: 8/8 SUCCESSAC Coverage
findAllAssessCommentschronologicalassess-comment-parser.ts:218+ 5 tests (incl. new dashboard-format)buildSupersessionHeader1-/N-priorassess-comment-parser.ts:540+ 4 testsdetectChurn≥3 priors w/o execassess-comment-parser.ts:576+ 6 tests; dogfooded against #532:{isChurn:true, count:3, firstDate:"2026-04-17"}shouldPromptOnConflictPROCEED/REWRITEassess-comment-parser.ts:620+ 5 testsdiffconfirms 3-dir identicalassess-prior-markers.test.tscases[Unreleased] / ### AddedCHANGELOG.md:12references #555, all 4 exports, HTML-marker detectionCoverage: 7/7 ACs fully met.
Resolution of Prior QA Gaps
Prior verdict was
AC_MET_BUT_NOT_A_PLUS(e35416d, 2026-04-29). Both gaps now closed:buildSupersessionHeader,detectChurn,shouldPromptOnConflict; added 2 Output Verification checkboxes1c9b24aisAssessCommentmatched only prose markers (## Assess Analysis) which production /assess output never contains. Fixed by extendingisAssessCommentto also match the durable HTML action marker `<!-- (assessBug Fixed in This Iteration
Found via dogfood, not specced: The original implementation reused
isAssessComment's prose-marker detection (## Assess Analysisetc.). Real production assess comments use the dashboard format (→ **PROCEED** — ...) with no prose header — only the HTML action marker. SofindAllAssessCommentsreturned 0 priors when run against #532's three real assess comments, defeating the feature on its literal motivating example. The 17 prior tests passed because fixtures used a synthetic body shape that combined both markers.Fix: New non-global
ASSESS_ACTION_MARKER_PATTERNregex;isAssessCommentnow matches prose markers OR the HTML action marker (durable contract). Added a verbatim-#532 dashboard-format test fixture.Quality Metrics
any)Valid skillSmoke Tests
npm run build(worktree)npm run lintnpx vitest run(full suite)npx skills-ref validatediffSKILL.mdSupersedes 3 prior assessments (most recent: 2026-04-26); churnisChurn:true; conflict prompts correct on 6 action permutationsCode Review
Strengths:
isAssessCommentbehavior change has zero regressions across the codebase.Issues: None blocking.
Suggestions:
ASSESS_ACTION_MARKER_PATTERNis correctly separated from the existing global patterns (which use/gand mutate state) — pattern hygiene is good.Risk Assessment
/assess 532invocation deferred. Reason: this Claude Code session is rooted at main (pre-fix); invoking/assess 532here would use main's still-buggyisAssessCommentand would not exercise the fix. Recommended as a post-merge smoke test from main.Verdict: READY_FOR_MERGE
All 7 ACs literally satisfied. Both prior-QA gaps resolved. End-to-end dogfood validates the feature on its literal motivating example. Full suite passes with zero regressions. 8/8 CI checks green.
Documentation
[Unreleased] / ### Added) with feat(assess): detect prior assess markers — supersession note + re-assessment churn warning #555 + all 4 new exports + HTML-marker detection noteNext Steps
/assess 532from main to confirm live-skill rendering matches the dogfooded predicate output.feat(#555): detect prior assess markers — supersession + churn + conf…