feat(protocol): add Paste request type for bracketed-paste events
feat(engine): summarize agent completion progress in UI notifications feat(main): enable and disable bracketed paste support in terminal fix(app_config): store API key from file as fallback for Claude provider refactor(workflow): remove unnecessary card separator in workflow panel
This commit is contained in:
+22
-11
@@ -278,18 +278,29 @@ fn spawn_single_agent(
|
||||
|
||||
// Notify UI: agent completed or failed
|
||||
if let Some(f) = live {
|
||||
let summary_from = |text: &str| {
|
||||
text.lines()
|
||||
.next()
|
||||
.unwrap_or(text)
|
||||
.chars()
|
||||
.take(80)
|
||||
.collect::<String>()
|
||||
};
|
||||
match &result {
|
||||
Ok(_) => f(
|
||||
agent_id.to_string(),
|
||||
agent_name.to_string(),
|
||||
AgentStatus {
|
||||
state: AgentState::Completed,
|
||||
started_at: Some(started_at),
|
||||
completed_at: Some(completed_at),
|
||||
error: None,
|
||||
progress: None,
|
||||
},
|
||||
),
|
||||
Ok(text) => {
|
||||
let summary = summary_from(text);
|
||||
f(
|
||||
agent_id.to_string(),
|
||||
agent_name.to_string(),
|
||||
AgentStatus {
|
||||
state: AgentState::Completed,
|
||||
started_at: Some(started_at),
|
||||
completed_at: Some(completed_at),
|
||||
error: None,
|
||||
progress: Some(summary),
|
||||
},
|
||||
)
|
||||
}
|
||||
Err(e) => f(
|
||||
agent_id.to_string(),
|
||||
agent_name.to_string(),
|
||||
|
||||
Reference in New Issue
Block a user