mirror of
https://wget.la/https://github.com/leookun/cursor-byok
synced 2026-10-04 02:52:55 +08:00
21 lines
530 B
Rust
21 lines
530 B
Rust
//! Synchronous local tool dispatch.
|
|
|
|
use crate::{model::ToolCall, Result};
|
|
|
|
use super::ToolStart;
|
|
use crate::cursor::tools::result;
|
|
|
|
pub(super) fn start(call: &ToolCall, message_index: usize) -> Result<ToolStart> {
|
|
Ok(ToolStart {
|
|
messages: Vec::new(),
|
|
completion: Some(result::local(call, message_index)?),
|
|
})
|
|
}
|
|
|
|
pub(super) fn subagents_disabled(call: &ToolCall) -> Result<ToolStart> {
|
|
Ok(ToolStart {
|
|
messages: Vec::new(),
|
|
completion: Some(result::subagents_disabled(call)?),
|
|
})
|
|
}
|