@vaur94/agz-memory 0.5.0 → 0.5.1

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.
@@ -0,0 +1,15 @@
1
+ import type { Database } from "bun:sqlite";
2
+ /** Content-free input for a future V12 quarantine migration decision. */
3
+ export declare function quarantinePrivacyReport(db: Database): {
4
+ quarantinedEvents: number;
5
+ keyedEvents: number;
6
+ unavailableKeyEvents: number;
7
+ legacyOrUnknownEvents: number;
8
+ keyIDs: string[];
9
+ digest: {
10
+ algorithm: "HMAC-SHA256";
11
+ input: "quarantine-source-identity-and-redacted-payload/2";
12
+ storage: "capture_events.payload_hash";
13
+ keyID: "capture_events.redaction_version quarantine-key suffix";
14
+ };
15
+ };
@@ -0,0 +1,41 @@
1
+ export interface ProcessStartMarkerReaders {
2
+ readLinuxStat?: (pid: number) => string | null;
3
+ readMacOSPs?: (pid: number) => string | null;
4
+ }
5
+ export interface ReindexTestOptions {
6
+ /** Test-only fault point after a durable batch commit but before its cursor is saved. */
7
+ afterCommitBeforeStateWrite?: () => void;
8
+ /** Test-only fault point immediately before the batch's database identity verification. */
9
+ beforeBatchDatabaseIdentity?: () => void;
10
+ /** Test-only synchronization point after a stale lock is classified but before takeover. */
11
+ beforeStaleLockTakeover?: () => void;
12
+ /** Test-only synchronization point while the owner lock is held. */
13
+ afterOwnerLockAcquired?: () => void;
14
+ }
15
+ export interface ReindexOwnerMetadata {
16
+ ownerID: string;
17
+ pid: number;
18
+ processStart: string;
19
+ hostname: string;
20
+ createdAt: number;
21
+ }
22
+ export declare function classifyReindexOwner(owner: unknown, localHostname: string, processAlive: boolean, currentProcessStart: string | null): "live" | "stale" | "unverifiable";
23
+ export declare function runResumableReindex(path: string, databaseID: string, backend: string, batchSize: number, maxBatches?: number, testOptions?: ReindexTestOptions): {
24
+ backend: string;
25
+ generation: number;
26
+ purges: number;
27
+ queued: number;
28
+ quarantined: number;
29
+ resumed: boolean;
30
+ incomplete?: undefined;
31
+ } | {
32
+ backend: string;
33
+ generation: number;
34
+ purges: number;
35
+ queued: number;
36
+ quarantined: number;
37
+ incomplete: boolean;
38
+ resumed: boolean;
39
+ };
40
+ export declare function readReindexProcessStartMarker(pid: number, platform?: NodeJS.Platform, readers?: ProcessStartMarkerReaders): string | null;
41
+ export declare function assertReindexOwnerLivenessSupported(platform?: NodeJS.Platform): void;
@@ -1,4 +1,5 @@
1
1
  export interface MemoryConfig {
2
2
  databasePath: string;
3
+ quarantineKeyringPath: string;
3
4
  }
4
5
  export declare function resolveConfig(environment?: NodeJS.ProcessEnv): MemoryConfig;
@@ -0,0 +1,16 @@
1
+ export type BusinessErrorCode = "invalid_request" | "not_found" | "conflict" | "limit_exceeded" | "invalid_cursor" | "cursor_scope_mismatch" | "stale_cursor" | "internal_error";
2
+ export declare class MemoryBusinessError extends Error {
3
+ readonly code: BusinessErrorCode;
4
+ readonly correlationID: string;
5
+ readonly cause?: unknown;
6
+ constructor(code: BusinessErrorCode, message: string, correlationID?: string, cause?: unknown);
7
+ }
8
+ export declare function correlationID(): string;
9
+ export declare function businessError(code: BusinessErrorCode, message: string, id?: string, cause?: unknown): MemoryBusinessError;
10
+ export declare function toPublicError(error: MemoryBusinessError): {
11
+ code: BusinessErrorCode;
12
+ correlationID: string;
13
+ retryable: boolean;
14
+ message: string;
15
+ };
16
+ export declare function asBusinessError(error: unknown, id?: string): MemoryBusinessError;
@@ -0,0 +1,18 @@
1
+ import * as z from "zod/v4";
2
+ /** Public payload limits, measured in UTF-8 bytes unless otherwise noted. */
3
+ export declare const LIMITS: {
4
+ readonly title: 240;
5
+ readonly summary: 4096;
6
+ readonly content: 65536;
7
+ readonly query: 4096;
8
+ readonly noteID: 256;
9
+ readonly batch: 10;
10
+ readonly requestBytes: 1048576;
11
+ readonly responseBytes: 1048576;
12
+ readonly pageSize: 100;
13
+ };
14
+ export type TextLimit = "title" | "summary" | "content" | "query" | "noteID";
15
+ export declare function utf8Bytes(value: string): number;
16
+ export declare function assertTextLimit(field: TextLimit, value: string): void;
17
+ export declare function boundedText(field: TextLimit, description: string): z.ZodString;
18
+ export declare function assertRequestLimit(value: unknown): void;
@@ -0,0 +1,31 @@
1
+ import { type Kind } from "../types";
2
+ export interface CreateMutation {
3
+ operation: "create";
4
+ kind: Kind;
5
+ title: string;
6
+ summary: string;
7
+ content?: string;
8
+ }
9
+ export interface PatchMutation {
10
+ operation: "patch";
11
+ id: string;
12
+ changes: Partial<Pick<CreateMutation, "kind" | "title" | "summary" | "content">>;
13
+ }
14
+ export interface DeleteMutation {
15
+ operation: "delete";
16
+ id: string;
17
+ confirmation?: string;
18
+ }
19
+ export type MutationOperation = CreateMutation | PatchMutation | DeleteMutation;
20
+ export interface LegacyMutation {
21
+ id?: string;
22
+ kind?: string;
23
+ title?: string;
24
+ summary?: string;
25
+ content?: string;
26
+ delete?: boolean;
27
+ confirmation?: string;
28
+ }
29
+ export declare function normalizeLegacyMutation(input: LegacyMutation): MutationOperation;
30
+ export declare function isMutationOperation(value: unknown): value is MutationOperation;
31
+ export declare function assertStrictMutationOperation(value: unknown): asserts value is MutationOperation;
@@ -0,0 +1,27 @@
1
+ export interface CursorScope {
2
+ projectID: string;
3
+ query: string;
4
+ snapshot: string;
5
+ }
6
+ interface CursorPayload extends CursorScope {
7
+ v: 1;
8
+ offset: number;
9
+ }
10
+ export interface PageOptions extends CursorScope {
11
+ limit: number;
12
+ cursor?: string;
13
+ /** Snapshot returned by the client on a follow-up request. */
14
+ requestedSnapshot?: string;
15
+ }
16
+ export interface Page<T> {
17
+ items: T[];
18
+ snapshot: string;
19
+ etag: string;
20
+ nextCursor?: string;
21
+ }
22
+ export declare function encodeCursor(payload: Omit<CursorPayload, "v">): string;
23
+ export declare function decodeCursor(cursor: string, scope: CursorScope): {
24
+ offset: number;
25
+ };
26
+ export declare function paginate<T>(items: readonly T[], options: PageOptions): Page<T>;
27
+ export {};
@@ -27,5 +27,9 @@ export * from "./capture/redact";
27
27
  export * from "./retrieval/contract";
28
28
  export * from "./retrieval/formatter";
29
29
  export * from "./store/capture";
30
+ export * from "./contracts/limits";
31
+ export * from "./contracts/mutation";
32
+ export * from "./contracts/error";
33
+ export * from "./contracts/pagination";
30
34
  export * from "./types";
31
35
  export * from "./version";
@@ -6,7 +6,9 @@ export interface DatabaseHealth {
6
6
  counts: Record<string, number>;
7
7
  }
8
8
  export declare function inspectDatabase(db: Database): DatabaseHealth;
9
- export declare function assertHealthyDatabase(db: Database): DatabaseHealth;
9
+ export declare function assertHealthyDatabase(db: Database, options?: {
10
+ verifySchema?: boolean;
11
+ }): DatabaseHealth;
10
12
  export declare function assertSchemaV11(db: Database): void;
11
13
  export declare function isSQLiteBusyError(error: unknown): boolean;
12
14
  export declare function hasTable(db: Database, table: string): boolean;
