docs: Replace Mindbase References with ReflexionMemory (#464)

* docs: fix mindbase syntax and document as optional MCP enhancement

Fix incorrect method call syntax and clarify mindbase as optional
enhancement that coexists with built-in ReflexionMemory.

Changes:
- Fix syntax: mindbase.search_conversations() → natural language
  instructions that allow Claude to autonomously select tools
- Clarify mindbase requires airis-mcp-gateway "recommended" profile
- Document ReflexionMemory as built-in fallback (always available)
- Show coexistence model: both systems work together

Architecture:
- ReflexionMemory (built-in): Keyword-based search, local JSONL
- Mindbase (optional MCP): Semantic search, PostgreSQL + pgvector
- Claude autonomously selects best available tool when needed

This approach allows users to enhance error learning with mindbase
when installed, while maintaining full functionality with
ReflexionMemory alone.

Related: #452

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>

* docs: add comprehensive ReflexionMemory user documentation

Add user-facing documentation for the ReflexionMemory error learning
system to address documentation gap identified during mindbase cleanup.

New Documentation:
- docs/user-guide/memory-system.md (283 lines)
  * Complete user guide for ReflexionMemory
  * How it works, storage format, usage examples
  * Performance benefits and troubleshooting
  * Manual inspection and management commands

- docs/memory/reflexion.jsonl.example (15 entries)
  * 15 realistic example reflexion entries
  * Covers common scenarios: auth, DB, CORS, uploads, etc.
  * Reference for understanding the data format

- docs/memory/README.md (277 lines)
  * Overview of memory directory structure
  * Explanation of all files (reflexion, metrics, patterns)
  * File management, backup, and git guidelines
  * Quick command reference

Context:
Previous mindbase cleanup removed references to non-existent external
MCP server, but didn't add sufficient user-facing documentation for
the actual ReflexionMemory implementation.

Related: #452

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>

* docs: translate Japanese text to English in documentation

Address PR feedback to remove Japanese text from English documentation files.

Changes:
- docs/mcp/mcp-integration-policy.md: Translate headers and descriptions
- docs/reference/pm-agent-autonomous-reflection.md: Translate error messages
- docs/research/reflexion-integration-2025.md: Translate error messages
- docs/memory/pm_context.md: Translate example keywords

All Japanese text in English documentation files has been translated to English.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>

---------

Co-authored-by: Claude <noreply@anthropic.com>
This commit is contained in:
Cedric Hurst
2025-10-30 22:14:35 -05:00
committed by GitHub
parent c733413d3c
commit bea4bfe289
11 changed files with 680 additions and 82 deletions

View File

@@ -191,30 +191,26 @@ When: Error detected
Token Budget: 0 tokens (cache lookup) → 1-2K tokens (new investigation)
Process:
1. Check Past Errors (Smart Lookup):
IF mindbase available:
mindbase.search_conversations(
query=error_message,
category="error",
limit=5
)
→ Semantic search (500 tokens)
ELSE (mindbase unavailable):
→ Grep docs/memory/solutions_learned.jsonl
→ Grep docs/mistakes/ -r "error_message"
→ Text-based search (0 tokens, file system only)
1. Check Past Errors (Automatic Tool Selection):
→ Search conversation history for similar errors
Claude automatically selects best available tool:
* mindbase_search (if airis-mcp-gateway installed)
- Semantic search across all conversations
- Higher recall, cross-project patterns
* ReflexionMemory (built-in, always available)
- Keyword search in reflexion.jsonl
- Fast, project-scoped error matching
2. IF similar error found:
✅ "⚠️ 過去に同じエラー発生済み"
✅ "解決策: [past_solution]"
✅ "⚠️ Same error occurred before"
✅ "Solution: [past_solution]"
✅ Apply solution immediately
→ Skip lengthy investigation (HUGE token savings)
3. ELSE (new error):
→ Root cause investigation (WebSearch, docs, patterns)
→ Document solution (future reference)
Update docs/memory/solutions_learned.jsonl
Store in ReflexionMemory for future sessions
4. Self-Reflection:
"Reflection:
@@ -225,9 +221,9 @@ Process:
📝 Learning: Add env validation to startup checklist"
Storage:
→ docs/memory/solutions_learned.jsonl (ALWAYS)
→ docs/memory/reflexion.jsonl (ReflexionMemory - ALWAYS)
→ docs/mistakes/[feature]-YYYY-MM-DD.md (failure analysis)
→ mindbase (if available, enhanced searchability)
→ mindbase (if airis-mcp-gateway installed, automatic storage)
Result:
✅ <10% error recurrence rate (same error twice)