@qvac/core 0.10.3 → 0.10.4

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 (46) hide show
  1. package/CHANGELOG.md +37 -1
  2. package/dist-lib/lib/assistant/history.js +18 -2
  3. package/dist-lib/lib/assistant/message.d.ts +17 -0
  4. package/dist-lib/lib/assistant/message.js +28 -0
  5. package/dist-lib/lib/assistant/video-budget.d.ts +13 -0
  6. package/dist-lib/lib/assistant/video-budget.js +29 -0
  7. package/dist-lib/lib/assistant.d.ts +22 -2
  8. package/dist-lib/lib/assistant.js +374 -15
  9. package/dist-lib/lib/core/chat-fork.js +1 -0
  10. package/dist-lib/lib/core/chat-search.js +1 -1
  11. package/dist-lib/lib/core/chunk.d.ts +2 -2
  12. package/dist-lib/lib/core/chunk.js +5 -1
  13. package/dist-lib/lib/core/document-attachment.js +3 -0
  14. package/dist-lib/lib/core/files/index.js +4 -4
  15. package/dist-lib/lib/core/files/records/chunks.js +21 -0
  16. package/dist-lib/lib/core/files/records/purge.js +4 -3
  17. package/dist-lib/lib/core/files/records/source.js +3 -5
  18. package/dist-lib/lib/core/files/upload.js +3 -2
  19. package/dist-lib/lib/core/video/attachment.d.ts +1 -0
  20. package/dist-lib/lib/core/video/attachment.js +7 -0
  21. package/dist-lib/lib/core/video/digest.d.ts +16 -0
  22. package/dist-lib/lib/core/video/digest.js +57 -0
  23. package/dist-lib/lib/core/video/frames.d.ts +32 -0
  24. package/dist-lib/lib/core/video/frames.js +224 -0
  25. package/dist-lib/lib/core.js +19 -1
  26. package/dist-lib/lib/credential-pusher.d.ts +5 -0
  27. package/dist-lib/lib/credential-pusher.js +42 -11
  28. package/dist-lib/lib/run-notices.d.ts +1 -0
  29. package/dist-lib/lib/run-notices.js +2 -1
  30. package/dist-lib/lib/task.js +1 -1
  31. package/dist-lib/schema/engine.js +4 -2
  32. package/dist-lib/schema/indexes.js +2 -2
  33. package/dist-lib/schema/qvac.js +4 -2
  34. package/dist-lib/spec/hrpc/messages.js +16 -6
  35. package/dist-lib/spec/hyperschema/index.js +16 -6
  36. package/dist-lib/spec/hyperschema/schema.json +10 -0
  37. package/dist-lib/spec/hyperschema/types.d.ts +2 -0
  38. package/dist-lib/spec/mesh/hyperdb/messages.js +26 -11
  39. package/dist-lib/spec/mesh/hyperdispatch/messages.js +18 -8
  40. package/dist-lib/spec/mesh/hyperschema/index.js +18 -8
  41. package/dist-lib/spec/mesh/hyperschema/schema.json +11 -1
  42. package/dist-lib/spec/mesh/hyperschema/types.d.ts +3 -1
  43. package/package.json +3 -1
  44. package/tui/app.mjs +34 -1
  45. package/tui/lib/render.mjs +5 -0
  46. package/tui/main.mjs +8 -0
@@ -82,7 +82,8 @@ export function registerQvacTypes(ns) {
82
82
  { name: 'senderMemberId', type: 'fixed32' },
83
83
  { name: 'capability', type: 'string' },
84
84
  { name: 'capabilityArgs', type: 'json' },
85
- { name: 'enhance', type: '@qvac/enhance-mode' }
85
+ { name: 'enhance', type: '@qvac/enhance-mode' },
86
+ { name: 'sourceId', type: 'string' }
86
87
  ]);
