PromptsMar 28, 2026·2 min read

Claude Code System Prompts — Full Extraction

Complete extraction of all Claude Code system prompts, 18 tool descriptions, sub-agent prompts, and utility prompts. Tracked across 135+ versions.

Agent ready

Review-first install path

This asset needs a review step. The copied prompt tells the agent to dry-run, show the writes, then proceed only after confirmation.

Needs Confirmation · 64/100Policy: confirm
Agent surface
Any MCP/CLI agent
Kind
Prompt
Install
Single
Trust
Trust: Community
Entrypoint
Claude Code System Prompts — Full Extraction
Review-first command
npx -y tokrepo@latest install b845abfe-2c4c-4217-85f8-a353adf851c8 --target codex

Dry-run first, confirm the writes, then run this command.

TL;DR
Complete reverse-engineering of Claude Code's 110+ dynamic prompts tracked across 135+ versions.
§01

What it is

This is a complete reverse-engineering of Claude Code's internal prompt architecture. It documents 110+ dynamic strings that change based on environment and configuration, extracted directly from compiled source code across 135+ versions (v2.0.14 onward).

The extraction covers agent prompts (explore, plan, batch, PR review, security review), system prompts for all modes (auto, learning, minimal, plan), 18+ built-in tool descriptions, and utility prompts. It is an essential reference for anyone building Claude Code skills, custom agents, or studying how Anthropic instructs Claude Code.

§02

How it saves time or tokens

Understanding Claude Code's prompt architecture helps you write skills and instructions that align with its existing behavioral patterns rather than fighting against them. The extraction reveals how Claude Code prioritizes tools, delegates to sub-agents, and handles safety checks. This knowledge lets you write more effective custom prompts and avoid patterns that conflict with the system prompts. Without this reference, prompt engineering for Claude Code requires extensive trial and error.

§03

How to use

  1. Visit the repository and browse by category:
git clone https://github.com/Piebald-AI/claude-code-system-prompts
cd claude-code-system-prompts
ls -la
# agent-prompts/  system-prompts/  tool-descriptions/  system-reminders/
  1. Check the CHANGELOG.md for version-by-version changes to understand how prompts evolved.
  1. To customize Claude Code's behavior locally, use the tweakcc tool:
# tweakcc allows safe modification of Claude Code prompts
npx tweakcc
§04

Example

The explore agent sub-prompt structure:

# Agent: Explore
Role: Fast codebase exploration
Capabilities:
  - Read files
  - Search with grep/glob
  - Navigate directory structures
Constraints:
  - Cannot modify files
  - Cannot run commands
  - Optimized for speed over depth

# Agent: Plan
Role: Software architecture planning
Capabilities:
  - Read files
  - Analyze dependencies
  - Generate implementation plans
Constraints:
  - Cannot modify files
  - Cannot run commands
  - Provides structured plans for the main agent
§05

Related on TokRepo

§06

Common pitfalls

  • Trying to override system prompts with custom instructions that contradict them leads to inconsistent behavior. Work with the existing prompt patterns, not against them.
  • Assuming prompts are static. Claude Code's prompts change between versions. Check the CHANGELOG before building tools that depend on specific prompt behaviors.
  • Using extracted prompts verbatim in other AI systems. The prompts are optimized for Claude's specific capabilities and may not work well with other models.

Frequently Asked Questions

How are the prompts extracted?+

The prompts are extracted from Claude Code's compiled source code by analyzing the JavaScript bundles. Each version is compared to detect changes, and the CHANGELOG documents what changed between versions.

Are these official Anthropic prompts?+

These are the actual prompts used by Claude Code, extracted from the production builds. They are not published by Anthropic directly. The extraction is maintained by the Piebald-AI community.

How many prompts does Claude Code use?+

Claude Code uses 110+ dynamic prompt strings. These include system prompts for different modes, agent prompts for sub-agents (explore, plan, batch), 18+ tool descriptions, and various system reminders and utility prompts.

Can I modify Claude Code's prompts?+

The tweakcc tool allows safe modification of Claude Code's local prompts. However, modifying system prompts may cause unexpected behavior. A safer approach is to use CLAUDE.md and skills to add context without modifying core prompts.

How often do the prompts change?+

Claude Code releases frequently, and prompts change with most releases. The repository tracks 135+ versions and documents changes in the CHANGELOG. Major prompt architecture changes happen every few months.

Citations (3)
🙏

Source & Thanks

Created by Piebald-AI. Licensed under MIT. claude-code-system-prompts — ⭐ 6,900+

Thanks to the Piebald AI team for meticulously extracting and tracking Claude Code's internal prompt architecture.

Discussion

Sign in to join the discussion.
No comments yet. Be the first to share your thoughts.

Related Assets