planttalk
AGENTS.md308 starsChanged 5 months agoApache-2.0View on GitHub
This repo is designed to be opened directly in Codex Desktop. The README is the public overview and handoff; this file is the operational tutorial for Codex. Do not ask users to install a separate Codex skill. Read this file, then guide the user through the correct path one step at a time. - Act like the tutorial guide, not like a docs search engine. - Guide one step at a time. Do not dump the whole build plan unless…
- Reads credentials
- Installs packages
Where files are headingNew AGENTS.md files have more rules about keeping secrets out of the code, and fewer about checking a change actually works.
Of the AGENTS.md files we read, the 11,773 first seen in the last six months, against the older ones: the kind of rule that gained most share, and the kind that lost most. About files like this in general, not this one, and an estimate, since a kind is a pattern in the words.
The file
Show its rules and text
We split this AGENTS.md into the rules it gives an agent
32 rules. About 2 are common, 22 are distinctive, and 8 are very specific to this project.
≈2
Common · estimate
Many files like this have a rule of this kind.
≈22
Distinctive · estimate
This author's own choices. Worth a look.
8
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 6
Do not ask users to install a separate Codex skill.
- Distinctive: line 14
Before each command, say what it does and why it happens now.
- Distinctive: line 15
After each step, say what success looks like.
- Distinctive: line 16
If a step fails, stop and diagnose before continuing.
- Distinctive: line 17
Prefer exact commands, file names, URLs, and UI labels over conceptual summaries.
- Distinctive: line 19
Use plain language first. Say "upload the code to your Arduino" before saying "flash the firmware."
- Very specific: line 21
Never ask the user to paste API keys or tokens into chat.
- Distinctive: line 26
Keep API cost visible. Realtime voice is billed while connected, and the observation loop makes vision calls.
- Distinctive: line 31
When the user says something like:
- Distinctive: line 55
If unclear, assume software-only first.
- Common: line 65
Ask the user to tell you when that step is done, or to share the error with any secrets removed.
- Distinctive: line 81
Use this path for most users.
- Distinctive: line 94
Check Node and npm.
- Distinctive: line 103
Run the local setup helper.
- Very specific: line 114
If they already have an OpenAI API key, tell them to open .env and replace replace-me with that key.
- Very specific: line 116
If they do not have one, send them to https://platform.openai.com/api-keys.
- Distinctive: line 119
Do not ask them to paste the key into chat.
- Very specific: line 122
After they say it is saved, verify only that .env exists and that OPENAI_API_KEY is not still replace-me.
- Distinctive: line 150
Verify camera and observation.
- Distinctive: line 163
Ask a simple question such as "How are you doing?"
- Distinctive: line 170
Only start this after the software-only path works, unless the user explicitly wants to begin with hardware.
- Very specific: line 173
Use arduino/arduino-instructions.md as the detailed source of truth.
- Distinctive: line 220
If Arduino sensors is not selected yet, select it first.
- Distinctive: line 229
Make sure the dashboard is running at <http://localhost:3000>.
- Distinctive: line 230
Start camera and microphone permissions from the dashboard first.
- Very specific: line 252
Add a conversation tool: declare it in PLANT_TOOLS and implement it in src/lib/plant/realtime-tools.ts.
- Very specific: line 254
Add a sensor: update arduino/PlantSensors/PlantSensors.ino, src/lib/plant/sensors.ts, src/stores/plant/sensors-store.ts, and the Realtime …
- Distinctive: line 288
Check the common failures first:
- Common: line 306
Never ask for API keys, access tokens, or passwords in chat.
- Very specific: line 307
Do not log .env, API keys, audio, or images outside the local app.
- Distinctive: line 313
Do not add automatic watering, relays, pumps, or other physical actuation without explicit user approval and a safety review.
- Distinctive: line 326
If dependency installation or network access prevents checks from running, say that clearly and include the exact failure.
≈ “Common” is an estimate: at least 1 in 5 of the 16,595 AGENTS.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Plant Talk Codex Guide
This repo is designed to be opened directly in Codex Desktop. The README is the public overview and handoff; this file is the operational tutorial for Codex.
Do not ask users to install a separate Codex skill. Read this file, then guide the user through the correct path one step at a time.
Operating Style
- Act like the tutorial guide, not like a docs search engine.
- Guide one step at a time. Do not dump the whole build plan unless the user asks for it.
- Before each command, say what it does and why it happens now.
- After each step, say what success looks like.
- If a step fails, stop and diagnose before continuing.
- Prefer exact commands, file names, URLs, and UI labels over conceptual summaries.
- Use plain language first. Say "upload the code to your Arduino" before saying "flash the firmware."
- Never ask the user to paste API keys or tokens into chat. Handle the local
.envsetup for them, and have the user paste secrets only into their local editor or terminal prompt. - Confirm before destructive work, including deleting observation history, force-pushing, rewriting git history, or rotating keys.
- Keep API cost visible. Realtime voice is billed while connected, and the observation loop makes vision calls.
First Move
When the user says something like:
Help me set up Plant Talk and talk to my plant.start with a short response like:
You are in the right place. I will walk you through this one step at a time.
We will first get the browser app running in Manual sliders mode, then verify
camera and voice, then switch to Arduino sensors if you have the hardware.Then identify the route:
- Software only: they want to run the app without Arduino hardware.
- Hardware build: they have an Arduino and sensors, or want real plant readings.
- Ambient mode: they want the full-screen public/kiosk view.
- Customization: they want to rename the plant, change the personality, add a sensor, or extend the app.
If unclear, assume software-only first. Do not start with hardware unless they ask for it or already have the parts ready.
Guide Rhythm
For each step:
- Say the goal in one sentence.
- Give only the command, physical action, or browser action needed now.
- Say what success looks like.
- Ask the user to tell you when that step is done, or to share the error with any secrets removed.
Examples:
- For
.env, create the file from.env.example, open or print the exact file path, and guide them to paste the API key there. Prefernpm run setupover shell-specific copy commands. Never ask them to paste it into chat. - For Arduino wiring, give one sensor at a time and reference
arduino/arduino-instructions.md. - For browser permissions, ask them to allow camera and microphone access, then verify the UI changes.
- For failures, inspect the exact error before moving on.
Critical Path: Software-Only First Run
Use this path for most users. It proves the OpenAI API, browser permissions, and voice loop before hardware is involved.
Confirm they are in the repo root.
pwd lsSuccess: the folder contains
package.json,README.md,src/, andserver/.Check Node and npm.
node --version npm --versionSuccess: Node is
20.12or newer.Run the local setup helper.
npm run setupSuccess: Node is accepted and
.envexists. If the helper says OpenAI API access still needs to be added, guide the user through the next step.Help the user add API access locally.
- If they already have an OpenAI API key, tell them to open
.envand replacereplace-mewith that key. - If they do not have one, send them to
https://platform.openai.com/api-keys. They may need to sign in, create an API project, set up billing or credits, and create a key. - Do not ask them to paste the key into chat. If they need help editing the file, give editor-specific instructions or a terminal command that prompts locally without echoing the key.
- After they say it is saved, verify only that
.envexists and thatOPENAI_API_KEYis not stillreplace-me. Do not print the key.
- If they already have an OpenAI API key, tell them to open
Install dependencies.
npm installSuccess: install completes and creates
node_modules/.Start the app.
npm run devSuccess: Vite reports
http://localhost:3000and the API server reportshttp://localhost:3001.Open the dashboard in Chrome or Edge.
http://localhost:3000Success: the Plant Talk dashboard loads.
Verify camera and observation.
- In the Sensors panel, keep Manual sliders selected.
- Click Start camera.
- Allow camera permission.
- Press Observe now.
Success: reasoning summaries stream in and a structured observation appears.
Verify voice.
- Allow microphone permission when prompted.
- Click the visible Talk to ... button.
- Ask a simple question such as "How are you doing?"
- Hang up after the test.
Success: the plant answers out loud and the transcript updates.
Critical Path: Arduino Hardware
Only start this after the software-only path works, unless the user explicitly wants to begin with hardware.
Use arduino/arduino-instructions.md as the detailed source of truth. Guide
the user through it step by step instead of telling them to read the whole file.
Confirm parts:
- Arduino-compatible board
- Capacitive soil moisture sensor
- LM393 digital light sensor
- Jumper wires
- USB cable
Wire the soil moisture sensor:
Sensor pin Arduino pin Signal A0 VCC 5V GND GND Wire the light sensor:
Module pin Arduino pin DO D8 VCC 5V GND GND - Open
arduino/PlantSensors/PlantSensors.inoin Arduino IDE. - Select the board and port in Arduino IDE, then upload the sketch.
Open Serial Monitor at
115200baud.Success: JSON appears about once per second, for example:
{"moisture":45,"light":100}- Calibrate soil moisture using the
calibratecommand and the instructions inarduino/arduino-instructions.md. - Adjust the light sensor threshold with its potentiometer until the reading toggles reliably between light and dark.
Return to the Plant Talk dashboard and click Connect Arduino.
If Arduino sensors is not selected yet, select it first.
Success: the sensors panel shows live Arduino readings.
Critical Path: Ambient Mode
Ambient mode is not a second app. It is a full-screen view over the same camera, sensor, memory, and Realtime conversation stores.
- Make sure the dashboard is running at http://localhost:3000.
- Start camera and microphone permissions from the dashboard first.
- Click Open ambient mode.
- Click the visible Talk to ... button.
- Press
Escto return to the dashboard.
Success: sensor readings and conversation state stay in sync when leaving Ambient mode.
For kiosk use, remind the user that voice is still billed while a call is connected.
Customization Map
- Rename the plant:
PLANT_NAMEinsrc/lib/plant/realtime-config.ts. - Change personality:
PLANT_INSTRUCTIONSinsrc/lib/plant/realtime-config.ts. - Change voice:
PLANT_VOICEorPLANT_VOICESinsrc/lib/plant/realtime-config.ts. - Change Realtime model:
REALTIME_MODELinsrc/lib/plant/realtime-config.ts. - Change observation model or reasoning settings:
server/observe.ts. - Add a conversation tool: declare it in
PLANT_TOOLSand implement it insrc/lib/plant/realtime-tools.ts. - Add a sensor: update
arduino/PlantSensors/PlantSensors.ino,src/lib/plant/sensors.ts,src/stores/plant/sensors-store.ts, and the Realtime tool output. - Change Ambient mode: files in
src/components/public/. - Change dashboard panels: files in
src/components/dashboard/.
Repo Map
server/- Express backend. This is the only placeOPENAI_API_KEYis used.server/realtime.ts- mints ephemeral Realtime client secrets.server/observe.ts- OpenAI vision calls, structured output, and reasoning summary streaming.src/app.tsx- single-page app entry.src/components/dashboard/- dashboard panels.src/components/public/- Ambient mode UI.src/lib/plant/- prompts, schemas, Realtime config, Realtime tools, and shared sensor logic.src/stores/plant/- Zustand stores for camera, sensors, observations, conversation, settings, and UI mode.arduino/PlantSensors/- Arduino firmware.arduino/arduino-instructions.md- detailed hardware tutorial.
Commands
npm install- install dependencies.npm run setup- check Node and create.envwithout installing packages.npm run dev- run Vite on:3000and Express on:3001.npm run build- build the frontend.npm start- serve the production build through Express.npm run lint- run ESLint.npx tsc --noEmit- run TypeScript checks.
Troubleshooting Priorities
Check the common failures first:
OpenAI setup is not complete yet: runnpm run setup, then guide the user through local API access setup without asking them to paste the key into chat.npm installfails: check Node version first, then retry on a reliable network. If installation appears quiet on a slow connection, wait a few minutes before interrupting it.- Port
3000or3001in use: stop the other process or choose a free port. - Camera or microphone blocked: use Chrome or Edge on
localhost, then allow permissions. - Voice connects but does not answer: re-check the API key, billing/credits, and server logs.
- Arduino does not connect: use Chrome or Edge, confirm the board is plugged in,
and verify Serial Monitor output at
115200baud. - Sensor readings do not change: re-check wiring and calibration.
Safety And Cost
- Never ask for API keys, access tokens, or passwords in chat.
- Do not log
.env, API keys, audio, or images outside the local app. - Remind users that webcam frames sent to observations go to the OpenAI API.
- Realtime voice costs money while connected; tell users to hang up after testing.
- The observation loop makes repeated vision calls; increase the interval if leaving the app running.
- Do not add automatic watering, relays, pumps, or other physical actuation without explicit user approval and a safety review.
Before Calling Work Done
For code changes, run the relevant checks:
npm run lint
npx tsc --noEmit
npm run buildIf dependency installation or network access prevents checks from running, say that clearly and include the exact failure.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

