nuwa-skill
alchaincyf
你想蒸馏的下一个员工,何必是同事。蒸馏任何人的思维方式——心智模型、决策启发式、表达DNA。Distill how anyone thinks.
PROJECT TOPICS
INSTALL REFERENCE
dsh plugin --profile web add github:cybtachyon/dsh-plugin-obsidian-mem
该命令指向仓库当前默认分支;尚无绑定当前 commit 的完整验证结果。
PROJECT README
Shared agent memory for DeepSeek Harness, built on plain Markdown vaults.
Obsidian Mem turns your Obsidian-style vaults into a frictionless, human-editable working wiki that every agent session can read from and write to.
OM adds Retrieval-Augmented Generation (RAG) Recall with vector search powered by a Milvus-Lite DB.
Open, edit, and sync your notes with a Markdown setup like Obsidian + Git, then watch your agents learn from shared experiences.
Command line:
# Latest NPM package.
dsh plugin --profile web add dsh-plugin-obsidian-mem
# From source.
dsh plugin --profile web add https://github.com/cybtachyon/dsh-plugin-obsidian-mem
When installing from a local checkout, run pnpm build first: it type-checks the workspace (tsc -b) and then produces the dsh/client.js browser card artifact with esbuild (node scripts/build-client.mjs).
Web UI: click Plugins → Add Plugin → paste dsh-plugin-obsidian-mem.
Or add from the DSH Plugin Marketplace.
memory_read: open a memory note from a vault by path.memory_search: hybrid vector + keyword recall across your vaults.memory_write: save a memory note (shared vaults only).memory_audit: report vault size, index state, git churn, and
over-budget warnings; its checkpoint view is the end-of-work pass.memory_dream: run the split-compaction pass that merges and prunes notes.$HOME/.dsh/obsidian-mem/!The agent-facing end-of-work pass is the completion checkpoint: run
memory_audit with view: "checkpoint" to get the full note rows plus
the completion-checkpoint instructions, the pass where the agent promotes
what the session settled and retires what was transient. The turn-end
save/audit reminder that used to fire at the end of every agent turn was
removed; the internal memory-tool usage watch is all that stays at turn
end.
Dreaming runs in isolation. While a memory_dream run is in flight, the
dream agent session and every session in its subagent lineage receive no
memory recall injections, and the launching session receives none for
the window of the run. The dream agent session carries no deployment
system prompt and no session runtime context: its whole session context
is the dreaming protocol in the editable dream-prompt.md (seeded once
at $HOME/.dsh/obsidian-mem-db/dream-prompt.md) plus the work plan in
the launch message. Other sessions are unaffected, and the launching
session's recall resumes the moment the run closes.
Out of the many, many out there (and I looked at as many as I could), none of them:
I wanted to share project notes with my agents and have maintained results be the cumulative effort of human and automated knowledge organization.
All *.md files are indexed, except: dot directories and dot files are
never indexed, and these vault-root paths are reserved for the plugin:
| Vault Path | Description |
|---|---|
<vault>/.<slug>_history.md |
Note history retired by dreaming; reserved suffix. |
<vault>/.INTENTS.md |
Agent intents file describing phrases that lead to memories. |
<vault>/.obsidian-mem/metadata/ |
Indexer state file and the DREAMS.md dream diary. |
| Plugin Path | Description |
|---|---|
$HOME/.dsh/obsidian-mem/ |
The default shared vault (created if none are already added). |
$HOME/.dsh/obsidian-mem-db/ |
The memory search Milvus-Lite database (rebuildable on-demand; safe to delete). |
$HOME/.dsh/obsidian-mem-db/models/ |
The memory search ONNX model cache. |
$HOME/.dsh/obsidian-mem-db/state/ |
Plugin state: card settings overrides (settings.json), the vault registry (vaults.json), and session state. Stays here even when milvus.dbPath points elsewhere. |
Every knob below is a real config path. Set them in the plugin's config
row of your DSH profile, or edit the same keys in the "Obsidian Mem"
card's Configuration pane (below Vaults), which persists them as card
overrides in the plugin's state directory
($HOME/.dsh/obsidian-mem-db/state/settings.json; the file stays there
even when milvus.dbPath points elsewhere). Card overrides win over the
same key in the profile row; "Reset all to profile settings" clears them.
| Knob | Default | Notes |
|---|---|---|
vaults[] |
$HOME/.dsh/obsidian-mem/ |
Each vault: path, mode (shared | read-only), globalFile (vault-root relative; blank = GLOBAL.md). The card's Vaults pane and the profile row both manage the list; the default shared vault is created on first use when nothing is registered. |
vectorDim |
384 |
Full e5-small width; 128 / 192 / 256 / 320 are lossy truncations that trade recall for speed; a change forces a full re-index. |
model.id |
Xenova/multilingual-e5-small |
ONNX q8 embedder, passage: / query: prefixes; changing it re-embeds every note. |
model.cacheDir |
$HOME/.dsh/obsidian-mem-db/models |
transformers.js download cache; first use of a new directory re-downloads the model. |
milvus.dbPath |
$HOME/.dsh/obsidian-mem-db |
Milvus-Lite data directory; a change applies on the next host restart and rebuilds the search index at the new location. |
llm.enabled / llm.baseUrl / llm.model / llm.apiKeyEnv |
off | Optional OpenAI-compatible endpoint that augments the heuristic wake-keyword extraction. llm.apiKeyEnv names the environment variable holding the API key; the key value itself is never stored or logged. |
budgets.turnStartRecallTokens |
1200 |
Token budget one turn-start recall injection may spend. |
budgets.globalMemoryTokens |
1500 |
Token ceiling for all recall injected across one session, counting the global memory file. |
budgets.readSections |
2 |
Most sections a Read-tool recall may inject. |
budgets.readSectionTokens |
350 |
Token budget each injected Read-tool section may spend. |
budgets.searchTopK |
6 |
Result count memory_search returns when the call omits limit. |
budgets.thinkShotsPerTurn |
3 |
Most keyword-extraction shots one turn may spend. |
git.enabled |
true |
Card checkbox "Use Git to version shared vaults": shared vaults are git repositories and the plugin commits them (see Git versioning below). |
git.churnThresholdPercent |
50 |
Churn bar in whole percent: a note touched in more than this share of the recent commit window is a memory_dream stressor (see Git versioning below). |
git.churnWindowCommits |
8 |
How many of the most recent commits the churn share is measured over (see Git versioning below). |
Everything except milvus.dbPath applies to the running process on
Apply: budgets and the keyword LLM take effect on the next call, and a
vectorDim or model.id change starts its re-index right away.
milvus.dbPath takes effect on the next host restart; until then the
card shows a "restart to apply" chip.
The pane shows effective values, so to hand one knob back to the profile row, blank the overridden text field: blanking deletes the override key and the profile value returns. A blank number field sends nothing, and a cleared override never writes an empty string, because an empty string is the built-in default for a path knob.
While git.enabled is on, every shared vault is a git repository
(read-only vaults are never versioned). The plugin adopts each shared
vault on the main branch with one initial commit recording whatever
notes the vault already holds. From then on a successful memory_write
schedules a commit of the vault it touched after the note is confirmed,
settling in the background and serialized per vault. That commit is one
whole-tree pass, so a batch of writes arriving faster than the serial
commit lane drains shares commit entries: history granularity follows
the commit waves, and one commit per write shows up only when the lane
is idle between writes. A finished memory_dream run closes with one
commit pass over every shared vault. A git failure logs and never
unwinds a write: the memory files are the source of truth and the
history is only the book.
A managed .gitignore at the vault root keeps the plugin's
.obsidian-mem/ sidecar (indexer state, the DREAMS.md diary) out of
the history; .git itself never enters it.
Churn is read from git history: a note's churn is the share of the last
git.churnWindowCommits (default 8) commits that touched it, and a note
touched in over git.churnThresholdPercent (default 50)% of them is a
stressor under the dream agent's Step 4 rule. memory_audit reports the
per-note churn and a per-shared-vault git rollup.
A remote is optional and stays plain git you manage yourself
(git remote add origin … inside the vault); the plugin never creates
remotes or handles credentials. When a remote exists, the dream agent's
Step 0 pre-sync uses it before the run touches any memory.
The plugin manages its own vector database on-demand:
uv/uvx toolchain (auto-installing uv when absent)milvus-lite server bound to a localhost port with data under
$HOME/.dsh/obsidian-mem-db/There is no user-facing Python, Milvus install step, or external Milvus.
RAG is a Hybrid search with both dense (HNSW/COSINE) search and sparse BM25
search powered by a local ONNX model. chunk_text is stored without embed-time
prefixes and uses enable_analyzer.
The plugin downloads Xenova/multilingual-e5-small (ONNX q8, roughly 135 MB)
into $HOME/.dsh/obsidian-mem-db/models.
For an offline host, pre-seed the cache on a connected machine:
node scripts/prefetch-model.mjs
Build, test, and lint with pnpm; see AGENTS.md for the architecture and the verification commands.
pnpm test is fully offline: a second integration tier
(packages/service/tests/integration/*.live.test.ts) is collected only with
RUN_LIVE=1 pnpm test.Xenova/multilingual-e5-small model from the local
cache and drives the full provisioning → indexing → hybrid search →
confirm-then-settle write → purge pipeline.Run it with:
RUN_LIVE=1 pnpm test
CLASSIFICATION EVIDENCE
系统优先读取 GitHub Topics,再与站内分类词典和词根规则比对。当前命中: agent、memory、智能体、记忆。