Expand description
The policy classifier: every tool call is allowed, needs approval, or is denied — decided by code, before the call.
It decides which calls run; what an allowed command can reach is the
OS sandbox’s job (crate::sandbox).
Structs§
Enums§
- Class
- The kind of object a decision covers.
- Decision
- What the engine does with a call.
- Object
- What a person’s decision covers: exactly one resolved object — never the request’s spelling and never a pattern (constitution V). A path is the canonical file a write reaches; a command is its exact argv with the directory it runs in and the executable it resolves to; an MCP tool is its name with the digest of its definition.
Constants§
- AUTOPILOT_
DENIED - Why an autopilot run refused a call that would have asked a person.
- MCP_
PREFIX - The prefix of an MCP tool’s name as the model sees it (
crate::mcp). - NOT_
FOUND - What an executable that cannot be found is recorded as.
Functions§
- argv_of
- The argv a
run_commandcall asks for (strings only). - argv_
sha256 - Hex SHA-256 over
argvas a JSON array. - prefix_
matches - Whether
argvstarts withprefix, a prefix of at least two elements (a bare program allows any argument, so it is never a prefix). - prefix_
refusal - Why a prefix entry is refused, if it is: a bare program allows any argument.