MCPcopy Index your code
hub / github.com/anomalyco/opencode / resolveTools

Function resolveTools

packages/opencode/src/cli/cmd/debug/agent.handler.ts:88–98  ·  view source on GitHub ↗
(agent: Agent.Info, availableTools: { id: string }[])

Source from the content-addressed store, hash-verified

86})
87
88function resolveTools(agent: Agent.Info, availableTools: { id: string }[]) {
89 const disabled = Permission.disabled(
90 availableTools.map((tool) => tool.id),
91 agent.permission,
92 )
93 const resolved: Record<string, boolean> = {}
94 for (const tool of availableTools) {
95 resolved[tool.id] = !disabled.has(tool.id)
96 }
97 return resolved
98}
99
100function parseToolParams(input?: string) {
101 if (!input) return {}

Callers 1

agent.handler.tsFile · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected