@antiphony/shared 0.3.0 → 0.5.0

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.
Files changed (45) hide show
  1. package/README.md +4 -4
  2. package/dist/cjs/api-codecs.cjs +149 -142
  3. package/dist/cjs/api-codecs.d.cts +157 -68
  4. package/dist/cjs/index.cjs +187 -192
  5. package/dist/cjs/index.d.cts +310 -7
  6. package/dist/cjs/nsid.cjs +6 -9
  7. package/dist/cjs/nsid.d.cts +7 -8
  8. package/dist/cjs/types/audio.cjs +133 -119
  9. package/dist/cjs/types/audio.d.cts +343 -199
  10. package/dist/cjs/types/blob.cjs +5 -9
  11. package/dist/cjs/types/blob.d.cts +21 -21
  12. package/dist/cjs/types/records.cjs +0 -45
  13. package/dist/cjs/types/records.d.cts +1 -103
  14. package/dist/esm/api-codecs.d.ts +187 -98
  15. package/dist/esm/api-codecs.js +4 -5
  16. package/dist/esm/chunk-D655OH2I.js +35 -0
  17. package/dist/esm/chunk-F5ZKFJL2.js +39 -0
  18. package/dist/esm/{chunk-6LROFBKK.js → chunk-SBYNIQRZ.js} +7 -9
  19. package/dist/esm/chunk-SMK4OZNU.js +17 -0
  20. package/dist/esm/chunk-TVOXIQKF.js +294 -0
  21. package/dist/esm/index.d.ts +310 -7
  22. package/dist/esm/index.js +5 -7
  23. package/dist/esm/nsid.d.ts +7 -8
  24. package/dist/esm/nsid.js +1 -1
  25. package/dist/esm/types/audio.d.ts +420 -276
  26. package/dist/esm/types/audio.js +3 -4
  27. package/dist/esm/types/blob.d.ts +21 -21
  28. package/dist/esm/types/blob.js +1 -1
  29. package/dist/esm/types/records.d.ts +1 -103
  30. package/dist/esm/types/records.js +1 -1
  31. package/package.json +94 -26
  32. package/dist/cjs/types/api.cjs +0 -166
  33. package/dist/cjs/types/api.d.cts +0 -242
  34. package/dist/cjs/types/views.cjs +0 -179
  35. package/dist/cjs/types/views.d.cts +0 -726
  36. package/dist/esm/chunk-5EHV73BA.js +0 -20
  37. package/dist/esm/chunk-F7IHVM34.js +0 -144
  38. package/dist/esm/chunk-FDM5FDN4.js +0 -46
  39. package/dist/esm/chunk-IHIBHQBJ.js +0 -78
  40. package/dist/esm/chunk-R6SBR3IG.js +0 -97
  41. package/dist/esm/chunk-Y6HNNRVD.js +0 -12
  42. package/dist/esm/types/api.d.ts +0 -242
  43. package/dist/esm/types/api.js +0 -4
  44. package/dist/esm/types/views.d.ts +0 -726
  45. package/dist/esm/types/views.js +0 -3
@@ -3,11 +3,6 @@ import { z } from 'zod';
3
3
  /**
4
4
  * Antiphony canonical audio-post contract (`dev.antiphony.*`).
5
5
  *
6
- * This is the NEW data model from `specs/antiphony-data-model.md`, added
7
- * ADDITIVELY alongside the legacy `PromptRecord`/`ReplyRecord` (Stream 1).
8
- * Nothing here touches the old shapes; Vox Pop keeps running on them until the
9
- * Stream 4 migration deletes the legacy schemas + `com.voxpop.*` lexicons.
10
- *
11
6
  * Mirrors the lexicons in `lexicons/dev/antiphony/`. Key model decisions:
12
7
  * - ONE post collection; `reply` presence discriminates prompt-vs-reply.
13
8
  * - The audio is a standard `embed.audio`; transcript is platform enrichment
@@ -85,20 +80,30 @@ type ReplyRef = z.infer<typeof ReplyRefSchema>;
85
80
  */
