Files
Agent-Native/runtime/codeorch/forbid.go
T
weichenandCursor e4020d297c
ci / vet-and-test (pull_request) Successful in 49s
ci / docker-checkout-hostgateway (pull_request) Successful in 1s
Add a script host, deferred tools, and background MCP connect
Why: models need a capped way to call several tools from one script, and a slow MCP server must not block the first prompt.
Evidence: GOWORK=off go test ./runtime/codeorch/ ./runtime/tools/ ./runtime/mcp/ ./runtime/policy/ ./adapters/native/
Impact: run_tool_script stays unregistered until the caller turns it on. Deferred tools stay out of the model list. An unready MCP server connects in the background.
Refs: feature/code-orchestration
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-10-03 18:02:53 +00:00

13 lines
346 B
Go

package codeorch
// Forbidden 是脚本不能再调用的工具:解释器、自身、派发和工作流。
func Forbidden(name string) bool {
switch name {
case "run_python", "run_shell", "run_command", "run_tool_script",
"delegate_task", "squad_orchestrate", "run_workflow", "review_findings":
return true
default:
return false
}
}