KScript docs
EN

Coding agents

Adding project guidance

Write project instructions above the generated block in AGENTS.md or on a new line below <!-- kscript agents: end -->. KScript keeps both sections when it updates the file. Keep the two generated marker comments on their own lines.

To maintain guidance in separate Markdown files, list them in kscript.json:

JSON
{
  "agents": {
    "merge": ["docs/team-guidance.md", "docs/review-checklist.md"]
  }
}

Run kscript agents to include the files in a Project guidance section near the top of the generated block, in the order listed. Edit the source Markdown and regenerate. File paths are relative to kscript.json. Each file must be a local .md or .markdown file inside the project. Generated files, symbolic links and reserved marker lines outside code fences are rejected. Close any code fences within each source file. Missing or invalid inputs leave the current AGENTS.md untouched.

kscript agents --print includes the merged guidance and kscript agents --check detects changes to it without updating files. The built-in reference budget leaves the project guidance whole.

Edit this page on GitHub