feat(confidence-engine): v0.60j preserve investigation on restart
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
// Owns the canonical identity contract: snapshot.id is the sole save identity.
|
||||
// Delegates to the concrete localStorage provider internally.
|
||||
|
||||
import { loadInvestigation as _load, saveInvestigation as _save, clearInvestigation as _clear, listInvestigations as _list } from "./providers/local-storage.js";
|
||||
import { loadInvestigation as _load, saveInvestigation as _save, clearInvestigation as _clear, listInvestigations as _list, restartInvestigation as _restart } from "./providers/local-storage.js";
|
||||
|
||||
/**
|
||||
* Canonical save contract: snapshot.id is the sole identity authority.
|
||||
@@ -40,3 +40,15 @@ export function clearInvestigation(id) {
|
||||
export function listInvestigations() {
|
||||
return _list();
|
||||
}
|
||||
|
||||
/**
|
||||
* Semantic restart: reset reasoning/report state within the Investigation container.
|
||||
*
|
||||
* The Investigation is NOT deleted or replaced. Its durable `id` and `scenario` (container)
|
||||
* are preserved. All reasoning-state fields are cleared so a new clean pass can begin.
|
||||
*
|
||||
* Missing/invalid id → silently no-op (does NOT fall back to legacy singleton).
|
||||
*/
|
||||
export function restartInvestigation(id) {
|
||||
return _restart(id);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user