Project Implementation Rules & Guidelines
This document outlines rules for referencing planning documents and managing the To-Do list during the implementation phase of features.
1. Referencing Planning Documents
When implementing features, consistently refer back to the relevant planning documents created during the Architect phase.
For Instance, For the AI Chatbot feature, these are:
- @chatbot-prd.md : :** Contains user stories, requirements, and overall goals. Use this to ensure the implementation meets the user needs.
- @chatbot-feature-spec.md : Provides technical details, architecture, API design, and data flow. Use this as the technical blueprint for implementation.
- @chatbot-plan-summary.md: Offers a high-level overview and data flow diagram for quick reference.
Before starting a specific implementation task, briefly review the corresponding sections in the PRD and Feature Spec to ensure alignment.
2. Updating the To-Do List (ex: @chatbot-todo.md)
The To-Do list is the primary tool for tracking implementation progress. Follow these steps:
- Before Starting a Task: Identify the next logical task(s) from the To-Do list (
[ ]
). - Mark Task as In Progress: When you begin working on a task, update its status marker to
[-]
.- Example:
[-] **Backend:** Create
backend/lambdas/chatbot-query/directory.
- Example:
- Upon Completing a Task: Once a task is successfully completed and verified (e.g., code written, infrastructure applied, tested locally), update its status marker to
[x]
.- Example:
[x] **Backend:** Create
backend/lambdas/chatbot-query/directory.
- Example:
- If Blocked: If a task cannot proceed due to external dependencies or unresolved issues, mark it as
[b]
and add a brief note explaining the blocker.- Example:
[b] **Infrastructure:** Add Cognito Authorizer configuration... (Blocked by Cognito infrastructure setup)
- Example:
- Adding New Tasks: If implementation reveals necessary sub-tasks not originally listed, add them to the appropriate phase in the To-Do list with the
[ ]
marker. - Regular Updates: Aim to update the To-Do list after completing each significant step or tool use.
3. Communication
When presenting results, briefly mention which task(s) from the To-Do list were addressed or are about to be addressed. This helps maintain context and track progress against the plan.
4. Maintain Overall Project Context
Before starting implementation on a specific task, it is crucial to understand the context of the entire project. Do not implement features in isolation without considering the existing codebase and conventions.
- Review Existing Code: Actively read the current codebase, particularly related modules, services, or configurations.
- Identify Established Patterns: Pay close attention to existing conventions, including:
- Dependency Versions: Check files like
package.json
,requirements.txt
, etc., to understand which library versions are currently used throughout the project. - Coding Style & Formatting: Adhere to established linting rules and code formatting practices.
- Architectural Patterns: Follow the architectural choices already implemented (e.g., existing design patterns, data access methods).
- Configuration Management: Understand how configuration is managed (e.g., environment variables, config files, parameter stores).
- API Design Principles: Maintain consistency with existing API endpoint naming, request/response structures, and authentication methods.
- Dependency Versions: Check files like
- Ensure Consistency: Adhere strictly to these established patterns and versions. Avoid arbitrarily choosing new library versions, introducing conflicting coding styles, or implementing architectural approaches that deviate significantly from the project’s standard without prior discussion and agreement.