hatch

A guided command for creating a pets-driven pet linked to the current project folder. Pets-driven is a local tool that connects coding agents with a desktop companion.

In plain words
What is it for?
It confirms the folder, checks existing pets, and creates or binds one when appropriate, asking for a name if needed.
Why use it?
It checks whether the folder already has a pet and uses the project's command-line tool to keep shared state consistent.

Command

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/young1the/pets-driven/hatch
Clone the repo
git clone --depth 1 https://github.com/young1the/pets-driven
Per session 14 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,409 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00014 $0.01409
Opus 5 $0.00007 $0.00705
Sonnet 5 $0.00003 $0.00282
Haiku 4.5 $0.00001 $0.00141

Measured yesterday against content hash e31b1f43ef46, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

hatch scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

plugins/pets-driven/commands/hatch.md · 116 lines

How it starts

The opening of the file, as written. The whole thing — 116 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Guide the user through creating a new pets-driven pet bound to a project folder. Do the steps in order, one prompt at a time, and stop if the user cancels.

Use the pdd CLI (on the user's PATH) for every pets-driven operation. It reads and writes the shared state file directly and safely — a cross-process lock keeps it from racing the desktop app — so it works whether or not the app is running. Never hand-edit the state file yourself; go through pdd. (If pdd is not installed, say so and stop.)

  1. Confirm the folder. Default to the current working directory. Show it and ask whether to use it or a different existing path. This becomes the pet's home folder.

    Check what already exists before hatching:

    pdd list
    

    Each pet comes back as {"id","name","assetId","personalityId","cwd",…}. A folder holds at most one pet, so if one already reports this folder as its cwd, say so and stop — there is nothing to hatch. A pet's cwd can be null: that pet exists with no folder bound. Offer to bind it to this folder (see below) instead of hatching a new one.

  2. Ask for a name. Nothing is required: an omitted name defaults to the bound folder's own name, the asset (look) and personality to a random pick, and the folder to the current directory. Suggest the folder's name and let the user accept it. Offer to let the user choose either:

    • Personality — run pdd presets for the authoritative id list, or recommend one from the leading behaviors below and pass --personality:
      • playful — romps and chases; explores and engages freely.
      • attentive — keeps watch and seeks the user readily.
      • reserved — peeks from a distance; cautious, stays close.
      • curious — inspects everything; investigates new space.
      • steady — follows a routine; calm and deliberate.
      • feisty — struts, quick to square up, approaches readily.
      • gentle — offers comfort; unhurried and hyper-agreeable.
      • mischievous — feints and pesters; restless troublemaker.
      • lazy — naps through most of the day.
      • zen — meditates; unbothered by anything around it.
      • aloof — withdraws and keeps to itself.
      • skittish — stands lookout and flees from contact.
      • shrewd — observes and calculates; cool, deliberate, self-directed.
    • Asset (look) — pass --asset <id>. Omit it for a random built-in pet. To browse the full catalog (including the user's own pet packs), open the desktop app.
  3. Create the pet. Pass plain, shell-quoted arguments — pdd builds the request and escapes paths safely:

    pdd hatch                                             # name from the folder, random asset + personality
    pdd hatch "<name>"                                    # random asset + personality, current folder
    pdd hatch "<name>" --personality <id>                 # choose the personality
    pdd hatch "<name>" --agent codex                      # pin which agent its session opens
    pdd hatch "<name>" --asset <id> --personality <id> --cwd "<folder>"
    
  4. Report the result from the command output:

    • {"ok":true,"pet":{…}} → the pet was created. If the desktop app is running it appears right away; otherwise it will on next launch.
    • {"ok":false,"error":…} → report it (e.g. the folder already has a pet).

Binding an existing pet instead

A pet and a folder are separable: a cwd: null pet is waiting for one, and a bound pet can be released without being deleted.

# bind this pet to the current folder (--cwd "<folder>" targets another)
pdd bind "<petId>"
# release the pet from its folder — the pet keeps existing with cwd null
pdd unbind "<petId>"

Read the full file on GitHub · 116 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 116 lines · 14 tokens per session scan A e31b1f43ef46

Subscribe to this mod's changes

hatch is a command published in the GitHub repository young1the/pets-driven (1 stars, last pushed 2d ago), licensed MIT. It adds 14 tokens to every session and 1,409 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.