pub const fn required_capabilities(profile: ToolProfile) -> CapabilitySetExpand description
Derive the capabilities a tool call requires from its profile — the spec’s existing annotations plus registry provenance. No new hand-written per-tool metadata.
The mapping (see the #587 design):
- sandbox-confined built-in ⇒ local read (+ local write unless read-only — destructive inside the box is still local);
- built-in fetcher ⇒ arbitrary egress (+ external mutation when destructive, e.g. a paying fetch);
- first-party / operator-registered connector ⇒ fixed-connector read (+ external mutation unless read-only and non-destructive);
- unknown / unclassifiable ⇒ the full privileged set, fail closed: an unknown tool never slips through un-gated.
open_world is deliberately not consulted: it marks an ingestion source
(drives taint when the result enters context), not an outbound
capability.