"use client"; import React from "react"; import { loadInvestigation, clearInvestigation } from "@/lib/storage/investigation-storage"; import Link from "next/link"; const INVESTIGATION_ID = "case-1"; function Portfolio() { const [existing, setExisting] = React.useState(null); React.useEffect(() => { setExisting(loadInvestigation()); }, []); const hasReport = Boolean( existing?.investigationReport && existing.investigationReport.understanding ); return (

Confidence Engine

Investigator's notebook — index of persisted investigations.

{/* Existing investigation */} {existing && (

Investigations

{existing.scenario || "Untitled investigation"}

{hasReport ? ( View report ) : null} Continue investigation
)} {/* No existing investigation */} {!existing && (

Investigations

No investigations yet.

)} + Create new investigation
); } export default Portfolio;