From 7155e6cd7ddf25a5a4d4f6d6abecd49f0cf519dc Mon Sep 17 00:00:00 2001 From: soryu Date: Tue, 20 Jan 2026 23:20:32 +0000 Subject: Add non-blocking persistent contract completion questions (#14) * [WIP] Heartbeat checkpoint - 2026-01-20 22:40:37 UTC * Task completion checkpoint --- makima/src/daemon/api/supervisor.rs | 10 ++++++++++ makima/src/daemon/cli/supervisor.rs | 8 ++++++++ 2 files changed, 18 insertions(+) (limited to 'makima/src/daemon') diff --git a/makima/src/daemon/api/supervisor.rs b/makima/src/daemon/api/supervisor.rs index bd3aefd..74c27e0 100644 --- a/makima/src/daemon/api/supervisor.rs +++ b/makima/src/daemon/api/supervisor.rs @@ -76,6 +76,12 @@ pub struct AskQuestionRequest { /// When true, allow selecting multiple choices (response will be comma-separated) #[serde(default)] pub multi_select: bool, + /// When true, return immediately without waiting for response + #[serde(default)] + pub non_blocking: bool, + /// Question type: general, phase_confirmation, or contract_complete + #[serde(default)] + pub question_type: String, } // Generic response type for JSON output @@ -209,6 +215,8 @@ impl ApiClient { timeout_seconds: i32, phaseguard: bool, multi_select: bool, + non_blocking: bool, + question_type: String, ) -> Result { let req = AskQuestionRequest { question: question.to_string(), @@ -217,6 +225,8 @@ impl ApiClient { timeout_seconds, phaseguard, multi_select, + non_blocking, + question_type, }; self.post("/api/v1/mesh/supervisor/questions", &req).await } diff --git a/makima/src/daemon/cli/supervisor.rs b/makima/src/daemon/cli/supervisor.rs index 798a55f..7e17135 100644 --- a/makima/src/daemon/cli/supervisor.rs +++ b/makima/src/daemon/cli/supervisor.rs @@ -188,6 +188,14 @@ pub struct AskArgs { /// Allow selecting multiple choices (response will be comma-separated) #[arg(long, default_value = "false")] pub multi_select: bool, + + /// Non-blocking mode - returns immediately without waiting for response + #[arg(long, default_value = "false")] + pub non_blocking: bool, + + /// Question type (general, phase_confirmation, contract_complete) + #[arg(long, default_value = "general")] + pub question_type: String, } /// Arguments for status command (get contract status including phase). -- cgit v1.2.3