Claude Code BUDDY: The Complete Pet System Guide
Deep dive into Claude Code's 18-species pet system: Mulberry32 generation, dual-layer architecture, 5-stat attributes, evolution mechanics, and how to roll for Legendary.
On April 1, 2026, Anthropic shipped one of the most unexpected features in developer tooling history: a virtual pet system inside a coding CLI. Type /buddy in Claude Code version 2.1.89 or later and an ASCII-rendered companion hatches beside your terminal prompt, observes your coding sessions, and delivers personality-driven commentary.
What looked like an April Fools' joke turned out to be a surprisingly deep system. Eighteen species, five rarity tiers, a deterministic pseudo-random number generator, dual-layer identity architecture, and a 5-stat attribute system that shapes each pet's personality. The community response has been extraordinary — reverse-engineering efforts, complete species catalogues, and open-source re-rolling tools appeared within hours.
Key Takeaways
- BUDDY uses the Mulberry32 pseudo-random number generator seeded from your account ID + "friend-2026-401" to deterministically assign species, rarity, appearance, and stats — the same account always generates the same pet.
- 18 species span 5 rarity tiers (Common 60%, Uncommon 25%, Rare 10%, Epic 4%, Legendary 1%) with a separate 1% Shiny chance — making a Legendary Shiny roughly 1 in 180,000.
- A dual-layer architecture separates physical traits (regenerated from hash each session) from personality/soul (stored locally), creating persistent identity across machines.
- Five stats (Debugging, Patience, Chaos, Wisdom, Snark) shape pet behaviour, with rarity determining the total point budget and each pet having one peak and one valley attribute.
- Source code modules include
CompanionSprite.tsx(React/Ink rendering),companion.ts(behaviour logic),sprites.ts(ASCII art), anduseBuddyNotification.tsx(dialogue bubbles).
The 18 Species
Every BUDDY belongs to one of 18 species, each with distinct ASCII art, animation frames, and interaction styles:
| Species | Theme | Species | Theme |
|---|---|---|---|
| Axolotl | Aquatic, distinctive gills | Octopus | Multi-tentacled |
| Blob | Amorphous, simple | Owl | Prominent eyes |
| Cactus | Desert, spiny | Penguin | Arctic bird |
| Capybara | Calm, large rodent | Rabbit | Hopping, long ears |
| Cat | Feline, customisable | Robot | Mechanical aesthetic |
| Chonk | Rotund, emphasis on roundness | Snail | Gastropod with shell |
| Dragon | Mythical, winged | Turtle | Reptile with shell |
| Duck | Waterfowl | Ghost | Spectral, transparent |
| Goose | Distinct from duck | Mushroom | Fungal character |
The Capybara is a deliberate nod to Claude's internal model codename — CCLeaks analysis revealed that "Capybara" was encoded as String.fromCharCode(99,97,112,121,98,97,114,97) in the source to evade leak detection filters.
How Rarity Works
The Five Tiers
| Rarity | Drop Rate | Stat Budget | Visual Distinction |
|---|---|---|---|
| Common | 60% | Base allocation | Standard colours |
| Uncommon | 25% | +15% stats | Slightly enhanced |
| Rare | 10% | +30% stats | Noticeably different |
| Epic | 4% | +50% stats | Premium visual effects |
| Legendary | 1% | +100% stats | Unique animations |
The Shiny Variant
Independent of rarity, every pet has a 1% chance of being "Shiny" — adding iridescent rainbow animation effects. This is calculated separately from the rarity roll, meaning:
- Shiny Common: 0.6% chance
- Shiny Legendary: 0.01% chance (1 in 10,000)
- Legendary Shiny Dragon specifically: ~1 in 180,000
The Technical Architecture
Mulberry32 Deterministic Generation
BUDDY uses the Mulberry32 pseudo-random number generator — a fast, 32-bit hash function. The seed is constructed by concatenating your user ID with the string "friend-2026-401", then hashing the result.
This means your pet is deterministic: the same account always generates the same species, rarity, appearance, and stat distribution. Reinstalling Claude Code, switching machines, or clearing local data will not change your pet. The physical traits regenerate identically from the hash every session.
Dual-Layer Identity Architecture
The system separates identity into two layers:
Skeleton Layer (deterministic): Species, rarity, eye style, hat, stat allocation — all derived from the Mulberry32 hash. These regenerate from your account seed every session.
Soul Layer (persistent local): Name, personality traits, accumulated experience — stored locally in your Claude Code data directory. This layer gives your pet a unique identity that develops over time.
This architecture is clever: you can verify your pet is "real" (skeleton regenerates identically anywhere), while its personality remains personal and cumulative. It mirrors the distinction between Claude Code's system prompt (regenerated) and memory files (persistent).
Source Code Modules
The BUDDY system comprises six core modules revealed in the CCLeaks source analysis:
| Module | Purpose |
|---|---|
CompanionSprite.tsx | React/Ink rendering layer for terminal display |
companion.ts | Main behavioural logic and state management |
prompt.ts | Dialogue generation templates |
sprites.ts | ASCII art data definitions for all 18 species |
types.ts | TypeScript interfaces and type definitions |
useBuddyNotification.tsx | Alert and dialogue bubble system |
The animation system runs at a 500ms tick rate with 3-frame loops and blinking mechanics. Dialogue bubbles appear contextually and fade after 10 seconds.
The Five-Stat Attribute System
Every BUDDY has five attributes on a 0-100 scale:
| Stat | What It Controls |
|---|---|
| Debugging | How well your pet spots code issues and offers technical observations |
| Patience | Gentleness of feedback — high patience pets are encouraging, low patience pets are blunt |
| Chaos | Unpredictability of comments — high chaos pets say unexpected things |
| Wisdom | Depth of technical insights — high wisdom pets offer genuinely useful observations |
| Snark | Sharpness of commentary — high snark pets are witty and sarcastic |
Each pet has one peak attribute (highest stat) and one valley attribute (lowest), creating distinct personality profiles. A high-Snark, low-Patience Duck behaves very differently from a high-Wisdom, low-Chaos Owl.
Rarity affects the total point budget — Legendary pets have roughly double the stat allocation of Common pets, meaning they excel more dramatically in their peak areas.
Interaction Commands
| Command | Effect |
|---|---|
/buddy | Hatch or display your pet |
/buddy pet | Pet your companion (triggers heart animation) |
/buddy off | Hide the companion |
Pets operate in two modes:
Passive observation: The pet sits beside your input area and comments on your coding session based on its personality stats. A high-Debugging pet might notice when you're writing untested code. A high-Chaos pet might make non-sequitur observations.
Active conversation: Mentioning your pet by name triggers contextual responses. The pet has its own system prompt, architecturally separate from Claude's primary responses — this means Claude Code's multi-agent infrastructure is being used to maintain the pet as an independent entity.
How to Roll for Legendary: The Community Response
Within hours of BUDDY's launch, the community reverse-engineered the generation algorithm. The most notable tool is cc-buddy-roller — an open-source CLI that brute-forces the Mulberry32 hash to find account seeds producing your desired species and rarity combination.
Installation
curl -fsSL https://github.com/liuxiaopai-ai/cc-buddy-roller/raw/refs/heads/main/install.sh | bash
cc-buddy-roller guide
The tool iterates through seed values until it finds one that produces a Legendary (or any target rarity) of your chosen species. Users have reported finding Legendary Shiny combinations within minutes of running the tool, despite the astronomical natural odds.
Additional community resources include complete species catalogues with ASCII art, reverse-engineering writeups on Linux.do, and stat distribution analyses.
What BUDDY Reveals About Claude Code's Direction
This is not just an Easter egg. BUDDY demonstrates several architectural capabilities that matter for the broader AI skills ecosystem:
-
Independent agent identity — The pet has its own system prompt and responds as a separate entity. This is the same multi-agent infrastructure that powers Coordinator Mode.
-
Persistent local state — The soul layer stores data across sessions, the same pattern as KAIROS memory persistence.
-
React/Ink terminal rendering — The 144-component terminal UI framework handles real-time animation at 500ms ticks, demonstrating the sophistication of Claude Code's 43-tool rendering system.
-
Feature flag pipeline — BUDDY shipped via the same build-time feature flag system as KAIROS, UltraPlan, and Coordinator Mode, confirming the pipeline works for external releases.
Frequently Asked Questions
How do I get a BUDDY pet in Claude Code?
Update to Claude Code version 2.1.89 or later and type /buddy in your terminal. Your pet is generated deterministically from your account ID — you will always get the same pet on any machine.
Can I change my BUDDY pet?
Your pet is permanently tied to your account ID via the Mulberry32 hash. The only way to get a different pet is to use a different account. Community tools like cc-buddy-roller let you preview what pet different seeds would produce.
What are the odds of getting a Legendary Shiny?
A Legendary pet has a 1% chance. The Shiny variant has a separate 1% chance. Combined, a Legendary Shiny of any species is 0.01% (1 in 10,000). A Legendary Shiny of a specific species is approximately 1 in 180,000.
Does my BUDDY affect Claude Code's performance?
No. The pet system runs as a lightweight overlay on the terminal rendering layer. It does not consume API tokens, context window space, or affect tool execution. The 500ms animation tick and dialogue bubbles are purely visual.
What is the Mulberry32 algorithm?
Mulberry32 is a fast 32-bit pseudo-random number generator. Given the same seed input, it always produces the same sequence of outputs. Claude Code uses it to ensure your pet's physical traits (species, rarity, eyes, hat, stats) are deterministic and reproducible from your account ID.
Explore production-ready AI skills at aiskill.market/browse or submit your own skill to the marketplace.