Borrowing it
Nothing to install: this file belongs to openJiuwen-ai/agent-memory. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/openJiuwen-ai/agent-memory/mem2.0/AGENTS.mdgit clone --depth 1 https://github.com/openJiuwen-ai/agent-memoryWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/instructions/openjiuwen-ai/agent-memory/agents-md)<a href="https://agentmods.dev/instructions/openjiuwen-ai/agent-memory/agents-md"><img src="https://agentmods.dev/badge/instructions/openjiuwen-ai/agent-memory/agents-md/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/instructions/openjiuwen-ai/agent-memory/agents-md"><img src="https://agentmods.dev/badge/instructions/openjiuwen-ai/agent-memory/agents-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.03140 | $0.03140 |
| Opus 5.5 | $0.01256 | $0.01256 |
| Sonnet 5.5 | $0.00628 | $0.00628 |
| Haiku 4.5 | $0.00314 | $0.00314 |
Grade A, and why
agent-memory AGENTS.md scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 121 lines — stays where its author put it; the contents beside it link to each section on GitHub.
agent-memory
结构化记忆系统 —— 负责记忆的摄入、构建、检索与生命周期管理。
项目结构
.
├── jiuwen_memory/ # 内核源码(接口/接入/构建/检索/编排/存储/共享插件)
├── tests/ # 测试(unit / integration,路径镜像 jiuwen_memory/)
├── jiuwen_memory_entry/ # 接入形态(CLI / HTTP / MCP / SDK;whl 独立顶层)
├── docs/ # 设计文档归档(design / specs / features)
├── jiuwen_memory_adapter/ # 外部 agent 插件适配(whl 独立顶层)
├── deploy/ # 部署配置(docker / local)
├── evaluation/ # 评测框架(benchmark / metrics / smoke_test)
├── examples/ # 使用示例与快速上手
├── scripts/ # 运行脚本(run-cli / run-server / run-mcp,见「环境与运行」)
└── .claude/ # AI 辅助工具配置(rules / skills / settings)
AGENTS.md 层级
AGENTS.md ← 本文件:项目入口,目录结构 + 测试/代码风格/归档/提交约定
jiuwen_memory/AGENTS.md ← 内核总览:模块地图 + 数据流 + 架构铁律 + 子模块 AGENTS.md 创建规则
jiuwen_memory/<subdir>/AGENTS.md ← 模块本地:代码目录结构、文件关系、入口、行为铁律、本地约束
docs/AGENTS.md ← 文档归档规约:文档目录结构、命名规则、文档骨架、提交约定
职责边界:
- 本文件:新人入口,描述项目是什么、怎么构建、代码风格、提交规范
jiuwen_memory/AGENTS.md:内核开发者入口,描述模块间关系和数据流走向jiuwen_memory/<subdir>/AGENTS.md:模块本地规约,只写相对稳定的结构性约束(模块职责边界、行为铁律、本地约束、文件关系),不写会频繁变化的特性设计docs/specs/:跨模块接口规约(接口契约、协议、不变量、公共 API),相对稳定docs/features/:特性设计文档(决策、方案取舍、验证基线、已知遗留),承载会变化的特性层面内容docs/AGENTS.md:只讲归档结构与命名规约,不重复模块设计内容
环境与运行
- Python:
>=3.11。包为顶层布局(jiuwen_memory/jiuwen_memory_entry/jiuwen_memory_adapter),无src/布局——仓库根存在空的src/目录但未纳入[tool.setuptools.packages.find],不要往里放代码或从中导入。 - 安装:
pip install -e ".[dev]"装开发依赖。按需追加 extras:deploy(Milvus/ES/Redis/PG 真后端 + api_reranker 出站 httpx)、mcp(MCP server)、nlp(spacy/hanlp)、embed(FlagEmbedding/torch)。pyproject.toml已配 uv 阿里云镜像。 - 运行入口用
scripts/run-{cli,server,mcp}.sh:它们已把PYTHONPATH设为仓库根:jiuwen_memory_entry/core;直接python -m jiuwen_memory_entry...会因缺jiuwen_memory_entry/core路径导致导入失败。- CLI:
scripts/run-cli.sh - HTTP server:
scripts/run-server.sh - MCP:
scripts/run-mcp.sh(需先pip install ".[mcp]";默认 stdio,设MCP_TRANSPORT=http+MCP_PORT切 Streamable HTTP)
- CLI:
- Postgres schema:
scripts/pg_schema.sql(deploy 后端用)。
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 3d ago First seen · 121 lines · 3,140 tokens per session scan A 07cce3a84a27
agent-memory AGENTS.md is an instructions file published in the GitHub repository openJiuwen-ai/agent-memory (72 stars, last pushed yesterday), licensed Apache-2.0. It adds 3,140 tokens to every session, about $0.0126 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-10-22.
Other instructions, from other repositories
vscode buildNext.instructions.md
Working notes and architecture documentation for the new esbuild-based build system in build/next. Use when making changes to the new build pipeline (transpile/bundle commands, NLS plugin, source-map handling, resource copying, or self-hosting watch tasks).
next.js AGENTS.md
AGENTS.md instructions for vercel/next.js, covering next.js development guide, codebase structure, monorepo overview, core package: packages/next and other important packages.
vscode oss-third-party-notices.instructions.md
Instructions for microsoft/vscode, covering vs code oss third-party-notices pipeline, architecture, pipeline flow in ci, cache eligibility and rollout and applying the notice (cutover).
langchain AGENTS.md
AGENTS.md instructions for langchain-ai/langchain, covering global development guidelines for the langchain monorepo, corridor security analysis, project architecture and context, monorepo structure and development tools & commands.
vscode copilot-instructions.md
Copilot instructions for microsoft/vscode, covering vs code copilot instructions, project overview, root folders, core architecture (src/ folder) and built-in extensions (extensions/ folder).
deepseek-harness AGENTS.md
AGENTS.md instructions for deepseek-ai/deepseek-harness, covering agents.md, pre-stable apis and released session data, repository layout, commands and host sandbox failures.