clawmem 0.20.0 → 0.20.2

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/README.md CHANGED
@@ -85,7 +85,7 @@ Full version history is in [RELEASE_NOTES.md](RELEASE_NOTES.md). Upgrade instruc
85
85
  - [Claude Code](https://docs.anthropic.com/en/docs/claude-code) — for hooks + MCP integration
86
86
  - [OpenClaw](https://github.com/openclaw/openclaw) — for native plugin integration
87
87
  - [Hermes Agent](https://github.com/NousResearch/hermes-agent) — for `MemoryProvider` plugin integration
88
- - [bd CLI](https://github.com/dolthub/dolt) v0.58.0+ — for Beads issue tracker sync (only if using Beads)
88
+ - [bd CLI](https://github.com/gastownhall/beads) v0.58.0+ (verified through v1.1.0) — for Beads issue tracker sync (only if using Beads)
89
89
 
90
90
  ### Install from npm (recommended)
91
91
 
@@ -572,7 +572,7 @@ Registered by `clawmem setup mcp`. Available to any MCP-compatible client.
572
572
 
573
573
  | Tool | Description |
574
574
  |---|---|
575
- | `beads_sync` | Sync Beads issues from Dolt backend (`bd` CLI) into memory: creates docs, bridges all dep types to `memory_relations`, runs A-MEM enrichment |
575
+ | `beads_sync` | Sync Beads issues from Dolt backend (`bd` CLI) into memory: syncs the full backlog (no 50-issue cap), creates docs, bridges all dep types to `memory_relations`, surfaces bd ≥1.1.0 claim leases, runs A-MEM enrichment |
576
576
 
577
577
  ### Vault Management
578
578
 
@@ -280,6 +280,8 @@ Sync Beads issues from Dolt backend into the search index.
280
280
  |-------|------|---------|-------------|
281
281
  | `project_path` | string | cwd | Path to project with `.beads/` directory |
282
282
 
283
+ Runs `bd list --json --limit 0` — the full backlog, not bd's default 50-issue page (v0.20.1). The spawned call disables bd usage metrics (`BD_DISABLE_METRICS=1`, ignored by pre-1.1.0 binaries). Issues carrying bd ≥1.1.0 claim-lease fields render a `**Claim Lease**` line in the indexed document (v0.20.1); upstream's removed `quality_score` field is no longer parsed.
284
+
283
285
  ## Vault management
284
286
 
285
287
  ### list_vaults
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "clawmem",
3
- "version": "0.20.0",
3
+ "version": "0.20.2",
4
4
  "description": "On-device memory layer for AI agents. Claude Code, OpenClaw, and Hermes. Hooks + MCP server + hybrid RAG search.",
5
5
  "type": "module",
6
6
  "bin": {
package/src/beads.ts CHANGED
@@ -9,7 +9,7 @@
9
9
 
10
10
  import { existsSync } from "node:fs";
11
11
  import { join } from "node:path";
12
- import { execSync } from "node:child_process";
12
+ import { execFileSync, execSync } from "node:child_process";
13
13
 
14
14
  // =============================================================================
15
15
  // Types (matches bd list --json output: IssueWithCounts)
@@ -43,7 +43,8 @@ export interface BeadsIssue {
43
43
  metadata?: Record<string, unknown>;
44
44
  labels?: string[];
45
45
  dependencies?: BeadsDependency[];
46
- quality_score?: number;
46
+ lease_expires_at?: string;
47
+ heartbeat_at?: string;
47
48
  // Computed counts from bd list --json
48
49
  dependency_count?: number;
49
50
  dependent_count?: number;
@@ -92,11 +93,13 @@ function runBd(projectDir: string, args: string[], timeoutMs = 10000): string |
92
93
  }
93
94
 
94
95
  try {
95
- return execSync(`${bd} ${args.join(" ")}`, {
96
+ return execFileSync(bd, args, {
96
97
  cwd: projectDir,
97
98
  encoding: "utf-8",
98
99
  timeout: timeoutMs,
99
- env: { ...process.env },
100
+ // No shell interpolation of args; bd usage metrics + event flush stay off
101
+ // (default-on with a remote endpoint as of bd 1.1.0).
102
+ env: { ...process.env, BD_DISABLE_METRICS: "1", BD_DISABLE_EVENT_FLUSH: "1" },
100
103
  stdio: ["pipe", "pipe", "pipe"],
101
104
  });
102
105
  } catch (err: any) {
@@ -114,7 +117,7 @@ function runBd(projectDir: string, args: string[], timeoutMs = 10000): string |
114
117
  * Returns parsed issues with labels and dependencies populated.
115
118
  */
116
119
  export function queryBeadsList(projectDir: string): BeadsIssue[] {
117
- const output = runBd(projectDir, ["list", "--json"]);
120
+ const output = runBd(projectDir, ["list", "--json", "--limit", "0"]);
118
121
  if (!output) return [];
119
122
 
120
123
  try {
@@ -158,7 +161,8 @@ function normalizeBeadsIssue(raw: any): BeadsIssue {
158
161
  metadata: raw.metadata,
159
162
  labels: raw.labels || [],
160
163
  dependencies: deps,
161
- quality_score: raw.quality_score,
164
+ lease_expires_at: raw.lease_expires_at,
165
+ heartbeat_at: raw.heartbeat_at,
162
166
  dependency_count: raw.dependency_count,
163
167
  dependent_count: raw.dependent_count,
164
168
  comment_count: raw.comment_count,
@@ -213,7 +217,7 @@ export function formatBeadsIssueAsMarkdown(issue: BeadsIssue): string {
213
217
  }
214
218
  if (issue.blocks && issue.blocks.length > 0) lines.push(`**Blocks**: ${issue.blocks.join(", ")}`);
215
219
  if (issue.external_ref) lines.push(`**External Ref**: ${issue.external_ref}`);
216
- if (issue.quality_score != null) lines.push(`**Quality Score**: ${issue.quality_score}`);
220
+ if (issue.lease_expires_at) lines.push(`**Claim Lease**: expires ${issue.lease_expires_at}`);
217
221
 
218
222
  if (issue.description) {
219
223
  lines.push("", "## Description", "", issue.description);