Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add skills/d-o-hub/github-template-ai-agents/docs-hooknpx skills add d-o-hub/github-template-ai-agents --skill docs-hookgit clone --depth 1 https://github.com/d-o-hub/github-template-ai-agentsWhat it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00058 | $0.00700 |
| Opus 5 | $0.00029 | $0.00350 |
| Sonnet 5 | $0.00012 | $0.00140 |
| Haiku 4.5 | $0.00006 | $0.00070 |
Grade A, and why
docs-hook scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 89 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Docs Hook
Ultra-lightweight documentation sync via git hooks.
When to Use
- User asks to update agents-docs on commit or merge events
- Need to sync documentation with minimal tokens
- Even if they just say "update the docs" or "sync the agent docs"
Trigger
- "git hook", "on commit", "pre-commit"
- "sync docs", "update docs"
- "merge sync", "push docs"
Usage
# Full automatic sync (recommended):
./scripts/post-commit-docs-sync.sh
# Or use the lightweight docs-sync only:
./scripts/docs-sync.sh HEAD~1 HEAD
Automatic Sync on Commit
The post-commit-docs-sync.sh script provides comprehensive documentation syncing:
- Skill table updates: Regenerates AGENTS.md skill table when
.agents/skills/changes - LLM context regeneration: Updates
llms.txtandllms-full.txtwhen markdown changes - Agent registry sync: Updates
AGENTS_REGISTRY.mdwhen agent configs change - Docs file sync: Copies changed docs to appropriate directories
- Commit amendment: Automatically amends commit with updated documentation
Configuration
Environment variables control behavior:
| Variable | Default | Description |
|---|---|---|
DOCS_SYNC_ENABLED |
true |
Enable/disable docs sync |
DOCS_SYNC_QUIET |
false |
Suppress output messages |
DOCS_SYNC_LLM_TXT |
true |
Regenerate LLM context files |
Minimal Token Workflow
- Diff: Get changed
.mdfiles between commits - Sync: Copy to target directory
- Done: No ML, no logging, no metrics
Working Scripts
scripts/post-commit-docs-sync.sh- Full documentation sync orchestratorscripts/docs-sync.sh- Lightweight file synchronization only
See Also
learn— Extract learnings into AGENTS.mdagents-md— AGENTS.md best practices
Rationalizations
| Rationalization | Reality |
|---|---|
| "Docs can sync manually, no need for automation" | Manual sync is forgotten within days. Automation ensures consistency. |
| "The hook is slow, I'll skip it" | A few seconds of sync time prevents hours of out-of-date documentation debt. |
| "Only production docs need syncing" | Stale developer docs cause onboarding confusion and incorrect assumptions. |
What ships with it
2 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 2d ago First seen · 89 lines · 58 tokens per session scan A d806b64aeb40
docs-hook is a skill published in the GitHub repository d-o-hub/github-template-ai-agents (2 stars, last pushed 2d ago), licensed MIT. It adds 58 tokens to every session and 700 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other skills, from other repositories
git-flow-pr
Executes the full PR-driven development workflow: create an isolated feature branch from the current work, commit all staged changes, rebase cleanly onto the selected base branch (skipping any ancestor commits already merged), push the branch, and open a GitHub pull request linked to a related issue. Includes guidance…
memory-continuity
Preserves cross-session continuity with deterministic MEMORY.md, index.md, and snapshot handoffs under .agentic/memories/.
new-gh-issue-orchestration
Orchestrates a GitHub-issue-driven delivery workflow from issue intake to PR creation using reviewer-first then worker execution. Invoked when the user provides a GitHub issue link/number and asks to start end-to-end delivery.
git-worktree-workspaces
Sets up and uses Git worktrees for parallel task workspaces in the same repository clone, including safe cleanup of local worktrees. Invoked when the user asks to work on multiple branches at once, isolate tasks without extra clones, or create/remove worktrees.
client-approval
Draft a clean client approval request, set a 48h SLA with a 72h escalation, and track revision rounds so the third billable revision never slips through unbilled.
client-report
Turn a month of campaign data into a confident client report — executive summary, what worked, what didn't, next month's plan and a clean channel/KPI table with deltas.