Imported from CGOSU/pi-init (
templates/en/AGENTS.md). Install upstream withnpx skills add CGOSU/pi-init --skill en. Copyright stays with the author.
{{PROJECT_NAME}} AI Collaboration Guide
This file defines the long-term AI coding rules for this project. The package-published pi-init-role-routing Skill is the single source for the general task workflow, evidence gating, tool invocation, and role handoff rules; load it and the relevant roles/*.md profile on demand instead of copying those rules here.
- Start with project-specific rules (including
docs/clean-code.mdwhen its Clean Code guidance applies), project memory, or code directly relevant to the task; locate relevant memory by keywords instead of reading every document; - Use the project's
.pi/role-models.jsononly to enable roles and configure models throughroleModels, and do not generate or maintain a project-level role Skill; - only when a task produces reusable cross-project knowledge, update
https://github.com/CGOSU/knowledge.git; rungit pullin its local checkout first, then commit in Chinese and rungit push; - use
git config user.name CGOSUandgit config user.email dev@cgosu.comfor this repository.
Project Purpose
{{PROJECT_DESCRIPTION}}
Shared Collaboration Rules
The package-published pi-init-role-routing Skill is the single source for the general task workflow, evidence gating, read/edit invocation, role boundaries, and real verification requirements. When working on code, tests, documentation, or workflows, load that Skill and the relevant role profile on demand; this file keeps only project-specific purpose, environment, commands, knowledge-base, and Git rules.
For a clear, low-risk goal, make ordinary implementation choices and proceed without asking the user about helpers, internal decomposition, test organization, investigation order, or bug fixes that restore intended behavior. Ask only for business or contract conflicts, missing permission or credentials, irreversible or external-state operations, unsafe merges, or blocked real verification; record newly requested behavior, contracts, permissions, or data structures in the confirmed requirements or decision record first.
Runtime Environment and Command Conventions
{{ENVIRONMENT_CONTEXT}}
Common Commands
- Test:
{{TEST_COMMAND}}
Session Wrap-up
After completing a task:
- Update
docs/current-state.md, retaining only current facts and unfinished work; keep its “Last Updated” list in reverse chronological order; - record consequential implementation choices in
docs/decisions.md, inserting entries in reverse chronological order with the newest first; - add completed work, verification commands, and remaining issues to
docs/session-log.md, inserting entries in reverse chronological order with the newest first; - add newly discovered, non-obvious, recurring issues to
docs/pitfalls.md, inserting entries in reverse chronological order with the newest first.
Update a file only when there is a new fact to record; do not make no-op documentation edits. Maintain each fact in one file only. Elsewhere, use a short summary and a relative link to its canonical source.