This document contains critical rules and guidelines for AI agents working on this codebase.
## Security Rules
### CRITICAL: No Dynamic Values in Logs
**All log statements MUST use static strings only
carries `review` unless it is already in another pipeline state.
- Category (`bug`, `feature`, `refactor`, `security`, `dependencies`, `enterprise`, `documentation`) and meta (`needs-qa`, `skip-qa`, `qa-approved`, `qa-self-verified
sibling files and MCP credentials. Workspace tool selection is a routing convention, not a security boundary; use separate computers for isolation.
### Prompts, memory & memos
- **Prompts**: Jinja2 templates in `src/ptc_agent/agent/prompts/templates/`, config
NAME` takes the certificate's name **without** the `Developer ID
Application:` prefix that `security find-identity` prints, which is the whole
string a person naturally copies. electron-builder picks
clear description, the affected areas (e.g., `desktop/electron/`), and any UI screenshots for renderer changes.
## Security & Configuration Tips
- API keys and model settings are user-configured in the app settings
capacity limits are path-specific contracts; establish each from current product evidence, a released security or compatibility obligation, or explicit approval.
Cross-device reachability, execution placement, state ownership, persistence, availability
Consumers include Cloudflare's Go fork, downstream modules, and external
researchers. Every change is security-sensitive. The README disclaims API
stability — the bar is **"correct and justified,"** not "frozen."
**When
size reduction with 85% performance retention
- Real-time conversation capabilities with local models
### Security and Privacy
- All processing happens locally - no data sent to cloud
- Suitable for privacy-sensitive applications
while retaining 85% performance
- Enables real-time conversation capabilities with local models
### Security and Privacy
- All processing is done locally - no data is sent to the cloud
- Suitable for privacy
still keep 85% performance
- E fit do real-time conversation wit local models
### Security and Privacy
- All processing dey happen for local - no data dey go cloud
- E good
validation; verify the PR and return its link. Do not merge without authorization.
## Security Red Lines
- Token、密码和私钥只能存入系统安全凭据存储,禁止进入数据库、配置文件、日志、URL 或同步仓库。
- 只有用户主动操作或明确开启的后台功能才能读取凭据;页面加载、Tab 切换、状态展示和普通启动不得读取。
- 开发版必须使用独立的凭据命名空间;授权
invoked directly.
Next.js documentation explicitly states: "Treat Server Actions with the same security considerations as public-facing API endpoints, and verify if the user is allowed to perform a mutation
pytest`, docs build if relevant)
- docs updates when CLI behavior, commands, or architecture changed
## Security & Configuration Tips
- Use `.env` for local secrets; never commit credentials.
- Bub runtime settings are driven
confirmed user
decisions. Ask only when an unresolved choice materially affects scope, user
data, security, ownership, or compatibility. An explicit user decision updates
the authoritative requirement immediately; record any implementation