docs(research): plan isolated candidate reproduction correction

This commit is contained in:
Boki 2026-10-27 14:31:15 -04:00
parent 610dcfcebc
commit 8807d9e504
5 changed files with 52 additions and 4 deletions

View file

@ -1,6 +1,6 @@
# Revised development roadmap
Current follow-up: [real-data research workflow](real-data-research.md). RP11/RP12 complete the verified partial-read recovery fixes. CL01–CL20 are independently accepted. RP01 adds scoped stored-source inspection; RP02 completed nine retained real-data runs after explicit strategy approval, exact reproduction and an evidence-linked finding reopened in the web app. RP03 adds explicit declared-session preparation with read-only two-session source verification; RP04 explains the retained evaluation horizon beside CAGR. RP05 enables older-page and known-hash dataset reuse; RP06 preserves settings and captured retention retries across same-backtest tabs/run URLs. RP07 downloads validated original datasets; RP08 downloads their original run results for local exploration. RP09 protects publication/clone custody during backtest handoff; RP10 preserves experiment choices when a linked template fails to load. RP11 preserves exact hypothesis links during unrelated history failures; RP12 keeps run history selectable while metrics load and retry. All 77 scheduled tasks across the original backlog and extensions are accepted; 7 conditional tasks and 4 merged redirects remain. CL21 and performance extensions remain deferred. Historical milestones below remain evidence, not a new activation request.
Current follow-up: [real-data research workflow](real-data-research.md). RP13 corrects a verified browser/backend mismatch blocking unreviewed candidate reproduction; RP11/RP12 are complete. CL01–CL20 are independently accepted. RP01 adds scoped stored-source inspection; RP02 completed nine retained real-data runs after explicit strategy approval, exact reproduction and an evidence-linked finding reopened in the web app. RP03 adds explicit declared-session preparation with read-only two-session source verification; RP04 explains the retained evaluation horizon beside CAGR. RP05 enables older-page and known-hash dataset reuse; RP06 preserves settings and captured retention retries across same-backtest tabs/run URLs. RP07 downloads validated original datasets; RP08 downloads their original run results for local exploration. RP09 protects publication/clone custody during backtest handoff; RP10 preserves experiment choices when a linked template fails to load. RP11 preserves exact hypothesis links during unrelated history failures; RP12 keeps run history selectable while metrics load and retry. All 77 scheduled tasks across the original backlog and extensions are accepted; 7 conditional tasks and 4 merged redirects remain. CL21 and performance extensions remain deferred. Historical milestones below remain evidence, not a new activation request.
## Cleanup implementation — October 26, 2026

View file

