---ci---
phase: 7
milestone: v0.1
status: verify
persona: ci-lead-developer
requirements:
covered: [REQ-67, REQ-68]
partial: []
---/ci---
Four-layer verification of P7. Structural: AskSuggestions below the
form (click fills the box, no router.push in the path), refine
exchange state machine with all controls, boundary methods + mock
impls documented with v0.2 mappings, ask-form fully retired.
Behavioral: 86/86 (coverage — open-only suggestions, no-auto-submit,
disabled-without-draft, full exchange, skippable optionals, keep-
original, escape, 3-click on AskView). Security: no secrets/env/
innerHTML, user input renders as text nodes, import discipline
clean. Quality: both features opt-in; honest captions; tokens only.
P1s fixed in-phase (verify agent, +2 regression tests, suite 86→88):
- Enter-in-drawer: the section-level keydown guard correctly blocks
outer-form submission (probe-proven), but a jsdom blind spot left
it unpinned — guard added directly on the input (defense in depth)
and pinned by test
- Focus stranded on <body> after drawer close — triggerRef focus
return per the house pattern (avatar→UserMenu), pinned by test
P2 logged: getRefinementQuestions ignores the draft (documented,
v0.2 territory). Gates re-run green: typecheck, lint 0/0, 88/88,
build.
---ci---
phase: 7
milestone: v0.1
status: execute
persona: frontend-engineer
task: T-7.2
requirements:
covered: [REQ-67, REQ-68]
partial: []
---/ci---
/ask restructured: AskView (client) owns question+context state;
AskForm retired (its tests move to AskView; the 3-click test drives
AskView — criterion green, suggestions/refine are opt-in).
REQ-67 AskSuggestions: open questions from past runs as clickable
cards (question + 'From your research — <report title>'
attribution); click fills the question box for editing, never
auto-submits; honest empty state ('they collect here as you run
research').
REQ-68 RefineQuestionButton + RefineDrawer: disabled until a draft
exists; inline drawer (dials-drawer pattern) shows the draft, asks
the scripted clarifying questions one at a time (progress n/3,
required scope vs skippable decision/depth, Enter submits), then
previews the composed refined question + suggested context; Use
this fills the form, Restart re-runs, Keep original / Escape leaves
the draft untouched; honest 'scripted in the prototype' caption.
Tests: 8 AskView suites (submit carry, suggestions render/join,
click-fills-box no-auto-submit, refine open/compose/skip/keep/
escape) + 6 boundary; 3-click re-pinned on AskView. Gates: lint
0/0, typecheck, 86/86, build. README documents both affordances.
---ci---
phase: 7
milestone: v0.1
status: execute
persona: frontend-engineer
task: T-7.1
requirements:
covered: []
partial: [REQ-67, REQ-68]
---/ci---
Types: SuggestedQuery (question + source run/report attribution),
RefinementQuestion (prompt/placeholder/optional), RefinedQuestion
(question + context). ApiClient gains getSuggestedQueries (v0.2:
GET /api/suggestions), getRefinementQuestions (v0.2: POST
/api/refine/questions), composeRefinedQuestion (v0.2: POST
/api/refine/compose — model-driven there, deterministic here).
Mock: suggestions derive live from OPEN taskInboxFixture items
joined with reportLibraryFixture for titles — done items drop
automatically; refine exchange is a scripted 3-question set
(scope/decision/depth) with a composer that weaves the scope into
the question and the optional answers into context, degrading
gracefully on skips. 6 boundary tests; gates green (81/81).