PhucUSk20/pixel-familiars/tree/main/plugins/pixel-pet
この mod について
<p align="center"> <img src="docs/images/slime.gif" width="160" alt="呼吸し、まばたきし、跳ね、喜ぶピクセルスライム"> </p> <h1 align="center">Pixel Familiars</h1> <p align="center"><strong>Codex</strong> と <strong>Claude Code</strong> のための動くピクセルコンパニオン。<br>生きたピクセル世界を通して、AI の活動、コンテキスト、クォータを確認できます。</p> <p align="center"> <a href="#codex"><img alt="Codex companion" src="https://img.shields.io/badge/Codex-VS_Code-5aa9ff"></a> <a href="#claude-code"><img alt="Claude Code companion" src="https://img.shields.io/badge/Claude_Code-terminal-ffe25a"></a> <a href="LICENSE"><img alt="License: MIT" src="https://img.shields.io/badge/license-MIT-5aa9ff"></a> </p>PhucUSk20 が所有・保守しています。Namenomeaning/pixel-pet をベースにしつつ、原作者表示と MIT の告知を保持しています。
コンパニオンを選ぶ
どちらの統合も共有ピクセルエンジンとテーマ形式を使います。それぞれが独自のランタイムに接続するため、イベントストリームと表示面の違いに応じて機能が異なります。
| | Codex | Claude Code | | --- | --- | --- | | 表示 | レスポンシブな VS Code パネル | プロンプト上のペット、下の HUD | | アクティビティ | ネイティブ hooks。利用できない場合はセッションログにフォールバック | Claude Code mod イベント | | 共通のペット動作 | 読み取り、検索、書き込み、ターミナル、ウェブ、思考、祝福 | 読み取り、検索、書き込み、ターミナル、ウェブ、思考、祝福 | | HUD | 残りコンテキストと報告されたクォータ/リセット時刻 | 残りコンテキストと報告されたクォータ/リセット時刻 | | カスタマイズ | MCP テーマツール、プレビュー、インポート | プラグイン skill、プレビュー、テーマツール | | タスクコンパニオン | Portal workers、subagent minis、自動プロジェクト Mini | メインペットに続く subagent minis | | アイドル時の遊び | 独立した徘徊と 20 種類のペットインタラクション | 呼吸、周囲を見る、睡眠 | | Legendary Pet | 5 つの Mega Rayquaza アクションを持つ独立パネル | Codex VS Code companion から利用可能 | | 詳細ガイド | Codex guide | Claude Code guide |
監視とアニメーションはローカルで動作し、AI の呼び出しやトークンを消費しません。AI にテーマを作り直させる場合は、通常のチャット/ツールワークフローを使います。
はじめに
このリポジトリをクローンして Codex companion をインストールするか、Claude プラグインをソースから直接読み込みます。
git clone https://github.com/PhucUSk20/pixel-familiars.git
cd pixel-familiars
Codex
要件:Node 22.18+、code コマンドを利用できる VS Code、Codex 拡張機能。
クローンしたフォルダーからインストールコマンドを 1 つ実行します。
npm.cmd run install:codex
macOS/Linux では npm run install:codex を使います。インストーラーは依存関係をダウンロードし、拡張機能をビルド/パッケージ化してインストールし、ローカル observer hooks と MCP テーマツールを設定します。hook の確認用に同梱の Codex CLI を開きます。
- プロンプトが表示されたらフォルダーの信頼を許可します。/hooks を入力し、12 個の Pixel Pet observer エントリを確認して信頼します。
- 確認用 CLI を終了します。Developer: Reload Window を実行し、VS Code で Pixel Pet: Open Companion を実行します。
- 新しい Codex 会話を開始してツールを実行します。実際のイベントを受け取ると、パネルに Direct hooks と表示されます。
Direct hooks は最も完全なツール/subagent のタイミングとコンパクションアニメーションを提供します。ネイティブイベントを利用できない場合は Log fallback も使えますが、ネストしたすべての開始時刻を復元することはできません。確認は Codex が必要とするもので、自動的には許可されません。承認後は確認用 CLI を閉じられます。
<p align="center"><img src="docs/images/codex-pet-summoning.gif" width="816" alt="Codex デモ:空のポータルから独立した Read、Edit、Run worker が現れ、結果を届ける"></p>ツールは色付きの空のポータルを通じて worker minis を呼び出します。並列作業では、記録された完了まで各 worker が分離されたままになります。成功するとメインペットに小包が戻り、失敗するとクリックできるエラー標識が現れます。永続する Mini は観測されたチェックとエディターエラーを自動的に監視します。
ペットは独立して探索し、20 種類のアイドルインタラクションにも時々参加します。Feed はピクニックを誘い、Play はキャッチを始め、Rest は自律的な遊びを一時停止します。実際の作業が遊びに割り込みます。草原はパネル幅いっぱいに広がり、狭いパネルではコンパクト HUD が隅に移動します。職場の建物は一時的に無効です。
<p align="center"><img src="docs/images/codex-pet-actions.gif" width="816" alt="Codex デモ:20 種類のローカルなペットインタラクションのギャラリー"></p>Codex GIF は本番レンダラーでシミュレートしたアクティビティを使います。インストーラーを再実行し、変更された hook 定義を確認して更新します。Codex guide でセッション選択、クォータの読み取り、設定、プライバシー、パネル配置を確認してください。ペットは Codex のチャットに埋め込まれたものではなく、独立したビューです。
Claude Code
要件:Claude Code 2.1.287+(claude --version)。このリポジトリの marketplace からプラグインをインストールします。
claude plugin marketplace add PhucUSk20/pixel-familiars
claude plugin install pixel-pet@pixel-pet
新しいセッションを開始するか、/reload-plugins を実行します。ペットはターミナルのプロンプト上に表示され、その下にコンテキスト/クォータ HUD が表示されます。
marketplace とプラグインは既存の pixel-pet 識別子を保持します。元の marketplace をすでに使っている場合も、そのインストールを変更せずに、この checkout を 1 セッション試せます。
claude --plugin-dir ./plugins/pixel-pet
<p align="center"><img src="docs/images/demo.gif" width="806" alt="Claude Code デモ:読み取り、検索、subagent minis、ウェブ取得、編集、失敗したテスト、祝福"></p>
ペットは読み取り、検索、書き込み、ターミナルコマンド、ウェブアクティビティを演じます。サブエージェントには完了まで残る minis が表示されます。ツールが失敗するとペットの表情が変わり、ターンが完了すると喜びます。アイドル時は呼吸、まばたき、睡眠を行います。
/plugin configure pixel-pet@pixel-pet で速度、睡眠、HUD、ステータステキスト、subagent minis を設定できます。Claude にペットをカスタマイズさせるか、/pixel-pet:pixel-pet を実行します。テーマを適用する前にブラウザプレビューを確認してください。設定、更新、対応ディスプレイ、プライバシー、開発チェックについては Claude Code guide を参照してください。
コンテキストとクォータ HUD
- HP:残りのコンテキストウィンドウ。
- MP:報告された残り 5 時間クォータとリセットまでのカウントダウン。
- ST:報告された残り 7 日クォータとリセットまでのカウントダウン。
クォータの可用性はランタイムとアカウントによって異なります。読み取りがない場合は不明のままです。バーは観測された使用量を示すもので、追加権限や保証されたタスク容量を示すものではありません。少ない読み取り値では色とペットの表情が変わります。
自分のものにする
どちらの統合も共有 テーマ形式 を通じて、カスタムピクセルペット、プロップ、エフェクト、ステータステキスト、HUD の色、シーンをサポートします。
紫色のスライム、ラバーダック、月のシーン、ウェブ検索用のレーダー、または FUEL という名前の HUD を試してください。Codex は get_theme、get_theme_format、preview_theme、set_theme を使い、Claude Code はプラグインの skill とテーマツールを使います。適用前に結果をプレビューします。
<p align="center"><img src="docs/images/pets.gif" width="440" alt="ピクセルスライムとカスタムラバーダック"></p>Legendary Pet
VS Code で Pixel Pet: Open Legendary Pet を実行すると、独立したパネルが開きます。Mega Rayquaza には flight、curled sleep、roar、Dragon Pulse、dash/braking の 5 つのアクションがあり、滑らかな遷移、Auto、Pause に対応します。Hình gốc は比較用に元のフレームを変更せず再生します。
<p align="center"><img src="docs/images/legendary-source-actions.gif" width="700" alt="滑らかな遷移と眠る頭部が見える Mega Rayquaza の 5 つのアクション"></p>アニメーションはローカルで実行され、AI セッションを共有せず、モデルリクエストも行いません。
開発
- 共有エンジンと Claude adapter: plugins/pixel-pet/。
- Codex adapter と VS Code パネル: extensions/codex/。
- ビルド、パッケージ化、録画: tools/codex/。
- 独立リポジトリのワークフローと上流への貢献: development guide。
Codex companion では npm.cmd ci、npm.cmd run typecheck、npm.cmd test、npm.cmd run package を実行します。ホスト、レンダラー、ブリッジを変更した後は npm.cmd run test:ui も実行します。macOS/Linux では npm を使います。
Claude プラグインを変更した場合は CLAUDE.md に従い、次を実行します。
claude plugin validate . --strict
claude plugin validate plugins/pixel-pet --strict
claude plugin test plugins/pixel-pet
Claude Code guide には生成型のセットアップとプレビュー確認が含まれます。npm.cmd run record:codex-pets または npm.cmd run record:legendary で Codex GIF を再作成できます(Chrome/Edge と ffmpeg が必要です)。
プライバシーとセキュリティ
Codex companion はローカル hooks、ワークスペース範囲のセッションログ、プロジェクト診断を監視します。サニタイズ済みのアクティビティメタデータは保持しますが、プロンプト、推論、完全なツール出力は保持しません。OpenAI のインストール済み拡張機能を変更したり、ツールを承認したりはしません。
Claude プラグイン は Claude Code 内で動作し、そのテーマ/セッション使用量/subagent 状態を読み取ってペットを描画します。この mod はネットワーク要求を行わず、プロセスを起動せず、環境変数も読み取りません。任意のステータスターゲットには短いファイル/コマンドヒントが表示されます。画面共有時はオフにしてください。
詳細は各統合のガイドを参照してください。脆弱性は 非公開のセキュリティアドバイザリ から報告してください。
ライセンスとクレジット
MIT。Pixel Familiars は PhucUSk20 が保守しています。元の Pixel Pet は Namenomeaning/pixel-pet の halluqinate によるものです。元の著作権表示とコミット作者情報は保持されています。
インストール
まず作者の README で marketplace とプラグイン名を確認してください。コマンドはリポジトリの構成によって変わる場合があります。
claude plugin marketplace add PhucUSk20/pixel-familiars claude plugin install pixel-pet
原文 / README
Owned and maintained by PhucUSk20. Based on Namenomeaning/pixel-pet, with original authorship and MIT notices preserved.
Choose your companion
Both integrations use the shared pixel engine and theme format. Each connects to its own runtime; features differ where their event streams and display surfaces differ.
| | Codex | Claude Code | | --- | --- | --- | | Display | Responsive VS Code panel | Pet above the terminal prompt, HUD below | | Activity | Native hooks, with a session-log fallback | Claude Code mod events | | Shared pet motions | Read, search, write, terminal, web, think and celebrate | Read, search, write, terminal, web, think and celebrate | | HUD | Context remaining and reported quota/reset times | Context remaining and reported quota/reset times | | Customization | MCP theme tools, preview and import | Plugin skill, preview and theme tools | | Task companions | Portal workers, subagent minis and automatic project Mini | Subagent minis following the main pet | | Idle play | Independent roaming and 20 pet interactions | Breathing, looking around and sleep | | Legendary Pet | Independent panel with five Mega Rayquaza actions | Available through the Codex VS Code companion | | Detailed guide | Codex guide | Claude Code guide |
Observation and animation run locally and add no AI calls or tokens. Asking an AI to redesign a theme uses its normal chat/tool workflow.
Get started
Clone this repository to install the Codex companion or load the Claude plugin directly from source:
git clone https://github.com/PhucUSk20/pixel-familiars.git
cd pixel-familiars
Codex
Requirements: Node 22.18+, VS Code with the code command available, and the Codex extension installed.
Run one installation command from the cloned folder:
npm.cmd run install:codex
On macOS/Linux, use npm run install:codex. The installer downloads dependencies, builds/packages the extension, installs it and configures the local observer hooks and MCP theme tools. It opens the bundled Codex CLI for hook review:
- Approve folder trust if prompted. Enter
/hooks, review and trust the 12 Pixel Pet observer entries. - Exit the review CLI. Run Developer: Reload Window, then Pixel Pet: Open Companion in VS Code.
- Start a new Codex conversation and run a tool. The panel should show Direct hooks after receiving a real event.
Direct hooks provides the fullest tool/subagent timing and compaction animations. Log fallback remains available when native events are unavailable; it cannot recover every nested start time. Review is required by Codex and is not granted automatically. The review CLI can close after approval.
<p align="center"><img src="docs/images/codex-pet-summoning.gif" width="816" alt="Codex demo: sky portals summon independent Read, Edit and Run workers, with result deliveries"></p>Tools summon worker minis through colored sky portals. Parallel work keeps separate workers until recorded completion. Success brings a parcel back to the main pet; failure brings a clickable error sign. The persistent Mini watches observed checks and editor errors automatically.
The pets also explore independently and occasionally meet for 20 different idle interactions. Feed invites a picnic, Play starts catch, and Rest pauses autonomous play. Real work interrupts play. The meadow fills the panel width, and short panels move the compact HUD into a corner. Workplace buildings are temporarily disabled.
<p align="center"><img src="docs/images/codex-pet-actions.gif" width="816" alt="Codex demo gallery of 20 different local pet interactions"></p>The Codex GIFs use simulated activity with the production renderer. Update by rerunning the installer and reviewing changed hook definitions. Read the Codex guide for session selection, quota readings, settings, privacy and panel placement. The pet is a separate view rather than an embedded part of Codex's chat.
Claude Code
Requirement: Claude Code 2.1.287+ (claude --version). Install the plugin from this repository's marketplace:
claude plugin marketplace add PhucUSk20/pixel-familiars
claude plugin install pixel-pet@pixel-pet
Start a new session, or run /reload-plugins. The pet appears above the terminal prompt with its context/quota HUD below.
The marketplace and plugin retain their established pixel-pet identifiers. If you already use the original marketplace, you can try this checkout for one session without changing that installation:
claude --plugin-dir ./plugins/pixel-pet
<p align="center"><img src="docs/images/demo.gif" width="806" alt="Claude Code demo: reading, searching, subagent minis, web fetching, editing, failed tests and celebration"></p>
The pet acts out reading, searching, writing, terminal commands and web activity. Subagents get minis that remain until they finish. Tool failures change the pet's expression; completed turns make it cheer. Idle time brings breathing, blinking and sleep.
Run /plugin configure pixel-pet@pixel-pet for speed, sleep, HUD, status text and subagent minis. Ask Claude to customize a pet or run /pixel-pet:pixel-pet; review its browser preview before applying the theme. See the Claude Code guide for settings, updating, supported displays, privacy and development checks.
Context and quota HUD
- HP: context window remaining.
- MP: remaining reported 5-hour quota, with a reset countdown.
- ST: remaining reported 7-day quota, with a reset countdown.
Quota availability depends on the runtime and account. Missing readings stay unknown. The bars reflect observed usage, not extra permissions or guaranteed task capacity. Low readings change colors and pet expressions.
Make it yours
Both integrations support custom pixel pets, props, effects, status text, HUD colors and scenes through the shared theme format.
Try a purple slime, a rubber duck, a moon scene, a radar for web searches or a HUD named FUEL. Codex uses get_theme, get_theme_format, preview_theme and set_theme; Claude Code uses its plugin skill and theme tools. Preview the result before applying it.
Legendary Pet
In VS Code, run Pixel Pet: Open Legendary Pet for an independent panel. Mega Rayquaza has five actions: flight, curled sleep, roar, Dragon Pulse and dash/braking, with smooth transitions, Auto and Pause. Hình gốc plays the unchanged source frames for comparison.
<p align="center"><img src="docs/images/legendary-source-actions.gif" width="700" alt="Five Mega Rayquaza actions with smooth transitions and a visible sleeping head"></p>Its animation runs locally, shares no AI session and makes no model requests.
Develop
- Shared engine and Claude adapter:
plugins/pixel-pet/. - Codex adapter and VS Code panels:
extensions/codex/. - Build, packaging and recordings:
tools/codex/. - Independent repo workflow and upstream contributions: development guide.
For the Codex companion, run npm.cmd ci, npm.cmd run typecheck, npm.cmd test and npm.cmd run package. Also run npm.cmd run test:ui after host, renderer or bridge changes. On macOS/Linux, use npm.
For Claude plugin changes, follow CLAUDE.md and run:
claude plugin validate . --strict
claude plugin validate plugins/pixel-pet --strict
claude plugin test plugins/pixel-pet
The Claude Code guide includes generated-type setup and preview checks. Recreate Codex GIFs with npm.cmd run record:codex-pets or npm.cmd run record:legendary (Chrome/Edge and ffmpeg required).
Privacy and security
The Codex companion observes local hooks, workspace-scoped session logs and project diagnostics. It retains sanitized activity metadata, not prompts, reasoning or full tool output. It does not modify OpenAI's installed extension or approve tools.
The Claude plugin runs inside Claude Code, reads its theme/session usage/subagent state and draws the pet. The mod makes no network requests, starts no processes and reads no environment variables. Its optional status targets show short file/command hints; turn those off when sharing your screen.
See each integration's guide for details. Report vulnerabilities through a private security advisory.
License and attribution
MIT. Pixel Familiars is maintained by PhucUSk20. Original Pixel Pet by halluqinate, from Namenomeaning/pixel-pet. Original copyright notices and commit authorship are preserved.