@ -8,7 +8,7 @@
[manifest.json](manifest.json) owns scheduling metadata: status, priorities, dependencies, ADR approvals, assignments and write locks. Task Markdown owns implementation scope/evidence/acceptance. This index and the [graph](dependencies.mmd) are derived views. Only the planning/integration owner updates scheduling state.
**Current total: 88 retained IDs — 77 done, 7 deferred, 4 merged.** RP01–RP12 add the authorized real-data workflow and its dataset reuse, export and workflow recovery follow-ups. The earlier 68 IDs retain their state. E11 adds seven authorized cleanup tasks and one conditional replay extraction; see the manifest for current scheduling. The original backlog accounted for 55 IDs. F09/P07 added projection/profiling work; the owner deferred P08's TypeScript optimization. Merged records preserve traceability; never execute them separately. Deferred work requires its stated trigger and explicit activation.
**Current total: 89 retained IDs — 77 done, 1 in progress, 7 deferred, 4 merged.** RP01–RP13 add the authorized real-data workflow and its dataset reuse, export and workflow recovery follow-ups. The earlier 68 IDs retain their state. E11 adds seven authorized cleanup tasks and one conditional replay extraction; see the manifest for current scheduling. The original backlog accounted for 55 IDs. F09/P07 added projection/profiling work; the owner deferred P08's TypeScript optimization. Merged records preserve traceability; never execute them separately. Deferred work requires its stated trigger and explicit activation.
States: ready, claimed, in_progress, review, done, blocked, deferred, merged. “Ready” means no code/ADR prerequisite, not execution authority. Implementation dependencies require accepted integration. `release_gates` govern enabling an end-to-end feature, not component coding or integration; conditional gates apply only to the named capability. F05 may integrate before F06, but its replay behavior is not released until F06 proves it.
@ -177,3 +177,5 @@ Owner authorized planning and per-task implementation commits. [Execution plan a
- [RP11: Partial hypothesis-history recovery](tasks/RP11.md) — done, `32f40ee7`; retain verified exact links despite unrelated history errors.
- [RP12: Available run history](tasks/RP12.md) — done, `a050c710`; keep saved runs selectable while optional metrics load.
- [RP13: Isolated candidate reproduction](tasks/RP13.md) — in progress; accept the existing null-review candidate preview without weakening built-in approval checks.

View file

@ -302,3 +302,6 @@ flowchart TD
R04 --> RP11
W01 --> RP12
R12 --> RP13
A02 --> RP13

View file

@ -1,8 +1,8 @@
{
"schema_version": 1,
"plan_revision": "2026-10-27.100",
"plan_revision": "2026-10-27.101",
"repository_base": "b7aeca4",
"plan_status": "partial_read_recovery_complete",
"plan_status": "candidate_reproduction_recovery_in_progress",
"execution_authorized": true,
"execution_scope": {
"authorized_by": "Owner: commit and continue with the rest of the tasks till 100%",
@ -3417,6 +3417,30 @@
"integration_base": "f4cee5affa257660c1ebb5f8b93f411eddb58ee0",
"reviewer": "/root/review_recovery_changes",
"review_notes": "Independent review accepted: 41 focused tests / 344 assertions. Root repository check passed: 1347 integration and 150 Rust tests. Complete Chromium suite passed: 21 scenarios / 750 assertions, including both partial-read regressions. Application/authored types, lint, formatting and build passed; real-data-research.md records exact evidence."
},
{
"id": "RP13",
"title": "Restore browser reproduction of isolated candidate runs",
"epic": "E12",
"priority": "P1",
"severity": "High",
"status": "in_progress",
"dependencies": [
"R12",
"A02"
],
"decision_dependencies": [],
"task_file": "backlog/tasks/RP13.md",
"complexity": "S",
"assignment": "/root/audit_recovery_next",
"write_locks": [
"candidate-reproduction-preview"
],
"blocker": null,
"integration_state": "pending",
"completion_evidence": "real-data-research.md",
"release_gates": [],
"review_status": "pending"
}
],
"review_note": "Independent skeptical revision: four superseded tasks retain stable IDs; deferred work is not a dependency of scheduled tasks. Release gates are distinct from implementation prerequisites.",

View file

@ -0,0 +1,19 @@
# RP13 — Restore browser reproduction of isolated candidate runs
Parent E12. Priority P1 / High workflow defect. Complexity S. Dependencies R12 and A02. Owner continuation authorizes this correction to existing research behavior.
Verified baseline: `backtestApiV2.reproductionPreview` requires a non-null `currentReviewId` for every available preview. `verifyReproductionInputs` deliberately allows an unreviewed candidate in isolation, returning null, while built-ins require approval. The browser therefore rejects a valid candidate preview and disables confirmation. `/tmp/stock-bot-rp13-baseline.log` records the failing actual component/transport regression using a schema-valid candidate. `test/postgres/isolated-candidates.test.ts` already exercises null-review reproduction, economic matching, explicit revocation and retained receipts.
Scope: apply the existing origin-specific review requirement in browser validation; show absent candidate review as absent, without implying approval or a failed eligibility check. Correct the shared preview field comment. Preserve full request/runtime validation, exact original identity, backend eligibility, frozen receipt retries and built-in approval checks. No change to isolation, financial semantics, reproduction admission, paper/live permissions or legacy behavior. No new endpoint or strategy abstraction.
Ownership: implementation agent owns `apps/stock/web-app/src/features/backtest/services/backtestApiV2.ts`, `components/RunReproduction.tsx` under the same feature, `apps/stock/config/src/contracts/canonical-research.ts` (comment only), and `test/integration/run-reproduction-ui.test.tsx`. Root owns shared browser/real PostgreSQL regressions, planning records and commits. Independent review required. Other discovered navigation defects are separate work.
Acceptance/tests:
- An available schema-valid candidate preview with null original/current review opens the exact retained inputs and enables explicit reproduction. Preview alone performs no write.
- Reviewed candidates still work; built-ins without current approval remain rejected. Unavailable/revoked candidates, incompatible runtime payloads and wrong run/parent identities cannot authorize a fresh submission.
- Candidate submission uses only the original run and the existing idempotency key. An uncertain response retries that exact receipt without using edited template settings.
- The browser completes an unreviewed candidate reproduction through the existing durable isolated runner, reopens the server's economic-match result and preserves original provenance. No human approval is created by reproduction.
- Existing PostgreSQL candidate reproduction and revocation/receipt tests continue passing; original built-in browser reproduction remains covered.
Gates: focused reproduction UI/API tests, application/authored types, lint/build, root repository check, focused disposable PostgreSQL candidate regression, and the full browser suite. No development runs or paper/live activation; conditional performance tasks stay deferred.