Borrowing it
Nothing to install: this file belongs to ZENG3LD/gate4agent. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/ZENG3LD/gate4agent/master/CLAUDE.mdgit clone --depth 1 https://github.com/ZENG3LD/gate4agentWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/instructions/zeng3ld/gate4agent/claude-md)<a href="https://agentmods.dev/instructions/zeng3ld/gate4agent/claude-md"><img src="https://agentmods.dev/badge/instructions/zeng3ld/gate4agent/claude-md/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/instructions/zeng3ld/gate4agent/claude-md"><img src="https://agentmods.dev/badge/instructions/zeng3ld/gate4agent/claude-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What 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.1 | $0.01471 | $0.01471 |
| Opus 5.5 | $0.00588 | $0.00588 |
| Sonnet 5.5 | $0.00294 | $0.00294 |
| Haiku 4.5 | $0.00147 | $0.00147 |
Grade A, and why
gate4agent CLAUDE.md 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 1mo 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 — 114 lines — stays where its author put it; the contents beside it link to each section on GitHub.
gate4agent — everything about providers: library, node, C2
gate4agent owns everything about CLI coding-agent providers (Claude Code,
Codex, Kimi, Grok): the library that spawns, streams, resumes, and owns
their subprocesses over PTY, pipe, ACP, and daemon transports behind one
API; the node process that wraps providers for one machine and serves them
over a wire; and the C2 that reaches the nodes on remote machines. The
harness, TUI, observation, and task/mail stack lives in hatchery, a
sibling repository that links these crates by path and talks to the node
only through its wire (gate4agent-node-protocol) and the C2's
(gate4agent-c2-protocol).
Plans/handoffs/audits live in the owner's private workspace documentation
tree, not in this repository.
Two generations
- Transport core — the root
gate4agentcrate (src/) plusgate4agent-pty(the in-house PTY backend). Spawns and owns the vendor CLI subprocess directly: structured inline (JSONL), PTY (ConPTY / unix pty), plus the ACP and daemon compatibility surfaces. This is the original generation and the one every downstream crate ultimately calls into. - Session runtime substrate —
gate4agent-catalog→gate4agent-kernel→gate4agent-runtime-native→gate4agent-shell-native, plusgate4agent-types,gate4agent-adapters,gate4agent-engine,gate4agent-handle,gate4agent-tool-protocol,gate4agent-tool-engine,gate4agent-provider-ports,gate4agent-shell-history,gate4agent-shell-capabilities,gate4agent-shell-hooks,gate4agent-shell-managed-hooks,gate4agent-shell-one-shot. This is the second generation: the managed-session substrate a node embeds (catalog lookup → kernel session lifecycle → native runtime execution → native shell integration), and it calls DOWN into the transport core for the actual subprocess. It does not replace the transport core; it wraps it.
Node and C2
gate4agent-node(binarygate4agent-node) — the node server: wraps providers, owns PTY/inline/ACP sessions, the file browser, local git, and worktrees for its machine.gate4agent-node-protocolis its bounded wire contract,gate4agent-node-wirethe transport/auth/client.gate4agent-c2(binarygate4agent-c2) — the relay that aggregates node state and routes commands down;gate4agent-c2-protocolandgate4agent-c2-client(CLIgate4agent-c2ctl) are its contract and client.gate4agent-build-stamp— the content hash of THIS repository's working tree that every node/C2 handshake carries; peers built from different trees refuse each other.- The node names no harness. What a session's harness-MCP door is called —
server name, argv, the environment variables that carry its endpoint and
token — arrives from the caller in
HarnessMcpLaunchV1on the reservation. - The node derives no observation/telemetry vocabulary. It publishes
NodeEvent::Controland the agent stream; the C2 relays a sanitized telemetry view of control events (C2ControlEvent::detail, capabilitycontrol-detail-v1) to a client that negotiated it, and the client builds its own telemetry from that.
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.
- 1mo ago Changed · -55 lines · -963 tokens per session 9c0966143da7
- 1mo ago Changed · +148 lines · +2,121 tokens per session 25f9e804c5c0
- 2mo ago First seen · 21 lines · 313 tokens per session scan A 8a9b9167e096
gate4agent CLAUDE.md is an instructions file published in the GitHub repository ZENG3LD/gate4agent (9 stars, last pushed 15d ago), licensed MIT. It adds 1,471 tokens to every session, about $0.0059 per session on Opus 5.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 instructions, from other repositories
vscode buildNext.instructions.md
Working notes and architecture documentation for the new esbuild-based build system in build/next. Use when making changes to the new build pipeline (transpile/bundle commands, NLS plugin, source-map handling, resource copying, or self-hosting watch tasks).
next.js AGENTS.md
AGENTS.md instructions for vercel/next.js, covering next.js development guide, codebase structure, monorepo overview, core package: packages/next and other important packages.
vscode oss-third-party-notices.instructions.md
Instructions for microsoft/vscode, covering vs code oss third-party-notices pipeline, architecture, pipeline flow in ci, cache eligibility and rollout and applying the notice (cutover).
langchain AGENTS.md
AGENTS.md instructions for langchain-ai/langchain, covering global development guidelines for the langchain monorepo, corridor security analysis, project architecture and context, monorepo structure and development tools & commands.
vscode copilot-instructions.md
Copilot instructions for microsoft/vscode, covering vs code copilot instructions, project overview, root folders, core architecture (src/ folder) and built-in extensions (extensions/ folder).
generative-ai-for-beginners AGENTS.md
AGENTS.md instructions for microsoft/generative-ai-for-beginners, covering agents.md, project overview, setup commands, initial repository setup and clone the repository.