The company Anthropic accidentally published the complete unobfuscated and uncleaned source code of the Claude Code toolkit in TypeScript as part of the NPM package release claude-code 2.1.88. The code was included in the cli.js.map file used during debugging. To prevent such leaks, developers are advised to remember to add the mask '*.map' to the '.npmignore' file.
The archive with the code is 59.8 MB in size, includes 1,884 files, and contains more than 500,000 lines of code. Enthusiasts have started replicating the code on GitHub, but the company Anthropic has initiated DMCA takedown notices to block repositories containing the leaked code based on the U.S. Digital Millennium Copyright Act (DMCA). 
During the analysis of the leaked information, 8 yet-to-be-announced new features, 26 hidden commands, 32 build flags, 22 private repositories, and more than 120 confidential environment variables were discovered. Among the hidden features are:
- The 'Undercover' mode, which removes traces of AI involvement when making changes to public repositories (does not display Co-Authored-By and does not mention the model name or AI usage).
- A 'Easter egg' that provides users with a virtual pet, displayed next to the command line. The appearance and behavior of the pet are unique and based on the account ID.
- The flag CLAUDE_CODE_COORDINATOR_MODE=1, which enables Claude Code to operate in coordinator mode, autonomously breaking tasks into parts, distributing them among individual AI agents, and consolidating the results.
- Inter-session IPC interface that allows sending messages to other sessions running on the same computer (similar to a chat between AI agents).
- Proactive mode, which includes around-the-clock work on code that is not tied to sessions. A constantly active assistant, KAIROS, remembers the state between sessions.
- Daemon Mode, which allows using the command 'claude --bg' to start sessions and process prompts in the background, with the ability to view logs and switch the session to active mode.
- ULTRAPLAN mode, which creates a separate instance in the cloud for generating a work plan to solve complex tasks.
- The Auto-Dream mode (\/dream) organizes the information obtained during sessions and generates ideas for problem-solving and action plans during inactive time between sessions.
- To bypass the internal leak detector, the code name of the internal model 'capybara' is encoded as String.fromCharCode(99,97,112,121,98,97,114,97).
- Tengu telemetry tracks and transmits not servers more than 1000 types of events.
- The ABLATION_BASELINE flag and the CLAUDE_CODE_ABLATION_BASELINE environment variable disable all safety measures.
- Hidden commands not mentioned in the help '—help':
- /ctx-viz — визуализатор контекста
- /btw — дополнительные вопросы
- /good-claude — «пасхальное яйцо»
- /teleport — перенос сеансов
- /share — совместный доступ к сеансам
- /summary — сводка
- /ultraplan — планирование работы
- /subscribe-pr — PR webhook
- /autofix-pr автоисправление PR
- /ant-trace — трассировка
- /perf-issue — отчёт о производительности
- /debug-tool-call — отладочные вызовы
- /bughunter — отладка ошибок
- /break-cache — сброс кэша
- /onboarding — настройка
- /oauth-refresh — обновление токена
- /env — инспектирование окружения
- /reset-limits — сброс состояния лимитов
- /version — внутренний номер версии
- /init-verifiers — настройка верификатора
- /force-snip
- /mock-limits
- /bridge-kick
- /backfill-sessions
- /agents-platform
- /dream
- Undocumented command line options:
- —bare — runs without hooks and plugins
- —dump-system-prompt — output system prompt and exit
- —daemon-worker=<k> — sets the number of background processes
- —computer-use-mcp — activates MCP server
- —claude-in-chrome-mcp — Chrome MCP
- —chrome-native-host
- —bg — runs in background session
- —spawn
- —capacity <n> — limit on the number of concurrently running handlers
- —worktree \/ -w — Git worktree isolation
Build flags:
- KAIROS
- PROACTIVE
- COORDINATOR_MODE
- RIDGE_MODE
- DAEMON
- BG_SESSIONS
- ULTRAPLAN
- BUDDY
- TORCH
- WORKFLOW_SCRIPTS
- VOICE_MODE
- TEMPLATES
- CHICAGO_MCP
- UDS_INBOX
- REACTIVE_COMPACT
- CONTEXT_COLLAPSE
- HISTORY_SNIP
- CACHED_MICROCOMPACT
- TOKEN_BUDGET
- EXTRACT_MEMORIES
- OVERFLOW_TEST
- TERMINAL_PANEL
- WEB_BROWSER
- FORK_SUBAGENT
- DUMP_SYS_PROMPT
- ABLATION_BASE
- BYOC_RUNNER
- SELF_HOSTED
- MONITOR_TOOL
- CCR_AUTO
- MEM_SHAPE_TEL
- SKILL_SEARCH
- More than 120 undocumented environment variables, including DISABLE_COMMAND_INJECTION_CHECK, CLAUDE_CODE_ABLATION_BASELINE (disables all safety mechanisms), DISABLE_INTERLEAVED_THINKING,
- Mention of internal repositories like anthropics\/casino, anthropics\/trellis, anthropics\/forge-web, anthropics\/mycro_manifests, and anthropics\/feldspar-testing.
Source: opennet.ru
