Skip to content

Task: document the command-hook runtime adapter pattern #268

Description

@antejavor

Part of #259

Question

Surfaced while resolving #264 (hook authoring/registration): agent-context-graph/README.md's existing "Adding a New Runtime Adapter" section (README.md:379-402) only documents the in-process/SDK-style pattern. Add a second section documenting the command-hook pattern (Claude Code/Codex-style: harness invokes an external command with a JSON payload on stdin), extracted from the two real implementations that already exist (adapters/claude_code.py's build_hooks_config/load_payload/CLI-entrypoint shape, and adapters/codex.py's equivalent) so a third party targeting a new command-hook harness (Cursor, an in-house CLI tool, etc.) has a copyable pattern instead of having to reverse-engineer it from source.

This is a documentation task, not an open design decision — the shape to document already exists in code and was confirmed correct while resolving #264.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions