prefrontal context
Project context that stays with the repository.
You stop re-explaining the project, and every agent starts from the same record.
- v0.4.0
- 106 lines of markdown
- no install
- no account
- no AI provider
- MIT
Copy the five files once; they live in the repo after that.
- 01files
Copy the five files into the repository root.
- 02direction
Write the Direction section of MEMORY.md in your own words.
- 03sessions
Agents read the files when a session starts, and check WORK.md when they continue or plan.
Open a file to see what it is for.
AGENTS.mdRules for agentsyou
Yours to write. It holds the rules an agent has to follow and the commands it should run, and agents read it before they touch anything. When a rule needs to change, they propose the change instead of editing the file.
Open AGENTS.md on GitHubMEMORY.mdCurrent project contextagents
Where the project stands today. Agents keep the State and Architecture sections current from what they verify, so a new session reads this instead of asking you to explain the project again.
Open MEMORY.md on GitHubshipped template, first three sections, trimmed
# MEMORY.md — the project as it stands This file gives a capable agent the context to understand the project correctly: complete, relevant, current, and free of obsolete material. … The sections below are defaults: reshape, rename, add, or drop them to fit the project. ## Direction — owner-governed _The owner's vision, current direction, durable requirements, non-goals, and constraints — in the owner's words … Update only from new owner statements. …_ ## State _What exists and works right now — the durable facts a fresh agent would otherwise have to rediscover. …_ ## Architecture …WORK.mdActive and planned workagents
What is in flight and what comes next. An agent reads it to pick up work without being told the plan, then records what moved.
Open WORK.md on GitHubDECISIONS.mdDecisions that currently standagents
The choices you don't want relitigated. When an agent wonders why you built something this way, the reason sits beside the code rather than in a chat that has scrolled away.
Open DECISIONS.md on GitHubOPEN.mdUnresolved questionsagents
The questions nobody has answered yet. Writing them down stops the next session from confidently inventing an answer, and a question leaves the file once someone settles it.
Open OPEN.md on GitHub
git clone --depth 1 https://github.com/itsabk/prefrontal-context /tmp/prefrontal-context \
&& cp /tmp/prefrontal-context/{AGENTS,MEMORY,WORK,DECISIONS,OPEN}.md . \
&& rm -rf /tmp/prefrontal-contextIf your repository already has an AGENTS.md, merge these rules into it instead of overwriting the file.
Set it up with your agent· 50 lines
Set up Prefrontal Context in this repository: five markdown files that keep project
memory between agent sessions. Work only in this repository.
The files and what each owns:
AGENTS.md - rules an agent must follow here, including how to maintain the
other four files. Owner-governed.
MEMORY.md - the project as it stands: direction (owner-governed), state,
architecture, conventions and quirks, how to verify.
WORK.md - what is being worked on now and what comes next.
DECISIONS.md - decisions that currently stand, and why.
OPEN.md - questions nobody has settled yet.
Templates: https://github.com/itsabk/prefrontal-context (or the copies already in
this repository, if they are there). Keep their rules; do not invent replacements.
1. Create the five files at the repository root. If AGENTS.md already exists, merge
these rules into it and keep every rule that is already there. If CLAUDE.md
exists, append the line `@AGENTS.md`; if the platform you run on reads a
different instruction file, add the equivalent one-line loader pointing at
AGENTS.md.
2. MEMORY.md's Direction section and AGENTS.md's Project rules are mine to write,
not yours. Ask me for my words before you fill them: at most three questions,
in one message, then wait for my answer. Record what I say in my words.
3. Fill every other section from what you actually verify in this repository, and
say how you know - the command, the test, or the file you read. Replace each
italic placeholder prompt with real content. Rename, merge or drop sections that
do not fit this project, but leave no section holding only its own prompt.
4. If this repository already has notes, roadmaps, progress logs or handoff files,
fold what is still current into the five files and list the rest for me to
delete or archive. Keep real project documents - specs, plans, design docs,
contracts - as documents, and reference them from MEMORY.md instead of copying
them in. Leave one home per fact.
5. Never invent a fact. Anything you cannot verify goes in OPEN.md as a question.
If something you find contradicts a recorded decision, tell me rather than
editing the decision yourself.
6. From now on, read these files before non-trivial work and keep them current in
the same piece of work: record what changed, prune what is stale or false, and
use git for history instead of keeping old text in the files.
7. When the setup is done, report: the files you wrote, the facts you verified with
the commands you ran, what you need from me, and anything you deliberately left
out.
Do not add indexes, sync scripts, hooks or other machinery for these files unless I
ask for it.Your agent can fetch the same text at prefrontal.dev/setup.txt.
To remove Prefrontal Context, delete the files; the copy step touched nothing else. The source is MIT at github.com/itsabk/prefrontal-context.
Working memory, not lifetime memory.
Carry what the next action needs rather than everything the project has ever seen.
- readable
Five markdown files you can open in any editor, with no account to create and no provider in the loop.
- portable
Swap coding agents and the files come with you, because project truth sits in the repository rather than in a vendor memory service.
- versioned
Each edit lands in git beside the code it describes, so you review project knowledge with diffs you already use.
- optional
The runtime is proposed and optional: the five files work the same with or without it.
No file can force an agent to comply, and agents behave differently. What these files do is hand every agent the same record to start from.
The five-file core, v0.4.0, MIT, sitting in your repository.
An optional memory runtime, and nothing on this page depends on it.