86
81
  declare const AudioEmbedSchema: z.ZodObject<{
87
82
  $type: z.ZodLiteral<"dev.antiphony.embed.audio">;
88
- /** The audio bytes as a content-addressed storage ref (CID/path). */
83
+ /** The audio bytes as a content-addressed blob ref (`ref.$link` = CID). */
89
84
  audio: z.ZodObject<{
90
85
  $type: z.ZodLiteral<"blob">;
91
- ref: z.ZodString;
86
+ ref: z.ZodObject<{
87
+ $link: z.ZodString;
88
+ }, "strip", z.ZodTypeAny, {
89
+ $link: string;
90
+ }, {
91
+ $link: string;
92
+ }>;
92
93
  mimeType: z.ZodString;
93
94
  size: z.ZodNumber;
94
95
  }, "strip", z.ZodTypeAny, {
95
96
  $type: "blob";
96
- ref: string;
97
+ ref: {
98
+ $link: string;
99
+ };
97
100
  mimeType: string;
98
101
  size: number;
99
102
  }, {
100
103
  $type: "blob";
101
- ref: string;
104
+ ref: {
105
+ $link: string;
106
+ };
102
107
  mimeType: string;
103
108
  size: number;
104
109
  }>;
@@ -112,24 +117,28 @@ declare const AudioEmbedSchema: z.ZodObject<{
112
117
  $type: "dev.antiphony.embed.audio";
113
118
  audio: {
114
119
  $type: "blob";
115
- ref: string;
120
+ ref: {
121
+ $link: string;
122
+ };
116
123
  mimeType: string;
117
124
  size: number;
118
125
  };
126
+ waveform?: number[] | undefined;
119
127
  durationMs?: number | undefined;
120
128
  alt?: string | undefined;
121
- waveform?: number[] | undefined;
122
129
  }, {
123
130
  $type: "dev.antiphony.embed.audio";
124
131
  audio: {
125
132
  $type: "blob";
126
- ref: string;
133
+ ref: {
134
+ $link: string;
135
+ };
127
136
  mimeType: string;
128
137
  size: number;
129
138
  };
139
+ waveform?: number[] | undefined;
130
140
  durationMs?: number | undefined;
131
141
  alt?: string | undefined;
132
- waveform?: number[] | undefined;
133
142
  }>;
134
143
  type AudioEmbed = z.infer<typeof AudioEmbedSchema>;
135
144
  /**
@@ -140,21 +149,21 @@ declare const TranscriptSegmentSchema: z.ZodEffects<z.ZodObject<{
140
149
  endMs: z.ZodNumber;
141
150
  text: z.ZodString;
142
151
  }, "strip", z.ZodTypeAny, {
143
- text: string;
144
152
  startMs: number;
145
153
  endMs: number;
146
- }, {
147
154
  text: string;
155
+ }, {
148
156
  startMs: number;
149
157
  endMs: number;
150
- }>, {
151
158
  text: string;
159
+ }>, {
152
160
  startMs: number;
153
161
  endMs: number;
154
- }, {
155
162
  text: string;
163
+ }, {
156
164
  startMs: number;
157
165
  endMs: number;
166
+ text: string;
158
167
  }>;
159
168
  type TranscriptSegment = z.infer<typeof TranscriptSegmentSchema>;
160
169
  /**
@@ -168,35 +177,35 @@ declare const TimedTranscriptSchema: z.ZodObject<{
168
177
  endMs: z.ZodNumber;
169
178
  text: z.ZodString;
170
179
  }, "strip", z.ZodTypeAny, {
171
- text: string;
172
180
  startMs: number;
173
181
  endMs: number;
174
- }, {
175
182
  text: string;
183
+ }, {
176
184
  startMs: number;
177
185
  endMs: number;
178
- }>, {
179
186
  text: string;
187
+ }>, {
180
188
  startMs: number;
181
189
  endMs: number;
182
- }, {
183
190
  text: string;
191
+ }, {
184
192
  startMs: number;
185
193
  endMs: number;
194
+ text: string;
186
195
  }>, "many">;
187
196
  text: z.ZodOptional<z.ZodString>;
188
197
  }, "strip", z.ZodTypeAny, {
189
198
  segments: {
190
- text: string;
191
199
  startMs: number;
192
200
  endMs: number;
201
+ text: string;
193
202
  }[];
194
203
  text?: string | undefined;
195
204
  }, {
196
205
  segments: {
197
- text: string;
198
206
  startMs: number;
199
207
  endMs: number;
208
+ text: string;
200
209
  }[];
201
210
  text?: string | undefined;
202
211
  }>;
@@ -208,6 +217,18 @@ type TimedTranscript = z.infer<typeof TimedTranscriptSchema>;
208
217
  */
209
218
  declare const AudioEmbedViewSchema: z.ZodObject<{
210
219
  $type: z.ZodLiteral<"dev.antiphony.embed.audio#view">;
220
+ /**
221
+ * `url`, `durationMs` and `waveform` are RESOLVED, not copied: once
222
+ * processing has produced an audio variant they describe that variant
223
+ * rather than the bytes the client uploaded. They always agree with one
224
+ * another — a duration and a set of peaks are only meaningful against the
225
+ * audio `url` actually points at.
226
+ *
227
+ * A client that stored `durationMs` at upload time should therefore expect
228
+ * it to change (trim removes leading/trailing silence), and should render
229
+ * these three as a set rather than caching them independently. The record's
230
+ * originals are immutable and unaffected; this is a read-time resolution.
231
+ */
211
232
  url: z.ZodString;
212
233
  durationMs: z.ZodOptional<z.ZodNumber>;
213
234
  alt: z.ZodOptional<z.ZodString>;
@@ -219,66 +240,103 @@ declare const AudioEmbedViewSchema: z.ZodObject<{
219
240
  endMs: z.ZodNumber;
220
241
  text: z.ZodString;
221
242
  }, "strip", z.ZodTypeAny, {
222
- text: string;
223
243
  startMs: number;
224
244
  endMs: number;
225
- }, {
226
245
  text: string;
246
+ }, {
227
247
  startMs: number;
228
248
  endMs: number;
229
- }>, {
230
249
  text: string;
250
+ }>, {
231
251
  startMs: number;
232
252
  endMs: number;
233
- }, {
234
253
  text: string;
254
+ }, {
235
255
  startMs: number;
236
256
  endMs: number;
257
+ text: string;
237
258
  }>, "many">;
238
259
  text: z.ZodOptional<z.ZodString>;
239
260
  }, "strip", z.ZodTypeAny, {
240
261
  segments: {
241
- text: string;
242
262
  startMs: number;
243
263
  endMs: number;
264
+ text: string;
244
265
  }[];
245
266
  text?: string | undefined;
246
267
  }, {
247
268
  segments: {
248
- text: string;
249
269
  startMs: number;
250
270
  endMs: number;
271
+ text: string;
251
272
  }[];
252
273
  text?: string | undefined;
253
274
  }>>;
275
+ /**
276
+ * Per-stage audio-processing status (denoise / trim / transcribe /
277
+ * waveform), when the app opted into processing. Absent otherwise. A
278
+ * `pending` stage means the client should poll (or re-render) for the
279
+ * result — including a stage that returns to `pending` after having been
280
+ * `ready`, which is how a recompute surfaces. Once a byte-mutating stage
281
+ * completes, `url`/`durationMs`/`waveform` above already resolve to the
282
+ * processed audio variant. See `types/processing.ts`.
283
+ */
284
+ processing: z.ZodOptional<z.ZodObject<{
285
+ transcribe: z.ZodOptional<z.ZodEnum<["pending", "ready", "failed", "skipped"]>>;
286
+ denoise: z.ZodOptional<z.ZodEnum<["pending", "ready", "failed", "skipped"]>>;
287
+ trim: z.ZodOptional<z.ZodEnum<["pending", "ready", "failed", "skipped"]>>;
288
+ waveform: z.ZodOptional<z.ZodEnum<["pending", "ready", "failed", "skipped"]>>;
289
+ }, "strip", z.ZodTypeAny, {
290
+ denoise?: "pending" | "ready" | "failed" | "skipped" | undefined;
291
+ trim?: "pending" | "ready" | "failed" | "skipped" | undefined;
292
+ transcribe?: "pending" | "ready" | "failed" | "skipped" | undefined;
293
+ waveform?: "pending" | "ready" | "failed" | "skipped" | undefined;
294
+ }, {
295
+ denoise?: "pending" | "ready" | "failed" | "skipped" | undefined;
296
+ trim?: "pending" | "ready" | "failed" | "skipped" | undefined;
297
+ transcribe?: "pending" | "ready" | "failed" | "skipped" | undefined;
298
+ waveform?: "pending" | "ready" | "failed" | "skipped" | undefined;
299
+ }>>;
254
300
  }, "strip", z.ZodTypeAny, {
255
301
  $type: "dev.antiphony.embed.audio#view";
256
302
  url: string;
303
+ waveform?: number[] | undefined;
257
304
  durationMs?: number | undefined;
258
305
  alt?: string | undefined;
259
- waveform?: number[] | undefined;
260
306
  transcript?: {
261
307
  segments: {
262
- text: string;
263
308
  startMs: number;
264
309
  endMs: number;
310
+ text: string;
265
311
  }[];
266
312
  text?: string | undefined;
267
313
  } | undefined;
314
+ processing?: {
315
+ denoise?: "pending" | "ready" | "failed" | "skipped" | undefined;
316
+ trim?: "pending" | "ready" | "failed" | "skipped" | undefined;
317
+ transcribe?: "pending" | "ready" | "failed" | "skipped" | undefined;
318
+ waveform?: "pending" | "ready" | "failed" | "skipped" | undefined;
319
+ } | undefined;
268
320
  }, {
269
321
  $type: "dev.antiphony.embed.audio#view";
270
322
  url: string;
323
+ waveform?: number[] | undefined;
271
324
  durationMs?: number | undefined;
272
325
  alt?: string | undefined;
273
- waveform?: number[] | undefined;
274
326
  transcript?: {
275
327
  segments: {
276
- text: string;
277
328
  startMs: number;
278
329
  endMs: number;
330
+ text: string;
279
331
  }[];
280
332
  text?: string | undefined;
281
333
  } | undefined;
334
+ processing?: {
335
+ denoise?: "pending" | "ready" | "failed" | "skipped" | undefined;
336
+ trim?: "pending" | "ready" | "failed" | "skipped" | undefined;
337
+ transcribe?: "pending" | "ready" | "failed" | "skipped" | undefined;
338
+ waveform?: "pending" | "ready" | "failed" | "skipped" | undefined;
339
+ } | undefined;
282
340
  }>;
