feat: add downloadable agent document outputs
This commit is contained in:
@@ -17,6 +17,8 @@ pub enum ToolCapability {
|
||||
AskUserQuestion,
|
||||
#[serde(rename = "Bash")]
|
||||
Bash,
|
||||
#[serde(rename = "CreateDocument")]
|
||||
CreateDocument,
|
||||
#[serde(rename = "Skill")]
|
||||
Skill,
|
||||
}
|
||||
@@ -31,6 +33,7 @@ impl ToolCapability {
|
||||
Self::Grep => "Grep",
|
||||
Self::AskUserQuestion => "AskUserQuestion",
|
||||
Self::Bash => "Bash",
|
||||
Self::CreateDocument => "CreateDocument",
|
||||
Self::Skill => "Skill",
|
||||
}
|
||||
}
|
||||
@@ -44,6 +47,7 @@ impl ToolCapability {
|
||||
"Grep" => Some(Self::Grep),
|
||||
"AskUserQuestion" => Some(Self::AskUserQuestion),
|
||||
"Bash" => Some(Self::Bash),
|
||||
"CreateDocument" => Some(Self::CreateDocument),
|
||||
"Skill" => Some(Self::Skill),
|
||||
_ => None,
|
||||
}
|
||||
@@ -64,7 +68,7 @@ pub struct ToolSpec {
|
||||
pub approval_can_be_remembered: bool,
|
||||
}
|
||||
|
||||
const SERVER_TOOLS: [ToolSpec; 7] = [
|
||||
const SERVER_TOOLS: [ToolSpec; 8] = [
|
||||
ToolSpec::policy(ToolCapability::Read),
|
||||
ToolSpec::policy(ToolCapability::Write),
|
||||
ToolSpec::policy(ToolCapability::Edit),
|
||||
@@ -72,6 +76,7 @@ const SERVER_TOOLS: [ToolSpec; 7] = [
|
||||
ToolSpec::policy(ToolCapability::Grep),
|
||||
ToolSpec::policy(ToolCapability::AskUserQuestion),
|
||||
ToolSpec::policy(ToolCapability::Bash),
|
||||
ToolSpec::policy(ToolCapability::CreateDocument),
|
||||
];
|
||||
|
||||
const DESKTOP_TOOLS: [ToolSpec; 8] = [
|
||||
@@ -207,7 +212,8 @@ mod tests {
|
||||
"Glob",
|
||||
"Grep",
|
||||
"AskUserQuestion",
|
||||
"Bash"
|
||||
"Bash",
|
||||
"CreateDocument"
|
||||
]
|
||||
);
|
||||
assert!(!policy.allows("Skill"));
|
||||
|
||||
Reference in New Issue
Block a user