@@ -1,2 +1,4 @@
1
1
  import type { Database } from "bun:sqlite";
2
- export declare function assertLegacySchemaIdentity(db: Database, version: number): void;
2
+ export declare function assertLegacySchemaIdentity(db: Database, version: number, options?: {
3
+ verifyHealth?: boolean;
4
+ }): void;
@@ -3,5 +3,15 @@ export interface OpenedDB {
3
3
  db: Database;
4
4
  close: () => void;
5
5
  }
6
- export declare function openMemoryDatabase(path: string): OpenedDB;
6
+ export type MigrationStage = "source-validation" | "backup-checkpoint" | "v2-import" | "v8-to-v9" | "v9-to-v10" | "v10-to-v11" | "fingerprint" | "deep-health";
7
+ export interface MigrationTiming {
8
+ phases: Array<{
9
+ stage: MigrationStage;
10
+ elapsedMs: number;
11
+ }>;
12
+ }
13
+ export declare function createMigrationTimingCollector(): MigrationTiming;
14
+ export declare function openMemoryDatabase(path: string, options?: {
15
+ timing?: MigrationTiming;
16
+ }): OpenedDB;
7
17
  export declare function openReadOnlyMemoryDatabase(path: string): OpenedDB;
@@ -0,0 +1,47 @@
1
+ export interface QuarantineSourceIdentity {
2
+ schema: string;
3
+ projectID: string;
4
+ bindingKey: string;
5
+ kind: string;
6
+ source: {
7
+ system: string;
8
+ opencodeVersion: string;
9
+ pluginVersion: string;
10
+ sessionID: string;
11
+ messageID?: string;
12
+ ordinal?: number;
13
+ toolCallID?: string;
14
+ };
15
+ }
16
+ export interface QuarantineDigest {
17
+ keyID: string;
18
+ digest: string;
19
+ }
20
+ export interface QuarantineKeyReference {
21
+ keyID: string;
22
+ }
23
+ /**
24
+ * Private local keyring for source-only quarantine digests. Windows is deliberately
25
+ * fail-closed until a current-user ACL verifier is available.
26
+ */
27
+ export declare class QuarantineKeyring {
28
+ private readonly path;
29
+ constructor(path: string);
30
+ readActiveKey(): QuarantineKeyReference;
31
+ ensureActiveKey(): QuarantineKeyReference;
32
+ rotate(): QuarantineKeyReference;
33
+ digestSource(source: QuarantineSourceIdentity, payloadFingerprint: string): QuarantineDigest;
34
+ /** Use after lifecycle initialization; a later missing key must fail closed. */
35
+ digestExistingSource(source: QuarantineSourceIdentity, payloadFingerprint: string): QuarantineDigest;
36
+ verifySourceDigest(source: QuarantineSourceIdentity, payloadFingerprint: string, keyID: string, digest: string): boolean;
37
+ private activeKey;
38
+ private keyReference;
39
+ private createInitialKeyring;
40
+ private readDocument;
41
+ private writeAtomically;
42
+ private acquireLock;
43
+ private assertSafeParent;
44
+ private assertSupportedPlatform;
45
+ private assertPermissions;
46
+ private syncParent;
47
+ }
@@ -1,5 +1,5 @@
1
1
  import { McpServer } from "@modelcontextprotocol/server";
2
2
  import type { MemoryStore } from "./store";
3
3
  export declare const SERVER_NAME = "agz-memory";
4
- export declare const SERVER_VERSION: "0.5.0";
4
+ export declare const SERVER_VERSION: "0.5.1";
5
5
  export declare function createMemoryServer(store: MemoryStore): McpServer;
@@ -1,4 +1,5 @@
1
1
  import type { Database } from "bun:sqlite";
