@kenz1117/dsh-engram 0.8.14 → 0.8.16

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/lib/index.js CHANGED
@@ -5318,12 +5318,24 @@ function registerEngramRoutes(ctx, deps) {
5318
5318
  if (req.method === "GET" && route === "refurb") {
5319
5319
  const rawScope = url.searchParams.get("scope");
5320
5320
  const scope = rawScope === "project" ? "project" : rawScope === "shared" ? "shared" : "user";
5321
- const suggestions = gatherRefurbSuggestions((await (await storeFor(scope)).list({
5321
+ const filter = await (await storeFor(scope)).list({
5322
5322
  scope,
5323
5323
  status: "active",
5324
5324
  limit: 500,
5325
5325
  offset: 0
5326
- })).records, deps.language, DEFAULT_REFURB_OPTIONS);
5326
+ });
5327
+ const suggestions = gatherRefurbSuggestions(filter.records, deps.language, DEFAULT_REFURB_OPTIONS);
5328
+ const byId = new Map(filter.records.map((record) => [record.id, record]));
5329
+ const previewOf = (id) => {
5330
+ const record = byId.get(id);
5331
+ if (record === void 0) return null;
5332
+ return {
5333
+ id: record.id,
5334
+ kind: record.kind,
5335
+ content: record.content.length > 280 ? `${record.content.slice(0, 280)}…` : record.content,
5336
+ importance: record.importance
5337
+ };
5338
+ };
5327
5339
  json(res, 200, {
5328
5340
  scope,
5329
5341
  count: suggestions.length,
@@ -5333,7 +5345,9 @@ function registerEngramRoutes(ctx, deps) {
5333
5345
  candidates: [...suggestion.candidates],
5334
5346
  scope: suggestion.scope,
5335
5347
  reason: suggestion.reason,
5336
- confidence: suggestion.confidence
5348
+ confidence: suggestion.confidence,
5349
+ primary: previewOf(suggestion.primaryId),
5350
+ candidatePreviews: suggestion.candidates.map(previewOf).filter((p) => p !== null)
5337
5351
  }))
5338
5352
  });
5339
5353
  return;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@kenz1117/dsh-engram",
3
3
  "description": "Cross-session long-term memory for DeepSeek Harness (memory palace · AGI Architecture Exploration on dsh-market): dual-scope SQLite memory graph, hybrid retrieval, provenance audit, and a knowledge flywheel.",
4
- "version": "0.8.14",
4
+ "version": "0.8.16",
5
5
  "icon": "icon.svg",
6
6
  "logo": "icon-256.svg",
7
7
  "publishConfig": {
@@ -81,6 +81,26 @@
81
81
  "@deepseek-ai/dsh-tools": "*",
82
82
  "@deepseek-ai/schemastery": "*"
83
83
  },
84
+ "peerDependenciesMeta": {
85
+ "@deepseek-ai/cordis": {
86
+ "optional": true
87
+ },
88
+ "@deepseek-ai/dsh-agent": {
89
+ "optional": true
90
+ },
91
+ "@deepseek-ai/dsh-client-ui-layout": {
92
+ "optional": true
93
+ },
94
+ "@deepseek-ai/dsh-llm": {
95
+ "optional": true
96
+ },
97
+ "@deepseek-ai/dsh-tools": {
98
+ "optional": true
99
+ },
100
+ "@deepseek-ai/schemastery": {
101
+ "optional": true
102
+ }
103
+ },
84
104
  "dependencies": {
85
105
  "@huggingface/transformers": "^4.2.0"
86
106
  },
@@ -92,5 +112,6 @@
92
112
  "tsdown": "^0.22.14",
93
113
  "typescript": "^5.9.3",
94
114
  "vitest": "^4.1.11"
95
- }
115
+ },
116
+ "packageManager": "pnpm@10.15.0"
96
117
  }