aboutsummaryrefslogtreecommitdiffstats
path: root/modules/development/pi-coding-agent/CONTEXT.md
diff options
context:
space:
mode:
Diffstat (limited to 'modules/development/pi-coding-agent/CONTEXT.md')
-rw-r--r--modules/development/pi-coding-agent/CONTEXT.md55
1 files changed, 55 insertions, 0 deletions
diff --git a/modules/development/pi-coding-agent/CONTEXT.md b/modules/development/pi-coding-agent/CONTEXT.md
new file mode 100644
index 0000000..c47c9e8
--- /dev/null
+++ b/modules/development/pi-coding-agent/CONTEXT.md
@@ -0,0 +1,55 @@
+# Global Pi Context
+
+## General
+
+- Inspect the project before making changes.
+- Follow existing project conventions and architecture.
+- Prefer the smallest correct change.
+- Preserve existing user changes.
+- Reuse existing dependencies and abstractions when appropriate.
+- Do not introduce dependencies unless they are necessary.
+- Avoid unrelated refactoring.
+
+## Before changing code
+
+- Read the relevant files and surrounding implementation.
+- Determine how the affected functionality is currently used.
+- Look for existing tests, scripts, formatters, linters, and documentation.
+- Check project-local instructions before making changes.
+
+## Implementation
+
+- Prefer simple, maintainable solutions.
+- Handle errors explicitly where appropriate.
+- Avoid unnecessary abstractions.
+- Avoid premature optimization.
+- Preserve existing public interfaces unless the task requires changing them.
+- Avoid over-documentation, keep comments to a minimum.
+- Only use comments if logic seems non-trivial or if it follows the project standard, like documentation comments for functions.
+
+## Validation
+
+- Run the project's appropriate formatter, linter, type checker,
+ build command, or tests after making changes.
+- Prefer targeted validation first, followed by broader validation
+ when practical.
+- Do not claim validation was performed when it was not.
+
+## Git
+
+- Inspect the working tree before destructive operations.
+- Never discard, reset, overwrite, or rewrite user changes unless
+ explicitly requested.
+- Do not create commits unless asked.
+- Keep commits focused when commits are requested.
+
+## Project instructions
+
+Project-local instructions take precedence for project-specific
+conventions and workflows.
+
+## Communication
+
+- Do not explain implementation details unless asked.
+- Keep responses concise.
+- Report relevant errors and validation results clearly.