283
341
  type AudioEmbedView = z.infer<typeof AudioEmbedViewSchema>;
284
342
  /**
@@ -293,6 +351,13 @@ type AudioEmbedView = z.infer<typeof AudioEmbedViewSchema>;
293
351
  declare const AudioPostRecordSchema: z.ZodEffects<z.ZodObject<{
294
352
  /** Storage id (rkey/doc id). */
295
353
  id: z.ZodString;
354
+ /**
355
+ * Content CID of the canonical lexicon record (CIDv1, dag-cbor, sha2-256
356
+ * — the AT Protocol record-CID rule). Computed at write time over the
357
+ * lexicon projection (public fields only, NOT the storage/tenancy fields
358
+ * below), so StrongRefs built from it are verifiable content addresses.
359
+ */
360
+ cid: z.ZodString;
296
361
  /** Origin app that created this record — the multi-tenant isolation key. */
297
362
  originAppId: z.ZodString;
298
363
  /** Authoring user. A queryable facet, not the tenancy boundary. */
@@ -309,9 +374,62 @@ declare const AudioPostRecordSchema: z.ZodEffects<z.ZodObject<{
309
374
  * opened the branch. Set on replies (deduped, 1–2 ids); absent on prompts
310
375
  * (a prompt's repliers are the app's audience policy, not a fixed pair).
311
376
  * Inherited down the branch so reply gating is an O(1) field check, never a
312
- * thread walk. See `specs/antiphony-data-model.md` §6 "Reply gating".
377
+ * thread walk.
313
378
  */
314
379
  threadParticipants: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
380
+ /**
381
+ * Author of this reply's thread ROOT (the prompt) — the reply's recipient,
382
+ * the person whose "replies to me" feed it lands in. Denormalized at write
383
+ * time so "replies whose root author is X" is a cheap composite-index query
384
+ * (see `queryByRootAuthor`). Set on replies (`kind === 'reply'`); absent on
385
+ * prompts. Storage-layer facet, NOT in the public lexicon or the record CID.
386
+ */
387
+ rootAuthorId: z.ZodOptional<z.ZodString>;
388
+ /**
389
+ * Async audio-processing state (transcribe / denoise), present iff the app
390
+ * opted into processing on create. Mutated by the processing worker after
391
+ * the post is created — storage-layer, NOT in the lexicon or the record
392
+ * CID. See `types/processing.ts`.
393
+ */
394
+ processing: z.ZodOptional<z.ZodObject<{
395
+ transcribe: z.ZodOptional<z.ZodEnum<["pending", "ready", "failed", "skipped"]>>;
396
+ denoise: z.ZodOptional<z.ZodEnum<["pending", "ready", "failed", "skipped"]>>;
397
+ trim: z.ZodOptional<z.ZodEnum<["pending", "ready", "failed", "skipped"]>>;
398
+ waveform: z.ZodOptional<z.ZodEnum<["pending", "ready", "failed", "skipped"]>>;
399
+ } & {
400
+ reprocess: z.ZodOptional<z.ZodBoolean>;
401
+ } & {
402
+ processedBlobCid: z.ZodOptional<z.ZodString>;
403
+ processedMimeType: z.ZodOptional<z.ZodString>;
404
+ processedDurationMs: z.ZodOptional<z.ZodNumber>;
405
+ waveformPeaks: z.ZodOptional<z.ZodArray<z.ZodNumber, "many">>;
406
+ leaseUntil: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodType<unknown, z.ZodTypeDef, unknown>, z.ZodString, z.ZodNumber, z.ZodDate]>, Date, unknown>>;
407
+ updatedAt: z.ZodEffects<z.ZodUnion<[z.ZodType<unknown, z.ZodTypeDef, unknown>, z.ZodString, z.ZodNumber, z.ZodDate]>, Date, unknown>;
408
+ }, "strip", z.ZodTypeAny, {
409
+ updatedAt: Date;
410
+ denoise?: "pending" | "ready" | "failed" | "skipped" | undefined;
411
+ trim?: "pending" | "ready" | "failed" | "skipped" | undefined;
412
+ transcribe?: "pending" | "ready" | "failed" | "skipped" | undefined;
413
+ waveform?: "pending" | "ready" | "failed" | "skipped" | undefined;
414
+ reprocess?: boolean | undefined;
415
+ processedBlobCid?: string | undefined;
416
+ processedMimeType?: string | undefined;
417
+ processedDurationMs?: number | undefined;
418
+ waveformPeaks?: number[] | undefined;
419
+ leaseUntil?: Date | undefined;
420
+ }, {
421
+ denoise?: "pending" | "ready" | "failed" | "skipped" | undefined;
422
+ trim?: "pending" | "ready" | "failed" | "skipped" | undefined;
423
+ transcribe?: "pending" | "ready" | "failed" | "skipped" | undefined;
424
+ waveform?: "pending" | "ready" | "failed" | "skipped" | undefined;
425
+ reprocess?: boolean | undefined;
426
+ processedBlobCid?: string | undefined;
427
+ processedMimeType?: string | undefined;
428
+ processedDurationMs?: number | undefined;
429
+ waveformPeaks?: number[] | undefined;
430
+ leaseUntil?: unknown;
431
+ updatedAt?: unknown;
432
+ }>>;
315
433
  /** User-authored text (bsky-semantic). May be empty for pure-audio posts. NEVER the transcript. */
316
434
  text: z.ZodString;
317
435
  /** Optional headline; a prompt feature, not the discriminator. */
