rho-coding-agent 2.19.0

A fast Rust agent harness with a small footprint and opinionated defaults
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
//! Keep the proposed plan available when the approval receipt is expanded.

use rho_tools::tool_card::{ToolBody, ToolCard, ToolFamily, ToolHeader, ToolStatus};

pub(super) fn card(arguments: &serde_json::Value, status: ToolStatus) -> ToolCard {
    let mut card = ToolCard::new(
        status,
        ToolFamily::Form,
        ToolHeader::call("exit_plan_mode", Some("Plan approval".into())),
    );
    if let Some(plan) = arguments.get("plan").and_then(serde_json::Value::as_str) {
        card.body = ToolBody::Lines(super::split_body_lines(plan));
    }
    card
}