kankaku 0.7.1 → 0.8.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.
@@ -201,6 +201,23 @@ export interface WorkRecordMetadata {
201
201
  * (SUBAGENT-REQ-017). Never set on an `orchestrator` record.
202
202
  */
203
203
  profile?: string;
204
+ /**
205
+ * Coding agent that MEASURED this record, lowercase slug (e.g. `"pi"`).
206
+ * Who measured, not who syncs — a different process (a standalone
207
+ * `kankaku` TUI, or a session for a different agent sharing the same
208
+ * `worklog.jsonl`) may later push this record to the hub, and must never
209
+ * overwrite this identity with its own. See kankaku-hub `docs/contract.md`
210
+ * "Agent and measurement quality" and `domain/hub-entry.ts`. Optional and
211
+ * additive: `WORK_RECORD_SCHEMA` is unchanged and an older record without
212
+ * it still validates.
213
+ */
214
+ agent?: string;
215
+ /** The measuring agent's own version, when it could be determined without a hot-path cost. Never guessed — omitted rather than sent wrong. */
216
+ agentVersion?: string;
217
+ /** The integration that wrote this record, lowercase slug (e.g. `"kankaku"`). Same who-measured-not-who-syncs rule as {@link agent}. */
218
+ plugin?: string;
219
+ /** This integration's own version, from its `package.json`, read once. */
220
+ pluginVersion?: string;
204
221
  }
205
222
 
206
223
  export type WorkRecord = WorkRecordCore & WorkRecordMetadata;
@@ -294,6 +311,10 @@ export function isWorkRecord(value: unknown): value is WorkRecord {
294
311
  (record["roleConfidence"] === undefined || record["roleConfidence"] === "uncertain") &&
295
312
  (record["orchestratorRef"] === undefined || isOrchestratorRef(record["orchestratorRef"])) &&
296
313
  (record["costObserved"] === undefined || record["costObserved"] === true) &&
297
- (record["profile"] === undefined || typeof record["profile"] === "string")
314
+ (record["profile"] === undefined || typeof record["profile"] === "string") &&
315
+ (record["agent"] === undefined || typeof record["agent"] === "string") &&
316
+ (record["agentVersion"] === undefined || typeof record["agentVersion"] === "string") &&
317
+ (record["plugin"] === undefined || typeof record["plugin"] === "string") &&
318
+ (record["pluginVersion"] === undefined || typeof record["pluginVersion"] === "string")
298
319
  );
299
320
  }
package/src/hub/index.ts CHANGED
@@ -7,7 +7,9 @@
7
7
  * for which ones and why.
8
8
  */
9
9
  export * from "../adapters/cached-catalog.ts";
10
+ export * from "../adapters/export-writer.ts";
10
11
  export * from "../adapters/file-modes.ts";
12
+ export * from "../adapters/hub-actions.ts";
11
13
  export * from "../adapters/hub-credentials.ts";
12
14
  export * from "../adapters/jsonl-work-log.ts";
13
15
  export * from "../adapters/kankaku-dir.ts";
@@ -15,5 +17,9 @@ export * from "../adapters/lazy-jsonl-work-log.ts";
15
17
  export * from "../adapters/pocketbase-catalog.ts";
16
18
  export * from "../adapters/pocketbase-client.ts";
17
19
  export * from "../adapters/pocketbase-sink.ts";
20
+ export * from "../adapters/project-config.ts";
21
+ export * from "../adapters/report-data.ts";
22
+ export * from "../adapters/report.ts";
23
+ export * from "../adapters/report-views.ts";
18
24
  export * from "../adapters/sync-runner.ts";
19
25
  export * from "../adapters/sync-state-store.ts";