@@ -319,20 +437,30 @@ declare const AudioPostRecordSchema: z.ZodEffects<z.ZodObject<{
319
437
  /** Audio (or other) attachment. Audio posts carry an `AudioEmbed`. */
320
438
  embed: z.ZodOptional<z.ZodObject<{
321
439
  $type: z.ZodLiteral<"dev.antiphony.embed.audio">;
322
- /** The audio bytes as a content-addressed storage ref (CID/path). */
440
+ /** The audio bytes as a content-addressed blob ref (`ref.$link` = CID). */
323
441
  audio: z.ZodObject<{
324
442
  $type: z.ZodLiteral<"blob">;
325
- ref: z.ZodString;
443
+ ref: z.ZodObject<{
444
+ $link: z.ZodString;
445
+ }, "strip", z.ZodTypeAny, {
446
+ $link: string;
447
+ }, {
448
+ $link: string;
449
+ }>;
326
450
  mimeType: z.ZodString;
327
451
  size: z.ZodNumber;
328
452
  }, "strip", z.ZodTypeAny, {
329
453
  $type: "blob";
330
- ref: string;
454
+ ref: {
455
+ $link: string;
456
+ };
331
457
  mimeType: string;
332
458
  size: number;
333
459
  }, {
334
460
  $type: "blob";
335
- ref: string;
461
+ ref: {
462
+ $link: string;
463
+ };
336
464
  mimeType: string;
337
465
  size: number;
338
466
  }>;
@@ -346,24 +474,28 @@ declare const AudioPostRecordSchema: z.ZodEffects<z.ZodObject<{
346
474
  $type: "dev.antiphony.embed.audio";
347
475
  audio: {
348
476
  $type: "blob";
349
- ref: string;
477
+ ref: {
478
+ $link: string;
479
+ };
350
480
  mimeType: string;
351
481
  size: number;
352
482
  };
483
+ waveform?: number[] | undefined;
353
484
  durationMs?: number | undefined;
354
485
  alt?: string | undefined;
355
- waveform?: number[] | undefined;
356
486
  }, {
357
487
  $type: "dev.antiphony.embed.audio";
358
488
  audio: {
359
489
  $type: "blob";
360
- ref: string;
490
+ ref: {
491
+ $link: string;
492
+ };
361
493
  mimeType: string;
362
494
  size: number;
363
495
  };
496
+ waveform?: number[] | undefined;
364
497
  durationMs?: number | undefined;
365
498
  alt?: string | undefined;
366
- waveform?: number[] | undefined;
367
499
  }>>;
368
500
  /** Present iff this post is a reply (StrongRef root + parent). */
369
501
  reply: z.ZodOptional<z.ZodObject<{
@@ -413,25 +545,28 @@ declare const AudioPostRecordSchema: z.ZodEffects<z.ZodObject<{
413
545
  selfLabels: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
414
546
  createdAt: z.ZodEffects<z.ZodUnion<[z.ZodType<unknown, z.ZodTypeDef, unknown>, z.ZodString, z.ZodNumber, z.ZodDate]>, Date, unknown>;
415
547
  }, "strip", z.ZodTypeAny, {
548
+ cid: string;
416
549
  text: string;
417
550
  id: string;
418
- createdAt: Date;
419
551
  originAppId: string;
420
552
  authorId: string;
421
- kind: "reply" | "prompt";
422
- title?: string | undefined;
423
- embed?: {
424
- $type: "dev.antiphony.embed.audio";
425
- audio: {
426
- $type: "blob";
427
- ref: string;
428
- mimeType: string;
429
- size: number;
430
- };
431
- durationMs?: number | undefined;
432
- alt?: string | undefined;
433
- waveform?: number[] | undefined;
553
+ kind: "prompt" | "reply";
554
+ createdAt: Date;
555
+ processing?: {
556
+ updatedAt: Date;
557
+ denoise?: "pending" | "ready" | "failed" | "skipped" | undefined;
558
+ trim?: "pending" | "ready" | "failed" | "skipped" | undefined;
559
+ transcribe?: "pending" | "ready" | "failed" | "skipped" | undefined;
560
+ waveform?: "pending" | "ready" | "failed" | "skipped" | undefined;
561
+ reprocess?: boolean | undefined;
562
+ processedBlobCid?: string | undefined;
563
+ processedMimeType?: string | undefined;
564
+ processedDurationMs?: number | undefined;
565
+ waveformPeaks?: number[] | undefined;
566
+ leaseUntil?: Date | undefined;
434
567
  } | undefined;
568
+ authorDid?: string | undefined;
569
+ orgId?: string | null | undefined;
435
570
  reply?: {
436
571
  root: {
437
572
  uri: string;
@@ -442,30 +577,47 @@ declare const AudioPostRecordSchema: z.ZodEffects<z.ZodObject<{
442
577
  cid: string;
443
578
  };
444
579
  } | undefined;
445
- langs?: string[] | undefined;
446
- selfLabels?: string[] | undefined;
447
- authorDid?: string | undefined;
448
- orgId?: string | null | undefined;
449
580
  threadParticipants?: string[] | undefined;
450
- }, {
451
- text: string;
452
- id: string;
453
- originAppId: string;
454
- authorId: string;
455
- kind: "reply" | "prompt";
581
+ rootAuthorId?: string | undefined;
456
582
  title?: string | undefined;
457
583
  embed?: {
458
584
  $type: "dev.antiphony.embed.audio";
459
585
  audio: {
460
586
  $type: "blob";
461
- ref: string;
587
+ ref: {
588
+ $link: string;
589
+ };
462
590
  mimeType: string;
463
591
  size: number;
464
592
  };
593
+ waveform?: number[] | undefined;
465
594
  durationMs?: number | undefined;
466
595
  alt?: string | undefined;
467
- waveform?: number[] | undefined;
468
596
  } | undefined;
597
+ langs?: string[] | undefined;
598
+ selfLabels?: string[] | undefined;
599
+ }, {
600
+ cid: string;
601
+ text: string;
602
+ id: string;
603
+ originAppId: string;
604
+ authorId: string;
605
+ kind: "prompt" | "reply";
606
+ processing?: {
607
+ denoise?: "pending" | "ready" | "failed" | "skipped" | undefined;
608
+ trim?: "pending" | "ready" | "failed" | "skipped" | undefined;
609
+ transcribe?: "pending" | "ready" | "failed" | "skipped" | undefined;
610
+ waveform?: "pending" | "ready" | "failed" | "skipped" | undefined;
611
+ reprocess?: boolean | undefined;
612
+ processedBlobCid?: string | undefined;
613
+ processedMimeType?: string | undefined;
614
+ processedDurationMs?: number | undefined;
615
+ waveformPeaks?: number[] | undefined;
616
+ leaseUntil?: unknown;
617
+ updatedAt?: unknown;
618
+ } | undefined;
619
+ authorDid?: string | undefined;
620
+ orgId?: string | null | undefined;
469
621
  reply?: {
470
622
  root: {
471
623
  uri: string;
@@ -476,32 +628,49 @@ declare const AudioPostRecordSchema: z.ZodEffects<z.ZodObject<{
476
628
  cid: string;
477
629
  };
478
630
  } | undefined;
479
- langs?: string[] | undefined;
480
- selfLabels?: string[] | undefined;
481
- createdAt?: unknown;
482
- authorDid?: string | undefined;
483
- orgId?: string | null | undefined;
484
631
  threadParticipants?: string[] | undefined;
485
- }>, {
486
- text: string;
487
- id: string;
488
- createdAt: Date;
489
- originAppId: string;
490
- authorId: string;
491
- kind: "reply" | "prompt";
632
+ rootAuthorId?: string | undefined;
492
633
  title?: string | undefined;
493
634
  embed?: {
494
635
  $type: "dev.antiphony.embed.audio";
495
636
  audio: {
496
637
  $type: "blob";
497
- ref: string;
638
+ ref: {
639
+ $link: string;
640
+ };
498
641
  mimeType: string;
499
642
  size: number;
500
643
  };
644
+ waveform?: number[] | undefined;
501
645
  durationMs?: number | undefined;
502
646
  alt?: string | undefined;
503
- waveform?: number[] | undefined;
504
647
  } | undefined;
648
+ langs?: string[] | undefined;
649
+ selfLabels?: string[] | undefined;
650
+ createdAt?: unknown;
651
+ }>, {
652
+ cid: string;
653
+ text: string;
654
+ id: string;
655
+ originAppId: string;
656
+ authorId: string;
657
+ kind: "prompt" | "reply";
658
+ createdAt: Date;
659
+ processing?: {
660
+ updatedAt: Date;
661
+ denoise?: "pending" | "ready" | "failed" | "skipped" | undefined;
662
+ trim?: "pending" | "ready" | "failed" | "skipped" | undefined;
663
+ transcribe?: "pending" | "ready" | "failed" | "skipped" | undefined;
664
+ waveform?: "pending" | "ready" | "failed" | "skipped" | undefined;
665
+ reprocess?: boolean | undefined;
666
+ processedBlobCid?: string | undefined;
667
+ processedMimeType?: string | undefined;
668
+ processedDurationMs?: number | undefined;
669
+ waveformPeaks?: number[] | undefined;
670
+ leaseUntil?: Date | undefined;
671
+ } | undefined;
672
+ authorDid?: string | undefined;
673
+ orgId?: string | null | undefined;
505
674
  reply?: {
506
675
  root: {
507
676
  uri: string;
@@ -512,30 +681,47 @@ declare const AudioPostRecordSchema: z.ZodEffects<z.ZodObject<{
512
681
  cid: string;
513
682
  };
514
683
  } | undefined;
515
- langs?: string[] | undefined;
516
- selfLabels?: string[] | undefined;
517
- authorDid?: string | undefined;
518
- orgId?: string | null | undefined;
519
684
  threadParticipants?: string[] | undefined;
520
- }, {
521
- text: string;
522
- id: string;
523
- originAppId: string;
524
- authorId: string;
525
- kind: "reply" | "prompt";
685
+ rootAuthorId?: string | undefined;
526
686
  title?: string | undefined;
527
687
  embed?: {
528
688
  $type: "dev.antiphony.embed.audio";
529
689
  audio: {
530
690
  $type: "blob";
531
- ref: string;
691
+ ref: {
692
+ $link: string;
693
+ };
532
694
  mimeType: string;
533
695
  size: number;
534
696
  };
697
+ waveform?: number[] | undefined;
535
698
  durationMs?: number | undefined;
536
699
  alt?: string | undefined;
537
- waveform?: number[] | undefined;
538
700
  } | undefined;
701
+ langs?: string[] | undefined;
702
+ selfLabels?: string[] | undefined;
703
+ }, {
704
+ cid: string;
705
+ text: string;
706
+ id: string;
707
+ originAppId: string;
708
+ authorId: string;
709
+ kind: "prompt" | "reply";
710
+ processing?: {
711
+ denoise?: "pending" | "ready" | "failed" | "skipped" | undefined;
712
+ trim?: "pending" | "ready" | "failed" | "skipped" | undefined;
713
+ transcribe?: "pending" | "ready" | "failed" | "skipped" | undefined;
714
+ waveform?: "pending" | "ready" | "failed" | "skipped" | undefined;
715
+ reprocess?: boolean | undefined;
716
+ processedBlobCid?: string | undefined;
717
+ processedMimeType?: string | undefined;
718
+ processedDurationMs?: number | undefined;
719
+ waveformPeaks?: number[] | undefined;
720
+ leaseUntil?: unknown;
721
+ updatedAt?: unknown;
722
+ } | undefined;
723
+ authorDid?: string | undefined;
724
+ orgId?: string | null | undefined;
539
725
  reply?: {
540
726
  root: {
541
727
  uri: string;
@@ -546,12 +732,26 @@ declare const AudioPostRecordSchema: z.ZodEffects<z.ZodObject<{
546
732
  cid: string;
547
733
  };
548
734
  } | undefined;
735
+ threadParticipants?: string[] | undefined;
736
+ rootAuthorId?: string | undefined;
737
+ title?: string | undefined;
738
+ embed?: {
739
+ $type: "dev.antiphony.embed.audio";
740
+ audio: {
741
+ $type: "blob";
742
+ ref: {
743
+ $link: string;
744
+ };
745
+ mimeType: string;
746
+ size: number;
747
+ };
748
+ waveform?: number[] | undefined;
749
+ durationMs?: number | undefined;
750
+ alt?: string | undefined;
751
+ } | undefined;
549
752
  langs?: string[] | undefined;
550
753
  selfLabels?: string[] | undefined;
551
754
  createdAt?: unknown;
552
- authorDid?: string | undefined;
553
- orgId?: string | null | undefined;
554
- threadParticipants?: string[] | undefined;
555
755
  }>;
556
756
  type AudioPostRecord = z.infer<typeof AudioPostRecordSchema>;
557
757
  /**
@@ -578,35 +778,35 @@ declare const TranscriptEnrichmentRecordSchema: z.ZodObject<{
578
778
  endMs: z.ZodNumber;
579
779
  text: z.ZodString;
580
780
  }, "strip", z.ZodTypeAny, {
581
- text: string;
582
781
  startMs: number;
583
782
  endMs: number;
584
- }, {
585
783
  text: string;
784
+ }, {
586
785
  startMs: number;
587
786
  endMs: number;
588
- }>, {
589
787
  text: string;
788
+ }>, {
590
789
  startMs: number;
591
790
  endMs: number;
592
- }, {
593
791
  text: string;
792
+ }, {
594
793
  startMs: number;
595
794
  endMs: number;
795
+ text: string;
596
796
  }>, "many">;
597
797
  text: z.ZodOptional<z.ZodString>;
598
798
  }, "strip", z.ZodTypeAny, {
599
799
  segments: {
600
- text: string;
601
800
  startMs: number;
602
801
  endMs: number;
802
+ text: string;
603
803
  }[];
604
804
  text?: string | undefined;
605
805
  }, {
606
806
  segments: {
607
- text: string;
608
807
  startMs: number;
609
808
  endMs: number;
809
+ text: string;
610
810
  }[];
611
811
  text?: string | undefined;
612
812
  }>;
@@ -616,16 +816,16 @@ declare const TranscriptEnrichmentRecordSchema: z.ZodObject<{
616
816
  model: z.ZodOptional<z.ZodString>;
617
817
  createdAt: z.ZodEffects<z.ZodUnion<[z.ZodType<unknown, z.ZodTypeDef, unknown>, z.ZodString, z.ZodNumber, z.ZodDate]>, Date, unknown>;
618
818
  }, "strip", z.ZodTypeAny, {
619
- id: string;
620
- createdAt: Date;
621
819
  transcript: {
622
820
  segments: {
623
- text: string;
624
821
  startMs: number;
625
822
  endMs: number;
823
+ text: string;
626
824
  }[];
627
825
  text?: string | undefined;
628
826
  };
827
+ id: string;
828
+ createdAt: Date;
629
829
  subject: {
630
830
  uri: string;
631
831
  cid: string;
@@ -633,15 +833,15 @@ declare const TranscriptEnrichmentRecordSchema: z.ZodObject<{
633
833
  lang?: string | undefined;
634
834
  model?: string | undefined;
635
835
  }, {
636
- id: string;
637
836
  transcript: {
638
837
  segments: {
639
- text: string;
640
838
  startMs: number;
641
839
  endMs: number;
840
+ text: string;
642
841
  }[];
643
842
  text?: string | undefined;
644
843
  };
844
+ id: string;
645
845
  subject: {
646
846
  uri: string;
647
847
  cid: string;
@@ -652,7 +852,13 @@ declare const TranscriptEnrichmentRecordSchema: z.ZodObject<{
652
852
  }>;
653
853
  type TranscriptEnrichmentRecord = z.infer<typeof TranscriptEnrichmentRecordSchema>;
654
854
  /**
655
- * `dev.antiphony.actor.profile` — port of `com.voxpop.actor.profile`.
855
+ * `dev.antiphony.actor.profile` — portable actor-profile record shape.
856
+ *
857
+ * Lexicon-only: the core never stores, serves, or CRUDs this record — the
858
+ * caller BFF is the sole authority for profile data. The schema stays in
859
+ * `@antiphony/shared` so a federating/exporting deployment has a well-known
860
+ * shape to project a BFF-owned profile into (see specs/core-bff-boundary.md,
861
+ * "actor.profile lexicon", resolved 2026-07-03).
656
862
  */
657
863
  declare const ActorProfileRecordSchema: z.ZodObject<{
658
864
  handle: z.ZodOptional<z.ZodString>;
@@ -747,7 +953,6 @@ declare const PostRecordPublicSchema: z.ZodObject<{
747
953
  }, "strip", z.ZodTypeAny, {
748
954
  text: string;
749
955
  createdAt: Date;
750
- title?: string | undefined;
751
956
  reply?: {
752
957
  root: {
753
958
  uri: string;
@@ -758,11 +963,11 @@ declare const PostRecordPublicSchema: z.ZodObject<{
758
963
  cid: string;
759
964
  };
760
965
  } | undefined;
966
+ title?: string | undefined;
761
967
  langs?: string[] | undefined;
762
968
  selfLabels?: string[] | undefined;
763
969
  }, {
764
970
  text: string;
765
- title?: string | undefined;
766
971
  reply?: {
767
972
  root: {
768
973
  uri: string;
@@ -773,6 +978,7 @@ declare const PostRecordPublicSchema: z.ZodObject<{
773
978
  cid: string;
774
979
  };
775
980
  } | undefined;
981
+ title?: string | undefined;
776
982
  langs?: string[] | undefined;
777
983
  selfLabels?: string[] | undefined;
778
984
  createdAt?: unknown;
@@ -780,106 +986,27 @@ declare const PostRecordPublicSchema: z.ZodObject<{
780
986
  type PostRecordPublic = z.infer<typeof PostRecordPublicSchema>;
781
987
  /**
782
988
  * `AudioPostView` — the hydrated, client-facing shape (the bsky `postView`
783
- * analogue): record content + author + hydrated embed + per-viewer state.
784
- * Produced by the (batched) hydrator; the default/public view, with
785
- * owner-extra arriving via `viewer` + separate authed endpoints, not fat
786
- * records.
989
+ * analogue): record content + opaque author references + hydrated embed +
990
+ * per-viewer state. Produced by the (batched) hydrator; the default/public
991
+ * view, with owner-extra arriving via `viewer` + separate authed endpoints,
992
+ * not fat records.
993
+ *
994
+ * Author identity is carried as **opaque references**, never a hydrated
995
+ * profile: `authorId` is the app's own user id (attribution facet) and
996
+ * `authorDid` is present only when the caller asserted one. Antiphony holds no
997
+ * user data — the caller BFF hydrates display identity by joining on
998
+ * `authorId` (see specs/core-surface.md, "The author model").
787
999
  */
788
1000
  declare const AudioPostViewSchema: z.ZodObject<{
789
1001
  /** at:// URI (or internal ref) identifying the post. */
790
1002
  uri: z.ZodString;
791
- cid: z.ZodOptional<z.ZodString>;
1003
+ /** Content CID of the canonical record (see `AudioPostRecordSchema.cid`). */
1004
+ cid: z.ZodString;
792
1005
  kind: z.ZodEnum<["prompt", "reply"]>;
793
- author: z.ZodObject<{
794
- id: z.ZodString;
795
- handle: z.ZodOptional<z.ZodNullable<z.ZodString>>;
796
- displayName: z.ZodOptional<z.ZodNullable<z.ZodString>>;
797
- avatarUrl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
798
- bio: z.ZodOptional<z.ZodNullable<z.ZodString>>;
799
- website: z.ZodOptional<z.ZodNullable<z.ZodString>>;
800
- links: z.ZodOptional<z.ZodArray<z.ZodObject<{
801
- label: z.ZodString;
802
- url: z.ZodString;
803
- }, "strip", z.ZodTypeAny, {
804
- label: string;
805
- url: string;
806
- }, {
807
- label: string;
808
- url: string;
809
- }>, "many">>;
810
- bluesky: z.ZodOptional<z.ZodObject<{
811
- handle: z.ZodString;
812
- did: z.ZodString;
813
- }, "strip", z.ZodTypeAny, {
814
- handle: string;
815
- did: string;
816
- }, {
817
- handle: string;
818
- did: string;
819
- }>>;
820
- stats: z.ZodOptional<z.ZodObject<{
821
- followers: z.ZodDefault<z.ZodNumber>;
822
- following: z.ZodDefault<z.ZodNumber>;
823
- prompts: z.ZodDefault<z.ZodNumber>;
824
- }, "strip", z.ZodTypeAny, {
825
- followers: number;
826
- following: number;
827
- prompts: number;
828
- }, {
829
- followers?: number | undefined;
830
- following?: number | undefined;
831
- prompts?: number | undefined;
832
- }>>;
833
- badges: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
834
- isVerified: z.ZodOptional<z.ZodBoolean>;
835
- createdAt: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodType<unknown, z.ZodTypeDef, unknown>, z.ZodString, z.ZodNumber, z.ZodDate]>, Date, unknown>>;
836
- }, "strip", z.ZodTypeAny, {
837
- id: string;
838
- handle?: string | null | undefined;
839
- displayName?: string | null | undefined;
840
- bio?: string | null | undefined;
841
- avatarUrl?: string | null | undefined;
842
- website?: string | null | undefined;
843
- links?: {
844
- label: string;
845
- url: string;
846
- }[] | undefined;
847
- createdAt?: Date | undefined;
848
- bluesky?: {
849
- handle: string;
850
- did: string;
851
- } | undefined;
852
- stats?: {
853
- followers: number;
854
- following: number;
855
- prompts: number;
856
- } | undefined;
857
- badges?: string[] | undefined;
858
- isVerified?: boolean | undefined;
859
- }, {
860
- id: string;
861
- handle?: string | null | undefined;
862
- displayName?: string | null | undefined;
863
- bio?: string | null | undefined;
864
- avatarUrl?: string | null | undefined;
865
- website?: string | null | undefined;
866
- links?: {
867
- label: string;
868
- url: string;
869
- }[] | undefined;
870
- createdAt?: unknown;
871
- bluesky?: {
872
- handle: string;
873
- did: string;
874
- } | undefined;
875
- stats?: {
876
- followers?: number | undefined;
877
- following?: number | undefined;
878
- prompts?: number | undefined;
879
- } | undefined;
880
- badges?: string[] | undefined;
881
- isVerified?: boolean | undefined;
882
- }>;
1006
+ /** The acting actor's app-scoped id — an opaque attribution ref, not a profile. */
1007
+ authorId: z.ZodString;
1008
+ /** The author's app-asserted AT Protocol DID, when the caller provided one. */
1009
+ authorDid: z.ZodOptional<z.ZodString>;
883
1010
  record: z.ZodObject<{
884
1011
  text: z.ZodString;
885
1012
  title: z.ZodOptional<z.ZodString>;
@@ -929,7 +1056,6 @@ declare const AudioPostViewSchema: z.ZodObject<{
929
1056
  }, "strip", z.ZodTypeAny, {
930
1057
  text: string;
931
1058
  createdAt: Date;
932
- title?: string | undefined;
933
1059
  reply?: {
934
1060
  root: {
935
1061
  uri: string;
@@ -940,11 +1066,11 @@ declare const AudioPostViewSchema: z.ZodObject<{
940
1066
  cid: string;
941
1067
  };
942
1068
  } | undefined;
1069
+ title?: string | undefined;
943
1070
  langs?: string[] | undefined;
944
1071
  selfLabels?: string[] | undefined;
945
1072
  }, {
946
1073
  text: string;
947
- title?: string | undefined;
948
1074
  reply?: {
949
1075
  root: {
950
1076
  uri: string;
@@ -955,6 +1081,7 @@ declare const AudioPostViewSchema: z.ZodObject<{
955
1081
  cid: string;
956
1082
  };
957
1083
  } | undefined;
1084
+ title?: string | undefined;
958
1085
  langs?: string[] | undefined;
959
1086
  selfLabels?: string[] | undefined;
960
1087
  createdAt?: unknown;
@@ -962,6 +1089,18 @@ declare const AudioPostViewSchema: z.ZodObject<{
962
1089
  /** Hydrated audio embed (signed URL + lifted transcript). */
963
1090
  embed: z.ZodOptional<z.ZodObject<{
964
1091
  $type: z.ZodLiteral<"dev.antiphony.embed.audio#view">;
1092
+ /**
1093
+ * `url`, `durationMs` and `waveform` are RESOLVED, not copied: once
1094
+ * processing has produced an audio variant they describe that variant
1095
+ * rather than the bytes the client uploaded. They always agree with one
1096
+ * another — a duration and a set of peaks are only meaningful against the
1097
+ * audio `url` actually points at.
1098
+ *
1099
+ * A client that stored `durationMs` at upload time should therefore expect
1100
+ * it to change (trim removes leading/trailing silence), and should render
1101
+ * these three as a set rather than caching them independently. The record's
1102
+ * originals are immutable and unaffected; this is a read-time resolution.
1103
+ */
965
1104
  url: z.ZodString;
966
1105
  durationMs: z.ZodOptional<z.ZodNumber>;
967
1106
  alt: z.ZodOptional<z.ZodString>;
@@ -973,66 +1112,103 @@ declare const AudioPostViewSchema: z.ZodObject<{
973
1112
  endMs: z.ZodNumber;
974
1113
  text: z.ZodString;
975
1114
  }, "strip", z.ZodTypeAny, {
976
- text: string;
977
1115
  startMs: number;
978
1116
  endMs: number;
979
- }, {
980
1117
  text: string;
1118
+ }, {
981
1119
  startMs: number;
982
1120
  endMs: number;
983
- }>, {
984
1121
  text: string;
1122
+ }>, {
985
1123
  startMs: number;
986
1124
  endMs: number;
987
- }, {
988
1125
  text: string;
1126
+ }, {
989
1127
  startMs: number;
990
1128
  endMs: number;
1129
+ text: string;
991
1130
  }>, "many">;
992
1131
  text: z.ZodOptional<z.ZodString>;
993
1132
  }, "strip", z.ZodTypeAny, {
994
1133
  segments: {
995
- text: string;
996
1134
  startMs: number;
997
1135
  endMs: number;
1136
+ text: string;
998
1137
  }[];
999
1138
  text?: string | undefined;
1000
1139
  }, {
1001
1140
  segments: {
1002
- text: string;
1003
1141
  startMs: number;
1004
1142
  endMs: number;
1143
+ text: string;
1005
1144
  }[];
1006
1145
  text?: string | undefined;
1007
1146
  }>>;
1147
+ /**
1148
+ * Per-stage audio-processing status (denoise / trim / transcribe /
1149
+ * waveform), when the app opted into processing. Absent otherwise. A
1150
+ * `pending` stage means the client should poll (or re-render) for the
1151
+ * result — including a stage that returns to `pending` after having been
1152
+ * `ready`, which is how a recompute surfaces. Once a byte-mutating stage
1153
+ * completes, `url`/`durationMs`/`waveform` above already resolve to the
1154
+ * processed audio variant. See `types/processing.ts`.
1155
+ */
1156
+ processing: z.ZodOptional<z.ZodObject<{
1157
+ transcribe: z.ZodOptional<z.ZodEnum<["pending", "ready", "failed", "skipped"]>>;
1158
+ denoise: z.ZodOptional<z.ZodEnum<["pending", "ready", "failed", "skipped"]>>;
1159
+ trim: z.ZodOptional<z.ZodEnum<["pending", "ready", "failed", "skipped"]>>;
1160
+ waveform: z.ZodOptional<z.ZodEnum<["pending", "ready", "failed", "skipped"]>>;
1161
+ }, "strip", z.ZodTypeAny, {
1162
+ denoise?: "pending" | "ready" | "failed" | "skipped" | undefined;
1163
+ trim?: "pending" | "ready" | "failed" | "skipped" | undefined;
1164
+ transcribe?: "pending" | "ready" | "failed" | "skipped" | undefined;
1165
+ waveform?: "pending" | "ready" | "failed" | "skipped" | undefined;
1166
+ }, {
1167
+ denoise?: "pending" | "ready" | "failed" | "skipped" | undefined;
1168
+ trim?: "pending" | "ready" | "failed" | "skipped" | undefined;
1169
+ transcribe?: "pending" | "ready" | "failed" | "skipped" | undefined;
1170
+ waveform?: "pending" | "ready" | "failed" | "skipped" | undefined;
1171
+ }>>;
1008
1172
  }, "strip", z.ZodTypeAny, {
1009
1173
  $type: "dev.antiphony.embed.audio#view";
1010
1174
  url: string;
1175
+ waveform?: number[] | undefined;
1011
1176
  durationMs?: number | undefined;
1012
1177
  alt?: string | undefined;
1013
- waveform?: number[] | undefined;
1014
1178
  transcript?: {
1015
1179
  segments: {
1016
- text: string;
1017
1180
  startMs: number;
1018
1181
  endMs: number;
1182
+ text: string;
1019
1183
  }[];
1020
1184
  text?: string | undefined;
1021
1185
  } | undefined;
1186
+ processing?: {
1187
+ denoise?: "pending" | "ready" | "failed" | "skipped" | undefined;
1188
+ trim?: "pending" | "ready" | "failed" | "skipped" | undefined;
1189
+ transcribe?: "pending" | "ready" | "failed" | "skipped" | undefined;
1190
+ waveform?: "pending" | "ready" | "failed" | "skipped" | undefined;
1191
+ } | undefined;
1022
1192
  }, {
1023
1193
  $type: "dev.antiphony.embed.audio#view";
1024
1194
  url: string;
1195
+ waveform?: number[] | undefined;
1025
1196
  durationMs?: number | undefined;
1026
1197
  alt?: string | undefined;
1027
- waveform?: number[] | undefined;
1028
1198
  transcript?: {
1029
1199
  segments: {
1030
- text: string;
1031
1200
  startMs: number;
1032
1201
  endMs: number;
1202
+ text: string;
1033
1203
  }[];
1034
1204
  text?: string | undefined;
1035
1205
  } | undefined;
1206
+ processing?: {
1207
+ denoise?: "pending" | "ready" | "failed" | "skipped" | undefined;
1208
+ trim?: "pending" | "ready" | "failed" | "skipped" | undefined;
1209
+ transcribe?: "pending" | "ready" | "failed" | "skipped" | undefined;
1210
+ waveform?: "pending" | "ready" | "failed" | "skipped" | undefined;
1211
+ } | undefined;
1036
1212
  }>>;
1037
1213
  viewer: z.ZodObject<{
1038
1214
  /** True when the authenticated caller authored this post. */
@@ -1056,35 +1232,12 @@ declare const AudioPostViewSchema: z.ZodObject<{
1056
1232
  }>;
1057
1233
  }, "strip", z.ZodTypeAny, {
1058
1234
  uri: string;
1059
- kind: "reply" | "prompt";
1060
- author: {
1061
- id: string;
1062
- handle?: string | null | undefined;
1063
- displayName?: string | null | undefined;
1064
- bio?: string | null | undefined;
1065
- avatarUrl?: string | null | undefined;
1066
- website?: string | null | undefined;
1067
- links?: {
1068
- label: string;
1069
- url: string;
1070
- }[] | undefined;
1071
- createdAt?: Date | undefined;
1072
- bluesky?: {
1073
- handle: string;
1074
- did: string;
1075
- } | undefined;
1076
- stats?: {
1077
- followers: number;
1078
- following: number;
1079
- prompts: number;
1080
- } | undefined;
1081
- badges?: string[] | undefined;
1082
- isVerified?: boolean | undefined;
1083
- };
1235
+ cid: string;
1236
+ authorId: string;
1237
+ kind: "prompt" | "reply";
1084
1238
  record: {
1085
1239
  text: string;
1086
1240
  createdAt: Date;
1087
- title?: string | undefined;
1088
1241
  reply?: {
1089
1242
  root: {
1090
1243
  uri: string;
@@ -1095,6 +1248,7 @@ declare const AudioPostViewSchema: z.ZodObject<{
1095
1248
  cid: string;
1096
1249
  };
1097
1250
  } | undefined;
1251
+ title?: string | undefined;
1098
1252
  langs?: string[] | undefined;
1099
1253
  selfLabels?: string[] | undefined;
1100
1254
  };
@@ -1103,52 +1257,35 @@ declare const AudioPostViewSchema: z.ZodObject<{
1103
1257
  canReply: boolean;
1104
1258
  replyDisabledReason?: "unauthenticated" | "not_a_participant" | undefined;
1105
1259
  };
1260
+ authorDid?: string | undefined;
1106
1261
  embed?: {
1107
1262
  $type: "dev.antiphony.embed.audio#view";
1108
1263
  url: string;
1264
+ waveform?: number[] | undefined;
1109
1265
  durationMs?: number | undefined;
1110
1266
  alt?: string | undefined;
1111
- waveform?: number[] | undefined;
1112
1267
  transcript?: {
1113
1268
  segments: {
1114
- text: string;
1115
1269
  startMs: number;
1116
1270
  endMs: number;
1271
+ text: string;
1117
1272
  }[];
1118
1273
  text?: string | undefined;
1119
1274
  } | undefined;
1275
+ processing?: {
1276
+ denoise?: "pending" | "ready" | "failed" | "skipped" | undefined;
1277
+ trim?: "pending" | "ready" | "failed" | "skipped" | undefined;
1278
+ transcribe?: "pending" | "ready" | "failed" | "skipped" | undefined;
1279
+ waveform?: "pending" | "ready" | "failed" | "skipped" | undefined;
1280
+ } | undefined;
1120
1281
  } | undefined;
1121
- cid?: string | undefined;
1122
1282
  }, {
1123
1283
  uri: string;
1124
- kind: "reply" | "prompt";
1125
- author: {
1126
- id: string;
1127
- handle?: string | null | undefined;
1128
- displayName?: string | null | undefined;
1129
- bio?: string | null | undefined;
1130
- avatarUrl?: string | null | undefined;
1131
- website?: string | null | undefined;
1132
- links?: {
1133
- label: string;
1134
- url: string;
1135
- }[] | undefined;
1136
- createdAt?: unknown;
1137
- bluesky?: {
1138
- handle: string;
1139
- did: string;
1140
- } | undefined;
1141
- stats?: {
1142
- followers?: number | undefined;
1143
- following?: number | undefined;
1144
- prompts?: number | undefined;
1145
- } | undefined;
1146
- badges?: string[] | undefined;
1147
- isVerified?: boolean | undefined;
1148
- };
1284
+ cid: string;
1285
+ authorId: string;
1286
+ kind: "prompt" | "reply";
1149
1287
  record: {
1150
1288
  text: string;
1151
- title?: string | undefined;
1152
1289
  reply?: {
1153
1290
  root: {
1154
1291
  uri: string;
@@ -1159,6 +1296,7 @@ declare const AudioPostViewSchema: z.ZodObject<{
1159
1296
  cid: string;
1160
1297
  };
1161
1298
  } | undefined;
1299
+ title?: string | undefined;
1162
1300
  langs?: string[] | undefined;
1163
1301
  selfLabels?: string[] | undefined;
1164
1302
  createdAt?: unknown;
@@ -1168,22 +1306,28 @@ declare const AudioPostViewSchema: z.ZodObject<{
1168
1306
  canReply?: boolean | undefined;
1169
1307
  replyDisabledReason?: "unauthenticated" | "not_a_participant" | undefined;
1170
1308
  };
1309
+ authorDid?: string | undefined;
1171
1310
  embed?: {
1172
1311
  $type: "dev.antiphony.embed.audio#view";
1173
1312
  url: string;
1313
+ waveform?: number[] | undefined;
1174
1314
  durationMs?: number | undefined;
1175
1315
  alt?: string | undefined;
1176
- waveform?: number[] | undefined;
1177
1316
  transcript?: {
1178
1317
  segments: {
1179
- text: string;
1180
1318
  startMs: number;
1181
1319
  endMs: number;
1320
+ text: string;
1182
1321
  }[];
1183
1322
  text?: string | undefined;
1184
1323
  } | undefined;
1324
+ processing?: {
1325
+ denoise?: "pending" | "ready" | "failed" | "skipped" | undefined;
1326
+ trim?: "pending" | "ready" | "failed" | "skipped" | undefined;
1327
+ transcribe?: "pending" | "ready" | "failed" | "skipped" | undefined;
1328
+ waveform?: "pending" | "ready" | "failed" | "skipped" | undefined;
1329
+ } | undefined;
1185
1330
  } | undefined;
1186
- cid?: string | undefined;
1187
1331
  }>;
1188
1332
  type AudioPostView = z.infer<typeof AudioPostViewSchema>;
1189
1333