Skip to content

Slice 033: Project context: AGENTS.md - #42

Merged
HackTuah merged 7 commits into
mainfrom
slice/033-project-context-agents-md
Sep 21, 2026
Merged

HackTuah merged 7 commits into
mainfrom
slice/033-project-context-agents-md

Conversation

@HackTuah

Copy link
Copy Markdown
Member

The session's project root as a setting (a column, Sessions.set_project_root/2, a field in the chat's bar) that the tools' working directory follows. Trinity.Context.AgentsMd reads every AGENTS.md from the root to the working directory, outermost first, caps the total at 16,384 bytes keeping the nearest file whole and stating every cut, and renders each inside an untrusted block with its digest into the prompt's context tier, read every turn (live reload). The context tier's budget rises from 300 to 5,800 tokens on measurement (this tree's own CLAUDE.md is 2,849). AC3: a file that says approvals are off changes nothing at the gate, proven end to end with a hostile fixture.

PROOF.md at slices/033-project-context-agents-md/PROOF.md.

Signed-off-by: Ayla Croft aylacroft@proton.me

… the slice opens

ROADMAP row 033 to in_progress. NOTES.md measures this tree's own
CLAUDE.md at 2,849 tokens, sets the AGENTS.md cap at 16,384 bytes and
raises the context tier's budget from 300 to 5,800 tokens so the cap
binds first; the six-line build plan, the empty manual queue, two
deviations stated before any code. plan_check: PASS.

Signed-off-by: Ayla Croft <aylacroft@proton.me>
… context tier fed every turn

sessions.project_root with Sessions.set_project_root/2; the tools'
cwd follows it. Trinity.Context.AgentsMd discovers every AGENTS.md
from the root to the working directory, outermost first, caps the
total at 16,384 bytes keeping the nearest whole and stating every
cut, and renders each inside an untrusted block with its digest. The
Session reads it every turn into the prompt's context tier, whose
budget rises to 5,800 tokens. Fixtures: plain, nested, hostile. Six
tests: AC1, AC2 twice, the root setter and the allowlist, live
reload, AC3.

Signed-off-by: Ayla Croft <aylacroft@proton.me>
… built

Signed-off-by: Ayla Croft <aylacroft@proton.me>
Signed-off-by: Ayla Croft <aylacroft@proton.me>
Signed-off-by: Ayla Croft <aylacroft@proton.me>
PROOF.md with every criterion's evidence by test name against run
35551683298 (gate, postgres and fips green). NOTES.md: five findings,
three follow-ups. ROADMAP row 033 to done; coverage.tsv row 78.50 %.

Signed-off-by: Ayla Croft <aylacroft@proton.me>
Signed-off-by: Ayla Croft <aylacroft@proton.me>
@HackTuah
HackTuah merged commit fe87ea4 into main Sep 21, 2026
8 checks passed
@HackTuah
HackTuah deleted the slice/033-project-context-agents-md branch September 21, 2026 03:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant