Skip to content

Harness: load AGENTS.md and DREAMCODER.md as project instructions #271

Open

Description

@GoDiao

Part of #270.

The CLI reads only CLAUDE.md files, so projects maintained with Codex CLI, ZCode or other agents lose their instructions in DreamCoder. This repository itself has only AGENTS.md. Details, including how Codex and ZCode find and wrap these files: T-CTX-01, T-INJ-19, T-CTX-07, T-CTX-08, T-CTX-15, T-SYS-14.

What to do (decided)

  • File names by priority: DREAMCODER.md > AGENTS.md > CLAUDE.md > .claude/CLAUDE.md. In each directory only the highest-priority existing file is read.
  • Every directory from the project root down to the working directory contributes its one file, as CLAUDE.md does today (src/utils/claudemd.ts).
  • When the model reads a file in a subdirectory, that subdirectory's instruction file is attached by the same rule, and its header says it is a project instruction file and which directory it applies to.
  • The user-level directory follows the same priority.
  • Each file is capped at 100 KiB; a truncated file ends with a line saying so.
  • @ includes of files outside the working directory load without an approval step, as in the user-level file. The desktop app has no way to approve them today.
  • CLAUDE.local.md and .claude/rules/ stay as they are.
  • System prompt text that names CLAUDE.md names the other files too.

Done when

Tests show: a directory with both AGENTS.md and CLAUDE.md loads only AGENTS.md; DREAMCODER.md wins over both; a parent and a child directory each contribute one file; the nested load follows the same rule; a file over 100 KiB is truncated with the notice; an external @ include loads without approval.

Activity

  1. added
    enhancement
    help wanted
    difficulty:2
    on Nov 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    difficulty:2enhancementhelp wanted

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions