AGENT SKILL

m-flow

Operate M-flow memory, graph-routed retrieval, ingestion pipelines, service integrations, MCP, and storage backends for the mflow-ai package.

License 许可
Apache-2.0
最近更新
2026-09-03
Stars
★ 351
Forks
27

01 前言 Front Matter

name
m-flow
license
Apache 2.0
metadata
{ "disco-role": "operating" }
description
Operate M-flow memory, graph-routed retrieval, ingestion pipelines, service integrations, MCP, and storage backends for the mflow-ai package.
disable-model-invocation
true

02 资源文件 5

03 SKILL.md 正文

M-flow

Use this repo skill when a task involves M-flow / mflow-ai: persistent memory for agents, graph-routed RAG, episodic/procedural memory, the m_flow Python package, the mflow CLI, the FastAPI service, web UI, MCP server, or storage backend configuration.

Fast orientation

M-flow stores knowledge as layered memory, then retrieves by graph-routed Bundle Search. The common in-process workflow is:

  1. await m_flow.add(...) or await m_flow.ingest(...) to register data.
  2. await m_flow.memorize(...) to build Episode / Facet / FacetPoint / Entity graph memory.
  3. await m_flow.query(...) or await m_flow.search(...) to retrieve context or an LLM-written answer.

Install the public package with pip install mflow-ai, or install a checkout with pip install -e .. Python 3.10-3.13 is supported by project metadata; use Python 3.11 when choosing a conservative inspection/development runtime.

Minimal checks:

python -c "import m_flow; print(m_flow.__version__)"
mflow --help
python scripts/check_mflow_env.py

Route by task

If the user asks about... Read
Python APIs, CLI commands, add/memorize/query/ingest, datasets, manual graph insertion, delete/update/prune, config facade sub-skills/core-memory-api/SKILL.md
Input formats, loader selection, preferred_loaders, chunking, content_type, content routing, procedural learning, custom pipelines sub-skills/ingestion-pipelines/SKILL.md
Recall modes, SearchConfig, episodic Bundle Search, graph/vector/relational/cache backend tuning, empty/noisy results, Cypher sub-skills/retrieval-graph-search/SKILL.md
FastAPI, web UI, Docker Compose, auth, settings, MCP, cloud sync, workers, face-aware playground, service status sub-skills/service-integrations/SKILL.md
Cross-cutting environment variables, optional extras, credential/service prerequisites references/configuration.md
Install/import, credentials, DB locks, optional dependency, logging, or safe-operation recovery references/troubleshooting.md
Staleness and source snapshot checks references/repo-provenance.md

Operating guardrails

  • M-flow API calls are mostly asynchronous; wrap examples in asyncio.run() or use an existing event loop.
  • TRIPLET_COMPLETION and graph construction need LLM/embedding credentials; EPISODIC, PROCEDURAL, CHUNKS_LEXICAL, and CYPHER retrieve from data that must already be memorized.
  • Defaults are local file-backed storage: SQLite relational metadata, LanceDB vectors, and Kuzu graph storage. External services need matching extras, environment variables, and service health checks.
  • Do not run destructive operations (delete, prune, hard deletion, DB migrations, service stop/kill) without explicit user scope and confirmation.
  • Treat optional browser scraping, face recognition, cloud sync, MCP remote API mode, Modal workers, and external DB providers as optional surfaces; verify credentials/services before claiming they work.
  • Keep generated helper scripts safe by default. Use live workflow flags only when the user accepts local storage writes and credential use.

04 同仓库更多 Skills

VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-triton-opt

Make a single PassNet Triton kernel fast AND numerically faithful: performance model (when a replacement can win at all), block/grid/warp tuning, autotune policy, launch overhead, and per-op numeric recipes to pass the dtype baseline tolerances. Use when a pass matches and is correct but speedup below expected, or when correctness fails by small numeric margins.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-solve

END-TO-END playbook for solving one PassNet sample: analyze the computation graphs, decide the optimization strategy (what to fuse, what to replace, what to leave alone), drive the iteration loop, and maximize the sample score. This is the ENTRY skill — invoke it first for any PassNet optimization task; it tells you when to use passnet-pattern-fusion, passnet-triton-opt and passnet-feedback.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-skill

PassNet GPU kernel optimization via compiler passes. Design and implement Triton-based optimization passes, create pass files under ./pass_dir/, self-evaluate with pass_evaluator, and iterate to maximize GPU speedup.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-pattern-fusion

Author PassNet pass files: write patterns that actually MATCH the FX graph, pick fusion regions (which ops to absorb into one Triton kernel), and structure multi-pass submissions with the mandatory shared-dispatch architecture. Use when creating or fixing pattern()/replacement_args()/replacement_func() files, when a pass "failed to match", or when deciding how to fuse multiple kernels/ops.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-orchestrate

Round/batch planning and decision support for PassNet graph optimization. Use for multi-sample triage, worker allocation, eval-budget policy, and post-eval keep/revert decisions. For solving one concrete sample end to end, use passnet-solve as the entry skill; consult this skill only when you need broader planning or a specific decision gate.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-feedback

Fast, deterministic feedback for PassNet work: pre-flight pattern/match verification WITHOUT burning a GPU evaluation, per-node bottleneck analysis of a sample's graphs, and eval-log parsing into per-variant status + estimated score + failure classification. Use BEFORE every GPU evaluation (check_pattern), at the START of a sample (analyze_graph), and AFTER every evaluation (parse_eval_log).

★ 351