Skip to content

Latest commit

 

History

History
201 lines (109 loc) · 10.2 KB

agent-hooks.md

File metadata and controls

201 lines (109 loc) · 10.2 KB

Agent Hooks

How Hide learns what an agent has spawned inside its own process, and what it writes to the operator's machine to learn it.

The engine lists panes. An agent that spawns a subagent in-process creates no pane, so nothing about it reaches the engine's pane list, and a pane running six subagents is indistinguishable from one working alone. This is the only part of the tree Hide cannot read from the session snapshot, and it is why anything is written to the operator's configuration at all.

This guide is kept as pieces under docs/agent-hooks/, one file per subject, each naming the code it covers. Read this table, then the pieces whose Code paths cover what you change. The headings after the table keep every section name and anchor this file had, so a reference such as docs/agent-hooks.md, <section> still lands here and names its piece.

Piece Code
What is written, how it is installed and judged hide-agent-hooks/src/install.rs, hide-agent-hooks/src/hook_request/install.rs, hide-agent-hooks/src/diagnosis.rs, hide-agent-hooks/src/account.rs, hide-kit/src/targets.rs, hide-kit/src/local.rs, hide-host/src/kit.rs
The hook report: what it returns and which session it names hide-agent-hooks/src/hook_request.rs, hide-agent-hooks/src/runtime.rs, hide-agent-hooks/src/workspace_context.rs, hide-core/src/links/session_brief.rs, hided/src/hook_request.rs, hided/src/pane_auth.rs, hide-core/src/agent_hooks/facts.rs
The turn and the subagents a hook reports hide-session/src/turns/native.rs, hide-session/src/calls.rs, hide-agent-hooks/src/report.rs, hide-agent-hooks/src/counters.rs, hide-agent-hooks/src/basic.rs
The global instruction and where a hook keeps its records hide-agent-hooks/src/delivery.rs, hide-agent-hooks/src/owed.rs, hide-agent-hooks/src/memory.rs, hided/src/hook_request.rs, scripts/agent_journey/hook_records.py
The opener guard, project guardrails and the plan record hide-agent-hooks/src/guardrails.rs, hide-agent-hooks/src/guardrails/, hide-agent-hooks/src/plan_record.rs, hide-session/src/call_shell.rs, hide-agent-hooks/tests/it/opener_guard.rs
Folder trust and MCP servers hide-agent-hooks/src/folder_trust.rs, hide-agent-hooks/src/folder_trust/, hide-core/src/agent_start.rs, hide-kit/src/store.rs, hide-kit/src/store/mcp.rs
Pi and omp: Hide's extension hide-agent-hooks/src/plugin.rs, hide-agent-hooks/src/pi_extension.rs, hide-agent-hooks/src/pi_extension/extension.js
Other agents: skill and guidance hook, adding an agent hide-agent-adapter/src/declarations.rs, hide-agent-adapter/tests/it/contract.rs, hide-kit/src/agents.rs, contracts/agent-adapters.json, scripts/install-agent-clis.py
Grok, Antigravity and Codex: their own hooks hide-agent-hooks/src/antigravity.rs, hide-agent-hooks/src/codex_trust.rs, hide-agent-hooks/tests/it/grok_cursor_hooks.rs, hide-agent-hooks/tests/it/agy_hooks.rs, hide-agent-hooks/tests/it/codex_trust.rs
Which agents are supported, installed and updated hide-kit/src/agent_update.rs, hide-agent-adapter/src/declarations.rs, hide-platform/tests/it/programs.rs, hide-ai/src/program.rs, hide-core/src/runtime/tests/agent_features.rs, contracts/agent-journey.json
Testing the hooks hide-agent-hooks/src/plugin/tests.rs, web/e2e/pi-omp-extension.spec.ts, scripts/agent_journey/routes.py, scripts/agent_journey/hook_records.py

What is written, and where

Moved to What is written, how it is installed and judged.

What the hook returns and reports back

Moved to The hook report: what it returns and which session it names.

Which session is the pane's

Moved to The hook report: what it returns and which session it names.

The turn the hook reports

Moved to The turn and the subagents a hook reports.

Which subagents run

Moved to The turn and the subagents a hook reports.

What the hook keeps of each subagent

Moved to The turn and the subagents a hook reports.

The Hide global instruction

Moved to The global instruction and where a hook keeps its records.

Where the hooks keep their records

Moved to The global instruction and where a hook keeps its records.

What a hook records when it fails

Moved to The global instruction and where a hook keeps its records.

What the report records when it fails

Moved to The global instruction and where a hook keeps its records.

Native questions

Moved to The opener guard, project guardrails and the plan record.

The opener guard

Moved to The opener guard, project guardrails and the plan record.

Which shell reads a call

Moved to The opener guard, project guardrails and the plan record.

Folder trust for the folders Hide starts agents in

Moved to Folder trust and MCP servers.

Agents whose folder trust Hide does not record

Moved to Folder trust and MCP servers.

MCP servers

Moved to Folder trust and MCP servers.

MCP keys

Moved to Folder trust and MCP servers.

When the MCP keys' secret is lost

Moved to Folder trust and MCP servers.

Project guardrails

Moved to The opener guard, project guardrails and the plan record.

The merge option's decisions

Moved to The opener guard, project guardrails and the plan record.

The pane's plan record

Moved to The opener guard, project guardrails and the plan record.

Pi and omp: Hide's extension

Moved to Pi and omp: Hide's extension.

Other agents: skill and guidance hook

Moved to Other agents: skill and guidance hook, adding an agent.

Which agents Hide supports

Moved to Other agents: skill and guidance hook, adding an agent.

ACP servers

Moved to Other agents: skill and guidance hook, adding an agent.

Adding an agent

Moved to Other agents: skill and guidance hook, adding an agent.

What the kit puts down

Moved to Other agents: skill and guidance hook, adding an agent.

The operator's skills from the store

Moved to Other agents: skill and guidance hook, adding an agent.

Grok's own hooks

Moved to Grok, Antigravity and Codex: their own hooks.

Antigravity: Hide's hook block

Moved to Grok, Antigravity and Codex: their own hooks.

Installed means the program is found

Moved to Which agents are supported, installed and updated.

When the program is gone

Moved to Which agents are supported, installed and updated.

Support table

Moved to Which agents are supported, installed and updated.

The oldest version of each agent

Moved to Which agents are supported, installed and updated.

Updating an agent that is too old

Moved to Which agents are supported, installed and updated.

Herdr's integration an earlier Hide installed

Moved to Which agents are supported, installed and updated.

Which agents ask for a review

Moved to Which agents are supported, installed and updated.

Retired agents

Moved to Which agents are supported, installed and updated.

Codex trusts Hide's own hooks

Moved to Grok, Antigravity and Codex: their own hooks.

Judging what is installed

Moved to What is written, how it is installed and judged.

Installing

Moved to What is written, how it is installed and judged.

More than one Hide on an account

Moved to What is written, how it is installed and judged.

Profile accounts

Moved to What is written, how it is installed and judged.

Testing

Moved to Testing the hooks.