Platform Extension MOIM (Minus One Info Message) (#5027)

This commit is contained in:
tlongwell-block
2025-11-16 12:14:49 -05:00
committed by GitHub
parent 5066a09c77
commit 02ca6f7ff1
16 changed files with 226 additions and 92 deletions
+1
View File
@@ -69,3 +69,4 @@ tempfile = "3"
temp-env = { version = "0.3.6", features = ["async_closure"] }
test-case = "3.3"
tokio = { version = "1.43", features = ["rt", "macros"] }
serial_test = "3.2.0"
+1 -1
View File
@@ -871,7 +871,7 @@ print(\"hello, world\")
format_tool_name("platform__manage_extensions"),
"Platform: Manage Extensions"
);
assert_eq!(format_tool_name("todo__read"), "Todo: Read");
assert_eq!(format_tool_name("todo__write"), "Todo: Write");
}
#[test]
@@ -141,6 +141,8 @@ where
use goose::config::ExtensionConfig;
use tokio::sync::Mutex;
goose::agents::moim::SKIP.with(|f| f.set(true));
if let Ok(path) = dotenv() {
println!("Loaded environment from {:?}", path);
}
+1 -5
View File
@@ -261,7 +261,7 @@ fn render_tool_request(req: &ToolRequest, theme: Theme, debug: bool) {
"developer__text_editor" => render_text_editor_request(call, debug),
"developer__shell" => render_shell_request(call, debug),
"dynamic_task__create_task" => render_dynamic_task_request(call, debug),
"todo__read" | "todo__write" => render_todo_request(call, debug),
"todo__write" => render_todo_request(call, debug),
_ => render_default_request(call, debug),
},
Err(e) => print_markdown(&e.to_string(), theme),
@@ -505,13 +505,9 @@ fn render_dynamic_task_request(call: &CallToolRequestParam, debug: bool) {
fn render_todo_request(call: &CallToolRequestParam, _debug: bool) {
print_tool_header(call);
// For todo tools, always show the full content without redaction
if let Some(args) = &call.arguments {
if let Some(Value::String(content)) = args.get("content") {
println!("{}: {}", style("content").dim(), style(content).green());
} else {
// For todo__read, there are no arguments
// Just print an empty line for consistency
}
}
println!();