MemOmics-Agent AGENTS.md

MemOmics-Agent AGENTS.md is an instructions file for Codex, OpenCode from GGbond-bo/MemOmics-Agent. It costs 810 tokens per session, scanned A, original, MIT.

A set of repository rules for AI agents and people working on MemOmics-Agent. It defines how to test changes, protect backups, structure code, and record analysis results.

In plain words
What is it for?
Use it when changing the MemOmics-Agent codebase, especially its web server, execution tools, tests, or analysis-result handling.
Why use it?
It prevents unfinished changes, accidental data loss, untested features, and violations of the project's architecture rules.

Instructions file for CodexOpenCode

Written for Codex and OpenCode: the file is AGENTS.md. Also seen: mentions AGENTS.md; built for hermes-agent.

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add instructions/ggbond-bo/memomics-agent/agents-md
Clone the repo
git clone --depth 1 https://github.com/GGbond-bo/MemOmics-Agent

Made for: Codex, OpenCode.

Wrote 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.

agentmods badge for MemOmics-Agent AGENTS.md

README.md
[![agentmods](https://agentmods.dev/badge/instructions/ggbond-bo/memomics-agent/agents-md.svg)](https://agentmods.dev/instructions/ggbond-bo/memomics-agent/agents-md)
Your own site
<a href="https://agentmods.dev/instructions/ggbond-bo/memomics-agent/agents-md"><img src="https://agentmods.dev/badge/instructions/ggbond-bo/memomics-agent/agents-md.svg" alt="Measured on agentmods" height="20"></a>
Per session 810 This file is loaded in full into every session.
When invoked 810 The same file — it is already loaded in full.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5.1 $0.00810 $0.00810
Opus 5 $0.00405 $0.00405
Sonnet 5 $0.00162 $0.00162
Haiku 4.5 $0.00081 $0.00081

Measured 6d ago against content hash ef298fc0a0a0, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-05, from the pricing page.

Security

Grade A, and why

MemOmics-Agent 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 6d 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.

AGENTS.md · 53 lines

What it actually says

AGENTS.md — MemOmics 协作规范

给在此仓库工作的 AI 代理(及人类协作者)的规则。违反这些规则的修改会被退回。

黄金规则

  1. 改完必须测:任何代码修改后,运行 .venv/Scripts/python.exe -m pytest(Windows) 或 uv run pytest(Linux/macOS)。测试不绿 = 修改未完成。
  2. 先测试后重构:涉及 webui/server.pyhermes-agent/tools/ 的改动, 先确认相关测试存在;无测试覆盖的新功能必须补测试(见 tests 规范)。
  3. 不删备份:删除 .bak* / .backups/ 前先确认内容;重要改动前先 git commit(不是 git stash)。
  4. 提交要小、信息要实:一个提交一件事;提交信息写清"为什么"和验证结果。

测试规范(P0-3 起)

  • 测试目录:webui/tests/,pytest + marker 门禁(pytest.ini
  • 默认运行只跑 offline:-m "not external and not network and not live_llm and not gpu and not ssh and not lab and not docker and not browser"
  • 需要真实外部资源的测试打对应 marker(@pytest.mark.network 等), 默认不跑;手动 -m network
  • 测试会话必须清理:用 conftest.pynew_session fixture 或 cleanup_session()(内存 + state.db + results 目录),禁止污染生产数据
  • 新接口/新模块:至少覆盖 正常路径 + 错误路径 + 边界

架构红线

  • webui/server.py(7398 行)是巨型文件:新增功能优先放 hermes-agent/tools/ 独立模块,server 只做薄路由
  • 核心执行层(code_execution_tool.py / persistent_kernel.py)改动必须 跑 webui/tests/test_kernel_pool.py + 集成验证(execute_code 真实调用)
  • 结果完成契约:分析结束用 POST /api/results/manifest 提交 analysis_manifest(版本化 + 溯源),不要只丢散文件
  • 可写路径白名单:MEMOMICS_ALLOWED_WRITE_ROOTS(server 自动注入 results+uploads);沙箱 degraded 模式写白名单外路径会被拒

历史教训(必须记住)

  • 2026-08-08:知识库图谱功能因"改完不提交"丢失两次(git 无记录), 完成一轮功能立即 git add + commit
  • .gitignore 曾有 test_*.py 规则导致测试文件入库失败——新增测试后 用 git status 确认文件真的被跟踪
  • last_active 曾用分钟精度导致会话排序不稳——时间戳一律秒精度
  • 备份还原时"只移植功能块"会漏关联改动——还原后跑全量测试对照

修改清单(改代码前自查)

  • 我知道要改哪些文件(不盲改)
  • 相关测试存在或本次新增
  • 改完跑全量 pytest
  • 提交信息含验证结果
  • git status 确认该入库的都入库了
Changes

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.

  1. 6d ago First seen · 53 lines · 810 tokens per session scan A ef298fc0a0a0

Subscribe to this mod's changes

MemOmics-Agent AGENTS.md is an instructions file published in the GitHub repository GGbond-bo/MemOmics-Agent (19 stars, last pushed 3d ago), licensed MIT. It adds 810 tokens to every session, about $0.0040 per session on Opus 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-08-30.