经 AI Skill Hub 精选评估,AI记忆系统 获评「推荐使用」。这款Agent工作流在功能完整性、社区活跃度和易用性方面表现出色,AI 评分 7.5 分,适合有一定技术背景的用户使用。
AI记忆系统 是一套完整的 AI Agent 自动化工作流方案。通过可视化的节点编排,将复杂的多步骤任务拆解为清晰的自动化流程,实现全程无人值守的智能处理。支持与数百种外部服务和 API 无缝集成,适合构建数据处理管线、业务自动化和 AI 辅助决策系统。
AI记忆系统 是一套完整的 AI Agent 自动化工作流方案。通过可视化的节点编排,将复杂的多步骤任务拆解为清晰的自动化流程,实现全程无人值守的智能处理。支持与数百种外部服务和 API 无缝集成,适合构建数据处理管线、业务自动化和 AI 辅助决策系统。
# 方式一:npm 全局安装 npm install -g cass_memory_system # 方式二:npx 直接运行(无需安装) npx cass_memory_system --help # 方式三:项目依赖安装 npm install cass_memory_system # 方式四:从源码运行 git clone https://github.com/Dicklesworthstone/cass_memory_system cd cass_memory_system npm install npm start
# 命令行使用
cass_memory_system --help
# 基本用法
cass_memory_system [options] <input>
# Node.js 代码中使用
const cass_memory_system = require('cass_memory_system');
const result = await cass_memory_system.run(options);
console.log(result);
# cass_memory_system 配置说明 # 查看配置选项 cass_memory_system --config-example > config.yml # 常见配置项 # output_dir: ./output # log_level: info # workers: 4 # 环境变量(覆盖配置文件) export CASS_MEMORY_SYSTEM_CONFIG="/path/to/config.yml"
Procedural memory for AI coding agents. Transforms scattered agent sessions into persistent, cross-agent memory—so every agent learns from every other agent's experience.
One-liner install (Linux/macOS):
curl -fsSL "https://raw.githubusercontent.com/Dicklesworthstone/cass_memory_system/main/install.sh?$(date +%s)" \
| bash -s -- --easy-mode --verify
Or via package managers:
```bash
cm doctor --json
ANTHROPIC_API_KEY, OPENAI_API_KEY, or GOOGLE_GENERATIVE_AI_API_KEYcm onboard status --json cm onboard sample --fill-gaps --json cm onboard read /path/to/session.jsonl --template --json cm onboard mark-done /path/to/session.jsonl ```
```bash
The installer is designed for reliability:
.sha256 files and verifies binary integrity before installationsha256sum on Linux, shasum -a 256 on macOScm --version
cm doctor --json
```bash
```bash
cm guard --install # Claude Code pre-tool hook cm guard --git # Git pre-commit hook cm guard --install --git # Both cm guard --status # Check installation status ```
Always use --json in agent contexts. stdout = data, stderr = diagnostics, exit 0 = success.
```bash
```bash
```bash
install.sh --version v0.2.2 --verify # Specific version install.sh --system --verify # Install to /usr/local/bin (requires sudo) install.sh --from-source # Build from source (requires bun) ```
| Flag | Effect |
|---|---|
--version | Install specific version (default: latest) |
--dest DIR | Install to custom directory (default: ~/.local/bin) |
--system | Install to /usr/local/bin (requires sudo) |
--easy-mode | Non-interactive, auto-configure PATH |
--verify | Run self-test after install |
--from-source | Build from source instead of downloading binary |
--quiet | Suppress output |
cm usage
cm onboard sample --fill-gaps ```
cm onboard sample --limit 20 ```
Filter sessions by various criteria to focus on specific areas:
```bash
install.sh [--version vX.Y.Z] [--dest DIR] [--system] [--easy-mode] [--verify] [--from-source] [--quiet]
cm init
cm init cm init --starter typescript # With starter template cm starters # List available starters
Config lives at ~/.cass-memory/config.json (global) and .cass/config.json (repo).
Precedence: CLI flags > Repo config > Global config > Defaults
Security: Repo config cannot override sensitive paths (cassPath, playbookPath, diaryDir) or user-level consent settings (crossAgent, remoteCass).
{
// LLM Settings
"provider": "anthropic",
"model": "claude-sonnet-4-20250514",
"budget": {
"dailyLimit": 0.10,
"monthlyLimit": 2.00,
"warningThreshold": 80
},
// Scoring Settings
"scoring": {
"decayHalfLifeDays": 90,
"harmfulMultiplier": 4,
"minFeedbackForActive": 3,
"minHelpfulForProven": 10,
"maxHarmfulRatioForProven": 0.1
},
// Context Settings
"maxBulletsInContext": 50,
"maxHistoryInContext": 10,
"sessionLookbackDays": 7,
"minRelevanceScore": 0.1,
// Privacy Settings
"crossAgent": {
"enabled": false,
"consentGiven": false,
"agents": [],
"auditLog": true
},
// Semantic Search Settings
"semanticSearchEnabled": false,
"semanticWeight": 0.6,
"embeddingModel": "Xenova/all-MiniLM-L6-v2",
"dedupSimilarityThreshold": 0.85,
// Paths (usually auto-detected)
"cassPath": "cass",
"remoteCass": {
"enabled": false,
"hosts": []
},
"playbookPath": "~/.cass-memory/playbook.yaml",
"diaryDir": "~/.cass-memory/diary"
}
| Option | Default | Description |
|---|---|---|
provider | "anthropic" | LLM provider: anthropic, openai, google |
model | "claude-sonnet-4-20250514" | Model for reflection |
baseUrl | _(unset)_ | Custom base URL for OpenAI-compatible gateways (OpenRouter, Z.AI, Azure, etc.) |
disableStructuredOutputs | false | Opt-in escape hatch for OpenAI strict structured-outputs mode. The reflect/audit/validate Zod schemas are written to be strict-compliant, but if you hit cm reflect returning zero deltas with "Invalid JSON response" warnings on a particular gateway/model combination (see #47), flipping this to true falls back to plain JSON mode while still applying the schemas as a post-hoc validator. Leave false unless you've confirmed strict-mode is the failure surface. |
budget.dailyLimit | 0.10 | Max daily LLM spend (USD) |
budget.monthlyLimit | 2.00 | Max monthly LLM spend (USD) |
budget.warningThreshold | 80 | Percentage before warning |
| Option | Default | Description |
|---|---|---|
scoring.decayHalfLifeDays | 90 | Days for feedback to decay to half value |
scoring.harmfulMultiplier | 4 | Weight harmful feedback N× more than helpful |
scoring.minFeedbackForActive | 3 | Min feedback to consider bullet "active" |
scoring.minHelpfulForProven | 10 | Min helpful marks for "proven" status |
scoring.maxHarmfulRatioForProven | 0.1 | Max harmful ratio for "proven" (10%) |
| Option | Default | Description |
|---|---|---|
maxBulletsInContext | 50 | Max rules to return in context |
maxHistoryInContext | 10 | Max history snippets to return |
sessionLookbackDays | 7 | Days to search for related sessions |
minRelevanceScore | 0.1 | Min relevance to include a bullet |
| Option | Default | Description |
|---|---|---|
crossAgent.enabled | false | Enable cross-agent diary enrichment |
crossAgent.consentGiven | false | Explicit consent flag |
crossAgent.agents | [] | Allowlist; empty means "all agents" |
crossAgent.auditLog | true | Log enrichment events |
Remote cass is opt-in and queries other machines via SSH (using your existing SSH config/keys). Remote hits are tagged with historySnippets[].origin.kind="remote" and origin.host.
| Option | Default | Description |
|---|---|---|
remoteCass.enabled | false | Enable SSH-based remote cass history |
remoteCass.hosts | [] | List of SSH targets: { host: "workstation", label?: "work" } |
| Option | Default | Description |
|---|---|---|
semanticSearchEnabled | false | Enable embedding-based search |
semanticWeight | 0.6 | Weight of semantic vs keyword (0-1) |
embeddingModel | Xenova/all-MiniLM-L6-v2 | Transformer model |
embeddingBackend | xenova | Embedding backend: xenova (local WASM) or ollama |
ollamaBaseUrl | http://localhost:11434 | Base URL when embeddingBackend: "ollama" |
dedupSimilarityThreshold | 0.85 | Threshold for duplicate detection |
The cm context command emits a semanticMode field in JSON/TOON output (one of "semantic" or "keyword"). When the user asked for semantic but the runtime could not provide it, semanticError explains why:
$ cm context "optimize API latency" --json | jq '.data | {semanticMode, semanticError}'
{ "semanticMode": "semantic", "semanticError": null }
In human output, a yellow warning banner is printed whenever semantic was requested but unavailable — no more silent fallback.
Releases ≤ v0.2.5 shipped a prebuilt binary that could not locate its bundled WASM runtime inside Bun's virtual filesystem. This was fixed in v0.2.6 (see issue #42): the onnxruntime-web WASM files are now embedded via Bun's type: "file" imports and wired up at startup. If you see ENOENT: ... /$bunfs/dist/ort-wasm-*.wasm on an older binary, upgrade:
curl -fsSL https://raw.githubusercontent.com/Dicklesworthstone/cass_memory_system/main/install.sh | bash -s -- --easy-mode
Alternatively, point cass-memory at a local Ollama daemon (no WASM):
{
"semanticSearchEnabled": true,
"embeddingBackend": "ollama",
"embeddingModel": "all-minilm"
}
| Variable | Purpose |
|---|---|
ANTHROPIC_API_KEY | API key for Anthropic (Claude) |
OPENAI_API_KEY | API key for OpenAI |
GOOGLE_GENERATIVE_AI_API_KEY | API key for Google Gemini |
CASS_PATH | Path to cass binary |
CASS_MEMORY_LLM | Set to none for LLM-free mode |
---
cm serve is an HTTP transport server (not stdio). Start it first, then point your MCP client at the URL.
For Claude Code (~/.config/claude/mcp.json):
{
"mcpServers": {
"cm": {
"type": "url",
"url": "http://127.0.0.1:8765/"
}
}
}
For VS Code (Cline/Continue):
{
"mcp": {
"servers": {
"cass-memory": {
"type": "url",
"url": "http://127.0.0.1:8765/"
}
}
}
}
---
cass-memory teaches agents how to use it—no external documentation required:
```bash
| Command | Purpose | Agent Use |
|---|---|---|
cm context "<task>" --json | Get rules + history for task | **Primary** |
cm quickstart --json | Self-documentation | Setup |
cm doctor --json | System health check | Diagnostics |
cm playbook list | Show all rules | Inspection |
cm similar "<query>" | Find similar rules | Search |
cm stats --json | Playbook metrics | Analytics |
cm trauma list | Show dangerous patterns | Safety |
cm guard --status | Check safety hook status | Safety |
cm quickstart --json
Recommended protocol for AI agents doing onboarding:
```markdown
```bash
cm serve
cass-memory implements the Agentic Context Engineering (ACE) framework with four stages:
┌──────────────┐ ┌──────────────┐ ┌──────────────┐ ┌──────────────┐
│ GENERATOR │ ──▶ │ REFLECTOR │ ──▶ │ VALIDATOR │ ──▶ │ CURATOR │
│ │ │ │ │ │ │ │
│ Pre-task │ │ LLM pattern │ │ Evidence │ │ Deterministic│
│ context │ │ extraction │ │ gate against │ │ delta merge │
│ hydration │ │ from diary │ │ cass history │ │ (NO LLM!) │
└──────────────┘ └──────────────┘ └──────────────┘ └──────────────┘
| Component | Responsibility | LLM? |
|---|---|---|
| **Generator** | Context hydration before tasks | No |
| **Reflector** | Pattern extraction from sessions | Yes |
| **Validator** | Evidence-based rule verification | Yes |
| **Curator** | Deterministic playbook management | **No** |
| **Scorer** | Decay-adjusted effectiveness calculation | No |
| **MCP Server** | Protocol bridge for agent integration | No |
cass-memory 是一个用于 AI 编码代理的过程性记忆系统。它提供了一个可扩展的记忆层,支持多种数据源和消费者。
cass-memory 的关键功能包括系统健康检查、可用功能、记忆层生成、反射器、验证器、收藏家和日记等。
cass-memory 需要 cass CLI 和 LLM API Key(可选)。cass CLI 可从 [cass repo](https://github.com/Dicklesworthstone/coding_agent_session_search) 安装。
cass-memory 的安装步骤包括构建 playbook(记忆层引导)、cm onboard status、cm onboard sample 和 cm onboard read 等。
cass-memory 的使用教程包括 agent 快速启动、cm doctor、cm quickstart 和 cm playbook list 等命令。
cass-memory 的配置说明包括目标采样选项、安装选项和全局配置等。
cass-memory 的 API 文档包括自我文档化 API、CLI 参考表和快速参考表等。
cass-memory 的工作流包括 onboarding 工作流、agent 命令和最小可行工作流等。
高质量的AI记忆系统,值得关注
该工具使用 NOASSERTION 协议,商用场景请仔细阅读协议条款,必要时咨询法律意见。
AI Skill Hub 为第三方内容聚合平台,本页面信息基于公开数据整理,不对工具功能和质量作任何法律背书。
建议在沙箱或测试环境中充分验证后,再部署至生产环境,并做好必要的安全评估。
📄 NOASSERTION — 请查阅原始协议条款了解具体使用限制。
AI Skill Hub 点评:AI记忆系统 的核心功能完整,质量良好。对于自动化工程师和运维人员来说,这是一个值得纳入个人工具库的选择。建议先在非生产环境试用,再逐步推广。
| 原始名称 | cass_memory_system |
| 原始描述 | 开源AI工作流:Procedural memory for AI coding agents: transforms scattered session history int。⭐374 · TypeScript |
| Topics | ai-agentsmemorytypescript |
| GitHub | https://github.com/Dicklesworthstone/cass_memory_system |
| License | NOASSERTION |
| 语言 | TypeScript |
收录时间:2026-06-06 · 更新时间:2026-06-06 · License:NOASSERTION · AI Skill Hub 不对第三方内容的准确性作法律背书。
选择 Agent 类型,复制安装指令后粘贴到对应客户端