Skip to main content

resolve_agent_tool_requirements

Function resolve_agent_tool_requirements 

Source
pub fn resolve_agent_tool_requirements(
    pack_dir: &Path,
    agents: &BTreeMap<String, Value>,
    cache_dir: &Path,
    offline: bool,
) -> Result<BTreeMap<String, Vec<ToolSecretReq>>>
Expand description

For each tool extension used by the agents, acquire its .gtxpack, read describe.json, and extract the secret requirements of the used tools.

Returns a map keyed by extension id. Errors (and propagates via ?) when a declared tool extension is not found in pack.extensions.json or cannot be acquired — no silent skips.

pack_dir must contain pack.extensions.json. cache_dir and offline are threaded through to [acquire_extension_bytes] for store:// sources.