2sagaco48 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/diagnostics.mjs +141 -0
- package/dist/compute.worker-j5ahIpF-.js +1 -0
- package/dist/graph.worker-DG6iGCB9.js +1 -0
- package/dist/index.html +2314 -0
- package/flatten-guide.md +248 -0
- package/index.html +12 -0
- package/package.json +38 -0
- package/src/App.orig.tsx +204 -0
- package/src/App.orig1.tsx +27 -0
- package/src/App.orig2.tsx +25 -0
- package/src/App.tsx +3 -0
- package/src/BaseApp.tsx +18 -0
- package/src/INTEGRATION_LEDGER.md +22 -0
- package/src/PERSIST_CANARY.orig.txt +1 -0
- package/src/PERSIST_CANARY.txt +1 -0
- package/src/REGRESSION_LEDGER.md +651 -0
- package/src/TEMPLATE_PIPELINE_AUDIT.md +208 -0
- package/src/WILLIAMS_PERSONA_GUIDE.md +62 -0
- package/src/chat/VeritasChat.tsx +69 -0
- package/src/chat/synthesis.ts +31 -0
- package/src/chat/tier.ts +45 -0
- package/src/components/AdaptersPage.orig.tsx +99 -0
- package/src/components/AdaptersPage.tsx +3 -0
- package/src/components/AdversarialPanel.tsx +136 -0
- package/src/components/AnchorBaselinePanel.tsx +75 -0
- package/src/components/AnswerPanel.tsx +60 -0
- package/src/components/ArtifactPanel.tsx +43 -0
- package/src/components/ChatApp.orig.tsx +1582 -0
- package/src/components/ChatApp.orig1.tsx +722 -0
- package/src/components/ChatApp.tsx +95 -0
- package/src/components/ChatAugmentPanels.tsx +73 -0
- package/src/components/CitationLedgerPanel.tsx +313 -0
- package/src/components/ComputeSandboxPanel.tsx +130 -0
- package/src/components/ConfigPanel.tsx +110 -0
- package/src/components/ControlPlanePage.tsx +195 -0
- package/src/components/CreativeTreeLifePage.tsx +234 -0
- package/src/components/CreativeTreeOfLifePanel.tsx +149 -0
- package/src/components/DebugTracePanel.tsx +137 -0
- package/src/components/DeepReasoningTrace.tsx +48 -0
- package/src/components/EntitySheetPanel.tsx +51 -0
- package/src/components/FailureModesPanel.tsx +104 -0
- package/src/components/GBSDashboard.tsx +239 -0
- package/src/components/GraphView.tsx +116 -0
- package/src/components/HUD.tsx +125 -0
- package/src/components/HypothesisPanel.tsx +67 -0
- package/src/components/InnovationGenomeEngine.tsx +792 -0
- package/src/components/InnovationPersonaGuide.tsx +348 -0
- package/src/components/InnovationPersonaPanel.tsx +289 -0
- package/src/components/LiveResourceHUD.tsx +109 -0
- package/src/components/LongWriterPanel.tsx +112 -0
- package/src/components/MainPipelineV10Bridge.tsx +72 -0
- package/src/components/MarkdownLite.tsx +63 -0
- package/src/components/MemoryInspector.tsx +38 -0
- package/src/components/MemoryMonitor.tsx +52 -0
- package/src/components/MemoryStressPanel.tsx +176 -0
- package/src/components/ModulesPage.tsx +171 -0
- package/src/components/PipelineDebugConsole.orig.tsx +1856 -0
- package/src/components/PipelineDebugConsole.tsx +3 -0
- package/src/components/PreFlightHUD.tsx +67 -0
- package/src/components/PrismaFetchTracePanel.tsx +87 -0
- package/src/components/ReportOSPanel.tsx +165 -0
- package/src/components/ResourceEstimatorPage.tsx +327 -0
- package/src/components/RichText.tsx +181 -0
- package/src/components/SagaOsPanel.tsx +605 -0
- package/src/components/SagaOsReference.tsx +421 -0
- package/src/components/SagaOsV2Panel.tsx +594 -0
- package/src/components/SagaStyleTab.tsx +382 -0
- package/src/components/SageBlueprintPanel.tsx +416 -0
- package/src/components/SharedChatInput.tsx +77 -0
- package/src/components/StatFinancePanel.tsx +190 -0
- package/src/components/StylePersonaPanel.tsx +128 -0
- package/src/components/TemplatesPage.tsx +300 -0
- package/src/components/TestPanel.tsx +63 -0
- package/src/components/TraceLog.tsx +89 -0
- package/src/components/V15CalibrationAugment.tsx +1134 -0
- package/src/components/V15CalibrationDialog.tsx +1871 -0
- package/src/components/V15Overlay.orig.tsx +120 -0
- package/src/components/V15Overlay.tsx +4 -0
- package/src/components/V15OverlayWrapper.tsx +362 -0
- package/src/components/V15Toggle.tsx +34 -0
- package/src/console/DiagnosticRecoveryPanel.tsx +358 -0
- package/src/console/EngineeringConsole.tsx +103 -0
- package/src/console/FictionSystemPanels.tsx +882 -0
- package/src/console/InspectorPanels.tsx +254 -0
- package/src/console/ManuscriptGraderPanel.tsx +182 -0
- package/src/console/RecursiveReviserPanel.tsx +245 -0
- package/src/console/SeedControlPanel.tsx +135 -0
- package/src/console/StoryControllerPanel.tsx +443 -0
- package/src/console/engineBridge.ts +258 -0
- package/src/console/gemini.ts +106 -0
- package/src/console/grading.ts +250 -0
- package/src/console/util.ts +45 -0
- package/src/fiction/continuity.ts +372 -0
- package/src/fiction/crash-protection.ts +111 -0
- package/src/fiction/diagnostics.ts +208 -0
- package/src/fiction/diff.ts +74 -0
- package/src/fiction/entity-state-machine.ts +214 -0
- package/src/fiction/nive-engine.ts +404 -0
- package/src/fiction/pipeline-selftest.ts +132 -0
- package/src/fiction/seed-control.ts +193 -0
- package/src/fiction/story-engine.ts +326 -0
- package/src/fiction/types.ts +68 -0
- package/src/flatten-guide.md +379 -0
- package/src/index.css +14 -0
- package/src/index.orig.css +13 -0
- package/src/lib/academic-sources.base.ts +188 -0
- package/src/lib/academic-sources.orig.ts +28 -0
- package/src/lib/academic-sources.ts +10 -0
- package/src/lib/advanced-math.ts +119 -0
- package/src/lib/adversarial-engine.base.ts +409 -0
- package/src/lib/adversarial-engine.ts +82 -0
- package/src/lib/ai-revision.ts +623 -0
- package/src/lib/app-state.tsx +426 -0
- package/src/lib/artifact-registry.ts +97 -0
- package/src/lib/artifacts.ts +180 -0
- package/src/lib/atlas-dr.ts +167 -0
- package/src/lib/browser-mtls.ts +127 -0
- package/src/lib/browser-queue.ts +221 -0
- package/src/lib/browser-search-scraper.base.ts +382 -0
- package/src/lib/browser-search-scraper.orig.ts +90 -0
- package/src/lib/browser-search-scraper.ts +10 -0
- package/src/lib/calc-interceptor.ts +82 -0
- package/src/lib/citation-lane-tap.ts +78 -0
- package/src/lib/citation-ledger-store.ts +369 -0
- package/src/lib/citation-ledger.ts +203 -0
- package/src/lib/compute-sandbox.ts +215 -0
- package/src/lib/compute.worker.ts +153 -0
- package/src/lib/connectors/gemini.ts +120 -0
- package/src/lib/connectors/jina.ts +233 -0
- package/src/lib/connectors/marketdata.ts +51 -0
- package/src/lib/connectors/prismafetch.base.ts +175 -0
- package/src/lib/connectors/prismafetch.ts +1 -0
- package/src/lib/connectors/serpapi.ts +65 -0
- package/src/lib/connectors/wikidata.ts +44 -0
- package/src/lib/constraints.ts +331 -0
- package/src/lib/continuation-detector.base.ts +153 -0
- package/src/lib/continuation-detector.ts +48 -0
- package/src/lib/contradraft.ts +168 -0
- package/src/lib/cors-proxy.ts +120 -0
- package/src/lib/coverage.ts +81 -0
- package/src/lib/debug/architecture-prescription.ts +556 -0
- package/src/lib/debug/covea-repair.ts +543 -0
- package/src/lib/debug/helios-ground.ts +319 -0
- package/src/lib/debug/intent-decomposer.ts +281 -0
- package/src/lib/debug/intent-lattice.ts +349 -0
- package/src/lib/debug/pipeline-diagnosis.ts +1149 -0
- package/src/lib/debug/pipeline-trace-bus.ts +424 -0
- package/src/lib/debug/prompt-forge.ts +678 -0
- package/src/lib/debug/repair-sites.ts +513 -0
- package/src/lib/debug/research-phase.ts +266 -0
- package/src/lib/debug/retrieval-context.ts +76 -0
- package/src/lib/debug/retrieval-hardener.ts +142 -0
- package/src/lib/debug/scraper-debug-runner.ts +576 -0
- package/src/lib/debug/scraper-forensics.ts +418 -0
- package/src/lib/debug/scraper-lane-roadmap.ts +136 -0
- package/src/lib/debug/self-test.ts +415 -0
- package/src/lib/debug/step-attribution.ts +211 -0
- package/src/lib/debug/template-rubric.ts +301 -0
- package/src/lib/debug/unified-innovation.ts +126 -0
- package/src/lib/debug/veritas-hybrid-scraper.ts +335 -0
- package/src/lib/defense-registry.ts +104 -0
- package/src/lib/defenses.ts +162 -0
- package/src/lib/deterministic-citation-ledger.ts +174 -0
- package/src/lib/elo-registry.base.ts +117 -0
- package/src/lib/elo-registry.ts +1 -0
- package/src/lib/entity-resolver.ts +291 -0
- package/src/lib/failure-modes.ts +267 -0
- package/src/lib/feature-registry.ts +69 -0
- package/src/lib/flaw-registry.ts +143 -0
- package/src/lib/flaws/_template.ts +52 -0
- package/src/lib/flaws/builtins.ts +63 -0
- package/src/lib/flaws/finance.ts +169 -0
- package/src/lib/flaws/fixers.ts +10 -0
- package/src/lib/flaws/index.ts +32 -0
- package/src/lib/flaws/legal.ts +157 -0
- package/src/lib/flaws/medical.ts +188 -0
- package/src/lib/flaws/original-defenses-pack.ts +81 -0
- package/src/lib/flaws/sample-declarative-pack.json +38 -0
- package/src/lib/flaws/selftest.ts +201 -0
- package/src/lib/flaws/software-extended.ts +125 -0
- package/src/lib/flaws/software-rn-webgl.ts +182 -0
- package/src/lib/flaws/statistics-advanced.ts +46 -0
- package/src/lib/flaws/statistics.ts +61 -0
- package/src/lib/gbse/config.ts +20 -0
- package/src/lib/gbse/engine.ts +226 -0
- package/src/lib/gbse/graph.ts +118 -0
- package/src/lib/gbse/graph.worker.ts +21 -0
- package/src/lib/gbse/tests.ts +117 -0
- package/src/lib/gbse/tiers.ts +65 -0
- package/src/lib/gbse/types.ts +94 -0
- package/src/lib/innovation-genome-engine-v2.orig.ts +1001 -0
- package/src/lib/innovation-genome-engine-v2.ts +3 -0
- package/src/lib/innovation-genome-engine.orig.ts +330 -0
- package/src/lib/innovation-genome-engine.ts +3 -0
- package/src/lib/innovation-genome-v10.orig.ts +314 -0
- package/src/lib/innovation-genome-v10.ts +2 -0
- package/src/lib/innovation-genome-v3.orig.ts +2015 -0
- package/src/lib/innovation-genome-v3.ts +2 -0
- package/src/lib/innovation-genome-v4.orig.ts +1959 -0
- package/src/lib/innovation-genome-v4.ts +2 -0
- package/src/lib/innovation-genome-v5.orig.ts +1210 -0
- package/src/lib/innovation-genome-v5.ts +2 -0
- package/src/lib/innovation-genome-v7.orig.ts +2549 -0
- package/src/lib/innovation-genome-v7.ts +2 -0
- package/src/lib/innovation-genome-v8.orig.ts +1485 -0
- package/src/lib/innovation-genome-v8.ts +2 -0
- package/src/lib/innovation-genome-v9.orig.ts +643 -0
- package/src/lib/innovation-genome-v9.ts +2 -0
- package/src/lib/jina.base.ts +293 -0
- package/src/lib/jina.ts +1 -0
- package/src/lib/live-telemetry.ts +61 -0
- package/src/lib/longwriter.ts +84 -0
- package/src/lib/manuscript-grade-v2.ts +298 -0
- package/src/lib/memory-governor.ts +173 -0
- package/src/lib/memory-stress-tests.ts +248 -0
- package/src/lib/model-intelligence.ts +48 -0
- package/src/lib/model-rotator.ts +75 -0
- package/src/lib/models.orig.ts +513 -0
- package/src/lib/models.ts +151 -0
- package/src/lib/n-deep.base.ts +592 -0
- package/src/lib/n-deep.ts +51 -0
- package/src/lib/nih-simulator.ts +56 -0
- package/src/lib/nih-vulnerability-fixes.ts +460 -0
- package/src/lib/omega-templates.base.ts +294 -0
- package/src/lib/omega-templates.ts +225 -0
- package/src/lib/omni-nexus.ts +64 -0
- package/src/lib/oracle-adapters.ts +67 -0
- package/src/lib/oracle-registry.ts +163 -0
- package/src/lib/orchestrator.ts +357 -0
- package/src/lib/output-boundary.ts +235 -0
- package/src/lib/overrides/vite-native-chaos-harness.ts +154 -0
- package/src/lib/overrides/vite-native-contract-plane.ts +245 -0
- package/src/lib/overrides/vite-native-doctor-plane.ts +208 -0
- package/src/lib/overrides/vite-native-knowledge-store.ts +267 -0
- package/src/lib/overrides/vite-native-policy-plane.ts +190 -0
- package/src/lib/overrides/vite-native-replay-plane.ts +197 -0
- package/src/lib/overrides/vite-native-runtime-plane.ts +106 -0
- package/src/lib/overrides/vite-native-scraper.ts +848 -0
- package/src/lib/overrides/vite-native-selftest-functional.ts +217 -0
- package/src/lib/overrides/vite-native-selftest.ts +183 -0
- package/src/lib/overrides/vite-native-snapshot-plane.ts +123 -0
- package/src/lib/philosophy-toolkit.ts +75 -0
- package/src/lib/pipeline.orig.ts +659 -0
- package/src/lib/pipeline.ts +42 -0
- package/src/lib/precache.ts +128 -0
- package/src/lib/py-sandbox.ts +205 -0
- package/src/lib/quality-score.ts +96 -0
- package/src/lib/quant-engine.ts +231 -0
- package/src/lib/quant-lib.ts +80 -0
- package/src/lib/reportos.ts +175 -0
- package/src/lib/research-os.ts +306 -0
- package/src/lib/resource-estimator.ts +114 -0
- package/src/lib/rpm-governor.ts +93 -0
- package/src/lib/runtime-estimator.ts +135 -0
- package/src/lib/sage/empty-space-v6.ts +560 -0
- package/src/lib/sage/empty-space-v7.ts +222 -0
- package/src/lib/sage/empty-space.ts +733 -0
- package/src/lib/sage/engine.ts +786 -0
- package/src/lib/sage/index.ts +17 -0
- package/src/lib/sage/judge.ts +246 -0
- package/src/lib/sage/prng.ts +53 -0
- package/src/lib/sage/reality-grounding.ts +380 -0
- package/src/lib/sage/repetition.ts +151 -0
- package/src/lib/sage/saga-os-v2-engines.ts +1870 -0
- package/src/lib/sage/saga-os-v2.ts +274 -0
- package/src/lib/sage/saga-os-v3-core.ts +1491 -0
- package/src/lib/sage/saga-os-v3-release.ts +739 -0
- package/src/lib/sage/saga-os-v4-aureate.ts +1161 -0
- package/src/lib/sage/saga-os-v4.ts +212 -0
- package/src/lib/sage/saga-os-v5.ts +205 -0
- package/src/lib/sage/saga-os-v6.ts +346 -0
- package/src/lib/sage/saga-os-v7.ts +314 -0
- package/src/lib/sage/saga-os-v8.ts +505 -0
- package/src/lib/sage/saga-os.ts +329 -0
- package/src/lib/sage/taxonomy.ts +403 -0
- package/src/lib/sage/unified-roll.ts +524 -0
- package/src/lib/sage/worked-sketches.ts +44 -0
- package/src/lib/sage.ts +166 -0
- package/src/lib/scraper-debug-bus.ts +53 -0
- package/src/lib/scraper-enhanced.orig.ts +153 -0
- package/src/lib/scraper-enhanced.ts +10 -0
- package/src/lib/scraper-hardener.base.orig.ts +155 -0
- package/src/lib/scraper-hardener.base.ts +317 -0
- package/src/lib/scraper-hardener.ts +1 -0
- package/src/lib/scraper-palisade/palisade-adjudicator.orig.ts +419 -0
- package/src/lib/scraper-palisade/palisade-adjudicator.ts +13 -0
- package/src/lib/scraper-vnext/arbiter-omega.orig.ts +688 -0
- package/src/lib/scraper-vnext/arbiter-omega.ts +13 -0
- package/src/lib/scraper-vnext/canonical-portfolio-augments.ts +479 -0
- package/src/lib/scraper-vnext/canonical-portfolio-orchestrator.orig.ts +1529 -0
- package/src/lib/scraper-vnext/canonical-portfolio-orchestrator.ts +13 -0
- package/src/lib/scraper-vnext/conclave-omega.ts +1830 -0
- package/src/lib/scraper-vnext/content-extractor-v2.ts +226 -0
- package/src/lib/scraper-vnext/diagnostics-suite.ts +36 -0
- package/src/lib/scraper-vnext/epistemic-packer.ts +97 -0
- package/src/lib/scraper-vnext/fusion-v2.ts +65 -0
- package/src/lib/scraper-vnext/hydra-reader.orig.ts +1216 -0
- package/src/lib/scraper-vnext/hydra-reader.ts +13 -0
- package/src/lib/scraper-vnext/native-scraper-browser-vnext.orig.ts +91 -0
- package/src/lib/scraper-vnext/native-scraper-browser-vnext.ts +13 -0
- package/src/lib/scraper-vnext/nexus-consensus.orig.ts +905 -0
- package/src/lib/scraper-vnext/nexus-consensus.ts +13 -0
- package/src/lib/scraper-vnext/portfolio-consensus-adjudicator.ts +804 -0
- package/src/lib/scraper-vnext/portfolio-consensus-memory.ts +377 -0
- package/src/lib/scraper-vnext/portfolio-terminal-governor.ts +548 -0
- package/src/lib/scraper-vnext/query-strategist.orig.ts +224 -0
- package/src/lib/scraper-vnext/query-strategist.ts +423 -0
- package/src/lib/scraper-vnext/retrieval-accelerator.ts +708 -0
- package/src/lib/scraper-vnext/retrieval-audit-augments.ts +477 -0
- package/src/lib/scraper-vnext/retrieval-control-plane.ts +904 -0
- package/src/lib/scraper-vnext/retrieval-policy-augments.ts +358 -0
- package/src/lib/scraper-vnext/safe-fetch-v2.ts +157 -0
- package/src/lib/scraper-vnext/sentinel-omega.ts +56 -0
- package/src/lib/scraper-vnext/sentinel-orchestrator.ts +69 -0
- package/src/lib/scraper-vnext/sibyl-oracle.orig.ts +413 -0
- package/src/lib/scraper-vnext/sibyl-oracle.ts +13 -0
- package/src/lib/scraper-vnext/smart-read-v2.ts +55 -0
- package/src/lib/scraper-vnext/spa-rescue-bridge.ts +608 -0
- package/src/lib/scraper-vnext/strata-engine.orig.ts +2666 -0
- package/src/lib/scraper-vnext/strata-engine.ts +13 -0
- package/src/lib/scraper-vnext/structured-source-adapter.orig.ts +369 -0
- package/src/lib/scraper-vnext/structured-source-adapter.ts +34 -0
- package/src/lib/scraper-vnext/terminal-complete.ts +224 -0
- package/src/lib/scraper-vnext/terminal-final.ts +277 -0
- package/src/lib/scraper-vnext/terminal-saturation.ts +345 -0
- package/src/lib/scraper-vnext/terminal-wire.ts +425 -0
- package/src/lib/scraper-vnext/vanguard-titanium.orig.ts +467 -0
- package/src/lib/scraper-vnext/vanguard-titanium.ts +17 -0
- package/src/lib/search-cache.ts +138 -0
- package/src/lib/sloop-runner.base.ts +223 -0
- package/src/lib/sloop-runner.ts +104 -0
- package/src/lib/sloop.ts +114 -0
- package/src/lib/small-model-adapters.ts +82 -0
- package/src/lib/sscp.ts +86 -0
- package/src/lib/system-map.ts +54 -0
- package/src/lib/uni-node.ts +86 -0
- package/src/lib/universal-rigor-guard.ts +433 -0
- package/src/lib/v15-gate-testbed.ts +274 -0
- package/src/lib/v15-gemini.base.ts +89 -0
- package/src/lib/v15-gemini.ts +1 -0
- package/src/lib/v15-grounding.orig.ts +241 -0
- package/src/lib/v15-grounding.ts +79 -0
- package/src/lib/v15-pipeline.base.ts +769 -0
- package/src/lib/v15-pipeline.orig.ts +1154 -0
- package/src/lib/v15-pipeline.ts +674 -0
- package/src/lib/v15-questions.ts +64 -0
- package/src/lib/v15-rate-limiter.orig.ts +91 -0
- package/src/lib/v15-rate-limiter.ts +48 -0
- package/src/lib/v15-state.base.ts +87 -0
- package/src/lib/v15-state.ts +28 -0
- package/src/lib/visual-table-generator.tsx +207 -0
- package/src/lib/wasm-runtime.ts +133 -0
- package/src/lib/williams-persona-guide.ts +265 -0
- package/src/lib/williams-style.base.ts +464 -0
- package/src/lib/williams-style.ts +59 -0
- package/src/lib/worker-pool.ts +96 -0
- package/src/lib/writing-tiers.ts +125 -0
- package/src/main.orig.tsx +10 -0
- package/src/main.tsx +10 -0
- package/src/utils/cn.orig.ts +6 -0
- package/src/utils/cn.ts +6 -0
- package/src/vite-env.d.ts +1 -0
- package/tsconfig.json +31 -0
- package/unify.mjs +537 -0
- package/vite.config.ts +18 -0
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
import { useState, useEffect } from "react";
|
|
2
|
+
import { V15Toggle } from "@/components/V15Toggle";
|
|
3
|
+
import { V15CalibrationDialog } from "@/components/V15CalibrationDialog";
|
|
4
|
+
import { V15CalibrationAugment } from "@/components/V15CalibrationAugment";
|
|
5
|
+
import { getTitaniumEgressEnabled, setTitaniumEgressEnabled } from "@/lib/v15-grounding";
|
|
6
|
+
|
|
7
|
+
export function V15Overlay() {
|
|
8
|
+
const [dialogOpen, setDialogOpen] = useState(false);
|
|
9
|
+
const [minimized, setMinimized] = useState(true);
|
|
10
|
+
const [titaniumEnabled, setTitaniumEnabledState] = useState(() => getTitaniumEgressEnabled());
|
|
11
|
+
const [searxngUrl, setSearxngUrl] = useState(() =>
|
|
12
|
+
typeof localStorage !== "undefined"
|
|
13
|
+
? localStorage.getItem("veritas.v15.searxngUrl") || "http://localhost:8080"
|
|
14
|
+
: "http://localhost:8080"
|
|
15
|
+
);
|
|
16
|
+
|
|
17
|
+
useEffect(() => {
|
|
18
|
+
const onStorage = () => setTitaniumEnabledState(getTitaniumEgressEnabled());
|
|
19
|
+
window.addEventListener("storage", onStorage);
|
|
20
|
+
return () => window.removeEventListener("storage", onStorage);
|
|
21
|
+
}, []);
|
|
22
|
+
|
|
23
|
+
const save = () => {
|
|
24
|
+
if (typeof localStorage !== "undefined") {
|
|
25
|
+
localStorage.setItem("veritas.v15.searxngUrl", searxngUrl.trim() || "http://localhost:8080");
|
|
26
|
+
}
|
|
27
|
+
};
|
|
28
|
+
|
|
29
|
+
const toggleTitanium = () => {
|
|
30
|
+
const next = !titaniumEnabled;
|
|
31
|
+
setTitaniumEgressEnabled(next);
|
|
32
|
+
setTitaniumEnabledState(next);
|
|
33
|
+
};
|
|
34
|
+
|
|
35
|
+
return (
|
|
36
|
+
<>
|
|
37
|
+
<div
|
|
38
|
+
className="fixed left-2 top-1/2 z-[9998] flex -translate-y-1/2 flex-col items-start gap-2"
|
|
39
|
+
style={{ pointerEvents: "none" }}
|
|
40
|
+
>
|
|
41
|
+
<div
|
|
42
|
+
className="rounded-2xl border border-zinc-200 bg-white/95 px-3 py-2 shadow-xl backdrop-blur"
|
|
43
|
+
style={{ pointerEvents: "auto" }}
|
|
44
|
+
>
|
|
45
|
+
{minimized ? (
|
|
46
|
+
<button
|
|
47
|
+
onClick={() => setMinimized(false)}
|
|
48
|
+
className="flex items-center gap-1.5 text-[11px] font-bold text-indigo-700 hover:text-indigo-900"
|
|
49
|
+
title="Expand V15 controls"
|
|
50
|
+
>
|
|
51
|
+
<span className="grid h-5 w-5 place-items-center rounded-md bg-indigo-600 text-[10px] font-bold text-white">
|
|
52
|
+
V15
|
|
53
|
+
</span>
|
|
54
|
+
<span>▲</span>
|
|
55
|
+
</button>
|
|
56
|
+
) : (
|
|
57
|
+
<>
|
|
58
|
+
<div className="flex flex-wrap items-center gap-2">
|
|
59
|
+
<div className="grid h-6 w-6 place-items-center rounded-md bg-gradient-to-br from-indigo-600 to-emerald-500 text-[10px] font-bold text-white">
|
|
60
|
+
V15
|
|
61
|
+
</div>
|
|
62
|
+
<V15Toggle />
|
|
63
|
+
<button
|
|
64
|
+
onClick={() => setDialogOpen(true)}
|
|
65
|
+
className="rounded-lg border border-indigo-300 bg-indigo-50 px-2 py-1 text-[11px] font-bold text-indigo-800 hover:bg-indigo-100"
|
|
66
|
+
>
|
|
67
|
+
📊 Calibrate
|
|
68
|
+
</button>
|
|
69
|
+
<button
|
|
70
|
+
onClick={() => setDialogOpen(true)}
|
|
71
|
+
className="rounded-lg border border-emerald-300 bg-emerald-50 px-2 py-1 text-[11px] font-bold text-emerald-800 hover:bg-emerald-100"
|
|
72
|
+
>
|
|
73
|
+
📖 Guide
|
|
74
|
+
</button>
|
|
75
|
+
<button
|
|
76
|
+
onClick={toggleTitanium}
|
|
77
|
+
className={`rounded-lg border px-2 py-1 text-[11px] font-bold transition-colors ${
|
|
78
|
+
titaniumEnabled
|
|
79
|
+
? "border-amber-400 bg-amber-100 text-amber-900 shadow-sm"
|
|
80
|
+
: "border-zinc-300 bg-zinc-50 text-zinc-600 hover:bg-zinc-100"
|
|
81
|
+
}`}
|
|
82
|
+
title="Toggle Vanguard-Titanium Virtual Egress (Google Translate & AMP routes)"
|
|
83
|
+
>
|
|
84
|
+
⚡ Titanium: {titaniumEnabled ? "ON" : "OFF"}
|
|
85
|
+
</button>
|
|
86
|
+
<button
|
|
87
|
+
onClick={() => setMinimized(true)}
|
|
88
|
+
className="rounded-lg border border-zinc-200 px-1.5 py-1 text-[10px] text-zinc-500 hover:bg-zinc-100"
|
|
89
|
+
>
|
|
90
|
+
▼
|
|
91
|
+
</button>
|
|
92
|
+
</div>
|
|
93
|
+
<div className="mt-2 flex items-center gap-1.5 border-t border-zinc-100 pt-1.5">
|
|
94
|
+
<span className="text-[10px] font-bold text-zinc-600">🔍 SearXNG:</span>
|
|
95
|
+
<input
|
|
96
|
+
value={searxngUrl}
|
|
97
|
+
onChange={(e) => setSearxngUrl(e.target.value)}
|
|
98
|
+
onBlur={save}
|
|
99
|
+
className="w-36 rounded border border-zinc-300 px-1 py-0.5 font-mono text-[10px]"
|
|
100
|
+
placeholder="http://localhost:8080"
|
|
101
|
+
/>
|
|
102
|
+
<button onClick={save} className="rounded bg-zinc-100 px-1.5 text-[10px] font-bold text-zinc-700">
|
|
103
|
+
Save
|
|
104
|
+
</button>
|
|
105
|
+
<button onClick={() => setDialogOpen(true)} className="text-[10px] text-blue-600 underline">
|
|
106
|
+
setup help
|
|
107
|
+
</button>
|
|
108
|
+
</div>
|
|
109
|
+
<div className="mt-1 text-[9px] leading-tight text-zinc-400">
|
|
110
|
+
Additive · original app unchanged when OFF · ⚡ Titanium overrides AMP/Translate routes
|
|
111
|
+
</div>
|
|
112
|
+
</>
|
|
113
|
+
)}
|
|
114
|
+
</div>
|
|
115
|
+
</div>
|
|
116
|
+
<V15CalibrationDialog open={dialogOpen} onClose={() => setDialogOpen(false)} />
|
|
117
|
+
<V15CalibrationAugment />
|
|
118
|
+
</>
|
|
119
|
+
);
|
|
120
|
+
}
|
|
@@ -0,0 +1,362 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* V15OverlayWrapper — unified left rail (V15 + P + c).
|
|
3
|
+
* ============================================================================
|
|
4
|
+
* Spacing fix: previously V15 lived in its own `fixed top-1/2 -translate-y-1/2`
|
|
5
|
+
* container and P/c lived in a SECOND fixed container with a hard-coded
|
|
6
|
+
* translateY(96px). That made the gap between V15 and P uneven (too large when
|
|
7
|
+
* V15 is collapsed, sometimes overlapping when expanded).
|
|
8
|
+
*
|
|
9
|
+
* Fix: one outer column at the same anchor as the package V15 overlay. The
|
|
10
|
+
* package V15 overlay is still rendered (so Calibrate/Guide/Titanium/SearXNG
|
|
11
|
+
* and V15CalibrationAugment keep working), but we measure its pill height with
|
|
12
|
+
* a ResizeObserver and offset P/c to sit exactly `GAP` px below it. No hard-coded
|
|
13
|
+
* magic number that drifts with expand/collapse.
|
|
14
|
+
*
|
|
15
|
+
* Rigor Guard hide: when the calibration dialog is open (detected via its unique
|
|
16
|
+
* <h2> text), P and c unmount entirely so they cannot show through the
|
|
17
|
+
* translucent backdrop.
|
|
18
|
+
*/
|
|
19
|
+
import { useEffect, useLayoutEffect, useRef, useState } from "react";
|
|
20
|
+
import { V15Overlay as PackageV15Overlay } from "./V15Overlay.orig";
|
|
21
|
+
import { InnovationGenomeEngine } from "@/components/InnovationGenomeEngine";
|
|
22
|
+
import { InnovationPersonaGuide } from "@/components/InnovationPersonaGuide";
|
|
23
|
+
import { CreativeTreeLifePage } from "@/components/CreativeTreeLifePage";
|
|
24
|
+
import {
|
|
25
|
+
subscribeCitationLedger,
|
|
26
|
+
type CitationLedgerSnapshotLive,
|
|
27
|
+
} from "@/lib/citation-ledger-store";
|
|
28
|
+
import type { InnovationGenomeV2 } from "@/lib/innovation-genome-engine-v2";
|
|
29
|
+
|
|
30
|
+
const PERSONAS_EVENT = "veritas:open-personas";
|
|
31
|
+
const INNOVATION_PERSONAS_EVENT = "veritas:open-innovation-personas";
|
|
32
|
+
|
|
33
|
+
/** Shared pill chrome — identical to the packaged V15 overlay container. */
|
|
34
|
+
const PILL = "rounded-2xl border border-zinc-200 bg-white/95 px-3 py-2 shadow-xl backdrop-blur";
|
|
35
|
+
/** Shared collapsed glyph — identical footprint to the packaged V15 badge. */
|
|
36
|
+
const GLYPH = "grid h-5 w-5 place-items-center rounded-md text-[10px] font-bold text-white";
|
|
37
|
+
/** Uniform gap between V15, P, and c pills (px). Matches package gap-2 = 8px. */
|
|
38
|
+
const RAIL_GAP_PX = 8;
|
|
39
|
+
|
|
40
|
+
const EMPTY_LEDGER: CitationLedgerSnapshotLive = {
|
|
41
|
+
records: [],
|
|
42
|
+
siteCount: 0,
|
|
43
|
+
lastQuestion: "",
|
|
44
|
+
updatedAt: 0,
|
|
45
|
+
};
|
|
46
|
+
|
|
47
|
+
export function V15OverlayWrapper() {
|
|
48
|
+
const [genomeEngineOpen, setGenomeEngineOpen] = useState(false);
|
|
49
|
+
const [personaOpen, setPersonaOpen] = useState(false);
|
|
50
|
+
const [citationOpen, setCitationOpen] = useState(false);
|
|
51
|
+
const [innovationGuideOpen, setInnovationGuideOpen] = useState(false);
|
|
52
|
+
const [treeOfLifeOpen, setTreeOfLifeOpen] = useState(false);
|
|
53
|
+
const [ledger, setLedger] = useState<CitationLedgerSnapshotLive>(EMPTY_LEDGER);
|
|
54
|
+
const [rigorGuardOpen, setRigorGuardOpen] = useState(false);
|
|
55
|
+
/** Distance from the top of the outer rail to the bottom of the V15 pill. */
|
|
56
|
+
const [v15BottomPx, setV15BottomPx] = useState(40);
|
|
57
|
+
const railRef = useRef<HTMLDivElement | null>(null);
|
|
58
|
+
|
|
59
|
+
useEffect(() => subscribeCitationLedger(setLedger), []);
|
|
60
|
+
|
|
61
|
+
// Detect Rigor Guard Calibration dialog (package-owned, translucent backdrop).
|
|
62
|
+
useEffect(() => {
|
|
63
|
+
if (typeof document === "undefined") return;
|
|
64
|
+
const DIALOG_HEADING = "Rigor Guard Calibration — Live";
|
|
65
|
+
const check = () => {
|
|
66
|
+
const headings = Array.from(document.querySelectorAll("h2"));
|
|
67
|
+
const open = headings.some((h) => (h.textContent || "").trim() === DIALOG_HEADING);
|
|
68
|
+
setRigorGuardOpen((prev) => (prev === open ? prev : open));
|
|
69
|
+
};
|
|
70
|
+
check();
|
|
71
|
+
const observer = new MutationObserver(check);
|
|
72
|
+
observer.observe(document.body, { childList: true, subtree: true });
|
|
73
|
+
const interval = window.setInterval(check, 400);
|
|
74
|
+
return () => {
|
|
75
|
+
observer.disconnect();
|
|
76
|
+
window.clearInterval(interval);
|
|
77
|
+
};
|
|
78
|
+
}, []);
|
|
79
|
+
|
|
80
|
+
// Measure the package V15 pill so P/c sit exactly RAIL_GAP_PX below it.
|
|
81
|
+
// The package V15Overlay is a sibling fixed element; we locate it by its
|
|
82
|
+
// unique "V15" badge text and the fixed left-2 top-1/2 positioning.
|
|
83
|
+
useLayoutEffect(() => {
|
|
84
|
+
if (typeof document === "undefined") return;
|
|
85
|
+
|
|
86
|
+
const findV15Pill = (): HTMLElement | null => {
|
|
87
|
+
const candidates = Array.from(
|
|
88
|
+
document.querySelectorAll<HTMLElement>("div.fixed.left-2"),
|
|
89
|
+
);
|
|
90
|
+
for (const el of candidates) {
|
|
91
|
+
// Skip our own rail
|
|
92
|
+
if (el === railRef.current) continue;
|
|
93
|
+
if (el.textContent?.includes("V15") && el.className.includes("top-1/2")) {
|
|
94
|
+
// The inner pill is the first child with rounded-2xl
|
|
95
|
+
const pill = el.querySelector<HTMLElement>("div.rounded-2xl");
|
|
96
|
+
return pill ?? el;
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
return null;
|
|
100
|
+
};
|
|
101
|
+
|
|
102
|
+
let ro: ResizeObserver | null = null;
|
|
103
|
+
let observed: HTMLElement | null = null;
|
|
104
|
+
|
|
105
|
+
const measure = () => {
|
|
106
|
+
const pill = findV15Pill();
|
|
107
|
+
if (!pill) return;
|
|
108
|
+
const h = pill.getBoundingClientRect().height;
|
|
109
|
+
// When the package container is centered with -translate-y-1/2, the pill
|
|
110
|
+
// extends h/2 above and below the 50% line. Our rail is ALSO centered at
|
|
111
|
+
// 50% with -translate-y-1/2. To place P at (pill bottom + GAP) relative to
|
|
112
|
+
// the rail's top edge (which is at 50% - railHeight/2), we use a simpler
|
|
113
|
+
// approach: position P/c with marginTop = h + GAP, and don't center the
|
|
114
|
+
// P/c group independently. See render below.
|
|
115
|
+
setV15BottomPx((prev) => (Math.abs(prev - h) < 0.5 ? prev : h));
|
|
116
|
+
|
|
117
|
+
if (observed !== pill) {
|
|
118
|
+
ro?.disconnect();
|
|
119
|
+
observed = pill;
|
|
120
|
+
ro = new ResizeObserver(measure);
|
|
121
|
+
ro.observe(pill);
|
|
122
|
+
}
|
|
123
|
+
};
|
|
124
|
+
|
|
125
|
+
measure();
|
|
126
|
+
const mo = new MutationObserver(measure);
|
|
127
|
+
mo.observe(document.body, { childList: true, subtree: true, attributes: true });
|
|
128
|
+
const interval = window.setInterval(measure, 500);
|
|
129
|
+
|
|
130
|
+
return () => {
|
|
131
|
+
mo.disconnect();
|
|
132
|
+
ro?.disconnect();
|
|
133
|
+
window.clearInterval(interval);
|
|
134
|
+
};
|
|
135
|
+
}, [personaOpen, citationOpen, rigorGuardOpen]);
|
|
136
|
+
|
|
137
|
+
// Listen for Innovation Personas guide open event
|
|
138
|
+
useEffect(() => {
|
|
139
|
+
const onOpen = () => setInnovationGuideOpen(true);
|
|
140
|
+
window.addEventListener(INNOVATION_PERSONAS_EVENT, onOpen);
|
|
141
|
+
return () => window.removeEventListener(INNOVATION_PERSONAS_EVENT, onOpen);
|
|
142
|
+
}, []);
|
|
143
|
+
|
|
144
|
+
const handleUseInV15 = (genome: InnovationGenomeV2) => {
|
|
145
|
+
if (typeof window !== "undefined") {
|
|
146
|
+
(window as any)._VERITAS_ACTIVE_INNOVATION_GENOME = genome;
|
|
147
|
+
(window as any)._VERITAS_INNOVATION_GENOME_V2 = genome;
|
|
148
|
+
}
|
|
149
|
+
window.dispatchEvent(new CustomEvent("veritas:genome-updated", { detail: genome }));
|
|
150
|
+
};
|
|
151
|
+
|
|
152
|
+
const fire = (name: string) => window.dispatchEvent(new CustomEvent(name));
|
|
153
|
+
|
|
154
|
+
// Offset of the P/c stack from the vertical centre of the viewport:
|
|
155
|
+
// package V15 is centered, so its bottom edge is at +v15BottomPx/2 from centre.
|
|
156
|
+
// We want P to start RAIL_GAP_PX below that bottom edge.
|
|
157
|
+
// Our P/c wrapper is NOT translate-centered; it uses top: calc(50% + offset).
|
|
158
|
+
const pcTopOffset = v15BottomPx / 2 + RAIL_GAP_PX;
|
|
159
|
+
|
|
160
|
+
return (
|
|
161
|
+
<>
|
|
162
|
+
{/* Packaged overlay — owns V15 pill + Calibrate dialog + Augment modals. */}
|
|
163
|
+
<PackageV15Overlay />
|
|
164
|
+
|
|
165
|
+
{/* P + c rail: same left edge, dynamically parked just under V15. */}
|
|
166
|
+
{!rigorGuardOpen && (
|
|
167
|
+
<div
|
|
168
|
+
ref={railRef}
|
|
169
|
+
className="fixed left-2 z-[9997] flex flex-col items-start"
|
|
170
|
+
style={{
|
|
171
|
+
top: `calc(50% + ${pcTopOffset}px)`,
|
|
172
|
+
gap: `${RAIL_GAP_PX}px`,
|
|
173
|
+
pointerEvents: "none",
|
|
174
|
+
}}
|
|
175
|
+
>
|
|
176
|
+
{/* ── P — Personas hub ─────────────────────────────────────────── */}
|
|
177
|
+
<div className={PILL} style={{ pointerEvents: "auto" }}>
|
|
178
|
+
{!personaOpen ? (
|
|
179
|
+
<button
|
|
180
|
+
onClick={() => setPersonaOpen(true)}
|
|
181
|
+
className="flex items-center gap-1.5 text-[11px] font-bold text-violet-700 hover:text-violet-900"
|
|
182
|
+
title="Personas — Williams style, Innovation Genome, and both guides"
|
|
183
|
+
>
|
|
184
|
+
<span className={`${GLYPH} bg-violet-600`}>P</span>
|
|
185
|
+
<span>▲</span>
|
|
186
|
+
</button>
|
|
187
|
+
) : (
|
|
188
|
+
<div className="w-[300px]">
|
|
189
|
+
<div className="flex items-center justify-between">
|
|
190
|
+
<div className="flex items-center gap-1.5">
|
|
191
|
+
<span className={`${GLYPH} bg-violet-600`}>P</span>
|
|
192
|
+
<span className="text-[11px] font-bold text-zinc-700">Personas</span>
|
|
193
|
+
</div>
|
|
194
|
+
<button
|
|
195
|
+
onClick={() => setPersonaOpen(false)}
|
|
196
|
+
className="rounded-lg border border-zinc-200 px-1.5 py-1 text-[10px] text-zinc-500 hover:bg-zinc-100"
|
|
197
|
+
>
|
|
198
|
+
▼
|
|
199
|
+
</button>
|
|
200
|
+
</div>
|
|
201
|
+
|
|
202
|
+
<div className="mt-2 flex flex-wrap items-center gap-1.5">
|
|
203
|
+
<button
|
|
204
|
+
onClick={() => fire(PERSONAS_EVENT)}
|
|
205
|
+
className="rounded-lg border border-rose-300 bg-rose-50 px-2 py-1 text-[11px] font-bold text-rose-800 hover:bg-rose-100"
|
|
206
|
+
>
|
|
207
|
+
🎨 Style Guide
|
|
208
|
+
</button>
|
|
209
|
+
<button
|
|
210
|
+
onClick={() => setInnovationGuideOpen(true)}
|
|
211
|
+
className="rounded-lg border border-amber-300 bg-amber-50 px-2 py-1 text-[11px] font-bold text-amber-800 hover:bg-amber-100"
|
|
212
|
+
>
|
|
213
|
+
💡 Innovation Guide
|
|
214
|
+
</button>
|
|
215
|
+
<button
|
|
216
|
+
onClick={() => setGenomeEngineOpen(true)}
|
|
217
|
+
className="rounded-lg border border-fuchsia-300 bg-fuchsia-50 px-2 py-1 text-[11px] font-bold text-fuchsia-800 hover:bg-fuchsia-100"
|
|
218
|
+
>
|
|
219
|
+
🧬 Genome
|
|
220
|
+
</button>
|
|
221
|
+
<button
|
|
222
|
+
onClick={() => setTreeOfLifeOpen(true)}
|
|
223
|
+
className="rounded-lg border border-lime-300 bg-lime-50 px-2 py-1 text-[11px] font-bold text-lime-800 hover:bg-lime-100"
|
|
224
|
+
>
|
|
225
|
+
🌳 Tree of Life
|
|
226
|
+
</button>
|
|
227
|
+
</div>
|
|
228
|
+
|
|
229
|
+
<button
|
|
230
|
+
onClick={() => fire(PERSONAS_EVENT)}
|
|
231
|
+
className="mt-2 w-full rounded-lg bg-gradient-to-r from-violet-700 to-violet-600 px-2.5 py-1.5 text-left text-[11px] font-bold text-white hover:from-violet-800 hover:to-violet-700"
|
|
232
|
+
>
|
|
233
|
+
✍️ Williams Persona
|
|
234
|
+
<div className="mt-0.5 text-[9px] font-normal text-violet-100">
|
|
235
|
+
Prose style · how the answer is WRITTEN
|
|
236
|
+
</div>
|
|
237
|
+
</button>
|
|
238
|
+
|
|
239
|
+
<button
|
|
240
|
+
onClick={() => setInnovationGuideOpen(true)}
|
|
241
|
+
className="mt-1.5 w-full rounded-lg bg-gradient-to-r from-amber-600 to-orange-600 px-2.5 py-1.5 text-left text-[11px] font-bold text-white hover:from-amber-700 hover:to-orange-700"
|
|
242
|
+
>
|
|
243
|
+
💡 Innovation Personas
|
|
244
|
+
<div className="mt-0.5 text-[9px] font-normal text-amber-100">
|
|
245
|
+
Thinking direction · how the problem is SEARCHED & REFRAMED
|
|
246
|
+
</div>
|
|
247
|
+
</button>
|
|
248
|
+
|
|
249
|
+
<div className="mt-1.5 text-[9px] leading-tight text-zinc-400">
|
|
250
|
+
Dual-persona architecture · both prompts run in parallel
|
|
251
|
+
</div>
|
|
252
|
+
</div>
|
|
253
|
+
)}
|
|
254
|
+
</div>
|
|
255
|
+
|
|
256
|
+
{/* ── c — Citation Ledger ──────────────────────────────────────── */}
|
|
257
|
+
<div className={PILL} style={{ pointerEvents: "auto" }}>
|
|
258
|
+
{!citationOpen ? (
|
|
259
|
+
<button
|
|
260
|
+
onClick={() => setCitationOpen(true)}
|
|
261
|
+
className="flex items-center gap-1.5 text-[11px] font-bold text-sky-700 hover:text-sky-900"
|
|
262
|
+
title={`Citation Ledger — ${ledger.records.length} verified-retrieved source(s)`}
|
|
263
|
+
>
|
|
264
|
+
<span className={`${GLYPH} bg-sky-600`}>c</span>
|
|
265
|
+
<span>▲</span>
|
|
266
|
+
{ledger.records.length > 0 && (
|
|
267
|
+
<span className="rounded bg-sky-100 px-1 font-mono text-[9px] text-sky-800">
|
|
268
|
+
{ledger.records.length}
|
|
269
|
+
</span>
|
|
270
|
+
)}
|
|
271
|
+
</button>
|
|
272
|
+
) : (
|
|
273
|
+
<div className="w-[300px]">
|
|
274
|
+
<div className="flex items-center justify-between">
|
|
275
|
+
<div className="flex items-center gap-1.5">
|
|
276
|
+
<span className={`${GLYPH} bg-sky-600`}>c</span>
|
|
277
|
+
<span className="text-[11px] font-bold text-zinc-700">
|
|
278
|
+
Citation Ledger ({ledger.records.length} source
|
|
279
|
+
{ledger.records.length === 1 ? "" : "s"})
|
|
280
|
+
</span>
|
|
281
|
+
</div>
|
|
282
|
+
<button
|
|
283
|
+
onClick={() => setCitationOpen(false)}
|
|
284
|
+
className="rounded-lg border border-zinc-200 px-1.5 py-1 text-[10px] text-zinc-500 hover:bg-zinc-100"
|
|
285
|
+
>
|
|
286
|
+
▼
|
|
287
|
+
</button>
|
|
288
|
+
</div>
|
|
289
|
+
|
|
290
|
+
{ledger.records.length === 0 ? (
|
|
291
|
+
<div className="mt-2 rounded-lg border border-dashed border-zinc-200 bg-zinc-50 p-2 text-[10px] leading-tight text-zinc-500">
|
|
292
|
+
No sources retrieved yet. Every document the grounding fleet
|
|
293
|
+
actually fetches is recorded here with its site, title and
|
|
294
|
+
first-use stage.
|
|
295
|
+
</div>
|
|
296
|
+
) : (
|
|
297
|
+
<>
|
|
298
|
+
<div className="mt-2 flex items-center gap-2 text-[10px] text-zinc-600">
|
|
299
|
+
<span className="rounded bg-sky-50 px-1.5 py-0.5 font-mono text-sky-800">
|
|
300
|
+
{ledger.siteCount} site{ledger.siteCount === 1 ? "" : "s"}
|
|
301
|
+
</span>
|
|
302
|
+
<span className="rounded bg-emerald-50 px-1.5 py-0.5 font-mono text-emerald-800">
|
|
303
|
+
{ledger.records.filter((r) => r.snippet.length > 0).length} quotable
|
|
304
|
+
</span>
|
|
305
|
+
</div>
|
|
306
|
+
<div className="mt-1.5 max-h-56 space-y-1 overflow-y-auto">
|
|
307
|
+
{ledger.records.map((record) => (
|
|
308
|
+
<a
|
|
309
|
+
key={record.id}
|
|
310
|
+
href={record.url}
|
|
311
|
+
target="_blank"
|
|
312
|
+
rel="noreferrer"
|
|
313
|
+
className="block rounded-lg border border-zinc-100 bg-zinc-50 px-2 py-1.5 hover:bg-zinc-100"
|
|
314
|
+
>
|
|
315
|
+
<div className="flex items-center justify-between gap-2">
|
|
316
|
+
<span className="font-mono text-[10px] font-bold text-zinc-700">
|
|
317
|
+
[S{record.id}]
|
|
318
|
+
</span>
|
|
319
|
+
<span className="rounded bg-white px-1 font-mono text-[9px] text-zinc-500">
|
|
320
|
+
{record.stage}
|
|
321
|
+
</span>
|
|
322
|
+
</div>
|
|
323
|
+
<div
|
|
324
|
+
className="truncate text-[10px] font-semibold text-zinc-800"
|
|
325
|
+
title={record.title}
|
|
326
|
+
>
|
|
327
|
+
{record.title}
|
|
328
|
+
</div>
|
|
329
|
+
<div className="truncate text-[9px] text-sky-700">{record.site}</div>
|
|
330
|
+
</a>
|
|
331
|
+
))}
|
|
332
|
+
</div>
|
|
333
|
+
</>
|
|
334
|
+
)}
|
|
335
|
+
<div className="mt-1.5 text-[9px] leading-tight text-zinc-400">
|
|
336
|
+
Full table with metrics sits under Style Persona in the Chat page.
|
|
337
|
+
</div>
|
|
338
|
+
</div>
|
|
339
|
+
)}
|
|
340
|
+
</div>
|
|
341
|
+
</div>
|
|
342
|
+
)}
|
|
343
|
+
|
|
344
|
+
<InnovationGenomeEngine
|
|
345
|
+
open={genomeEngineOpen}
|
|
346
|
+
onClose={() => setGenomeEngineOpen(false)}
|
|
347
|
+
onUseInV15={handleUseInV15}
|
|
348
|
+
/>
|
|
349
|
+
|
|
350
|
+
<InnovationPersonaGuide
|
|
351
|
+
open={innovationGuideOpen}
|
|
352
|
+
onClose={() => setInnovationGuideOpen(false)}
|
|
353
|
+
/>
|
|
354
|
+
|
|
355
|
+
{treeOfLifeOpen && (
|
|
356
|
+
<CreativeTreeLifePage
|
|
357
|
+
onClose={() => setTreeOfLifeOpen(false)}
|
|
358
|
+
/>
|
|
359
|
+
)}
|
|
360
|
+
</>
|
|
361
|
+
);
|
|
362
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* V15 Pipeline toggle — reads/writes localStorage via v15-state (isolated from npm state).
|
|
3
|
+
* Default OFF. When OFF, the original app runs unchanged.
|
|
4
|
+
*/
|
|
5
|
+
import { useEffect, useState } from "react";
|
|
6
|
+
import { getV15Enabled, setV15Enabled, subscribeV15 } from "../lib/v15-state";
|
|
7
|
+
|
|
8
|
+
export function V15Toggle({ compact }: { compact?: boolean }) {
|
|
9
|
+
const [on, setOn] = useState<boolean>(() => getV15Enabled());
|
|
10
|
+
|
|
11
|
+
useEffect(() => subscribeV15(setOn), []);
|
|
12
|
+
|
|
13
|
+
return (
|
|
14
|
+
<label
|
|
15
|
+
title="V15 Rigor Guard Pipeline — additive verification (default OFF). Original app runs unchanged when unchecked."
|
|
16
|
+
className={`flex items-center gap-1.5 cursor-pointer select-none rounded-lg border px-2 py-1 transition-colors ${
|
|
17
|
+
on ? "border-indigo-300 bg-indigo-50" : "border-zinc-200 bg-white hover:bg-zinc-50"
|
|
18
|
+
}`}
|
|
19
|
+
>
|
|
20
|
+
<input
|
|
21
|
+
type="checkbox"
|
|
22
|
+
checked={on}
|
|
23
|
+
onChange={(e) => setV15Enabled(e.target.checked)}
|
|
24
|
+
className="h-3.5 w-3.5 accent-indigo-600"
|
|
25
|
+
/>
|
|
26
|
+
<span className={`text-[11px] font-bold ${on ? "text-indigo-800" : "text-zinc-600"}`}>
|
|
27
|
+
{compact ? "V15" : "V15 Pipeline"}
|
|
28
|
+
</span>
|
|
29
|
+
{on && !compact && (
|
|
30
|
+
<span className="rounded-full bg-indigo-600 px-1.5 py-0.5 text-[9px] font-bold text-white">ON</span>
|
|
31
|
+
)}
|
|
32
|
+
</label>
|
|
33
|
+
);
|
|
34
|
+
}
|