@aiwayds/dsh-topics-memory
dsh-plugin: OKF v0.2 topic memory for dsh - local-first git-tracked bundle, hot-path LLM-free injection, two-stage observer with background distill
安装
$
npx -p @deepseek-ai/dsh dsh plugin --profile web add github:fan56/dsh-topics-memory说明文档
阅读完整 README ↗Configuration
First-time setup belongs to /topics onboard; day-to-day tuning is /topics set (writes the topics namespace in settings.yaml, effective from the next session). All keys and defaults:
| Key | Default | Meaning |
|---|---|---|
repo | empty (local-only) | GitHub sync repo owner/name; suggested dsh-topics-data; empty = back to local-only |
autoInject | true | Per-turn injection master switch |
injectDedup | true | Session-level injection dedup: topics already injected in this session are not re-injected (registry cleared at session end; budget-dropped topics stay injectable; deduped topK slots are NOT backfilled) — ADR 0012 |
topK | 4 | Max topics injected per turn |
perTopicBudget | 300 | Per-topic digest token budget |
totalBudget | 1500 | Total injection budget per turn |
matchThreshold | 0.3 | Hit threshold; tune from /topics stats near-miss evidence |
tagBoost | 0.15 | Additive boost per tag hit |
graphDepth | 2 | depends graph walk depth (0 disables) |
recencyWindowDays | 7 | Recency bonus window (+0.2) |
autoObserve | true | Capture atomic observations every turn |
includeSubagents | true | Whether injection and observation also engage subagent sessions (ADR 0011); off skips them entirely |
observationMaxChars | 2000 | Per-side per-turn observation truncation |
distillProvider / distillModel | empty (distill off) | Distill lane model route; both must be set to enable. With a UI, /topics set distill-provider / distill-model without a value opens a picker panel (provider list → that provider's model catalog); a mixed provider model / provider/model value for distill-model splits into both keys |
distillEveryTurns | 5 | Distill every N turns of a long session |
distillOnSessionEnd | true | Distill once when a session ends |
distillBatchSize | 40 | Observations per distill model call. On an output-limit (max-tokens) failure the batch halves automatically (floor 5) and retries — a failing batch can no longer livelock the backlog; the shrink persists until reload or a config change. Note: /topics set distillBatchSize back to the same value does not reset the shrink — set a different value or reload the plugin |
distillMaxModelCalls | 8 | Max model calls per distill run, including the one corrective retry for ops echoing no valid observed_ids (the run stalls when the budget can't fit it). Batches already distilled keep their marks when the budget stops the run (partial progress), recorded as partial: … in the distill state |
pushDebounceSeconds | 45 | GitHub-mode debounced push interval |