feat(confidence-engine): v0.59b-c — report freshness on Report page + Portfolio
v0.59b — Report page freshness UI: - Shows Current / Update available beside the generated report - Manual Update report action with duplicate prevention guard - Explanation copy about investigation changes since generation - Persists generatedFromRevision during update flow v0.59c — Portfolio Report freshness state: - Surfaces Current / Update available alongside existing View report link - Derives solely from revision provenance (zero model calls) - No Update report action on Portfolio (manual update owned by Report page) - Neither state shown when no Report exists - Updated makeSnapshot with investigationRevision for realistic test data
This commit is contained in:
+32
-2
@@ -85,6 +85,23 @@ RAW USER EVIDENCE
|
||||
- Restart clears Investigation + Report via `clearInvestigation()` + `setInvestigationRevision(0)`.
|
||||
- Report history/comparison remains deferred beyond MVP.
|
||||
|
||||
### v0.59b — Report freshness UI on the Report page
|
||||
|
||||
- Report page shows `Current` (matching revisions) or `Update available` (differing revisions).
|
||||
- Manual `Update report` action on Report page triggers regeneration via `/api/cases/overview`.
|
||||
- Duplicate prevention guard during in-flight update.
|
||||
- No automatic regeneration.
|
||||
- Explanation copy: "The investigation has changed since this report was generated."
|
||||
|
||||
### v0.59c — Report freshness state surfaced on the Portfolio
|
||||
|
||||
- Portfolio surfaces `Current` / `Update available` alongside existing View report link.
|
||||
- Derives freshness solely from revision provenance (`investigationReport.generatedFromRevision === investigationRevision`).
|
||||
- Zero model calls during Portfolio render.
|
||||
- No mutation of Investigation.
|
||||
- No `Update report` action on the Portfolio — manual Report updating remains owned by the Report page.
|
||||
- If no Report, neither freshness state is shown.
|
||||
|
||||
**Semantic transitions that advance revision:**
|
||||
```
|
||||
Episode Done (with content) → +1
|
||||
@@ -120,6 +137,21 @@ Reconstruct CU when canonical meaning or eligible evidence set changes — NOT w
|
||||
- **Temporary identity:** `case-1`. True multi-investigation persistence/identity is future work.
|
||||
- **Portfolio client hydration:** Portfolio page uses `'use client'` — initial pre-hydration empty state ≠ absence of persisted data. Always wait for hydrated semantic controls before classifying state.
|
||||
|
||||
## MVP boundaries (v0.59b)
|
||||
|
||||
**Implemented in MVP:**
|
||||
- visible Report freshness state (`Current` / `Update available`)
|
||||
- explanation that the Investigation has changed since Report generation
|
||||
- manual `Update report` action (user-triggered)
|
||||
- no automatic regeneration
|
||||
- duplicate prevention guard during in-flight update
|
||||
|
||||
**Deferred beyond MVP:**
|
||||
- Report history
|
||||
- retaining multiple Reports
|
||||
- Report comparison
|
||||
- modelling/preview comparison between Investigation revisions
|
||||
|
||||
## Current development / verification constraints
|
||||
|
||||
- Canonical dev server at `http://localhost:3000`. Never start/stop/restart/probe it. If unavailable → BLOCKED and stop.
|
||||
@@ -136,8 +168,6 @@ Reconstruct CU when canonical meaning or eligible evidence set changes — NOT w
|
||||
|
||||
- Multi-investigation portfolio (search/tag/archive/group)
|
||||
- Durable investigation identities beyond `case-1`
|
||||
- Visible Report freshness UI (revision comparison display — backend tracking in place)
|
||||
- "Update report" action (manual regeneration only)
|
||||
- Export/copy of Reports to Jira or external document
|
||||
- Portfolio expansion beyond one canonical investigation
|
||||
- Report history / comparison
|
||||
|
||||
Reference in New Issue
Block a user