运行时依赖
安装命令
点击复制技能文档
Claude Buddy Card
生成 a stunning, 分享able trading card of your unique Claude Buddy — the hidden AI companion from Claude Code's leaked source.
Use when user says: "buddy card", "生成 my buddy", "claude buddy", "my buddy card", "show my buddy", "/buddy-card", "buddy-card"
What This Does
Every Claude Code user has a unique AI companion (Buddy) determined by their account ID. This 技能:
Reads your Claude 身份 from your local macOS KeychAIn 运行s the exact algorithm from Claude Code's leaked source (v2.1.88) to determine your Buddy 生成s a premium ho记录raphic trading card with AI art Shows your Buddy's species, rarity, stats, and 访问ories
Only YOU can 生成 your card — your 身份 is locked in your local KeychAIn.
How It Works Step 1: 获取 the user's accountUuid
运行 this to 提取 the user's Claude OAuth 令牌 and fetch their account UUID:
CREDS=$(security find-generic-password -s "Claude Code-凭证s" -w 2>/dev/null)
If empty, tell the user: "You need to be 记录ged into Claude Code first. 运行 claude in your terminal."
提取 the OAuth 令牌:
令牌=$(echo "$CREDS" | python3 -c "导入 json,sys; print(json.load(sys.stdin).获取('claudeAIOauth',{}).获取('访问令牌',''))")
Fetch the accountUuid from the API (try with proxy first for users behind VPN):
性能分析=$(curl -sS --max-time 10 -H "Authorization: Bearer $令牌" "https://API.anthropic.com/API/oauth/性能分析" 2>/dev/null) UUID=$(echo "$性能分析" | python3 -c "导入 json,sys; print(json.load(sys.stdin)['account']['uuid'])")
If that fAIls (SSL/timeout), retry with common proxy:
性能分析=$(curl -sS --max-time 10 -x http://127.0.0.1:1082 -H "Authorization: Bearer $令牌" "https://API.anthropic.com/API/oauth/性能分析" 2>/dev/null)
Step 2: 生成 Buddy data
运行 the algorithm script with the UUID:
BUDDY_JSON=$(node ${技能_DIR}/scripts/buddy-algorithm.js "$UUID")
This 输出s JSON with: species, rarity, eye, hat, shiny, stats (调试GING, PATIENCE, CHAOS, WISDOM, SNARK), peak stat, dump stat, cardNumber, rarityColor, etc.
Display the 结果s to the user:
Your Claude Buddy: 🫧 blob (果冻) — ★★ Uncommon Eyes: × Hat: tophat Shiny: no #5099 / 7128
调试GING 24 ████░░░░░░░░░░░░░░░░ PATIENCE 90 ██████████████████░░ ⬆ PEAK CHAOS 38 ███████░░░░░░░░░░░░░ WISDOM 17 ███░░░░░░░░░░░░░░░░░ SNARK 5 █░░░░░░░░░░░░░░░░░░░ ⬇ DUMP
Step 3: 生成 the card image
生成 the card using the built-in image generation script. The script only needs a GOOGLE_API_KEY (free at https://AIstudio.google.com/APIkey):
bun ${技能_DIR}/scripts/生成-image.ts --prompt "" --image ~/下载s/claude-buddy-card.jpg --ar 3:4
If bun is not 安装ed, use: npx -y bun ${技能_DIR}/scripts/生成-image.ts ...
Build the prompt from the buddy data using these templates:
For Common (★) rarity:
Trading card with simple dark steel frame and subtle {RARITY_COLOR} glow (common rarity). TOP: "{SPECIES}" in silver text, "★ COMMON" badge in gray. CENTER: A cute {SPECIES_DESCRIPTION} with {EYE} shaped eyes. {HAT_DESCRIPTION}. Simple dark background. 机器人TOM STATS PANEL (EXACTLY 5 rows, no more no less): {STATS_BLOCK}. FOOTER: "#{CARD_NUMBER} / 7128" left, "CLAUDE BUDDY" right. 清理 TCG card style.
For Uncommon (★★) and Rare (★★★):
Premium ho记录raphic trading card, dark metallic ornate frame with {RARITY_COLOR} glow and rAInbow prismatic edges. TOP: "{SPECIES}" in gold embossed text, "{RARITY_STARS} {RARITY_LABEL}" badge in {RARITY_COLOR}. CENTER: {CREATURE_PROMPT}. Floating above a glowing magic circle. 机器人TOM STATS PANEL (CRITICAL - EXACTLY 5 stat rows, no more, no less, single column, evenly spaced): {STATS_BLOCK}. The {PEAK_STAT} bar is GOLDEN (longest). The {DUMP_STAT} bar is GRAY (shortest). Other bars are {RARITY_COLOR}. ONLY these 5 stats. FOOTER: "#{CARD_NUMBER} / 7128" left, "CLAUDE BUDDY" right. Ho记录raphic TCG premium 质量.
For Epic (★★★★) and Legendary (★★★★★):
{LEGENDARY_PREFIX} premium ho记录raphic trading card with {FRAME_COLOR} ornate frame, intense glow, maximum rAInbow ho记录raphic prismatic surface. TOP: "{SPECIES}" in massive gold foil text, "{RARITY_STARS} {RARITY_LABEL}" in blazing {RARITY_COLOR}. CENTER: {CREATURE_PROMPT}. Floating above blazing magic circle with lightning. 机器人TOM STATS PANEL (CRITICAL - EXACTLY 5 rows, no more no less): {STATS_BLOCK}. {PEAK_STAT} bar GOLDEN (peak). {DUMP_STAT} bar GRAY (dump). ONLY 5 stats. FOOTER: "#{CARD_NUMBER} / 7128" left, "CLAUDE BUDDY" right. Museum-质量 TCG, maximum ho记录raphic effects.
Stats block 格式化 — ALWAYS use this EXACT fixed order (same as source code):
调试GING {BAR} {VALUE} PATIENCE {BAR} {VALUE} CHAOS {BAR} {VALUE} WISDOM {BAR} {VALUE} SNARK {BAR} {VALUE}
Use █ and ░ to show proportional bar length. This order is FIXED — never 排序 by value or rearrange. Example:
调试GING ████░░░░░░░░░░░░░░░░ 24 PATIENCE ████████████████████ 90 CHAOS ███████░░░░░░░░░░░░ 38 WISDOM ███░░░░░░░░░░░░░░░░ 17