From abeb3fcb0362e229e514bfba34860ad3c70780cb Mon Sep 17 00:00:00 2001 From: robbond Date: Wed, 26 Aug 2026 19:22:54 +0100 Subject: [PATCH] feat(confidence-engine): add focused investigation overlay workspace --- components/reasoning-workspace.jsx | 391 ++++++++--- tests/run-a-focused-content.test.jsx | 965 +++++++++++++++++++++++++++ 2 files changed, 1271 insertions(+), 85 deletions(-) diff --git a/components/reasoning-workspace.jsx b/components/reasoning-workspace.jsx index 79b4f20..1ce0e69 100644 --- a/components/reasoning-workspace.jsx +++ b/components/reasoning-workspace.jsx @@ -169,90 +169,106 @@ function FocusedQuestionBody({ setFollowUpQuestion, focusedContributions, }) { + const hasContent = focused?.question?.trim() || formulationStep === "active" || processingStep === "active" || focused?.error; + const hasResult = Boolean(focused?.result); + return ( <> - {isFocused && (() => { - const hasContent = focused?.question?.trim() || formulationStep === "active" || processingStep === "active" || focused?.error; + {isFocused && hasContent && ( +
+
+ {focused?.question?.trim() ? ( +
+

Question

+

{focused.question}

+
+ ) : formulationStep === "active" ? ( +

{formulateMsg}

+ ) : null} - if (!hasContent) return null; + {focused?.question?.trim() && processingStep !== "active" && focused.status === "formulated" && ( +
+ +