Skill Tracer
Skills › BMAD Method › bmod-method › project-context.md

project-context.md

51 lines · skills/bmod-method/help/project-context.md at bd70c64

Open on GitHub

Most marks come from matching words in the file, so treat them as pointers.

1# Project context and what belongs in AGENTS.md
2
3Use this when a user asks which `bmad-project-context` intent to run, why its block is small and has no repo overview, or what to do when agents repeat a mistake.
4

Project context and what belongs in AGENTS.md

Use this when a user asks which bmad-project-context intent to run, why its block is small and has no repo overview, or what to do when agents repeat a mistake.

Raw lines 1 to 4
Project instruction file AGENTS.md :1
Names a skill bmad-project-context :3
5## What it produces
6
7A small, verified block of rules in `AGENTS.md` at the repo root, between the `<!-- bmad:context -->` and `<!-- /bmad:context -->` markers. The run is a conversation, and the user approves every write.
8

What it produces

A small, verified block of rules in AGENTS.md at the repo root, between the <!-- bmad:context --> and <!-- /bmad:context --> markers. The run is a conversation, and the user approves every write.

Raw lines 5 to 8
Project instruction file AGENTS.md :7
9## Intents
11| Intent | Recommend when |
12|---|---|
13| setup | No instruction file has meaningful content. |
14| adopt | The user already wrote an `AGENTS.md` or `CLAUDE.md`. The user sees what happens to each instruction. |
15| refresh | A block exists and the code changed a lot. It does not re-ask what was settled. |
16| record | An agent just got something wrong. A recurring or costly mistake earns a line. |
17| audit | The block feels stale or bloated. It ends smaller or equal. |

Intents

IntentRecommend when
setupNo instruction file has meaningful content.
adoptThe user already wrote an AGENTS.md or CLAUDE.md. The user sees what happens to each instruction.
refreshA block exists and the code changed a lot. It does not re-ask what was settled.
recordAn agent just got something wrong. A recurring or costly mistake earns a line.
auditThe block feels stale or bloated. It ends smaller or equal.
Raw lines 9 to 18
Project instruction file AGENTS.md :14
Project instruction file CLAUDE.md :14
19## What earns a line
21- Policy the code cannot express: branch rules, frozen paths, generated files, security.
22- What a config file cannot say about running the project: integration tests need a service up first.
23- Conventions that differ from ecosystem defaults, including a command whose obvious form is wrong.
24- Pitfalls someone has observed. A scan finding alone becomes a question to the user.
25- Rules that must hold across components, required tool versions, and entry points.

What earns a line

  • Policy the code cannot express: branch rules, frozen paths, generated files, security.
  • What a config file cannot say about running the project: integration tests need a service up first.
  • Conventions that differ from ecosystem defaults, including a command whose obvious form is wrong.
  • Pitfalls someone has observed. A scan finding alone becomes a question to the user.
  • Rules that must hold across components, required tool versions, and entry points.
Raw lines 19 to 26
27## What stays out
29Repo overviews, directory trees, stack lists, commands the obvious guess gets right, pasted code, history, and plans. For a style rule a linter, hook, or CI check can enforce, the skill proposes the check. Product intent belongs in a spec, and a contested design decision in `bmad-architecture`. To learn the code, recommend `bmad-walkthrough` (`help/existing-codebase.md`).

What stays out

Repo overviews, directory trees, stack lists, commands the obvious guess gets right, pasted code, history, and plans. For a style rule a linter, hook, or CI check can enforce, the skill proposes the check. Product intent belongs in a spec, and a contested design decision in bmad-architecture. To learn the code, recommend bmad-walkthrough (help/existing-codebase.md).

Raw lines 27 to 30
Names a skill bmad-architecture :29
Names a skill bmad-walkthrough :29
31## Why the block is small
33- Every line loads in every session, and agents follow instructions less well as the loaded set grows.
34- Agents read code better than prose about code, and a stored copy goes stale.
35- Instruction files that restate what the repo already shows cost tokens every session and do not make agents more successful.
36- Agents often skip context they must choose to fetch, so rules that must hold stay in the block.

Why the block is small

  • Every line loads in every session, and agents follow instructions less well as the loaded set grows.
  • Agents read code better than prose about code, and a stored copy goes stale.
  • Instruction files that restate what the repo already shows cost tokens every session and do not make agents more successful.
  • Agents often skip context they must choose to fetch, so rules that must hold stay in the block.
Raw lines 31 to 37
38## Where it writes
40- Only between the markers. Text outside them changes only with the user's approval.
41- For a tool that reads another file, it proposes a one-line `@AGENTS.md` import.
42- It never commits. The user reviews and commits the change.
43- Personal preferences and rules shared by all of a user's projects belong in their global agent config.

Where it writes

  • Only between the markers. Text outside them changes only with the user's approval.
  • For a tool that reads another file, it proposes a one-line @AGENTS.md import.
  • It never commits. The user reviews and commits the change.
  • Personal preferences and rules shared by all of a user's projects belong in their global agent config.
Raw lines 38 to 44
Project instruction file AGENTS.md :41
45## How a rule gets removed
47A policy or pitfall goes only when the thing it guards is gone or the user retires it. No recent failures is not a reason. An instruction a human wrote is deleted only when it is stale or wrong, enforced by a hook or check, contradictory, or approved for deletion as its own item.

How a rule gets removed

A policy or pitfall goes only when the thing it guards is gone or the user retires it. No recent failures is not a reason. An instruction a human wrote is deleted only when it is stale or wrong, enforced by a hook or check, contradictory, or approved for deletion as its own item.

Raw lines 45 to 48
49## An old project-context.md
51The older `bmad-generate-project-context` and `bmad-document-project` skills were removed; this skill replaces both. It reads an existing `project-context.md`, offers to absorb its content, and does not delete the file without the user's agreement.

An old project-context.md

The older bmad-generate-project-context and bmad-document-project skills were removed; this skill replaces both. It reads an existing project-context.md, offers to absorb its content, and does not delete the file without the user's agreement.

Raw lines 49 to 51