87
88
  versioned('chunk-counter', [
88
89
  { name: 'chatId', type: 'string', required: true },
@@ -115,7 +116,8 @@ export function registerQvacTypes(ns) {
115
116
  { name: 'senderMemberId', type: 'fixed32' },
116
117
  { name: 'capability', type: 'string' },
117
118
  { name: 'capabilityArgs', type: 'json' },
118
- { name: 'enhance', type: '@qvac/enhance-mode' }
119
+ { name: 'enhance', type: '@qvac/enhance-mode' },
120
+ { name: 'sourceId', type: 'string' }
119
121
  ]);
120
122
  versioned('update-chunk-operation', [
121
123
  { name: 'id', type: 'string', required: true },
@@ -3681,7 +3681,8 @@ const encoding99 = {
3681
3681
  (m.senderMemberId ? 262144 : 0) |
3682
3682
  (m.capability ? 524288 : 0) |
3683
3683
  (m.capabilityArgs ? 1048576 : 0) |
3684
- (m.enhance ? 2097152 : 0)
3684
+ (m.enhance ? 2097152 : 0) |
3685
+ (m.sourceId ? 4194304 : 0)
3685
3686
 
3686
3687
  c.string.preencode(state, m.id)
3687
3688
  c.string.preencode(state, m.chatId)
@@ -3713,6 +3714,7 @@ const encoding99 = {
3713
3714
  if (m.capability) c.string.preencode(state, m.capability)
3714
3715
  if (m.capabilityArgs) c.json.preencode(state, m.capabilityArgs)
3715
3716
  if (m.enhance) encoding71.preencode(state, m.enhance)
3717
+ if (m.sourceId) c.string.preencode(state, m.sourceId)
3716
3718
  },
3717
3719
  encode(state, m) {
3718
3720
  const flags =
@@ -3737,7 +3739,8 @@ const encoding99 = {
3737
3739
  (m.senderMemberId ? 262144 : 0) |
3738
3740
  (m.capability ? 524288 : 0) |
3739
3741
  (m.capabilityArgs ? 1048576 : 0) |
3740
- (m.enhance ? 2097152 : 0)
3742
+ (m.enhance ? 2097152 : 0) |
3743
+ (m.sourceId ? 4194304 : 0)
3741
3744
 
3742
3745
  c.string.encode(state, m.id)
3743
3746
  c.string.encode(state, m.chatId)
@@ -3769,6 +3772,7 @@ const encoding99 = {
3769
3772
  if (m.capability) c.string.encode(state, m.capability)
3770
3773
  if (m.capabilityArgs) c.json.encode(state, m.capabilityArgs)
3771
3774
  if (m.enhance) encoding71.encode(state, m.enhance)
3775
+ if (m.sourceId) c.string.encode(state, m.sourceId)
3772
3776
  },
3773
3777
  decode(state) {
3774
3778
  const r0 = c.string.decode(state)
@@ -3804,7 +3808,8 @@ const encoding99 = {
3804
3808
  senderMemberId: (flags & 262144) !== 0 ? c.fixed32.decode(state) : null,
3805
3809
  capability: (flags & 524288) !== 0 ? c.string.decode(state) : null,
3806
3810
  capabilityArgs: (flags & 1048576) !== 0 ? c.json.decode(state) : null,
3807
- enhance: (flags & 2097152) !== 0 ? encoding71.decode(state) : null
3811
+ enhance: (flags & 2097152) !== 0 ? encoding71.decode(state) : null,
3812
+ sourceId: (flags & 4194304) !== 0 ? c.string.decode(state) : null
3808
3813
  }
3809
3814
  }
3810
3815
  }
@@ -4449,7 +4454,8 @@ const encoding113 = {
4449
4454
  (m.raw ? 64 : 0) |
4450
4455
  (m.fileId ? 128 : 0) |
4451
4456
  (m.totalBytes ? 256 : 0) |
4452
- (m.meshId ? 512 : 0)
4457
+ (m.meshId ? 512 : 0) |
4458
+ (m.sourceId ? 1024 : 0)
4453
4459
 
4454
4460
  c.uint.preencode(state, flags)
4455
4461
 
@@ -4462,6 +4468,7 @@ const encoding113 = {
4462
4468
  if (m.fileId) c.string.preencode(state, m.fileId)
4463
4469
  if (m.totalBytes) c.uint.preencode(state, m.totalBytes)
4464
4470
  if (m.meshId) c.string.preencode(state, m.meshId)
4471
+ if (m.sourceId) c.string.preencode(state, m.sourceId)
4465
4472
  },
4466
4473
  encode(state, m) {
4467
4474
  const flags =
@@ -4474,7 +4481,8 @@ const encoding113 = {
4474
4481
  (m.raw ? 64 : 0) |
4475
4482
  (m.fileId ? 128 : 0) |
4476
4483
  (m.totalBytes ? 256 : 0) |
4477
- (m.meshId ? 512 : 0)
4484
+ (m.meshId ? 512 : 0) |
4485
+ (m.sourceId ? 1024 : 0)
4478
4486
 
4479
4487
  c.uint.encode(state, flags)
4480
4488
 
@@ -4487,6 +4495,7 @@ const encoding113 = {
4487
4495
  if (m.fileId) c.string.encode(state, m.fileId)
4488
4496
  if (m.totalBytes) c.uint.encode(state, m.totalBytes)
4489
4497
  if (m.meshId) c.string.encode(state, m.meshId)
4498
+ if (m.sourceId) c.string.encode(state, m.sourceId)
4490
4499
  },
4491
4500
  decode(state) {
4492
4501
  const flags = c.uint.decode(state)
@@ -4501,7 +4510,8 @@ const encoding113 = {
4501
4510
  raw: (flags & 64) !== 0,
4502
4511
  fileId: (flags & 128) !== 0 ? c.string.decode(state) : null,
4503
4512
  totalBytes: (flags & 256) !== 0 ? c.uint.decode(state) : 0,
4504
- meshId: (flags & 512) !== 0 ? c.string.decode(state) : null
4513
+ meshId: (flags & 512) !== 0 ? c.string.decode(state) : null,
4514
+ sourceId: (flags & 1024) !== 0 ? c.string.decode(state) : null
4505
4515
  }
4506
4516
  }
4507
4517
  }
@@ -3681,7 +3681,8 @@ const encoding99 = {
3681
3681
  (m.senderMemberId ? 262144 : 0) |
3682
3682
  (m.capability ? 524288 : 0) |
3683
3683
  (m.capabilityArgs ? 1048576 : 0) |
3684
- (m.enhance ? 2097152 : 0)
3684
+ (m.enhance ? 2097152 : 0) |
3685
+ (m.sourceId ? 4194304 : 0)
3685
3686
 
3686
3687
  c.string.preencode(state, m.id)
3687
3688
  c.string.preencode(state, m.chatId)
@@ -3713,6 +3714,7 @@ const encoding99 = {
3713
3714
  if (m.capability) c.string.preencode(state, m.capability)
3714
3715
  if (m.capabilityArgs) c.json.preencode(state, m.capabilityArgs)
3715
3716
  if (m.enhance) encoding71.preencode(state, m.enhance)
3717
+ if (m.sourceId) c.string.preencode(state, m.sourceId)
3716
3718
  },
3717
3719
  encode(state, m) {
3718
3720
  const flags =
@@ -3737,7 +3739,8 @@ const encoding99 = {
3737
3739
  (m.senderMemberId ? 262144 : 0) |
3738
3740
  (m.capability ? 524288 : 0) |
3739
3741
  (m.capabilityArgs ? 1048576 : 0) |
3740
- (m.enhance ? 2097152 : 0)
3742
+ (m.enhance ? 2097152 : 0) |
3743
+ (m.sourceId ? 4194304 : 0)
3741
3744
 
3742
3745
  c.string.encode(state, m.id)
3743
3746
  c.string.encode(state, m.chatId)
@@ -3769,6 +3772,7 @@ const encoding99 = {
3769
3772
  if (m.capability) c.string.encode(state, m.capability)
3770
3773
  if (m.capabilityArgs) c.json.encode(state, m.capabilityArgs)
3771
3774
  if (m.enhance) encoding71.encode(state, m.enhance)
3775
+ if (m.sourceId) c.string.encode(state, m.sourceId)
3772
3776
  },
3773
3777
  decode(state) {
3774
3778
  const r0 = c.string.decode(state)
@@ -3804,7 +3808,8 @@ const encoding99 = {
3804
3808
  senderMemberId: (flags & 262144) !== 0 ? c.fixed32.decode(state) : null,
3805
3809
  capability: (flags & 524288) !== 0 ? c.string.decode(state) : null,
3806
3810
  capabilityArgs: (flags & 1048576) !== 0 ? c.json.decode(state) : null,
3807
- enhance: (flags & 2097152) !== 0 ? encoding71.decode(state) : null
3811
+ enhance: (flags & 2097152) !== 0 ? encoding71.decode(state) : null,
3812
+ sourceId: (flags & 4194304) !== 0 ? c.string.decode(state) : null
3808
3813
  }
3809
3814
  }
3810
3815
  }
@@ -4449,7 +4454,8 @@ const encoding113 = {
4449
4454
  (m.raw ? 64 : 0) |
4450
4455
  (m.fileId ? 128 : 0) |
4451
4456
  (m.totalBytes ? 256 : 0) |
4452
- (m.meshId ? 512 : 0)
4457
+ (m.meshId ? 512 : 0) |
4458
+ (m.sourceId ? 1024 : 0)
4453
4459
 
4454
4460
  c.uint.preencode(state, flags)
4455
4461
 
@@ -4462,6 +4468,7 @@ const encoding113 = {
4462
4468
  if (m.fileId) c.string.preencode(state, m.fileId)
4463
4469
  if (m.totalBytes) c.uint.preencode(state, m.totalBytes)
4464
4470
  if (m.meshId) c.string.preencode(state, m.meshId)
4471
+ if (m.sourceId) c.string.preencode(state, m.sourceId)
4465
4472
  },
4466
4473
  encode(state, m) {
4467
4474
  const flags =
@@ -4474,7 +4481,8 @@ const encoding113 = {
4474
4481
  (m.raw ? 64 : 0) |
4475
4482
  (m.fileId ? 128 : 0) |
4476
4483
  (m.totalBytes ? 256 : 0) |
4477
- (m.meshId ? 512 : 0)
4484
+ (m.meshId ? 512 : 0) |
4485
+ (m.sourceId ? 1024 : 0)
4478
4486
 
4479
4487
  c.uint.encode(state, flags)
4480
4488
 
@@ -4487,6 +4495,7 @@ const encoding113 = {
4487
4495
  if (m.fileId) c.string.encode(state, m.fileId)
4488
4496
  if (m.totalBytes) c.uint.encode(state, m.totalBytes)
4489
4497
  if (m.meshId) c.string.encode(state, m.meshId)
4498
+ if (m.sourceId) c.string.encode(state, m.sourceId)
4490
4499
  },
4491
4500
  decode(state) {
4492
4501
  const flags = c.uint.decode(state)
@@ -4501,7 +4510,8 @@ const encoding113 = {
4501
4510
  raw: (flags & 64) !== 0,
4502
4511
  fileId: (flags & 128) !== 0 ? c.string.decode(state) : null,
4503
4512
  totalBytes: (flags & 256) !== 0 ? c.uint.decode(state) : 0,
4504
- meshId: (flags & 512) !== 0 ? c.string.decode(state) : null
4513
+ meshId: (flags & 512) !== 0 ? c.string.decode(state) : null,
4514
+ sourceId: (flags & 1024) !== 0 ? c.string.decode(state) : null
4505
4515
  }
4506
4516
  }
4507
4517
  }
@@ -2877,6 +2877,11 @@
2877
2877
  "name": "enhance",
2878
2878
  "type": "@assistant/enhance-mode",
2879
2879
  "version": 1
2880
+ },
2881
+ {
2882
+ "name": "sourceId",
2883
+ "type": "string",
2884
+ "version": 1
2880
2885
  }
2881
2886
  ]
2882
2887
  },
@@ -3433,6 +3438,11 @@
3433
3438
  "name": "meshId",
3434
3439
  "type": "string",
3435
3440
  "version": 1
3441
+ },
3442
+ {
3443
+ "name": "sourceId",
3444
+ "type": "string",
3445
+ "version": 1
3436
3446
  }
3437
3447
  ]
3438
3448
  },
@@ -588,6 +588,7 @@ export interface AssistantChunkV1 {
588
588
  capability?: string | null
589
589
  capabilityArgs?: unknown | null
590
590
  enhance?: AssistantEnhanceMode | null
591
+ sourceId?: string | null
591
592
  }
592
593
 
593
594
  export type AssistantChunk = (AssistantChunkV1 & { version?: number })
@@ -701,6 +702,7 @@ export interface AssistantUploadAttachmentRequest {
701
702
  fileId?: string | null
702
703
  totalBytes?: number
703
704
  meshId?: string | null
705
+ sourceId?: string | null
704
706
  }
705
707
 
706
708
  export interface AssistantUploadAttachmentResponse {
@@ -1,12 +1,12 @@
1
1
  // This file is autogenerated by the hyperschema compiler
2
- // Schema Version: 15
2
+ // Schema Version: 16
3
3
  /* eslint-disable camelcase */
4
4
  /* eslint-disable quotes */
5
5
  /* eslint-disable space-before-function-paren */
6
6
 
7
7
  import { c } from 'hyperschema/runtime'
8
8
 
9
- const VERSION = 15
9
+ const VERSION = 16
10
10
 
11
11
  // eslint-disable-next-line no-unused-vars
12
12
  let version = VERSION
@@ -1046,7 +1046,8 @@ const encoding27 = {
1046
1046
  ((version >= 8 && m.senderMemberId) ? 262144 : 0) |
1047
1047
  ((version >= 10 && m.capability) ? 524288 : 0) |
1048
1048
  ((version >= 10 && m.capabilityArgs) ? 1048576 : 0) |
1049
- ((version >= 10 && m.enhance) ? 2097152 : 0)
1049
+ ((version >= 10 && m.enhance) ? 2097152 : 0) |
1050
+ ((version >= 16 && m.sourceId) ? 4194304 : 0)
1050
1051
 
1051
1052
  c.string.preencode(state, m.id)
1052
1053
  c.string.preencode(state, m.chatId)
@@ -1078,6 +1079,7 @@ const encoding27 = {
1078
1079
  if (version >= 10 && m.capability) c.string.preencode(state, m.capability)
1079
1080
  if (version >= 10 && m.capabilityArgs) c.json.preencode(state, m.capabilityArgs)
1080
1081
  if (version >= 10 && m.enhance) encoding141.preencode(state, m.enhance)
1082
+ if (version >= 16 && m.sourceId) c.string.preencode(state, m.sourceId)
1081
1083
  },
1082
1084
  encode(state, m) {
1083
1085
  const flags =
@@ -1102,7 +1104,8 @@ const encoding27 = {
1102
1104
  ((version >= 8 && m.senderMemberId) ? 262144 : 0) |
1103
1105
  ((version >= 10 && m.capability) ? 524288 : 0) |
1104
1106
  ((version >= 10 && m.capabilityArgs) ? 1048576 : 0) |
1105
- ((version >= 10 && m.enhance) ? 2097152 : 0)
1107
+ ((version >= 10 && m.enhance) ? 2097152 : 0) |
1108
+ ((version >= 16 && m.sourceId) ? 4194304 : 0)
1106
1109
 
1107
1110
  c.string.encode(state, m.id)
1108
1111
  c.string.encode(state, m.chatId)
@@ -1134,6 +1137,7 @@ const encoding27 = {
1134
1137
  if (version >= 10 && m.capability) c.string.encode(state, m.capability)
1135
1138
  if (version >= 10 && m.capabilityArgs) c.json.encode(state, m.capabilityArgs)
1136
1139
  if (version >= 10 && m.enhance) encoding141.encode(state, m.enhance)
1140
+ if (version >= 16 && m.sourceId) c.string.encode(state, m.sourceId)
1137
1141
  },
1138
1142
  decode(state) {
1139
1143
  const r0 = c.string.decode(state)
@@ -1169,7 +1173,8 @@ const encoding27 = {
1169
1173
  senderMemberId: (version >= 8 && (flags & 262144) !== 0) ? c.fixed32.decode(state) : null,
1170
1174
  capability: (version >= 10 && (flags & 524288) !== 0) ? c.string.decode(state) : null,
1171
1175
  capabilityArgs: (version >= 10 && (flags & 1048576) !== 0) ? c.json.decode(state) : null,
1172
- enhance: (version >= 10 && (flags & 2097152) !== 0) ? encoding141.decode(state) : null
1176
+ enhance: (version >= 10 && (flags & 2097152) !== 0) ? encoding141.decode(state) : null,
1177
+ sourceId: (version >= 16 && (flags & 4194304) !== 0) ? c.string.decode(state) : null
1173
1178
  }
1174
1179
  }
1175
1180
  }
@@ -1312,7 +1317,8 @@ const encoding31 = {
1312
1317
  ((version >= 8 && m.senderMemberId) ? 131072 : 0) |
1313
1318
  ((version >= 10 && m.capability) ? 262144 : 0) |
1314
1319
  ((version >= 10 && m.capabilityArgs) ? 524288 : 0) |
1315
- ((version >= 10 && m.enhance) ? 1048576 : 0)
1320
+ ((version >= 10 && m.enhance) ? 1048576 : 0) |
1321
+ ((version >= 16 && m.sourceId) ? 2097152 : 0)
1316
1322
 
1317
1323
  c.string.preencode(state, m.id)
1318
1324
  c.string.preencode(state, m.chatId)
@@ -1342,6 +1348,7 @@ const encoding31 = {
1342
1348
  if (version >= 10 && m.capability) c.string.preencode(state, m.capability)
1343
1349
  if (version >= 10 && m.capabilityArgs) c.json.preencode(state, m.capabilityArgs)
1344
1350
  if (version >= 10 && m.enhance) encoding141.preencode(state, m.enhance)
1351
+ if (version >= 16 && m.sourceId) c.string.preencode(state, m.sourceId)
1345
1352
  },
1346
1353
  encode(state, m) {
1347
1354
  const flags =
@@ -1365,7 +1372,8 @@ const encoding31 = {
1365
1372
  ((version >= 8 && m.senderMemberId) ? 131072 : 0) |
1366
1373
  ((version >= 10 && m.capability) ? 262144 : 0) |
1367
1374
  ((version >= 10 && m.capabilityArgs) ? 524288 : 0) |
1368
- ((version >= 10 && m.enhance) ? 1048576 : 0)
1375
+ ((version >= 10 && m.enhance) ? 1048576 : 0) |
1376
+ ((version >= 16 && m.sourceId) ? 2097152 : 0)
1369
1377
 
1370
1378
  c.string.encode(state, m.id)
1371
1379
  c.string.encode(state, m.chatId)
@@ -1395,6 +1403,7 @@ const encoding31 = {
1395
1403
  if (version >= 10 && m.capability) c.string.encode(state, m.capability)
1396
1404
  if (version >= 10 && m.capabilityArgs) c.json.encode(state, m.capabilityArgs)
1397
1405
  if (version >= 10 && m.enhance) encoding141.encode(state, m.enhance)
1406
+ if (version >= 16 && m.sourceId) c.string.encode(state, m.sourceId)
1398
1407
  },
1399
1408
  decode(state) {
1400
1409
  const r0 = c.string.decode(state)
@@ -1428,7 +1437,8 @@ const encoding31 = {
1428
1437
  senderMemberId: (version >= 8 && (flags & 131072) !== 0) ? c.fixed32.decode(state) : null,
1429
1438
  capability: (version >= 10 && (flags & 262144) !== 0) ? c.string.decode(state) : null,
1430
1439
  capabilityArgs: (version >= 10 && (flags & 524288) !== 0) ? c.json.decode(state) : null,
1431
- enhance: (version >= 10 && (flags & 1048576) !== 0) ? encoding141.decode(state) : null
1440
+ enhance: (version >= 10 && (flags & 1048576) !== 0) ? encoding141.decode(state) : null,
1441
+ sourceId: (version >= 16 && (flags & 2097152) !== 0) ? c.string.decode(state) : null
1432
1442
  }
1433
1443
  }
1434
1444
  }
@@ -7124,7 +7134,8 @@ const encoding179 = {
7124
7134
  ((version >= 8 && m.senderMemberId) ? 262144 : 0) |
7125
7135
  ((version >= 10 && m.capability) ? 524288 : 0) |
7126
7136
  ((version >= 10 && m.capabilityArgs) ? 1048576 : 0) |
7127
- ((version >= 10 && m.enhance) ? 2097152 : 0)
7137
+ ((version >= 10 && m.enhance) ? 2097152 : 0) |
7138
+ ((version >= 16 && m.sourceId) ? 4194304 : 0)
7128
7139
 
7129
7140
  c.string.preencode(state, m.chatId)
7130
7141
  c.uint.preencode(state, flags)
@@ -7155,6 +7166,7 @@ const encoding179 = {
7155
7166
  if (version >= 10 && m.capability) c.string.preencode(state, m.capability)
7156
7167
  if (version >= 10 && m.capabilityArgs) c.json.preencode(state, m.capabilityArgs)
7157
7168
  if (version >= 10 && m.enhance) encoding141.preencode(state, m.enhance)
7169
+ if (version >= 16 && m.sourceId) c.string.preencode(state, m.sourceId)
7158
7170
  },
7159
7171
  encode(state, m) {
7160
7172
  const flags =
@@ -7179,7 +7191,8 @@ const encoding179 = {
7179
7191
  ((version >= 8 && m.senderMemberId) ? 262144 : 0) |
7180
7192
  ((version >= 10 && m.capability) ? 524288 : 0) |
7181
7193
  ((version >= 10 && m.capabilityArgs) ? 1048576 : 0) |
7182
- ((version >= 10 && m.enhance) ? 2097152 : 0)
7194
+ ((version >= 10 && m.enhance) ? 2097152 : 0) |
7195
+ ((version >= 16 && m.sourceId) ? 4194304 : 0)
7183
7196
 
7184
7197
  c.string.encode(state, m.chatId)
7185
7198
  c.uint.encode(state, flags)
@@ -7210,6 +7223,7 @@ const encoding179 = {
7210
7223
  if (version >= 10 && m.capability) c.string.encode(state, m.capability)
7211
7224
  if (version >= 10 && m.capabilityArgs) c.json.encode(state, m.capabilityArgs)
7212
7225
  if (version >= 10 && m.enhance) encoding141.encode(state, m.enhance)
7226
+ if (version >= 16 && m.sourceId) c.string.encode(state, m.sourceId)
7213
7227
  },
7214
7228
  decode(state) {
7215
7229
  const r1 = c.string.decode(state)
@@ -7244,7 +7258,8 @@ const encoding179 = {
7244
7258
  senderMemberId: (version >= 8 && (flags & 262144) !== 0) ? c.fixed32.decode(state) : null,
7245
7259
  capability: (version >= 10 && (flags & 524288) !== 0) ? c.string.decode(state) : null,
7246
7260
  capabilityArgs: (version >= 10 && (flags & 1048576) !== 0) ? c.json.decode(state) : null,
7247
- enhance: (version >= 10 && (flags & 2097152) !== 0) ? encoding141.decode(state) : null
7261
+ enhance: (version >= 10 && (flags & 2097152) !== 0) ? encoding141.decode(state) : null,
7262
+ sourceId: (version >= 16 && (flags & 4194304) !== 0) ? c.string.decode(state) : null
7248
7263
  }
7249
7264
  }
7250
7265
  }
@@ -1,12 +1,12 @@
1
1
  // This file is autogenerated by the hyperschema compiler
2
- // Schema Version: 15
2
+ // Schema Version: 16
3
3
  /* eslint-disable camelcase */
4
4
  /* eslint-disable quotes */
5
5
  /* eslint-disable space-before-function-paren */
6
6
 
7
7
  import { c } from 'hyperschema/runtime'
8
8
 
9
- const VERSION = 15
9
+ const VERSION = 16
10
10
 
11
11
  // eslint-disable-next-line no-unused-vars
12
12
  let version = VERSION
@@ -1046,7 +1046,8 @@ const encoding27 = {
1046
1046
  ((version >= 8 && m.senderMemberId) ? 262144 : 0) |
1047
1047
  ((version >= 10 && m.capability) ? 524288 : 0) |
1048
1048
  ((version >= 10 && m.capabilityArgs) ? 1048576 : 0) |
1049
- ((version >= 10 && m.enhance) ? 2097152 : 0)
1049
+ ((version >= 10 && m.enhance) ? 2097152 : 0) |
1050
+ ((version >= 16 && m.sourceId) ? 4194304 : 0)
1050
1051
 
1051
1052
  c.string.preencode(state, m.id)
1052
1053
  c.string.preencode(state, m.chatId)
@@ -1078,6 +1079,7 @@ const encoding27 = {
1078
1079
  if (version >= 10 && m.capability) c.string.preencode(state, m.capability)
1079
1080
  if (version >= 10 && m.capabilityArgs) c.json.preencode(state, m.capabilityArgs)
1080
1081
  if (version >= 10 && m.enhance) encoding141.preencode(state, m.enhance)
1082
+ if (version >= 16 && m.sourceId) c.string.preencode(state, m.sourceId)
1081
1083
  },
1082
1084
  encode(state, m) {
1083
1085
  const flags =
@@ -1102,7 +1104,8 @@ const encoding27 = {
1102
1104
  ((version >= 8 && m.senderMemberId) ? 262144 : 0) |
1103
1105
  ((version >= 10 && m.capability) ? 524288 : 0) |
1104
1106
  ((version >= 10 && m.capabilityArgs) ? 1048576 : 0) |
1105
- ((version >= 10 && m.enhance) ? 2097152 : 0)
1107
+ ((version >= 10 && m.enhance) ? 2097152 : 0) |
1108
+ ((version >= 16 && m.sourceId) ? 4194304 : 0)
1106
1109
 
1107
1110
  c.string.encode(state, m.id)
1108
1111
  c.string.encode(state, m.chatId)
@@ -1134,6 +1137,7 @@ const encoding27 = {
1134
1137
  if (version >= 10 && m.capability) c.string.encode(state, m.capability)
1135
1138
  if (version >= 10 && m.capabilityArgs) c.json.encode(state, m.capabilityArgs)
1136
1139
  if (version >= 10 && m.enhance) encoding141.encode(state, m.enhance)
1140
+ if (version >= 16 && m.sourceId) c.string.encode(state, m.sourceId)
1137
1141
  },
1138
1142
  decode(state) {
1139
1143
  const r0 = c.string.decode(state)
@@ -1169,7 +1173,8 @@ const encoding27 = {
1169
1173
  senderMemberId: (version >= 8 && (flags & 262144) !== 0) ? c.fixed32.decode(state) : null,
1170
1174
  capability: (version >= 10 && (flags & 524288) !== 0) ? c.string.decode(state) : null,
1171
1175
  capabilityArgs: (version >= 10 && (flags & 1048576) !== 0) ? c.json.decode(state) : null,
1172
- enhance: (version >= 10 && (flags & 2097152) !== 0) ? encoding141.decode(state) : null
1176
+ enhance: (version >= 10 && (flags & 2097152) !== 0) ? encoding141.decode(state) : null,
1177
+ sourceId: (version >= 16 && (flags & 4194304) !== 0) ? c.string.decode(state) : null
1173
1178
  }
1174
1179
  }
1175
1180
  }
@@ -1312,7 +1317,8 @@ const encoding31 = {
1312
1317
  ((version >= 8 && m.senderMemberId) ? 131072 : 0) |
1313
1318
  ((version >= 10 && m.capability) ? 262144 : 0) |
1314
1319
  ((version >= 10 && m.capabilityArgs) ? 524288 : 0) |
1315
- ((version >= 10 && m.enhance) ? 1048576 : 0)
1320
+ ((version >= 10 && m.enhance) ? 1048576 : 0) |
1321
+ ((version >= 16 && m.sourceId) ? 2097152 : 0)
1316
1322
 
1317
1323
  c.string.preencode(state, m.id)
1318
1324
  c.string.preencode(state, m.chatId)
@@ -1342,6 +1348,7 @@ const encoding31 = {
1342
1348
  if (version >= 10 && m.capability) c.string.preencode(state, m.capability)
1343
1349
  if (version >= 10 && m.capabilityArgs) c.json.preencode(state, m.capabilityArgs)
1344
1350
  if (version >= 10 && m.enhance) encoding141.preencode(state, m.enhance)
1351
+ if (version >= 16 && m.sourceId) c.string.preencode(state, m.sourceId)
1345
1352
  },
1346
1353
  encode(state, m) {
1347
1354
  const flags =
@@ -1365,7 +1372,8 @@ const encoding31 = {
1365
1372
  ((version >= 8 && m.senderMemberId) ? 131072 : 0) |
1366
1373
  ((version >= 10 && m.capability) ? 262144 : 0) |
1367
1374
  ((version >= 10 && m.capabilityArgs) ? 524288 : 0) |
1368
- ((version >= 10 && m.enhance) ? 1048576 : 0)
1375
+ ((version >= 10 && m.enhance) ? 1048576 : 0) |
1376
+ ((version >= 16 && m.sourceId) ? 2097152 : 0)
1369
1377
 
1370
1378
  c.string.encode(state, m.id)
1371
1379
  c.string.encode(state, m.chatId)
@@ -1395,6 +1403,7 @@ const encoding31 = {
1395
1403
  if (version >= 10 && m.capability) c.string.encode(state, m.capability)
1396
1404
  if (version >= 10 && m.capabilityArgs) c.json.encode(state, m.capabilityArgs)
1397
1405
  if (version >= 10 && m.enhance) encoding141.encode(state, m.enhance)
1406
+ if (version >= 16 && m.sourceId) c.string.encode(state, m.sourceId)
1398
1407
  },
1399
1408
  decode(state) {
1400
1409
  const r0 = c.string.decode(state)
@@ -1428,7 +1437,8 @@ const encoding31 = {
1428
1437
  senderMemberId: (version >= 8 && (flags & 131072) !== 0) ? c.fixed32.decode(state) : null,
1429
1438
  capability: (version >= 10 && (flags & 262144) !== 0) ? c.string.decode(state) : null,
1430
1439
  capabilityArgs: (version >= 10 && (flags & 524288) !== 0) ? c.json.decode(state) : null,
1431
- enhance: (version >= 10 && (flags & 1048576) !== 0) ? encoding141.decode(state) : null
1440
+ enhance: (version >= 10 && (flags & 1048576) !== 0) ? encoding141.decode(state) : null,
1441
+ sourceId: (version >= 16 && (flags & 2097152) !== 0) ? c.string.decode(state) : null
1432
1442
  }
1433
1443
  }
1434
1444
  }
@@ -1,12 +1,12 @@
1
1
  // This file is autogenerated by the hyperschema compiler
2
- // Schema Version: 15
2
+ // Schema Version: 16
3
3
  /* eslint-disable camelcase */
4
4
  /* eslint-disable quotes */
5
5
  /* eslint-disable space-before-function-paren */
6
6
 
7
7
  import { c } from 'hyperschema/runtime'
8
8
 
9
- const VERSION = 15
9
+ const VERSION = 16
10
10
 
11
11
  // eslint-disable-next-line no-unused-vars
12
12
  let version = VERSION
@@ -1046,7 +1046,8 @@ const encoding27 = {
1046
1046
  ((version >= 8 && m.senderMemberId) ? 262144 : 0) |
1047
1047
  ((version >= 10 && m.capability) ? 524288 : 0) |
1048
1048
  ((version >= 10 && m.capabilityArgs) ? 1048576 : 0) |
1049
- ((version >= 10 && m.enhance) ? 2097152 : 0)
1049
+ ((version >= 10 && m.enhance) ? 2097152 : 0) |
1050
+ ((version >= 16 && m.sourceId) ? 4194304 : 0)
1050
1051
 
1051
1052
  c.string.preencode(state, m.id)
1052
1053
  c.string.preencode(state, m.chatId)
@@ -1078,6 +1079,7 @@ const encoding27 = {
1078
1079
  if (version >= 10 && m.capability) c.string.preencode(state, m.capability)
1079
1080
  if (version >= 10 && m.capabilityArgs) c.json.preencode(state, m.capabilityArgs)
1080
1081
  if (version >= 10 && m.enhance) encoding141.preencode(state, m.enhance)
1082
+ if (version >= 16 && m.sourceId) c.string.preencode(state, m.sourceId)
1081
1083
  },
1082
1084
  encode(state, m) {
1083
1085
  const flags =
@@ -1102,7 +1104,8 @@ const encoding27 = {
1102
1104
  ((version >= 8 && m.senderMemberId) ? 262144 : 0) |
1103
1105
  ((version >= 10 && m.capability) ? 524288 : 0) |
1104
1106
  ((version >= 10 && m.capabilityArgs) ? 1048576 : 0) |
1105
- ((version >= 10 && m.enhance) ? 2097152 : 0)
1107
+ ((version >= 10 && m.enhance) ? 2097152 : 0) |
1108
+ ((version >= 16 && m.sourceId) ? 4194304 : 0)
1106
1109
 
1107
1110
  c.string.encode(state, m.id)
1108
1111
  c.string.encode(state, m.chatId)
@@ -1134,6 +1137,7 @@ const encoding27 = {
1134
1137
  if (version >= 10 && m.capability) c.string.encode(state, m.capability)
1135
1138
  if (version >= 10 && m.capabilityArgs) c.json.encode(state, m.capabilityArgs)
1136
1139
  if (version >= 10 && m.enhance) encoding141.encode(state, m.enhance)
1140
+ if (version >= 16 && m.sourceId) c.string.encode(state, m.sourceId)
1137
1141
  },
1138
1142
  decode(state) {
1139
1143
  const r0 = c.string.decode(state)
@@ -1169,7 +1173,8 @@ const encoding27 = {
1169
1173
  senderMemberId: (version >= 8 && (flags & 262144) !== 0) ? c.fixed32.decode(state) : null,
1170
1174
  capability: (version >= 10 && (flags & 524288) !== 0) ? c.string.decode(state) : null,
1171
1175
  capabilityArgs: (version >= 10 && (flags & 1048576) !== 0) ? c.json.decode(state) : null,
1172
- enhance: (version >= 10 && (flags & 2097152) !== 0) ? encoding141.decode(state) : null
1176
+ enhance: (version >= 10 && (flags & 2097152) !== 0) ? encoding141.decode(state) : null,
1177
+ sourceId: (version >= 16 && (flags & 4194304) !== 0) ? c.string.decode(state) : null
1173
1178
  }
1174
1179
  }
1175
1180
  }
@@ -1312,7 +1317,8 @@ const encoding31 = {
1312
1317
  ((version >= 8 && m.senderMemberId) ? 131072 : 0) |
1313
1318
  ((version >= 10 && m.capability) ? 262144 : 0) |
1314
1319
  ((version >= 10 && m.capabilityArgs) ? 524288 : 0) |
1315
- ((version >= 10 && m.enhance) ? 1048576 : 0)
1320
+ ((version >= 10 && m.enhance) ? 1048576 : 0) |
1321
+ ((version >= 16 && m.sourceId) ? 2097152 : 0)
1316
1322
 
1317
1323
  c.string.preencode(state, m.id)
1318
1324
  c.string.preencode(state, m.chatId)
@@ -1342,6 +1348,7 @@ const encoding31 = {
1342
1348
  if (version >= 10 && m.capability) c.string.preencode(state, m.capability)
1343
1349
  if (version >= 10 && m.capabilityArgs) c.json.preencode(state, m.capabilityArgs)
1344
1350
  if (version >= 10 && m.enhance) encoding141.preencode(state, m.enhance)
1351
+ if (version >= 16 && m.sourceId) c.string.preencode(state, m.sourceId)
1345
1352
  },
1346
1353
  encode(state, m) {
1347
1354
  const flags =
@@ -1365,7 +1372,8 @@ const encoding31 = {
1365
1372
  ((version >= 8 && m.senderMemberId) ? 131072 : 0) |
1366
1373
  ((version >= 10 && m.capability) ? 262144 : 0) |
1367
1374
  ((version >= 10 && m.capabilityArgs) ? 524288 : 0) |
1368
- ((version >= 10 && m.enhance) ? 1048576 : 0)
1375
+ ((version >= 10 && m.enhance) ? 1048576 : 0) |
1376
+ ((version >= 16 && m.sourceId) ? 2097152 : 0)
1369
1377
 
1370
1378
  c.string.encode(state, m.id)
1371
1379
  c.string.encode(state, m.chatId)
@@ -1395,6 +1403,7 @@ const encoding31 = {
1395
1403
  if (version >= 10 && m.capability) c.string.encode(state, m.capability)
1396
1404
  if (version >= 10 && m.capabilityArgs) c.json.encode(state, m.capabilityArgs)
1397
1405
  if (version >= 10 && m.enhance) encoding141.encode(state, m.enhance)
1406
+ if (version >= 16 && m.sourceId) c.string.encode(state, m.sourceId)
1398
1407
  },
1399
1408
  decode(state) {
1400
1409
  const r0 = c.string.decode(state)
@@ -1428,7 +1437,8 @@ const encoding31 = {
1428
1437
  senderMemberId: (version >= 8 && (flags & 131072) !== 0) ? c.fixed32.decode(state) : null,
1429
1438
  capability: (version >= 10 && (flags & 262144) !== 0) ? c.string.decode(state) : null,
1430
1439
  capabilityArgs: (version >= 10 && (flags & 524288) !== 0) ? c.json.decode(state) : null,
1431
- enhance: (version >= 10 && (flags & 1048576) !== 0) ? encoding141.decode(state) : null
1440
+ enhance: (version >= 10 && (flags & 1048576) !== 0) ? encoding141.decode(state) : null,
1441
+ sourceId: (version >= 16 && (flags & 2097152) !== 0) ? c.string.decode(state) : null
1432
1442
  }
1433
1443
  }
1434
1444
  }
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": 15,
2
+ "version": 16,
3
3
  "schema": [
4
4
  {
5
5
  "name": "chunk-type",
@@ -743,6 +743,11 @@
743
743
  "name": "enhance",
744
744
  "type": "@qvac/enhance-mode",
745
745
  "version": 10
746
+ },
747
+ {
748
+ "name": "sourceId",
749
+ "type": "string",
750
+ "version": 16
746
751
  }
747
752
  ]
748
753
  },
@@ -935,6 +940,11 @@
935
940
  "name": "enhance",
936
941
  "type": "@qvac/enhance-mode",
937
942
  "version": 10
943
+ },
944
+ {
945
+ "name": "sourceId",
946
+ "type": "string",
947
+ "version": 16
938
948
  }
939
949
  ]
940
950
  },
@@ -1,5 +1,5 @@
1
1
  // This file is autogenerated by hyperschema-ts
2
- // Schema version: 15
2
+ // Schema version: 16
3
3
  // Do not edit manually.
4
4
 
5
5
  export type QvacChunkType = "user-message" | "content" | "thinking" | "tool-call" | "tool-result" | "attachment" | "approval-request" | "run-status" | "run-request" | "sources" | "compaction"
@@ -140,6 +140,7 @@ export interface QvacChunkV1 {
140
140
  capability?: string | null
141
141
  capabilityArgs?: unknown | null
142
142
  enhance?: QvacEnhanceMode | null
143
+ sourceId?: string | null
143
144
  }
144
145
 
145
146
  export type QvacChunk = (QvacChunkV1 & { version?: number })
@@ -179,6 +180,7 @@ export interface QvacAppendChunkOperationV1 {
179
180
  capability?: string | null
180
181
  capabilityArgs?: unknown | null
181
182
  enhance?: QvacEnhanceMode | null
183
+ sourceId?: string | null
182
184
  }
183
185
 
184
186
  export type QvacAppendChunkOperation = (QvacAppendChunkOperationV1 & { version?: number })
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@qvac/core",
3
- "version": "0.10.3",
3
+ "version": "0.10.4",
4
4
  "type": "module",
5
5
  "description": "Peer-to-peer AI across your devices",
6
6
  "engines": {
@@ -253,11 +253,13 @@
253
253
  "bare-crypto": "^1.15.3",
254
254
  "bare-events": "^2.9.1",
255
255
  "bare-fetch": "^3.0.1",
256
+ "bare-ffmpeg": "^1.5.0",
256
257
  "bare-file-logger": "^1.2.1",
257
258
  "bare-fs": "^4.7.2",
258
259
  "bare-gpu-info": "^0.1.0",
259
260
  "bare-http1": "4.6.1",
260
261
  "bare-media": "^2.10.0",
262
+ "bare-module": "~7.4.0",
261
263
  "bare-os": "^3.9.1",
262
264
  "bare-path": "^3.0.1",
263
265
  "bare-pdfium": "^1.5.5",