Usage instructions
Core usage
memory-pipelineIt is a dual-track AI agent enhancement system, includingMemory Pipeline(Python)andPerformance Routine(TypeScript)Two major subsystems.
Memory PipelineRun a three-stage process between sessions:
1. Extract— Extract structured facts (decisions, preferences, learning, commitments) from daily notes and session transcripts using LLM
2. Link— Build embedded vector knowledge graphs, establish bidirectional links between facts, detect contradictions and mark outdated information
3. Briefing— Generate a compact BRIEFING.md that contains context such as personalized reminders, active projects, recent decisions, etc.
Performance RoutineExecuted within the session through four life cycle hooks:
before_agent_start:Inject pre-assembled briefing package (checklist+memory+constraints)before_tool_call: Execution tool strategy (deny list, parameter normalization)tool_result_persist: Head-to-tail compression of large tool results to prevent context bloatagent_end: Write an after-action review to build memory for the next run
The system supports OpenAI, Anthropic, and Gemini APIs, automatically detects workspaces, and can be integrated into HEARTBEAT.md for automation.
Significant advantages
1. Cross-session continuity: Solve the core pain point of LLM statelessness, the agent can "remember" user preferences and project history
2. enforce discipline: Drawing on the principle of "separating thinking and execution" from sports psychology to avoid instruction conflicts during mid-run
3. contextual efficiency: Intelligent compression (first 60% + last 30%) and 2000 character briefing limit, adapted to long context model
4. knowledge interpretability: Generate human-readable knowledge summaries and conflict detection reports to facilitate manual auditing
5. Zero-invasive integration: Works through the OpenClaw hook system without modifying the agent core logic
Potential Disadvantages and Limitations
1. Heavy external dependencies: At least one LLM API key must be configured, and the offline environment cannot run
2. delay cost: A full pipeline run requires multiple LLM calls, which may increase session startup time
3. Embed quality sensitive: When there is no OpenAI key, it degrades to keyword matching and the link accuracy decreases.
4. Newer version: v0.1.0 has not yet been verified for mass production, and the API may change
5. OpenClaw binding:Performance Routine relies on the OpenClaw context loading feature which is not yet fully released
Suitable target group
- Long-term project agent user: Developers who need agents to handle complex tasks for weeks/months
- Multi-session workflow team: Enterprise scenario where multiple people share agent context
- AI agent framework developer:Researcher who studies memory architecture and tool execution disciplines
- Scenarios with high reliability requirements: Finance, medical and other fields that require decision traceability
Risks of use
- API cost accumulation: Daily automatic operation may cause continuous Token consumption
- memory drift: After long-term operation, the knowledge graph may accumulate contradictions and require regular manual review.
- Blurred privacy boundaries: Session records are automatically uploaded to the third-party LLM API, and sensitive data needs to be preprocessed
- File system bloat:
extracted.jsonlFor additional writing, an archiving strategy is required for long-term operation.
Safety review
Core usage
Memory PipelineProvides three-stage memory management:
- Extract: Extract structured facts (decisions, preferences, commitments, etc.) from conversation records and notes, and the output is
extracted.jsonl - Link: Construct a knowledge graph, generate embedding vectors, establish two-way links between facts, and detect contradictions
- Briefing: Generate daily
BRIEFING.md, integrating personality settings, active projects, and key context
Performance RoutineFour lifecycle hooks are provided:
before_agent_start: Pre-injection briefing package, separation of thinking and executionbefore_tool_call: Tool call policy control, support deny listtool_result_persist: Head-to-tail compression of large tool results to prevent context bloatagent_end: Write a review after the action to accumulate memory for the next run.
Significant advantages
1. Clear architecture: Python script is responsible for offline memory processing, TypeScript hook is responsible for online execution control, and the separation of responsibilities is clear.
2. Advanced design principles: Drawing on the "rehearsal-execution-review" model of sports psychology, intervention during execution is prohibited to avoid instruction conflicts.
3. Compatible with multiple models: Supports OpenAI/Anthropic/Gemini APIs, automatic downgrade and fault tolerance
4. Safe and controllable: File operations are strictly limited to the user's workspace, no dangerous code patterns, and obtained security certification level A
5. Expandable: Provides a complete configuration interface and custom model options
potential limitations
- Cloud dependency: The core functions rely on external LLM API, user data needs to be transferred overseas, and privacy-sensitive scenarios are limited.
- Data persistence is not clear:
extracted.jsonlWaiting for files to be appended indefinitely and lack of automatic cleaning mechanism - Features under development: The automatic loading of BRIEFING.md depends on the "OpenClaw context loading" function under development
- Weak error recovery: If the API call fails, only an error will be printed, without a retry mechanism.
- No native model support: Local deployment solutions such as Ollama/vLLM are currently not supported
Suitable for the crowd
- Requires AI agentMaintain consistency across sessionsof long-term project users
- PursueExecution quality controllabilityProfessional scenarios (research, writing, programming assistance)
- Agent framework developers using OpenClaw or a compatible lifecycle hook architecture
- Individual or team users who are willing to accept the Cloud LLM data processing policy
General risks
|risk category|illustrate|Mitigation measures|
|---------|------|---------|
|Data export|Session content transferred to OpenAI/Anthropic/Google|Review the data processing policies of each service provider and consider desensitizing sensitive information|
|memory file bloat|JSONL/Graph files grow over time|Manually clean up regularly or set up a cron task to archive old data|
|API availability|Functions depend on external service providers for stability|Configure multiple API keys for backup, and keep local copies for key scenarios|
|Privacy Compliance Gaps|Lack of clear data retention policy and user consent mechanism|Create your own data management documents to clearly remember the file life cycle|
automationproductivitydevelopment-engineeringdata-analyticsbackendai-ml
Copyright and takedown notice: AI Islands curates this page from public information. Skills, code, documents and packages remain the property of their original authors or rights holders. This listing is provided for indexing, research and installation convenience. If you believe any listing or download link infringes your rights, contact ai-islands@streamflowintel.com with proof of ownership, relevant URLs and your request. We will review and remove or adjust the content promptly. Review package permissions, dependencies and safety risks before installing.