Skip to content

About

Free copy-paste brain files for AI coding tools: CLAUDE.md, AGENTS.md, GEMINI.md, Cursor rules (.mdc), Copilot instructions. Templates for web apps, Godot/Unity games, Discord bots, Python and more.

Topics

Resources

Contributing

Stars

1 star

Watchers

0 watching

Forks

Latest commit

 

History

1 Commit

Folders and files

Repository files navigation

BrainStack logo

BrainStack Templates

Copy-paste brain files for your AI coding tools.
CLAUDE.md · AGENTS.md · GEMINI.md · Cursor rules (.mdc) · copilot-instructions.md

Generator · Guides · Newsletter · @BrainStacksAI


Your AI forgets your project every time you open a new chat. A brain file fixes that: a short Markdown file in your repo that your AI tool loads automatically at the start of every session, with your stack, commands, rules, and where to keep memory. Write it once, and you stop re-explaining your project (and stop finding API keys in your code).

This repo is a free library of ready-made brain files for common project types, in the format each tool expects. They're built with the same logic as the free BrainStack Brain File Generator, so you can start from a template here or generate a pre-filled one in your browser.

Which tool reads which file?

Tool File it reads Where it goes
Claude Code CLAUDE.md Project root (or .claude/CLAUDE.md). Global: ~/.claude/CLAUDE.md. Supports @path imports; recent versions also read AGENTS.md when there's no CLAUDE.md.
AGENTS.md agents (OpenAI Codex, Cursor, GitHub Copilot cloud agent, Google Antigravity, and others) AGENTS.md Project root. Nested AGENTS.md files in subfolders add folder rules.
Gemini CLI and Google Antigravity GEMINI.md Project root and subfolders. Global: ~/.gemini/GEMINI.md. Plain Markdown, no frontmatter.
Cursor .cursor/rules/*.mdc Must be .mdc with frontmatter (description, globs, alwaysApply). Cursor also reads AGENTS.md.
GitHub Copilot .github/copilot-instructions.md Repository-wide. Path-specific: .github/instructions/*.instructions.md with applyTo.

Not sure? Start with AGENTS.md: the most tools read it. More detail: GEMINI.md vs CLAUDE.md vs AGENTS.md vs Cursor rules vs Copilot.

Templates

Every project type comes in all five formats. Same rules, each tool's file name and format.

Project type Claude Code AGENTS.md Gemini / Antigravity Cursor Copilot
Vibe-coded web app CLAUDE.md AGENTS.md GEMINI.md project.mdc copilot-instructions.md
Godot game CLAUDE.md AGENTS.md GEMINI.md project.mdc copilot-instructions.md
Unity game CLAUDE.md AGENTS.md GEMINI.md project.mdc copilot-instructions.md
Discord bot CLAUDE.md AGENTS.md GEMINI.md project.mdc copilot-instructions.md
Python / data / automation CLAUDE.md AGENTS.md GEMINI.md project.mdc copilot-instructions.md
General (any project) CLAUDE.md AGENTS.md GEMINI.md project.mdc copilot-instructions.md

Extras

Folder What's inside
memory/ A docs/brain/ memory folder (NOW.md handoff, decision log, architecture, gotchas, glossary). Every template tells the AI to use it.
extras/one-source-of-truth/ Use several AI tools on one repo with a single AGENTS.md plus tiny pointer files (CLAUDE.md with @AGENTS.md, Gemini CLI settings.json, and more).
extras/scoped-rules/ Rules that load only for some files: Cursor globs, Claude Code .claude/rules paths, Copilot applyTo, Antigravity .agents/rules triggers.
extras/global/ A personal "about me" file for ~/.claude/CLAUDE.md or ~/.gemini/GEMINI.md.

How to use

  1. Pick your project type in the table above and open the file for your tool.
  2. Copy it to the same path in your project. CLAUDE.md, AGENTS.md, and GEMINI.md go in the root; the Cursor file goes in .cursor/rules/; the Copilot file goes in .github/.
  3. Replace every TODO. Put in your real versions and commands. Exact versions are what stop your AI from writing outdated code.
  4. Delete what doesn't apply. Shorter files get followed better. Aim for under ~150 lines.
  5. Copy memory/docs/ into your project root if you want the AI to keep session notes and a decision log.
  6. Test it. Start a fresh session and ask: "What are the rules for this project, and what command runs the tests?" If the answer doesn't match your file, it isn't loaded.
  7. Commit it. Your AI's brain is now versioned and backed up with your code.

Prefer not to edit by hand? The Brain File Generator fills all of this in from a short form, in your browser. Nothing is uploaded.

Or grab one from the command line, for example:

curl -fsSL -o AGENTS.md https://raw.githubusercontent.com/TheRealSnouk/brainstack-templates/main/templates/web-app/AGENTS.md

Tips that make brain files actually work

  • Be specific. "Run npm test before saying you're done" beats "test your changes".
  • Pin versions. "Godot 4.5, never Godot 3 syntax" saves hours.
  • Write security rules down. No secrets in code, only deploy the build folder, ask before destructive commands.
  • Grow it from mistakes. When you correct the AI on the same thing twice, add a rule.
  • No secrets in brain files, ever. They're committed to git and sent to the model.

Learn more

Official docs: Claude Code memory · AGENTS.md · Gemini CLI GEMINI.md · Antigravity rules · Cursor rules · Copilot custom instructions

AI tools change fast. These templates were checked against the official docs in October 2026; if something behaves differently, please open an issue.

Get new templates by email

The free BrainStack newsletter sends one short email when there's a new guide, template, or AI setup trick worth stealing. Subscribers also get the Brain File Starter Pack: these templates in one zip, plus a printable quickstart.

Contributing

Fixes and new templates are welcome. See CONTRIBUTING.md.

License

MIT. Use these in any project, commercial or not. No attribution required (but a star helps others find it ⭐).

BrainStack is independent and not affiliated with Anthropic, Google, OpenAI, Cursor (Anysphere), or GitHub. Product names are trademarks of their owners.

About

Free copy-paste brain files for AI coding tools: CLAUDE.md, AGENTS.md, GEMINI.md, Cursor rules (.mdc), Copilot instructions. Templates for web apps, Godot/Unity games, Discord bots, Python and more.

Topics

Resources

Contributing

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors