CLAUDE-NOTE-TAKING-INSTRUCTIONS.mdโข9.05 kB
# Revenue Engine MCP - Claude Documentation Instructions
## Purpose
Instructions for Claude on how to document all work in the Knowledge Matrix to enable automated analysis via `matrix_daily_summary` and `matrix_time_analysis` tools.
---
## Core Rules - ALWAYS FOLLOW
### 1. Every Entry Must Have Timestamp
**Format:** `H:MMpm/am TIMEZONE`
โ
**Correct:**
- `3:45pm CST ๐ Fixed EMAIL-001`
- `11:30am CST ๐ Updated documentation`
โ **Wrong:**
- `Fixed a bug` (no timestamp)
- `3pm Fixed bug` (no timezone)
### 2. Track Time Spent on Everything
**Format:** `[30m]`, `[2h]`, `[1.5h]`, `[45min]`
โ
**Correct:**
- `3:45pm CST Fixed EMAIL-001 [30m]`
- `Debugging session [1h] - found root cause`
โ **Wrong:**
- `Fixed bug (took a while)`
- `About an hour of work`
### 3. All Bugs Must Have UIDs
**Format:** `[CATEGORY]-[NUMBER]`
**Categories:** EMAIL, DEPLOY, MATRIX, PIPELINE, CALENDAR, API, MCP, AUTH, DATA, PERF
**Bug Entry Template:**
```
[TIME] [UID] [STATUS] [SEVERITY] Description [TIME]
- Root cause: ...
- Solution: ...
- Related: [OTHER-UID] (if applicable)
```
**Status:** NEW, INVESTIGATING, IN PROGRESS, TESTING, FIXED, WONTFIX
**Severity:** CRITICAL, HIGH, MEDIUM, LOW
**Example:**
```
3:00pm CST EMAIL-001 FIXED HIGH get_email_content not working [30m]
- Root cause: MCP pointing to old deployment @23, isStarred() invalid
- Solution: Created deployment @25, updated MCP URL
```
---
## Topic-Specific Guidelines
### ๐ Bugs & Fixes
**Must include:**
- Bug UID in [CATEGORY]-[NUMBER] format
- Status and severity
- Root cause (when fixed)
- Solution (when fixed)
- Time spent debugging + fixing
**Example:**
```
3:00pm CST EMAIL-001 FIXED HIGH get_email_content not working [30m]
- Root cause: MCP server pointing to old deployment @23
- Solution: Removed isStarred(), created deployment @25, updated URL
- Status: โ
VERIFIED
```
### โ
Features Added
**Must include:**
- Feature name/description
- Technical implementation details
- Time spent building
- Purpose/impact
**Example:**
```
4:00pm CST โ
Built matrix_daily_summary tool [1h]
- Parses timestamps, bug UIDs, time markers
- 3 output formats: bullet, prose, slack
- Auto-calculates session stats
- Deployed as MCP function + Apps Script backend
```
### ๐งช Testing Results
**Must include:**
- What was tested
- Time spent testing
- Test scenarios/results
- Any bugs discovered (create UIDs immediately)
**Example:**
```
3:15pm CST ๐งช Email fetching fully tested [15m]
- Test email: "Check this out" from Chris
- Retrieved: 3 attachments (19.1MB), all metadata working
- No bugs discovered
```
### ๐ฏ Decisions & Direction
**Must include:**
- Decision made
- Context/reasoning
- Time spent thinking/researching
- Expected impact
**Example:**
```
3:20pm CST ๐ฏ Learned deployment workflow [20m]
- Apps Script deployments are immutable
- Process: Edit โ push โ deploy โ update URL โ restart
- Each deploy creates new version
```
### ๐ Documentation Updates
**Must include:**
- File created/updated
- Key additions
- Purpose
**Example:**
```
5:00pm CST ๐ Created CLAUDE-NOTE-TAKING-INSTRUCTIONS.md [30m]
- Instructions for Matrix documentation
- Defines mandatory formats for automation
- Quality checklist included
```
### โก Next Session Goals
**Must include:**
- Priority marker: ๐ด HIGH, ๐ก MEDIUM, ๐ข LOW
- Specific, actionable goals
- Time estimates
- Context or blockers
**Example:**
```
๐ด HIGH: Test new Matrix automation tools [30m estimated]
- Restart Claude Desktop to load v1.7.0
- Test matrix_daily_summary with today's data
- Test matrix_time_analysis groupBy: bug, topic, day
๐ก MEDIUM: Build search_files tool [1h estimated]
- Grep-like functionality across project files
- Would have saved 15 mins today finding isStarred()
```
---
## Session Workflow
### During Work - Document as You Go
**Never batch document at end of session!**
1. **Starting a bug fix?**
- Create bug UID immediately with NEW status
- Update status: NEW โ INVESTIGATING โ IN PROGRESS โ TESTING โ FIXED
2. **Building a feature?**
- Start entry when beginning
- Add time markers as you progress
- Include technical details
3. **Made a decision?**
- Document immediately with reasoning
4. **Updated code/docs?**
- Note what changed and why
### End of Session Checklist
- [ ] All entries have timestamps
- [ ] All activities have time markers `[30m]`
- [ ] All bugs have UIDs + status + severity
- [ ] Bug fixes include root cause + solution
- [ ] Next Session Goals written with priorities
- [ ] Time totals are accurate
---
## Time Tracking Best Practices
### Be Honest and Accurate
- Track actual time, not ideal time
- Include troubleshooting and debugging
- Use 15-minute increments minimum
- Round to nearest 5 minutes for quick tasks
### Split Complex Work
```
3:00pm CST EMAIL-001 INVESTIGATING Root cause analysis [45m]
3:45pm CST EMAIL-001 IN PROGRESS Implementing fix [30m]
4:15pm CST EMAIL-001 TESTING Deployed and testing [15m]
4:30pm CST EMAIL-001 FIXED Verified working [10m]
```
### Track Interruptions Separately
```
3:00pm CST Answered user question about pipeline [10m]
3:10pm CST Back to EMAIL-001 debugging [20m]
```
---
## For Automation Tools to Work
### `matrix_daily_summary` Requires:
โ
Timestamps at start: `3:45pm CST`
โ
Bug UIDs: `EMAIL-001`, `DEPLOY-003`
โ
Time markers: `[30m]`, `[2h]`
โ
Clear topic separation
### `matrix_time_analysis` Requires:
โ
All time in brackets: `[30m]`, `[1.5h]`
โ
Bug UIDs for bug-specific tracking
โ
Consistent date format: YYYY-MM-DD
---
## Common Mistakes to Avoid
โ **Vague:** "Fixed bug"
โ
**Correct:** `3:00pm CST EMAIL-001 FIXED HIGH [30m]`
โ **Missing time:** "Added feature"
โ
**Correct:** `3:00pm CST โ
Added feature [2h]`
โ **No UID:** "Fixed email error"
โ
**Correct:** `EMAIL-001 FIXED HIGH`
โ **Batch documenting:** Writing everything at end
โ
**Correct:** Document as you work
โ **Unclear time:** "took a while"
โ
**Correct:** `[1.5h]`
โ **No root cause:** "Fixed EMAIL-001"
โ
**Correct:** Include root cause and solution
---
## Complete Entry Examples
### Bug Fix
```
3:00pm CST EMAIL-001 FIXED HIGH get_email_content tool not working [30m]
- Root cause: MCP server pointing to old deployment @23, thread.isStarred() not valid Gmail API method
- Solution: Removed isStarred() line, created deployment @25, updated MCP URL to new version
- Status: โ
VERIFIED - successfully fetching emails with attachments
```
### Feature
```
4:00pm CST โ
Built matrix_daily_summary tool [1h]
- Auto-generates formatted summaries of Matrix entries for any date
- Parses: timestamps, bug UIDs, time spent markers [30m], [2h]
- 3 output formats: bullet (markdown), prose (paragraph), slack (emojis)
- Auto-calculates stats: total time, bugs fixed, features added
- Deployed as MCP function + Apps Script backend
```
### Testing
```
3:15pm CST ๐งช Email fetching fully tested [15m]
- Test email: "Check this out" from Chris Waldenberger
- Successfully retrieved: subject, from/to, date, body, 3 attachments (19.1MB total)
- Returns complete thread metadata: labels, unread status, importance
- All message properties working: id, plainBody, htmlBody, attachments array
- No bugs discovered
```
### Decision
```
3:20pm CST ๐ฏ Learned deployment workflow [20m]
- Apps Script deployments are immutable - can't modify existing ones
- Process: Edit code โ clasp push โ clasp deploy โ update MCP URL โ restart Claude Desktop
- Each deploy creates new version number and new URL
- MCP server needs restart to pick up config changes
- Learned: Two restarts required today for versions @24 and @25
```
### Next Session Goals
```
๐ด HIGH: Test new Matrix automation tools [30m estimated]
- Restart Claude Desktop to load v1.7.0
- Test matrix_daily_summary with today's data (2025-10-16)
- Test matrix_time_analysis groupBy: bug, topic, day
- Verify time parsing works correctly with [30m], [2h] formats
๐ก MEDIUM: Build search_files tool [1h estimated]
- Would have saved 15 mins finding isStarred() bug today
- Grep-like functionality across project files
- Support for regex patterns and file type filtering
```
---
## Remember
**The Matrix is not just a log - it's training data for automation.**
Every well-formatted entry makes:
- `matrix_daily_summary` more useful
- `matrix_time_analysis` more accurate
- Future debugging faster
- Time tracking automatic
- Pattern detection possible
**Write for the tools, and the tools will work for you.**
---
## Quick Reference
### Time Format
- 15m = `[15m]`
- 30m = `[30m]`
- 45m = `[45min]`
- 1h = `[1h]`
- 1.5h = `[1.5h]`
- 2h = `[2h]`
### Bug UID Format
`[CATEGORY]-[NUMBER]`
- EMAIL-001
- DEPLOY-003
- MATRIX-005
### Timestamp Format
`H:MMpm/am TIMEZONE`
- 3:45pm CST
- 11:30am CST
### Status Values
NEW โ INVESTIGATING โ IN PROGRESS โ TESTING โ FIXED
### Severity Levels
CRITICAL > HIGH > MEDIUM > LOW
### Priority Markers
๐ด HIGH | ๐ก MEDIUM | ๐ข LOW