2
+ import { QuarantineKeyring } from "../security/quarantine-key";
2
3
  export interface ProjectBindingInput {
3
4
  memoryProjectID: string;
4
5
  opencodeProjectID: string;
@@ -16,7 +17,10 @@ export interface CaptureIngestResult {
16
17
  export declare class CaptureStore {
17
18
  private db;
18
19
  private indexBackends;
19
- constructor(db: Database, indexBackends?: readonly string[]);
20
+ private readonly quarantineKeyring;
21
+ constructor(db: Database, indexBackends?: readonly string[], options?: {
22
+ quarantineKeyring?: QuarantineKeyring;
23
+ });
20
24
  bindProject(input: ProjectBindingInput): {
21
25
  ok: true;
22
26
  bindingKey: string;
@@ -1,5 +1,9 @@
1
1
  import type { Database } from "bun:sqlite";
2
2
  import type { OutboxBackend } from "../retrieval/contract";
3
+ interface OutboxRetentionOptions {
4
+ terminalRetention?: number;
5
+ terminalPruneInterval?: number;
6
+ }
3
7
  export type OutboxOutcome = "idle" | "succeeded" | "stale" | "quarantined" | "retry" | "dead" | "lost_lease";
4
8
  export declare class OutboxWorker {
5
9
  private db;
@@ -7,11 +11,16 @@ export declare class OutboxWorker {
7
11
  private now;
8
12
  private random;
9
13
  private readonly workerID;
10
- constructor(db: Database, backends: ReadonlyMap<string, OutboxBackend>, now?: () => number, random?: () => number);
14
+ private readonly terminalRetention;
15
+ private readonly terminalPruneInterval;
16
+ private terminalTransitions;
17
+ constructor(db: Database, backends: ReadonlyMap<string, OutboxBackend>, now?: () => number, random?: () => number, retention?: OutboxRetentionOptions);
11
18
  processNext(): Promise<OutboxOutcome>;
12
19
  private claim;
13
20
  private runBackend;
14
21
  private stale;
15
22
  private succeed;
16
23
  private fail;
24
+ private pruneTerminalOutbox;
17
25
  }
26
+ export {};
@@ -1,17 +1,10 @@
1
1
  import type { Database } from "bun:sqlite";
2
+ import { type MutationOperation } from "./contracts/mutation";
2
3
  import type { Edge, Note, Project, ProjectSummary, RecallCard } from "./types";
3
4
  export interface ProjectSelector {
4
5
  projectID?: string;
5
6
  projectName?: string;
6
7
  }
7
- export interface UpdateInput {
8
- kind?: string;
9
- title?: string;
10
- summary?: string;
11
- content?: string;
12
- id?: string;
13
- delete?: boolean;
14
- }
15
8
  export interface UpdateResult {
16
9
  ok: boolean;
17
10
  id?: string;
@@ -31,6 +24,7 @@ export declare class MemoryStore {
31
24
  reason?: string;
32
25
  };
33
26
  listProjects(): ProjectSummary[];
27
+ listProjectsPage(limit: number, cursor?: string, snapshot?: string): import("./core").Page<ProjectSummary>;
34
28
  createProject(nameValue: string): {
35
29
  ok: boolean;
36
30
  project?: Project;
@@ -53,7 +47,7 @@ export declare class MemoryStore {
53
47
  };
54
48
  reason?: string;
55
49
  };
56
- update(projectID: string, input: UpdateInput): UpdateResult;
50
+ update(projectID: string, operation: MutationOperation): UpdateResult;
57
51
  pin(projectID: string, id: string, pinned: boolean): {
58
52
  projectID?: undefined;
59
53
  projectName?: undefined;
@@ -80,8 +74,25 @@ export declare class MemoryStore {
80
74
  read(projectID: string, id: string): {
81
75
  note?: Note;
82
76
  edges?: Edge[];
77
+ snapshot?: string;
78
+ etag?: string;
79
+ nextCursor?: string;
83
80
  reason?: string;
84
81
  };
82
+ readPage(projectID: string, id: string, limit: number, cursor?: string, snapshot?: string): {
83
+ reason: string;
84
+ } | {
85
+ items: Edge[];
86
+ snapshot: string;
87
+ etag: string;
88
+ nextCursor?: string;
89
+ reason?: undefined;
90
+ note: Note;
91
+ };
92
+ listRevisionsPage(projectID: string, noteID: string, limit: number, cursor?: string, snapshot?: string): import("./core").Page<{
93
+ revision: number;
94
+ created_at: number;
95
+ }>;
85
96
  link(projectID: string, sourceID: string, targetID: string, predicate: string): {
86
97
  projectID?: undefined;
87
98
  projectName?: undefined;
@@ -94,7 +105,14 @@ export declare class MemoryStore {
94
105
  projectName: string;
95
106
  };
96
107
  recall(projectID: string, query: string, limit?: number): RecallCard[];
108
+ recallPage(projectID: string, query: string, limit?: number, cursor?: string, snapshot?: string): {
109
+ cards: RecallCard[];
110
+ snapshot: string;
111
+ etag: string;
112
+ nextCursor?: string | undefined;
113
+ };
97
114
  private getProjectRow;
115
+ private bumpProjectVersion;
98
116
  private getProjectByNormalizedName;
99
117
  private projectNameExists;
100
118
  private getNoteRow;
@@ -1 +1 @@
1
- export declare const PRODUCT_VERSION: "0.5.0";
1
+ export declare const PRODUCT_VERSION: "0.5.1";
@@ -2,7 +2,7 @@
2
2
 
3
3
  English | [Türkçe](backup-restore-runbook.tr.md)
4
4
 
5
- This runbook applies to `@vaur94/agz-memory@0.5.0` and SQLite schema v11.
5
+ This runbook applies to `@vaur94/agz-memory@0.5.1` and SQLite schema v11.
6
6
 
7
7
  ## Preconditions
8
8
 
@@ -25,16 +25,16 @@ Do not proceed with a guessed or empty path.
25
25
  Run a read-only health report first:
26
26
 
27
27
  ```sh
28
- bunx --package @vaur94/agz-memory@0.5.0 agz-memory-admin doctor
28
+ bunx --package @vaur94/agz-memory@0.5.1 agz-memory-admin doctor
29
29
  ```
30
30
 
31
31
  `ok` must be `true`. Record `schemaVersion`, row counts, and invariant counts.
32
32
  Then create a standalone verified backup and upgrade:
33
33
 
34
34
  ```sh
35
- bunx --package @vaur94/agz-memory@0.5.0 agz-memory-admin backup
36
- bunx --package @vaur94/agz-memory@0.5.0 agz-memory-admin upgrade --to 11
37
- bunx --package @vaur94/agz-memory@0.5.0 agz-memory-admin doctor
35
+ bunx --package @vaur94/agz-memory@0.5.1 agz-memory-admin backup
36
+ bunx --package @vaur94/agz-memory@0.5.1 agz-memory-admin upgrade --to 11
37
+ bunx --package @vaur94/agz-memory@0.5.1 agz-memory-admin doctor
38
38
  ```
39
39
 
40
40
  The upgrade itself creates another verified pre-migration backup when the
@@ -54,16 +54,16 @@ The manifest format is `agz-memory-backup/1`. `agz-memory-admin restore` verifie
54
54
  that the manifest and database are regular files in the same backup directory,
55
55
  then checks size, SHA-256, SQLite integrity, foreign keys, and row counts.
56
56
 
57
- Final `0.5.0` does not accept prerelease manifest formats. Use the originating
57
+ Final `0.5.1` does not accept prerelease manifest formats. Use the originating
58
58
  prerelease to restore such a backup, run its doctor check, and only then upgrade
59
- that restored database with `0.5.0`.
59
+ that restored database with `0.5.1`.
60
60
 
61
61
  ## Restore Rehearsal
62
62
 
63
63
  Keep all writers stopped. First request a dry run by omitting confirmation:
64
64
 
65
65
  ```sh
66
- bunx --package @vaur94/agz-memory@0.5.0 agz-memory-admin restore \
66
+ bunx --package @vaur94/agz-memory@0.5.1 agz-memory-admin restore \
67
67
  "$OPENCODE_MEMORY_DATABASE_PATH.backup/<backup>.manifest.json"
68
68
  ```
69
69
 
@@ -71,7 +71,7 @@ Compare `targetPath`, `sourceSchema`, `targetSchema`, row counts, size, and
71
71
  SHA-256 with the recorded backup. Then use the exact manifest hash:
72
72
 
73
73
  ```sh
74
- bunx --package @vaur94/agz-memory@0.5.0 agz-memory-admin restore \
74
+ bunx --package @vaur94/agz-memory@0.5.1 agz-memory-admin restore \
75
75
  "$OPENCODE_MEMORY_DATABASE_PATH.backup/<backup>.manifest.json" \
76
76
  --sha256 <manifest-database-sha256> \
77
77
  --confirm RESTORE_DATABASE_FROM_VERIFIED_BACKUP
@@ -84,9 +84,9 @@ database passes all checks.
84
84
  ## Post-Restore Validation
85
85
 
86
86
  ```sh
87
- bunx --package @vaur94/agz-memory@0.5.0 agz-memory-admin doctor
88
- bunx --package @vaur94/agz-memory@0.5.0 agz-memory-admin capture status
89
- bunx --package @vaur94/agz-memory@0.5.0 agz-memory-admin outbox status
87
+ bunx --package @vaur94/agz-memory@0.5.1 agz-memory-admin doctor
88
+ bunx --package @vaur94/agz-memory@0.5.1 agz-memory-admin capture status
89
+ bunx --package @vaur94/agz-memory@0.5.1 agz-memory-admin outbox status
90
90
  ```
91
91
 
92
92
  Start only the MCP server and perform read-only `project_list`, `memory_recall`,
@@ -103,7 +103,7 @@ gate, and restore artifacts, then select a verified backup. Supply the exact
103
103
  recorded owner ID only on the restoring command:
104
104
 
105
105
  ```sh
106
- bunx --package @vaur94/agz-memory@0.5.0 agz-memory-admin restore <manifest> \
106
+ bunx --package @vaur94/agz-memory@0.5.1 agz-memory-admin restore <manifest> \
107
107
  --sha256 <manifest-sha256> \
108
108
  --confirm RESTORE_DATABASE_FROM_VERIFIED_BACKUP \
109
109
  --maintenance-owner <owner-id> \
@@ -124,7 +124,7 @@ style error first if uncertain. Break only a proven stale lock with the exact
124
124
  owner ID and confirmation:
125
125
 
126
126
  ```sh
127
- bunx --package @vaur94/agz-memory@0.5.0 agz-memory-admin unlock \
127
+ bunx --package @vaur94/agz-memory@0.5.1 agz-memory-admin unlock \
128
128
  --owner <owner-id> \
129
129
  --confirm BREAK_STALE_MIGRATION_LOCK
130
130
  ```
@@ -138,13 +138,13 @@ The first command is non-destructive and returns a digest over the exact backup
138
138
  set:
139
139
 
140
140
  ```sh
141
- bunx --package @vaur94/agz-memory@0.5.0 agz-memory-admin backup prune
141
+ bunx --package @vaur94/agz-memory@0.5.1 agz-memory-admin backup prune
142
142
  ```
143
143
 
144
144
  Review every listed manifest/database pair. Delete only that unchanged set:
145
145
 
146
146
  ```sh
147
- bunx --package @vaur94/agz-memory@0.5.0 agz-memory-admin backup prune \
147
+ bunx --package @vaur94/agz-memory@0.5.1 agz-memory-admin backup prune \
148
148
  --digest <dry-run-digest> \
149
149
  --confirm DELETE_VERIFIED_BACKUPS
150
150
  ```
@@ -2,7 +2,7 @@
2
2
 
3
3
  [English](backup-restore-runbook.md) | Türkçe
4
4
 
5
- Bu runbook `@vaur94/agz-memory@0.5.0` ve SQLite schema v11 için geçerlidir.
5
+ Bu runbook `@vaur94/agz-memory@0.5.1` ve SQLite schema v11 için geçerlidir.
6
6
 
7
7
  ## Ön Koşullar
8
8
 
@@ -25,16 +25,16 @@ Tahmin edilmiş veya boş bir yolla devam etmeyin.
25
25
  Önce salt-okunur sağlık raporu alın:
26
26
 
27
27
  ```sh
28
- bunx --package @vaur94/agz-memory@0.5.0 agz-memory-admin doctor
28
+ bunx --package @vaur94/agz-memory@0.5.1 agz-memory-admin doctor
29
29
  ```
30
30
 
31
31
  `ok` değeri `true` olmalıdır. `schemaVersion`, satır sayıları ve değişmez kural
32
32
  sayılarını kaydedin. Sonra bağımsız doğrulanmış yedek oluşturup yükseltin:
33
33
 
34
34
  ```sh
35
- bunx --package @vaur94/agz-memory@0.5.0 agz-memory-admin backup
36
- bunx --package @vaur94/agz-memory@0.5.0 agz-memory-admin upgrade --to 11
37
- bunx --package @vaur94/agz-memory@0.5.0 agz-memory-admin doctor
35
+ bunx --package @vaur94/agz-memory@0.5.1 agz-memory-admin backup
36
+ bunx --package @vaur94/agz-memory@0.5.1 agz-memory-admin upgrade --to 11
37
+ bunx --package @vaur94/agz-memory@0.5.1 agz-memory-admin doctor
38
38
  ```
39
39
 
40
40
  Veritabanı v11'den eskiyse yükseltme ayrıca değişiklikten önce doğrulanmış yedek
@@ -54,16 +54,16 @@ Manifest formatı `agz-memory-backup/1` olur. `agz-memory-admin restore`, manife
54
54
  ile veritabanının aynı yedek dizinindeki normal dosyalar olduğunu doğrular;
55
55
  ardından boyut, SHA-256, SQLite bütünlüğü, foreign key ve satır sayılarını denetler.
56
56
 
57
- Final `0.5.0` ön sürüm manifest formatlarını kabul etmez. Böyle bir yedeği onu
57
+ Final `0.5.1` ön sürüm manifest formatlarını kabul etmez. Böyle bir yedeği onu
58
58
  oluşturan ön sürümle geri yükleyin, o sürümün doctor kontrolünü çalıştırın ve
59
- yalnız bundan sonra geri yüklenen veritabanını `0.5.0` ile yükseltin.
59
+ yalnız bundan sonra geri yüklenen veritabanını `0.5.1` ile yükseltin.
60
60
 
61
61
  ## Geri Yükleme Provası
62
62
 
63
63
  Tüm yazıcıları kapalı tutun. Önce onay vermeden deneme yapın:
64
64
 
65
65
  ```sh
66
- bunx --package @vaur94/agz-memory@0.5.0 agz-memory-admin restore \
66
+ bunx --package @vaur94/agz-memory@0.5.1 agz-memory-admin restore \
67
67
  "$OPENCODE_MEMORY_DATABASE_PATH.backup/<backup>.manifest.json"
68
68
  ```
69
69
 
@@ -71,7 +71,7 @@ bunx --package @vaur94/agz-memory@0.5.0 agz-memory-admin restore \
71
71
  değerlerini kaydedilen yedekle karşılaştırın. Sonra tam manifest özetini kullanın:
72
72
 
73
73
  ```sh
74
- bunx --package @vaur94/agz-memory@0.5.0 agz-memory-admin restore \
74
+ bunx --package @vaur94/agz-memory@0.5.1 agz-memory-admin restore \
75
75
  "$OPENCODE_MEMORY_DATABASE_PATH.backup/<backup>.manifest.json" \
76
76
  --sha256 <manifest-database-sha256> \
77
77
  --confirm RESTORE_DATABASE_FROM_VERIFIED_BACKUP
@@ -84,9 +84,9 @@ veritabanı tüm kontrollerden geçmeden bunu silmeyin.
84
84
  ## Geri Yükleme Sonrası Doğrulama
85
85
 
86
86
  ```sh
87
- bunx --package @vaur94/agz-memory@0.5.0 agz-memory-admin doctor
88
- bunx --package @vaur94/agz-memory@0.5.0 agz-memory-admin capture status
89
- bunx --package @vaur94/agz-memory@0.5.0 agz-memory-admin outbox status
87
+ bunx --package @vaur94/agz-memory@0.5.1 agz-memory-admin doctor
88
+ bunx --package @vaur94/agz-memory@0.5.1 agz-memory-admin capture status
89
+ bunx --package @vaur94/agz-memory@0.5.1 agz-memory-admin outbox status
90
90
  ```
91
91
 
92
92
  Yalnız MCP sunucusunu başlatın ve salt-okunur `project_list`, `memory_recall` ve
@@ -103,7 +103,7 @@ dosyaları, kapıyı ve geri yükleme kalıntılarını koruyun; ardından doğr
103
103
  yedek seçin. Kayıtlı tam sahip kimliğini yalnız geri yükleme komutunda verin:
104
104
 
105
105
  ```sh
106
- bunx --package @vaur94/agz-memory@0.5.0 agz-memory-admin restore <manifest> \
106
+ bunx --package @vaur94/agz-memory@0.5.1 agz-memory-admin restore <manifest> \
107
107
  --sha256 <manifest-sha256> \
108
108
  --confirm RESTORE_DATABASE_FROM_VERIFIED_BACKUP \
109
109
  --maintenance-owner <owner-id> \
@@ -123,7 +123,7 @@ Sahip dosyasındaki PID, makine ve başlangıç zamanını doğrulayın. Yalnız
123
123
  kanıtlanan kilidi tam sahip ID'si ve onayla kırın:
124
124
 
125
125
  ```sh
126
- bunx --package @vaur94/agz-memory@0.5.0 agz-memory-admin unlock \
126
+ bunx --package @vaur94/agz-memory@0.5.1 agz-memory-admin unlock \
127
127
  --owner <owner-id> \
128
128
  --confirm BREAK_STALE_MIGRATION_LOCK
129
129
  ```
@@ -136,14 +136,14 @@ kanıtıdır; veritabanı doğrulamasını atlama izni değildir.
136
136
  İlk komut silme yapmaz ve tam yedek kümesinin özetini döndürür:
137
137
 
138
138
  ```sh
139
- bunx --package @vaur94/agz-memory@0.5.0 agz-memory-admin backup prune
139
+ bunx --package @vaur94/agz-memory@0.5.1 agz-memory-admin backup prune
140
140
  ```
141
141
 
142
142
  Listelenen her manifest/veritabanı çiftini inceleyin. Yalnız değişmemiş kümeyi
143
143
  silin:
144
144
 
145
145
  ```sh
146
- bunx --package @vaur94/agz-memory@0.5.0 agz-memory-admin backup prune \
146
+ bunx --package @vaur94/agz-memory@0.5.1 agz-memory-admin backup prune \
147
147
  --digest <dry-run-digest> \
148
148
  --confirm DELETE_VERIFIED_BACKUPS
149
149
  ```
@@ -1,6 +1,6 @@
1
1
  # SQLite Schema 11
2
2
 
3
- Schema 11 is the canonical storage contract for AGZ Memory 0.5.0. SQLite remains the source of truth. Search backends are derived, redacted, disposable indexes rebuilt through the durable outbox.
3
+ Schema 11 is the canonical storage contract for AGZ Memory 0.5.1. SQLite remains the source of truth. Search backends are derived, redacted, disposable indexes rebuilt through the durable outbox.
4
4
 
5
5
  ## Database Identity
6
6
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vaur94/agz-memory",
3
- "version": "0.5.0",
3
+ "version": "0.5.1",
4
4
  "description": "Project-scoped persistent linked memory MCP server for OpenCode V2",
5
5
  "type": "module",
6
6
  "main": "./dist/server.js",
@@ -35,8 +35,8 @@
35
35
  "LICENSE"
36
36
  ],
37
37
  "scripts": {
38
- "types": "rm -rf dist/types && bunx tsc -p tsconfig.build.json",
39
- "build": "rm -rf dist && bun build src/index.ts --target bun --format esm --packages external --outfile dist/server.js && bun build src/core.ts --target bun --format esm --packages external --outfile dist/core.js && bun build src/admin/index.ts --target bun --format esm --packages external --outfile dist/admin.js && bunx tsc -p tsconfig.build.json && bun run --cwd packages/opencode-plugin build",
38
+ "types": "bun scripts/clean.ts dist/types && bunx tsc -p tsconfig.build.json",
39
+ "build": "bun scripts/clean.ts && bun build src/index.ts --target bun --format esm --packages external --outfile dist/server.js && bun build src/core.ts --target bun --format esm --packages external --outfile dist/core.js && bun build src/admin/index.ts --target bun --format esm --packages external --outfile dist/admin.js && bunx tsc -p tsconfig.build.json && bun run --cwd packages/opencode-plugin build",
40
40
  "check": "bun run types && bunx tsc --noEmit && bun run --cwd packages/opencode-plugin check",
41
41
  "test": "bun scripts/run-tests.ts",
42
42
  "test:property": "bun scripts/run-tests.ts test/security/redaction-property.test.ts",
package/skills/index.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "skills": [
3
3
  {
4
4
  "name": "agz-memory",
5
- "version": "0.5.0",
5
+ "version": "0.5.1",
6
6
  "files": ["agz-memory.md"]
7
7
  }
8
8
  ]