@fengrru/project-memory
v0.1.0
Published
File-based project memory with MEMORY.md persistence, Markdown parsing, fact promotion from stable checkpoints, and full-text search
Maintainers
Readme
@fengrru/project-memory
File-based MEMORY.md project knowledge persistence.
Install
npm install @fengrru/project-memoryQuick Start
import { ProjectMemoryManager } from "@fengrru/project-memory"
const manager = new ProjectMemoryManager({
filePath: "./MEMORY.md",
})
// Add entry
await manager.upsert({
id: "auth-pattern",
section: "patterns",
content: "Use JWT for authentication",
confidence: 0.9,
})
// Search
const results = manager.search("authentication")
// Promote discovery
await manager.promoteDiscovery("User prefers dark mode")Sections
| Section | Description | |---------|-------------| | facts | Verified information | | patterns | Recurring behaviors | | rules | Constraints and guidelines | | decisions | Architecture choices | | observations | Runtime insights |
Features
- JSONL format: line-based storage
- Auto-dedup: merge similar entries
- Verification count: increment on access
- User lock: protect user-created entries
- Confidence markers: visual indicator in markdown
Documentation
- API Reference — TypeDoc-generated API docs
- Source Code
- Examples
License
MIT
