Skip to main content
hook CX Codex

aiboarding — Claude Code hook for AGENTS.md and CLAUDE.md upkeep

aiboarding is a Claude Code and Codex hook that generates, maintains, compresses, and audits AI-agent onboarding files, keeping AGENTS.md and CLAUDE.md current as the codebase changes.

MIT ★ 1,596 updated 2026-10-29

Install into Claude Code · Manually: put the files in place All methods and platforms ↓
.claude/settings.json
Open on GitHub

What aiboarding does

aiboarding is a hook bundle for keeping agent onboarding files in sync with the repository. It generates AGENTS.md and CLAUDE.md, compresses them when the context grows too large, and audits for drift. The triggers are PostToolUse and SessionStart, so checks run after tool calls and whenever a session begins.

For Codex, the hook ships as a bash script called codex-lifecycle plus a Windows version, codex-lifecycle.cmd. The config wires them to SessionStart, SubagentStart, and PostToolUse. Timeouts differ: 10 seconds for session and subagent start, 15 for PostToolUse.

On Claude Code the install is manual: you add the hook to .claude/settings.json yourself. There is no marketplace command or one-line installer here. If your project already hooks the same triggers, check for conflicts before adding aiboarding on top.

What it helps with

  • generate AGENTS.md and CLAUDE.md for a project
  • keep onboarding files in sync with code changes
  • detect drift between docs and the actual repository state
  • shrink an overgrown agent context
  • run onboarding checks on session start and after Bash calls

Example prompts for the agent

  • Check the onboarding files after the latest changes to the repo
  • Compress AGENTS.md so it fits the context limit
  • Find where CLAUDE.md no longer matches the project

How to install aiboarding

Manually: put the files in place

.claude/settings.json

The hooks block: event (PreToolUse, PostToolUse, Stop…) → command. Personal ones go to ~/.claude/settings.json

Step by step, with commands for each platform: Claude Code hooks: what they are, where to configure them, how to block a risky command

Questions about aiboarding

How do I install aiboarding in Claude Code?

You add the hook to .claude/settings.json manually: point SessionStart, SubagentStart, and PostToolUse at the codex-lifecycle script. There is no install command or marketplace entry.

What does aiboarding do?

It generates, maintains, compresses, and audits AI-agent onboarding files like AGENTS.md and CLAUDE.md. The hook fires on session start, subagent start, and after every Bash call.

How is aiboarding different from a plain AGENTS.md?

A static AGENTS.md goes stale quickly. aiboarding automates the upkeep: it tracks drift, compresses context, and rechecks the files as the codebase changes.

Source text

hooks.json · MIT
Hooks bundle shipped with the aiboarding plugin for Claude Code.

Generate, maintain, compress, and audit standard AI-agent onboarding files with AGENTS.md, CLAUDE.md, drift tracking, and lifecycle hooks.

Triggers on: PostToolUse, SessionStart.

```json
{
  "description": "Optional AIBoarding lifecycle nudges for Codex.",
  "hooks": {
    "SessionStart": [{
      "matcher": "startup|resume",
      "hooks": [{
        "type": "command",
        "command": "bash \"$PLUGIN_ROOT/hooks/codex-lifecycle\"",
        "commandWindows": "\"%PLUGIN_ROOT%\\hooks\\codex-lifecycle.cmd\"",
        "timeout": 10,
        "additionalContextLimit": 300
      }]
    }],
    "SubagentStart": [{
      "hooks": [{
        "type": "command",
        "command": "bash \"$PLUGIN_ROOT/hooks/codex-lifecycle\"",
        "commandWindows": "\"%PLUGIN_ROOT%\\hooks\\codex-lifecycle.cmd\"",
        "timeout": 10,
        "additionalContextLimit": 300
      }]
    }],
    "PostToolUse": [{
      "matcher": "^Bash$",
      "hooks": [{
        "type": "command",
        "command": "bash \"$PLUGIN_ROOT/hooks/codex-lifecycle\"",
        "commandWindows": "\"%PLUGIN_ROOT%\\hooks\\codex-lifecycle.cmd\"",
        "timeout": 15,
        "additionalContextLimit": 300
      }]
    }]
  }
}

```

© hashgraph-online · MIT · hashgraph-online/awesome-codex-plugins

Similar hooks

All hooks for Agent setup: memory, context, orchestration →

From the same set391

The whole set →
debt-ops The debt-ops hook records deferred tech-debt items in a repository registry, while a review skill ranks them by file churn. Use it to keep postponed cleanup visible during coding. CX Codex ★ 1,596repo stars cc cc — a hook bridge between Claude Code and Codex. It runs reviews, rescue tasks and tracked background jobs from Claude Code inside a Codex session. CX Codex ★ 1,596repo stars babok_analyst babok_analyst is a Claude Code hook bundle that manages the BABOK v3 business analysis agent’s session lifecycle and controls MCP tool execution through approval gates. CX Codex ★ 1,596repo stars archcore archcore is a Claude Code hook that brings Git project context into spec-driven development. It runs at session start, before file edits, and after Archcore document operations. CX Codex ★ 1,596repo stars ai-sdlc ai-sdlc — a hook bundle for a six-stage Markdown SDLC in Claude Code. It checks tool calls to block unauthorized file edits and safeguard sensitive project paths. CX Codex ★ 1,596repo stars agent-guard This hook checks tool activity for exposed secrets in Claude Code and Codex. It suits projects that need local checks plus Git and CI safeguards. CX Codex ★ 1,596repo stars a-team a-team is a hook for Claude Code that runs at session start and on clear or compact. It displays team status and loads session instructions. CX Codex ★ 1,596repo stars amazon-ads-create-dsp-campaign amazon-ads-create-dsp-campaign walks an Amazon DSP Performance+ or Brand+ campaign from intake to launch: paused setup, ad groups per tactic, then activation after two separate approvals. CX Codex +1 ★ 1,596repo stars

Project sponsors

Companies that keep this analytics open