
okf-memory/okf-agent-memory
Developer toolsこのページは AI により自動翻訳されています。技術的な詳細は原文をご確認ください。 原文を見る
AIコーディングエージェント向けのgitネイティブ永続メモリ。Google OKF v0.2を実装し、300μs未満のメモリ内BM25検索、組み込みMCPサーバー、プログレッシブ開示を可能にしています。
概要
コンテキストウィンドウが閉じるとAIエージェントとの会話はリセットされます。貴重なアーキテクチャ上の決定、ドメイン発見、運用上の事実は、永続的に保存されなければ失われてしまいます。 標準化されたベンダー中立のメモリ層を提供し、リポジトリ(knowledge/)に直接存在し、YAMLフロントマター付きのプレーンMarkdownファイルとして存在します。これは、非構造化のアドホックマークダウンファイル(CLAUDE.md、AGENTS.md)と複雑でブラックボックスのベクターデータベースの間の橋渡しをします。 * : メモリ内のBM25取得およびバンドル検証は、VMのスピンアップやネットワーク往復なしでマイクロ秒単位で実行されます。* : すべてバージョン管理されたプレーンテキストです。標準のgit diffとgit logを使ってエージェントのメモリを検査、監査、レビューします。外部データベースは不要です。* : ローカル語彙によるBM25インデックス作成により、繰り返し発生するベクトル埋め込みAPIコストやネットワーク往復を削減します。* : エージェント知識にはオープンスタンダードフォーマットを使用し、出所(ソース)、信頼階層(生成と生成)を完全サポートします
概要(AI 翻訳)
**Open Knowledge Format(OKF)v0.2に基づくAIエージェント向けのドメインニュートラル、gitネイティブの永続プロジェクトメモリ **
🌟 概要
コンテキストウィンドウが閉じるとAIエージェントとの会話はリセットされます。貴重なアーキテクチャ上の決定、ドメイン発見、運用上の事実は、永続的に保存されなければ失われてしまいます。
従来の手法には2つの致命的な失敗モードがあります。
- プロンプトモノリス:すべてのドメイン知識とルールを
AGENTS.mdまたはCLAUDE.md]に詰め込むと、文脈の膨張が大きくなり、注意のずれ(エージェントが重要な指示を無視する)を引き起こします。 - RAGブラインドスポット:ベクターデータベースに振る舞いルールをダンプするのは失敗します。なぜなら、エージェントは一般的なタスク中に運用上の制約(例:フォーマットやセキュリティルール)を意味的に検索しないためです。
OKFエージェントメモリは**デュアルメモリエージェントアーキテクチャ(DMAA)**でこのジレンマを解決します:
普遍合成モデル
DMAAでは、すべてのエージェント構成は普遍的な構成によって構成されます:
$$\テキスト{エージェントたち。
このページは AI により自動翻訳されています。技術的な詳細は原文をご確認ください。
README
以下は原文 README の抜粋です。原文を見る。
OKF Agent Memory
A Domain-Neutral, Git-Native Persistent Project Memory for AI Agents based on the Open Knowledge Format (OKF) v0.2.
🌟 Overview
Conversations with AI agents reset when context windows close. Valuable architectural decisions, domain discoveries, and operational facts are lost unless stored persistently.
Traditional approaches suffer from two fatal failure modes:
- The Prompt Monolith: Stuffing all domain knowledge and rules into
AGENTS.mdorCLAUDE.mdcreates massive context bloat and causes attention drift (agents ignore critical instructions). - The RAG Blindspot: Dumping behavioral rules into vector databases fails because agents never semantically search for operational constraints (e.g. formatting or security rules) during general tasks.
OKF Agent Memory resolves this dilemma with the Dual-Memory Agent Architecture (DMAA):
flowchart TD
subgraph PUSH["1. Normative Working Memory (Push Layer)"]
direction TB
C1["Canonical AGENTS.md (capped at 400 tokens)"]
C2["Domain Codex (Invariants, Ethics, Tone)"]
C3["OKF Memory Bridge (Deterministic Triggers)"]
C4["Agent Action Grammar (AAG) Micro-Syntax"]
end
subgraph PULL["2. Semantic Domain Memory (Pull Layer)"]
direction TB
O1["OKF v0.2 Knowledge Bundle (knowledge/)"]
O2["0 Tokens baseline in system prompt"]
O3["Selective Retrieval via okf_search / okf_show"]
O4["Persistent Graph of Decisions, Facts & Runbooks"]
end
INPUT["User Request"] --> PUSH
PUSH -->|Enforces Domain Codex & Triggers| AGENT["AI Agent (LLM)"]
AGENT -->|Selective Retrieval| PULL
PULL -->|Context & Facts| AGENT
AGENT --> OUTPUT["Deterministic Response"]
The Universal Composition Model
In DMAA, every agent configuration is structured by a universal composition:
インストール
This server does not publish a one-line install command.
Open the repository installation guide MCP 初心者?mcpskill.org のガイドから始めましょう →設定
{
"mcpServers": {
"okf-memory": {
"command": "/path/to/okf-agent-memory/bin/okf",
"args": ["mcp", "/path/to/project/knowledge"]
}
}
}