Claude.md and Parallelism Drive Consistent, Scalable Coding

Load Claude.md (40k characters) into every prompt to enforce codebase architecture, coding standards, team patterns, and best practices—users often underuse it, but this ensures the LLM follows your exact style without retraining. For scalability, build for parallelism: spin up 5-10 sub-agents sharing prompt caches for free concurrency, using git worktrees (isolated branches per agent) to avoid conflicts. Three sub-agent models—fork (inherits parent cache), teammate (separate pane with file-based mailbox), and worktree—outperform single-agent flows, as confirmed by Claude Code's inventor. Result: faster, conflict-free handling of large codebases versus sequential processing.

Smart Permissions and Multi-Layer Compaction Prevent Failures

Preconfigure permissions in settings.json across three modes—bypass (no checks, dangerous), allow-edits (auto file ops), or auto (LLM classifies actions on first run, predicts approvals)—eliminating constant user prompts that frustrate sessions. The 'auto' mode balances speed and safety by skipping obvious yeses and blocking risks, deprecating manual 'dangerously-skip' flags.

Compaction is key to long-context reliability: use /compact proactively on 200k-token default (or opt to 1M, still outperforming rivals past 200k) to retain essentials while forgetting noise. Five methods—micro-compact (time-clears old tool results), context-collapse (summarizes spans, lossy), session-memory (files key context like tasks/errors), full-compact (whole history), PTL-truncation (drops oldest messages)—plus disk-storing large tool results (8kb preview to model) keep inputs focused. Resuming sessions via JSONL files preserves structured summaries (tasks, files, state), beating fresh starts for momentum.

Hooks, Tools, and Streaming Enable Power-User Customization

Hook into 6+ events (pre/post-tool, prompt-submit, session start/end) via 5 types (command, prompt, agent, HTTP, function) to automate workflows like auto-updating docs on commits. 66 builtin tools split concurrent (read-only, parallel-safe like browsing/reading) from serialized (mutating like edits/bash, one-at-a-time) for efficient delegation.

Streaming makes interruptions cheap—stop misguided outputs instantly without token loss, resuming seamlessly to avoid sunk-cost errors. Run locally via Python rewrite (legal, model-agnostic) for any LLM, though Claude excels due to harness-model synergy.

Leak Accelerates Open-Source Agent Innovation

22M X views in <24h expose harness secrets without API keys or data breaches, letting competitors study prompts, agent chains, and permissions to build cheaper/better alternatives like Open Code. Tinkerers integrate ideas (e.g., sub-agent sharing) into projects, hardening security via crowd scrutiny. Pair with tools like Zapier MCP for 1000s of integrations, turning any agent into a supertool—fuels recursive self-improvement in meta-harnesses.