Build 'Team Memory' for coding teams with Claude.md | Alpha | PandaiTech

Build 'Team Memory' for coding teams with Claude.md

How to use a 'claude.md' file in your repository to teach Claude Code about your team's specific rules and automatically update the file through Pull Requests (PR).

Learning Timeline
Key Insights

The 'Compound Engineering' Principle

Never correct the same mistake twice. As soon as you see Claude make an error, update 'claude.md' immediately so the AI learns and avoids repeating it in the future.

Flexible File Format

The 'claude.md' file is just a plain text file. You are free to use any format (Markdown, bullet points, etc.) that makes it easy for your team to read and manage.

Correct Tagging Tip

Ensure you use '@claude' (without a period) when mentioning it in GitHub Issues or Pull Requests to activate the bot.
Prompts

Updating Team Memory via PR

Target: Claude Code (via GitHub PR Comments)
@claude please update the claude.md file to include a rule that we should always use functional components instead of class components for all new React files.
Step by Step

Building and Managing 'Team Memory' Using claude.md

  1. Create an empty text file named 'claude.md' in the root directory of your team's Git repository.
  2. Add coding guidelines, team-specific rules, or a 'do not do' list that Claude needs to know into the file.
  3. Commit and Push the file to the main repository so the entire team has access to the same 'Team Memory'.
  4. Install the Claude Code GitHub Action into your repository to enable Claude to interact directly with Pull Requests (PR).
  5. During the Code Review process, identify mistakes or improvements that the AI should remember for the future.
  6. Leave a comment on the Pull Request (PR) by mentioning @claude to instruct the AI to automatically update the 'claude.md' file.
  7. Review the changes made by Claude within that PR branch (Claude will auto-push the changes back to your branch).
  8. Merge the Pull Request to ensure the updated 'Team Memory' is available for other team members.

More from AI-Powered Coding & App Development

View All