Ghoststack Docs

AI Prompting and Project Memory

You do not need a complicated prompt system. Give your AI a clear result, relevant context, and a way to check that it worked.

Use the prompt library

Open the guide for the thing you want to build. Complete its prerequisites, choose one prompt, and replace the [BRACKETS] with your own details. Follow-up prompts assume you have already built the feature they change. You do not need to run every prompt or connect every service.

All examples work with Codex, Claude Code, or Cursor. Use whichever tool you already have; the goal is to learn one simple cycle: describe a change, build it, and check it.

A prompt you can reuse

I want [WHO USES THE FEATURE] to be able to [DESIRED RESULT].

Example: [A REAL INPUT AND THE EXPECTED OUTPUT].
Keep the first version small: [WHAT IS INCLUDED].
Follow AGENTS.md and inspect the existing code before changing it.
Done when: [WHAT I SHOULD BE ABLE TO DO AND SEE].
Implement it, run the relevant checks, and tell me what passed or could not be tested.
I'm new to coding; explain unfamiliar steps in plain language.

For a complex change, ask for a short plan first. Read it and correct the assumptions before asking the agent to implement. For a question only, say β€œExplain this without editing files.” These requests work across tools without relying on a specific mode name.

Work in small, testable steps

  1. Save a Git version before a meaningful change. Describe one outcome, such as β€œsigned-in users can save a project.”
  2. Let the agent inspect the relevant code, implement the change, and run its checks.
  3. Review the changes and try the feature in the browser, including an error or empty state.
  4. Ask it to explain what changed and why. Save another Git version once the result works.

For auth, payments, and data access, also test as another user and while logged out. An agent saying β€œdone” is not evidence that a payment or email was delivered.

For a visual change, attach a screenshot or describe what should look different. Ask the agent to compare the result at desktop and phone sizes if it has browser access; otherwise, open the preview yourself.

Continue in the same conversation while working toward the same result. Your tool can summarize a long conversation or let you resume it later. Start a new conversation for an unrelated task; when switching tools or handing off unfinished work, use the short handoff below.

If a fix keeps failing, stop and describe the smallest steps that reproduce the problem. Ask the agent to check its assumptions before trying another patch. The debugging prompts help you do this. One agent is enough to get started.

These habits follow the current Codex, Claude Code, and Cursor guidance. You do not need to copy a model's API system prompt or set up a custom agent framework to use them.

One source of shared project context

Use the exact filenames AGENTS.md and CLAUDE.md, including capitalization. They are still current project-instruction conventions; automatic memory and skills serve different purposes.

FilePurpose
AGENTS.mdShort, versioned project rules: commands, file map, conventions, and important boundaries. Codex and Cursor read it.
CLAUDE.mdA small adapter containing @AGENTS.md, which Claude Code loads as an import.
docs/Generated Markdown copies of the hosted guides, read only when needed; these are not app routes.
A focused plan file, when neededThe current feature's goal, decisions, unfinished work, and verification status.

The website is the current source for these guides; the starter’s docs/ copy is reference material for you and your agent. Keep your own feature notes elsewhere so a guide update does not overwrite them. If an agent cannot open a hosted guide that needs your customer sign-in, ask it to read the corresponding local Markdown file or copy the relevant steps into your task. It should not claim to have read a page it cannot access.

Do not rename one instruction file into another or keep multiple copies of the same rules. Update AGENTS.md when an important project convention changes. Ask the agent to summarize the loaded instructions if you are unsure; instructions guide behavior but do not enforce permissions.

Codex and Cursor support more-specific instructions in subdirectories. Claude Code also supports scoped rules. This small starter does not need extra instruction files everywhere: add them only when a part of your app develops its own conventions. Codex's AGENTS.override.md can take precedence over AGENTS.md; do not add one just to duplicate the starter rules.

See official Codex instructions, Claude Code memory and imports, and Cursor rules. The Codex, Claude Code, and Cursor guides show how to check the active session.

What to remember

Save facts that will help with later tasks: who the app serves, a settled product decision, a non-obvious integration constraint, or the reason for a workaround. Keep temporary task details out of the always-loaded instructions.

Save a short handoff in plans/current-feature.md:
- Goal and decisions we made
- Files changed
- Checks actually run and their results
- Remaining work and the next action
Do not include secrets, customer data, or the conversation transcript.

That file is ordinary project documentation; the filename has no special automatic behavior. In the next task, explicitly ask the agent to read it. Replace or remove it when the feature is finished.

Tool-specific automatic memory can help with your personal workflow, but it is not a substitute for shared project documentation. Claude Code's generated memory is normally under ~/.claude/projects/<project>/memory/. Codex's optional memory is managed by the app and stored under ~/.codex/memories on the host. These are separate from versioned instructions and are not a portable handoff to every teammate or cloud session. Review saved notes when they become outdated. Ghoststack does not require a universal MEMORY.md file or a memory plugin. Claude memory, Codex memory.

Do not copy personal generated memories into a starter you distribute. Promote a useful, non-private convention into AGENTS.md deliberately; leave unrelated history and credentials out.

Models, skills, and tools

Start with the model your coding tool recommends. Use a more capable option if a difficult task needs it; do not paste old model names from tutorials. Your app's OpenRouter model is a separate choice.

MechanismWhat it doesNeeded to begin?
Project instructionsExplain how to work in this repositoryAlready included
Personal memorySaves context for your own tool/hostOptional
SkillPackages a reusable workflow, often as SKILL.mdAdd for a repeated specialist task
PluginInstalls a bundle of capabilities, potentially skills and MCP serversOptional; support differs by interface
MCP connectionMakes external service tools available after configuration and authenticationAdd when connecting a service

Skill locations depend on the tool. Codex uses project .agents/skills/; Cursor supports .agents/skills/ and .cursor/skills/; Claude Code uses .claude/skills/. Do not create empty folders or copies for every tool. If you need a skill, use your selected tool's documented location and scope. Codex skills, Cursor skills, Claude Code skills.

Writing β€œuse Supabase MCP” in AGENTS.md does not install a server, log you in, or grant access. Connect only the services you need and verify actual tool results. The app's .env.local settings are a separate configuration used by the running app.

When a tool needs current API or UI guidance, include the official URL in ordinary language:

Use DaisyUI components and semantic colors with Tailwind layout utilities.
For unfamiliar component syntax, consult https://daisyui.com/llms.txt
and follow the installed version in package.json.

File mentions and browsing controls differ across apps. Plain filenames and URLs keep these prompts portable. Never save API keys in instructions or memory; .gitignore does not prevent agent access to a local file.