@qvac/harness 0.2.12 → 0.3.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.
Files changed (74) hide show
  1. package/CHANGELOG.md +213 -0
  2. package/dist/harness.bundle +16 -13
  3. package/dist-lib/index.d.ts +12 -2
  4. package/dist-lib/index.js +66 -5
  5. package/dist-lib/lib/capabilities/completion.d.ts +5 -0
  6. package/dist-lib/lib/capabilities/completion.js +17 -5
  7. package/dist-lib/lib/capabilities/enhance.d.ts +10 -0
  8. package/dist-lib/lib/capabilities/enhance.js +29 -0
  9. package/dist-lib/lib/capabilities/invoke.d.ts +11 -2
  10. package/dist-lib/lib/capabilities/invoke.js +32 -8
  11. package/dist-lib/lib/connect.js +1 -0
  12. package/dist-lib/lib/contract-types.d.ts +1 -0
  13. package/dist-lib/lib/helpers/clean-answer.d.ts +1 -0
  14. package/dist-lib/lib/helpers/clean-answer.js +16 -0
  15. package/dist-lib/lib/helpers/load-stall.d.ts +6 -0
  16. package/dist-lib/lib/helpers/load-stall.js +24 -0
  17. package/dist-lib/lib/helpers/tool-call-markup.js +15 -7
  18. package/dist-lib/lib/models/model-pool.d.ts +6 -0
  19. package/dist-lib/lib/models/model-pool.js +12 -0
  20. package/dist-lib/lib/models/nmt-catalog.d.ts +34 -0
  21. package/dist-lib/lib/models/nmt-catalog.js +166 -0
  22. package/dist-lib/lib/no-redirect-fetch-impl.d.ts +3 -2
  23. package/dist-lib/lib/no-redirect-fetch-impl.js +4 -1
  24. package/dist-lib/lib/serve.js +1 -0
  25. package/dist-lib/lib/tools/exec/adapters/adapter.d.ts +2 -0
  26. package/dist-lib/lib/tools/exec/adapters/python/distributions.d.ts +1 -0
  27. package/dist-lib/lib/tools/exec/adapters/python/distributions.js +4 -0
  28. package/dist-lib/lib/tools/exec/adapters/python/guarded-fetch.d.ts +67 -0
  29. package/dist-lib/lib/tools/exec/adapters/python/guarded-fetch.js +196 -0
  30. package/dist-lib/lib/tools/exec/adapters/python/loader.js +2 -1
  31. package/dist-lib/lib/tools/exec/adapters/python/module-distributions.d.ts +1 -0
  32. package/dist-lib/lib/tools/exec/adapters/python/module-distributions.js +52 -0
  33. package/dist-lib/lib/tools/exec/adapters/python/net-shim.d.ts +2 -0
  34. package/dist-lib/lib/tools/exec/adapters/python/net-shim.js +148 -0
  35. package/dist-lib/lib/tools/exec/adapters/python/output-policy.js +13 -1
  36. package/dist-lib/lib/tools/exec/adapters/python/pyodide.d.ts +1 -0
  37. package/dist-lib/lib/tools/exec/adapters/python/pyodide.js +1 -0
  38. package/dist-lib/lib/tools/exec/adapters/python/python-adapter.d.ts +9 -3
  39. package/dist-lib/lib/tools/exec/adapters/python/python-adapter.js +130 -20
  40. package/dist-lib/lib/tools/exec/adapters/python/run-session.d.ts +3 -0
  41. package/dist-lib/lib/tools/exec/adapters/python/run-session.js +25 -8
  42. package/dist-lib/lib/tools/exec/adapters/python/wheels.d.ts +6 -0
  43. package/dist-lib/lib/tools/exec/adapters/python/wheels.js +17 -3
  44. package/dist-lib/lib/tools/exec/adapters/shell/shell-adapter.js +7 -1
  45. package/dist-lib/lib/tools/exec/shell-guidance.d.ts +10 -0
  46. package/dist-lib/lib/tools/exec/shell-guidance.js +123 -0
  47. package/dist-lib/lib/tools/exec/video-tools.d.ts +5 -0
  48. package/dist-lib/lib/tools/exec/video-tools.js +40 -0
  49. package/dist-lib/lib/tools/exec.d.ts +2 -1
  50. package/dist-lib/lib/tools/exec.js +59 -32
  51. package/dist-lib/lib/tools/generate-image.js +2 -25
  52. package/dist-lib/lib/tools/http-request/truncate-response.d.ts +1 -0
  53. package/dist-lib/lib/tools/http-request/truncate-response.js +1 -1
  54. package/dist-lib/lib/tools/http-request.js +4 -1
  55. package/dist-lib/lib/tools/operations/builders.d.ts +1 -1
  56. package/dist-lib/lib/tools/operations/builders.js +9 -0
  57. package/dist-lib/lib/tools/operations/compile.js +41 -18
  58. package/dist-lib/lib/tools/operations/decoders.d.ts +6 -0
  59. package/dist-lib/lib/tools/operations/decoders.js +82 -0
  60. package/dist-lib/lib/tools/operations/manifest.d.ts +16 -2
  61. package/dist-lib/lib/tools/operations/manifest.js +6 -1
  62. package/dist-lib/lib/tools/skill.d.ts +3 -0
  63. package/dist-lib/lib/tools/skill.js +38 -5
  64. package/dist-lib/lib/tools/skills/manifest-parse.js +43 -1
  65. package/dist-lib/lib/tools/skills/manifest.d.ts +13 -0
  66. package/dist-lib/lib/tools/translate.d.ts +78 -0
  67. package/dist-lib/lib/tools/translate.js +228 -0
  68. package/dist-lib/schema/harness.js +22 -2
  69. package/dist-lib/spec/hrpc/messages.js +101 -8
  70. package/dist-lib/spec/hyperschema/index.js +101 -8
  71. package/dist-lib/spec/hyperschema/schema.json +71 -1
  72. package/dist-lib/spec/hyperschema/types.d.ts +19 -1
  73. package/package.json +35 -2
  74. package/wheels/manifest.json +15 -0
@@ -1,12 +1,12 @@
1
1
  // This file is autogenerated by the hyperschema compiler
2
- // Schema Version: 11
2
+ // Schema Version: 13
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 = 11
9
+ const VERSION = 13
10
10
 
11
11
  // eslint-disable-next-line no-unused-vars
12
12
  let version = VERSION
@@ -490,7 +490,8 @@ const encoding11 = {
490
490
  ((version >= 5 && m.grantedWriteDirs) ? 16777216 : 0) |
491
491
  ((version >= 9 && m.captureInferenceCalls) ? 33554432 : 0) |
492
492
  ((version >= 11 && m.capability) ? 67108864 : 0) |
493
- ((version >= 11 && m.arguments) ? 134217728 : 0)
493
+ ((version >= 11 && m.arguments) ? 134217728 : 0) |
494
+ ((version >= 12 && m.enhance) ? 268435456 : 0)
494
495
 
495
496
  encoding10.preencode(state, m.type)
496
497
  c.uint.preencode(state, flags)
@@ -520,6 +521,7 @@ const encoding11 = {
520
521
  if (version >= 5 && m.grantedWriteDirs) encoding11_25.preencode(state, m.grantedWriteDirs)
521
522
  if (version >= 11 && m.capability) c.string.preencode(state, m.capability)
522
523
  if (version >= 11 && m.arguments) c.json.preencode(state, m.arguments)
524
+ if (version >= 12 && m.enhance) c.string.preencode(state, m.enhance)
523
525
  },
524
526
  encode(state, m) {
525
527
  const flags =
@@ -550,7 +552,8 @@ const encoding11 = {
550
552
  ((version >= 5 && m.grantedWriteDirs) ? 16777216 : 0) |
551
553
  ((version >= 9 && m.captureInferenceCalls) ? 33554432 : 0) |
552
554
  ((version >= 11 && m.capability) ? 67108864 : 0) |
553
- ((version >= 11 && m.arguments) ? 134217728 : 0)
555
+ ((version >= 11 && m.arguments) ? 134217728 : 0) |
556
+ ((version >= 12 && m.enhance) ? 268435456 : 0)
554
557
 
555
558
  encoding10.encode(state, m.type)
556
559
  c.uint.encode(state, flags)
@@ -580,6 +583,7 @@ const encoding11 = {
580
583
  if (version >= 5 && m.grantedWriteDirs) encoding11_25.encode(state, m.grantedWriteDirs)
581
584
  if (version >= 11 && m.capability) c.string.encode(state, m.capability)
582
585
  if (version >= 11 && m.arguments) c.json.encode(state, m.arguments)
586
+ if (version >= 12 && m.enhance) c.string.encode(state, m.enhance)
583
587
  },
584
588
  decode(state) {
585
589
  const r0 = encoding10.decode(state)
@@ -614,7 +618,8 @@ const encoding11 = {
614
618
  grantedWriteDirs: (version >= 5 && (flags & 16777216) !== 0) ? encoding11_25.decode(state) : null,
615
619
  captureInferenceCalls: (version >= 9 && (flags & 33554432) !== 0),
616
620
  capability: (version >= 11 && (flags & 67108864) !== 0) ? c.string.decode(state) : null,
617
- arguments: (version >= 11 && (flags & 134217728) !== 0) ? c.json.decode(state) : null
621
+ arguments: (version >= 11 && (flags & 134217728) !== 0) ? c.json.decode(state) : null,
622
+ enhance: (version >= 12 && (flags & 268435456) !== 0) ? c.string.decode(state) : null
618
623
  }
619
624
  }
620
625
  }
@@ -3040,12 +3045,13 @@ const encoding82 = {
3040
3045
  c.string.preencode(state, m.authUrl)
3041
3046
  c.string.preencode(state, m.tokenUrl)
3042
3047
  c.string.preencode(state, m.tokenAuth)
3043
- state.end++ // max flag is 16 so always one byte
3048
+ state.end++ // max flag is 32 so always one byte
3044
3049
 
3045
3050
  if (version >= 11 && m.scopes) encoding82_4.preencode(state, m.scopes)
3046
3051
  if (version >= 11 && m.extraAuthParams) encoding82_5.preencode(state, m.extraAuthParams)
3047
3052
  if (version >= 11 && m.registrationEndpoint) c.string.preencode(state, m.registrationEndpoint)
3048
3053
  if (version >= 11 && m.port) c.uint.preencode(state, m.port)
3054
+ if (version >= 13 && m.verify) encoding82_9.preencode(state, m.verify)
3049
3055
  },
3050
3056
  encode(state, m) {
3051
3057
  const flags =
@@ -3053,7 +3059,8 @@ const encoding82 = {
3053
3059
  ((version >= 11 && m.extraAuthParams) ? 2 : 0) |
3054
3060
  ((version >= 11 && m.registrationEndpoint) ? 4 : 0) |
3055
3061
  ((version >= 11 && m.port) ? 8 : 0) |
3056
- ((version >= 11 && m.sharedIosSession) ? 16 : 0)
3062
+ ((version >= 11 && m.sharedIosSession) ? 16 : 0) |
3063
+ ((version >= 13 && m.verify) ? 32 : 0)
3057
3064
 
3058
3065
  c.string.encode(state, m.stateKey)
3059
3066
  c.string.encode(state, m.authUrl)
@@ -3065,6 +3072,7 @@ const encoding82 = {
3065
3072
  if (version >= 11 && m.extraAuthParams) encoding82_5.encode(state, m.extraAuthParams)
3066
3073
  if (version >= 11 && m.registrationEndpoint) c.string.encode(state, m.registrationEndpoint)
3067
3074
  if (version >= 11 && m.port) c.uint.encode(state, m.port)
3075
+ if (version >= 13 && m.verify) encoding82_9.encode(state, m.verify)
3068
3076
  },
3069
3077
  decode(state) {
3070
3078
  const r0 = c.string.decode(state)
@@ -3082,7 +3090,86 @@ const encoding82 = {
3082
3090
  extraAuthParams: (version >= 11 && (flags & 2) !== 0) ? encoding82_5.decode(state) : null,
3083
3091
  registrationEndpoint: (version >= 11 && (flags & 4) !== 0) ? c.string.decode(state) : null,
3084
3092
  port: (version >= 11 && (flags & 8) !== 0) ? c.uint.decode(state) : 0,
3085
- sharedIosSession: (version >= 11 && (flags & 16) !== 0)
3093
+ sharedIosSession: (version >= 11 && (flags & 16) !== 0),
3094
+ verify: (version >= 13 && (flags & 32) !== 0) ? encoding82_9.decode(state) : null
3095
+ }
3096
+ }
3097
+ }
3098
+
3099
+ // @harness/skill-oauth-verify-rule.status
3100
+ const encoding83_1 = c.array(c.uint)
3101
+
3102
+ // @harness/skill-oauth-verify-rule
3103
+ const encoding83 = {
3104
+ preencode(state, m) {
3105
+ c.string.preencode(state, m.error)
3106
+ state.end++ // max flag is 4 so always one byte
3107
+
3108
+ if (version >= 13 && m.status) encoding83_1.preencode(state, m.status)
3109
+ if (version >= 13 && m.field) c.string.preencode(state, m.field)
3110
+ if (version >= 13 && m.notEqual) c.string.preencode(state, m.notEqual)
3111
+ },
3112
+ encode(state, m) {
3113
+ const flags =
3114
+ ((version >= 13 && m.status) ? 1 : 0) |
3115
+ ((version >= 13 && m.field) ? 2 : 0) |
3116
+ ((version >= 13 && m.notEqual) ? 4 : 0)
3117
+
3118
+ c.string.encode(state, m.error)
3119
+ c.uint.encode(state, flags)
3120
+
3121
+ if (version >= 13 && m.status) encoding83_1.encode(state, m.status)
3122
+ if (version >= 13 && m.field) c.string.encode(state, m.field)
3123
+ if (version >= 13 && m.notEqual) c.string.encode(state, m.notEqual)
3124
+ },
3125
+ decode(state) {
3126
+ const r0 = c.string.decode(state)
3127
+ const flags = c.uint.decode(state)
3128
+
3129
+ return {
3130
+ error: r0,
3131
+ status: (version >= 13 && (flags & 1) !== 0) ? encoding83_1.decode(state) : null,
3132
+ field: (version >= 13 && (flags & 2) !== 0) ? c.string.decode(state) : null,
3133
+ notEqual: (version >= 13 && (flags & 4) !== 0) ? c.string.decode(state) : null
3134
+ }
3135
+ }
3136
+ }
3137
+
3138
+ // @harness/skill-oauth-verify.reject
3139
+ const encoding84_3 = c.array(c.frame(encoding83))
3140
+
3141
+ // @harness/skill-oauth-verify
3142
+ const encoding84 = {
3143
+ preencode(state, m) {
3144
+ c.string.preencode(state, m.url)
3145
+ state.end++ // max flag is 4 so always one byte
3146
+
3147
+ if (version >= 13 && m.method) c.string.preencode(state, m.method)
3148
+ if (version >= 13 && m.body) c.string.preencode(state, m.body)
3149
+ if (version >= 13 && m.reject) encoding84_3.preencode(state, m.reject)
3150
+ },
3151
+ encode(state, m) {
3152
+ const flags =
3153
+ ((version >= 13 && m.method) ? 1 : 0) |
3154
+ ((version >= 13 && m.body) ? 2 : 0) |
3155
+ ((version >= 13 && m.reject) ? 4 : 0)
3156
+
3157
+ c.string.encode(state, m.url)
3158
+ c.uint.encode(state, flags)
3159
+
3160
+ if (version >= 13 && m.method) c.string.encode(state, m.method)
3161
+ if (version >= 13 && m.body) c.string.encode(state, m.body)
3162
+ if (version >= 13 && m.reject) encoding84_3.encode(state, m.reject)
3163
+ },
3164
+ decode(state) {
3165
+ const r0 = c.string.decode(state)
3166
+ const flags = c.uint.decode(state)
3167
+
3168
+ return {
3169
+ url: r0,
3170
+ method: (version >= 13 && (flags & 1) !== 0) ? c.string.decode(state) : null,
3171
+ body: (version >= 13 && (flags & 2) !== 0) ? c.string.decode(state) : null,
3172
+ reject: (version >= 13 && (flags & 4) !== 0) ? encoding84_3.decode(state) : null
3086
3173
  }
3087
3174
  }
3088
3175
  }
@@ -3095,6 +3182,8 @@ const encoding28_14 = c.frame(encoding51)
3095
3182
  const encoding42_2 = c.frame(encoding57)
3096
3183
  // @harness/skill-setup-route-v2.oauth, deferred due to recusive use
3097
3184
  const encoding50_10 = c.frame(encoding82)
3185
+ // @harness/skill-oauth-config.verify, deferred due to recusive use
3186
+ const encoding82_9 = c.frame(encoding84)
3098
3187
 
3099
3188
  function setVersion(v) {
3100
3189
  version = v
@@ -3313,6 +3402,10 @@ function getEncoding(name) {
3313
3402
  return encoding81
3314
3403
  case '@harness/skill-oauth-config':
3315
3404
  return encoding82
3405
+ case '@harness/skill-oauth-verify-rule':
3406
+ return encoding83
3407
+ case '@harness/skill-oauth-verify':
3408
+ return encoding84
3316
3409
  default:
3317
3410
  throw new Error('Encoder not found ' + name)
3318
3411
  }
@@ -1,12 +1,12 @@
1
1
  // This file is autogenerated by the hyperschema compiler
2
- // Schema Version: 11
2
+ // Schema Version: 13
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 = 11
9
+ const VERSION = 13
10
10
 
11
11
  // eslint-disable-next-line no-unused-vars
12
12
  let version = VERSION
@@ -490,7 +490,8 @@ const encoding11 = {
490
490
  ((version >= 5 && m.grantedWriteDirs) ? 16777216 : 0) |
491
491
  ((version >= 9 && m.captureInferenceCalls) ? 33554432 : 0) |
492
492
  ((version >= 11 && m.capability) ? 67108864 : 0) |
493
- ((version >= 11 && m.arguments) ? 134217728 : 0)
493
+ ((version >= 11 && m.arguments) ? 134217728 : 0) |
494
+ ((version >= 12 && m.enhance) ? 268435456 : 0)
494
495
 
495
496
  encoding10.preencode(state, m.type)
496
497
  c.uint.preencode(state, flags)
@@ -520,6 +521,7 @@ const encoding11 = {
520
521
  if (version >= 5 && m.grantedWriteDirs) encoding11_25.preencode(state, m.grantedWriteDirs)
521
522
  if (version >= 11 && m.capability) c.string.preencode(state, m.capability)
522
523
  if (version >= 11 && m.arguments) c.json.preencode(state, m.arguments)
524
+ if (version >= 12 && m.enhance) c.string.preencode(state, m.enhance)
523
525
  },
524
526
  encode(state, m) {
525
527
  const flags =
@@ -550,7 +552,8 @@ const encoding11 = {
550
552
  ((version >= 5 && m.grantedWriteDirs) ? 16777216 : 0) |
551
553
  ((version >= 9 && m.captureInferenceCalls) ? 33554432 : 0) |
552
554
  ((version >= 11 && m.capability) ? 67108864 : 0) |
553
- ((version >= 11 && m.arguments) ? 134217728 : 0)
555
+ ((version >= 11 && m.arguments) ? 134217728 : 0) |
556
+ ((version >= 12 && m.enhance) ? 268435456 : 0)
554
557
 
555
558
  encoding10.encode(state, m.type)
556
559
  c.uint.encode(state, flags)
@@ -580,6 +583,7 @@ const encoding11 = {
580
583
  if (version >= 5 && m.grantedWriteDirs) encoding11_25.encode(state, m.grantedWriteDirs)
581
584
  if (version >= 11 && m.capability) c.string.encode(state, m.capability)
582
585
  if (version >= 11 && m.arguments) c.json.encode(state, m.arguments)
586
+ if (version >= 12 && m.enhance) c.string.encode(state, m.enhance)
583
587
  },
584
588
  decode(state) {
585
589
  const r0 = encoding10.decode(state)
@@ -614,7 +618,8 @@ const encoding11 = {
614
618
  grantedWriteDirs: (version >= 5 && (flags & 16777216) !== 0) ? encoding11_25.decode(state) : null,
615
619
  captureInferenceCalls: (version >= 9 && (flags & 33554432) !== 0),
616
620
  capability: (version >= 11 && (flags & 67108864) !== 0) ? c.string.decode(state) : null,
617
- arguments: (version >= 11 && (flags & 134217728) !== 0) ? c.json.decode(state) : null
621
+ arguments: (version >= 11 && (flags & 134217728) !== 0) ? c.json.decode(state) : null,
622
+ enhance: (version >= 12 && (flags & 268435456) !== 0) ? c.string.decode(state) : null
618
623
  }
619
624
  }
620
625
  }
@@ -3040,12 +3045,13 @@ const encoding82 = {
3040
3045
  c.string.preencode(state, m.authUrl)
3041
3046
  c.string.preencode(state, m.tokenUrl)
3042
3047
  c.string.preencode(state, m.tokenAuth)
3043
- state.end++ // max flag is 16 so always one byte
3048
+ state.end++ // max flag is 32 so always one byte
3044
3049
 
3045
3050
  if (version >= 11 && m.scopes) encoding82_4.preencode(state, m.scopes)
3046
3051
  if (version >= 11 && m.extraAuthParams) encoding82_5.preencode(state, m.extraAuthParams)
3047
3052
  if (version >= 11 && m.registrationEndpoint) c.string.preencode(state, m.registrationEndpoint)
3048
3053
  if (version >= 11 && m.port) c.uint.preencode(state, m.port)
3054
+ if (version >= 13 && m.verify) encoding82_9.preencode(state, m.verify)
3049
3055
  },
3050
3056
  encode(state, m) {
3051
3057
  const flags =
@@ -3053,7 +3059,8 @@ const encoding82 = {
3053
3059
  ((version >= 11 && m.extraAuthParams) ? 2 : 0) |
3054
3060
  ((version >= 11 && m.registrationEndpoint) ? 4 : 0) |
3055
3061
  ((version >= 11 && m.port) ? 8 : 0) |
3056
- ((version >= 11 && m.sharedIosSession) ? 16 : 0)
3062
+ ((version >= 11 && m.sharedIosSession) ? 16 : 0) |
3063
+ ((version >= 13 && m.verify) ? 32 : 0)
3057
3064
 
3058
3065
  c.string.encode(state, m.stateKey)
3059
3066
  c.string.encode(state, m.authUrl)
@@ -3065,6 +3072,7 @@ const encoding82 = {
3065
3072
  if (version >= 11 && m.extraAuthParams) encoding82_5.encode(state, m.extraAuthParams)
3066
3073
  if (version >= 11 && m.registrationEndpoint) c.string.encode(state, m.registrationEndpoint)
3067
3074
  if (version >= 11 && m.port) c.uint.encode(state, m.port)
3075
+ if (version >= 13 && m.verify) encoding82_9.encode(state, m.verify)
3068
3076
  },
3069
3077
  decode(state) {
3070
3078
  const r0 = c.string.decode(state)
@@ -3082,7 +3090,86 @@ const encoding82 = {
3082
3090
  extraAuthParams: (version >= 11 && (flags & 2) !== 0) ? encoding82_5.decode(state) : null,
3083
3091
  registrationEndpoint: (version >= 11 && (flags & 4) !== 0) ? c.string.decode(state) : null,
3084
3092
  port: (version >= 11 && (flags & 8) !== 0) ? c.uint.decode(state) : 0,
3085
- sharedIosSession: (version >= 11 && (flags & 16) !== 0)
3093
+ sharedIosSession: (version >= 11 && (flags & 16) !== 0),
3094
+ verify: (version >= 13 && (flags & 32) !== 0) ? encoding82_9.decode(state) : null
3095
+ }
3096
+ }
3097
+ }
3098
+
3099
+ // @harness/skill-oauth-verify-rule.status
3100
+ const encoding83_1 = c.array(c.uint)
3101
+
3102
+ // @harness/skill-oauth-verify-rule
3103
+ const encoding83 = {
3104
+ preencode(state, m) {
3105
+ c.string.preencode(state, m.error)
3106
+ state.end++ // max flag is 4 so always one byte
3107
+
3108
+ if (version >= 13 && m.status) encoding83_1.preencode(state, m.status)
3109
+ if (version >= 13 && m.field) c.string.preencode(state, m.field)
3110
+ if (version >= 13 && m.notEqual) c.string.preencode(state, m.notEqual)
3111
+ },
3112
+ encode(state, m) {
3113
+ const flags =
3114
+ ((version >= 13 && m.status) ? 1 : 0) |
3115
+ ((version >= 13 && m.field) ? 2 : 0) |
3116
+ ((version >= 13 && m.notEqual) ? 4 : 0)
3117
+
3118
+ c.string.encode(state, m.error)
3119
+ c.uint.encode(state, flags)
3120
+
3121
+ if (version >= 13 && m.status) encoding83_1.encode(state, m.status)
3122
+ if (version >= 13 && m.field) c.string.encode(state, m.field)
3123
+ if (version >= 13 && m.notEqual) c.string.encode(state, m.notEqual)
3124
+ },
3125
+ decode(state) {
3126
+ const r0 = c.string.decode(state)
3127
+ const flags = c.uint.decode(state)
3128
+
3129
+ return {
3130
+ error: r0,
3131
+ status: (version >= 13 && (flags & 1) !== 0) ? encoding83_1.decode(state) : null,
3132
+ field: (version >= 13 && (flags & 2) !== 0) ? c.string.decode(state) : null,
3133
+ notEqual: (version >= 13 && (flags & 4) !== 0) ? c.string.decode(state) : null
3134
+ }
3135
+ }
3136
+ }
3137
+
3138
+ // @harness/skill-oauth-verify.reject
3139
+ const encoding84_3 = c.array(c.frame(encoding83))
3140
+
3141
+ // @harness/skill-oauth-verify
3142
+ const encoding84 = {
3143
+ preencode(state, m) {
3144
+ c.string.preencode(state, m.url)
3145
+ state.end++ // max flag is 4 so always one byte
3146
+
3147
+ if (version >= 13 && m.method) c.string.preencode(state, m.method)
3148
+ if (version >= 13 && m.body) c.string.preencode(state, m.body)
3149
+ if (version >= 13 && m.reject) encoding84_3.preencode(state, m.reject)
3150
+ },
3151
+ encode(state, m) {
3152
+ const flags =
3153
+ ((version >= 13 && m.method) ? 1 : 0) |
3154
+ ((version >= 13 && m.body) ? 2 : 0) |
3155
+ ((version >= 13 && m.reject) ? 4 : 0)
3156
+
3157
+ c.string.encode(state, m.url)
3158
+ c.uint.encode(state, flags)
3159
+
3160
+ if (version >= 13 && m.method) c.string.encode(state, m.method)
3161
+ if (version >= 13 && m.body) c.string.encode(state, m.body)
3162
+ if (version >= 13 && m.reject) encoding84_3.encode(state, m.reject)
3163
+ },
3164
+ decode(state) {
3165
+ const r0 = c.string.decode(state)
3166
+ const flags = c.uint.decode(state)
3167
+
3168
+ return {
3169
+ url: r0,
3170
+ method: (version >= 13 && (flags & 1) !== 0) ? c.string.decode(state) : null,
3171
+ body: (version >= 13 && (flags & 2) !== 0) ? c.string.decode(state) : null,
3172
+ reject: (version >= 13 && (flags & 4) !== 0) ? encoding84_3.decode(state) : null
3086
3173
  }
3087
3174
  }
3088
3175
  }
@@ -3095,6 +3182,8 @@ const encoding28_14 = c.frame(encoding51)
3095
3182
  const encoding42_2 = c.frame(encoding57)
3096
3183
  // @harness/skill-setup-route-v2.oauth, deferred due to recusive use
3097
3184
  const encoding50_10 = c.frame(encoding82)
3185
+ // @harness/skill-oauth-config.verify, deferred due to recusive use
3186
+ const encoding82_9 = c.frame(encoding84)
3098
3187
 
3099
3188
  function setVersion(v) {
3100
3189
  version = v
@@ -3313,6 +3402,10 @@ function getEncoding(name) {
3313
3402
  return encoding81
3314
3403
  case '@harness/skill-oauth-config':
3315
3404
  return encoding82
3405
+ case '@harness/skill-oauth-verify-rule':
3406
+ return encoding83
3407
+ case '@harness/skill-oauth-verify':
3408
+ return encoding84
3316
3409
  default:
3317
3410
  throw new Error('Encoder not found ' + name)
3318
3411
  }
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": 11,
2
+ "version": 13,
3
3
  "schema": [
4
4
  {
5
5
  "name": "empty",
@@ -470,6 +470,11 @@
470
470
  "name": "arguments",
471
471
  "type": "json",
472
472
  "version": 11
473
+ },
474
+ {
475
+ "name": "enhance",
476
+ "type": "string",
477
+ "version": 12
473
478
  }
474
479
  ]
475
480
  },
@@ -2481,6 +2486,71 @@
2481
2486
  "name": "sharedIosSession",
2482
2487
  "type": "bool",
2483
2488
  "version": 11
2489
+ },
2490
+ {
2491
+ "name": "verify",
2492
+ "type": "@harness/skill-oauth-verify",
2493
+ "version": 13
2494
+ }
2495
+ ]
2496
+ },
2497
+ {
2498
+ "name": "skill-oauth-verify-rule",
2499
+ "namespace": "harness",
2500
+ "compact": false,
2501
+ "flagsPosition": 1,
2502
+ "fields": [
2503
+ {
2504
+ "name": "error",
2505
+ "required": true,
2506
+ "type": "string",
2507
+ "version": 13
2508
+ },
2509
+ {
2510
+ "name": "status",
2511
+ "array": true,
2512
+ "type": "uint",
2513
+ "version": 13
2514
+ },
2515
+ {
2516
+ "name": "field",
2517
+ "type": "string",
2518
+ "version": 13
2519
+ },
2520
+ {
2521
+ "name": "notEqual",
2522
+ "type": "string",
2523
+ "version": 13
2524
+ }
2525
+ ]
2526
+ },
2527
+ {
2528
+ "name": "skill-oauth-verify",
2529
+ "namespace": "harness",
2530
+ "compact": false,
2531
+ "flagsPosition": 1,
2532
+ "fields": [
2533
+ {
2534
+ "name": "url",
2535
+ "required": true,
2536
+ "type": "string",
2537
+ "version": 13
2538
+ },
2539
+ {
2540
+ "name": "method",
2541
+ "type": "string",
2542
+ "version": 13
2543
+ },
2544
+ {
2545
+ "name": "body",
2546
+ "type": "string",
2547
+ "version": 13
2548
+ },
2549
+ {
2550
+ "name": "reject",
2551
+ "array": true,
2552
+ "type": "@harness/skill-oauth-verify-rule",
2553
+ "version": 13
2484
2554
  }
2485
2555
  ]
2486
2556
  }
@@ -1,5 +1,5 @@
1
1
  // This file is autogenerated by hyperschema-ts
2
- // Schema version: 11
2
+ // Schema version: 13
3
3
  // Do not edit manually.
4
4
 
5
5
  export interface HarnessEmpty {
@@ -90,6 +90,7 @@ export interface HarnessCompletionFrame {
90
90
  captureInferenceCalls?: boolean
91
91
  capability?: string | null
92
92
  arguments?: unknown | null
93
+ enhance?: string | null
93
94
  }
94
95
 
95
96
  export type HarnessCompletionEventType = "content" | "thinking" | "tool-call" | "tool-result" | "approval-ask" | "metrics" | "error" | "aborted" | "attach-ask" | "fetch-ask" | "progress" | "rag-ask" | "question-ask" | "done" | "tool-activity" | "drive-ask" | "inference-call" | "inference-sent"
@@ -513,6 +514,21 @@ export interface HarnessSkillOauthConfig {
513
514
  registrationEndpoint?: string | null
514
515
  port?: number
515
516
  sharedIosSession?: boolean
517
+ verify?: HarnessSkillOauthVerify | null
518
+ }
519
+
520
+ export interface HarnessSkillOauthVerifyRule {
521
+ error: string
522
+ status?: number[] | null
523
+ field?: string | null
524
+ notEqual?: string | null
525
+ }
526
+
527
+ export interface HarnessSkillOauthVerify {
528
+ url: string
529
+ method?: string | null
530
+ body?: string | null
531
+ reject?: HarnessSkillOauthVerifyRule[] | null
516
532
  }
517
533
 
518
534
  export interface SchemaTypes {
@@ -599,4 +615,6 @@ export interface SchemaTypes {
599
615
  "@harness/detect-language-response": HarnessDetectLanguageResponse
600
616
  "@harness/skill-oauth-param": HarnessSkillOauthParam
601
617
  "@harness/skill-oauth-config": HarnessSkillOauthConfig
618
+ "@harness/skill-oauth-verify-rule": HarnessSkillOauthVerifyRule
619
+ "@harness/skill-oauth-verify": HarnessSkillOauthVerify
602
620
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@qvac/harness",
3
- "version": "0.2.12",
3
+ "version": "0.3.1",
4
4
  "type": "module",
5
5
  "description": "An AI harness implementing generate(context) via @qvac/sdk. Knows nothing about workbench, hyperdb, or chunks — just inference in, events out.",
6
6
  "exports": {
@@ -212,6 +212,14 @@
212
212
  "types": "./dist-lib/lib/tools/exec/adapters/python/create-effect.d.ts",
213
213
  "default": "./dist-lib/lib/tools/exec/adapters/python/create-effect.js"
214
214
  },
215
+ "./lib/tools/exec/adapters/python/distributions.ts": {
216
+ "types": "./dist-lib/lib/tools/exec/adapters/python/distributions.d.ts",
217
+ "default": "./dist-lib/lib/tools/exec/adapters/python/distributions.js"
218
+ },
219
+ "./lib/tools/exec/adapters/python/guarded-fetch.ts": {
220
+ "types": "./dist-lib/lib/tools/exec/adapters/python/guarded-fetch.d.ts",
221
+ "default": "./dist-lib/lib/tools/exec/adapters/python/guarded-fetch.js"
222
+ },
215
223
  "./lib/tools/exec/adapters/python/loader.ts": {
216
224
  "types": "./dist-lib/lib/tools/exec/adapters/python/loader.d.ts",
217
225
  "default": "./dist-lib/lib/tools/exec/adapters/python/loader.js"
@@ -220,6 +228,14 @@
220
228
  "types": "./dist-lib/lib/tools/exec/adapters/python/memfs.d.ts",
221
229
  "default": "./dist-lib/lib/tools/exec/adapters/python/memfs.js"
222
230
  },
231
+ "./lib/tools/exec/adapters/python/module-distributions.ts": {
232
+ "types": "./dist-lib/lib/tools/exec/adapters/python/module-distributions.d.ts",
233
+ "default": "./dist-lib/lib/tools/exec/adapters/python/module-distributions.js"
234
+ },
235
+ "./lib/tools/exec/adapters/python/net-shim.ts": {
236
+ "types": "./dist-lib/lib/tools/exec/adapters/python/net-shim.d.ts",
237
+ "default": "./dist-lib/lib/tools/exec/adapters/python/net-shim.js"
238
+ },
223
239
  "./lib/tools/exec/adapters/python/output-policy.ts": {
224
240
  "types": "./dist-lib/lib/tools/exec/adapters/python/output-policy.d.ts",
225
241
  "default": "./dist-lib/lib/tools/exec/adapters/python/output-policy.js"
@@ -328,6 +344,14 @@
328
344
  "types": "./dist-lib/lib/tools/exec/shell-argv.d.ts",
329
345
  "default": "./dist-lib/lib/tools/exec/shell-argv.js"
330
346
  },
347
+ "./lib/tools/exec/shell-guidance.ts": {
348
+ "types": "./dist-lib/lib/tools/exec/shell-guidance.d.ts",
349
+ "default": "./dist-lib/lib/tools/exec/shell-guidance.js"
350
+ },
351
+ "./lib/tools/exec/video-tools.ts": {
352
+ "types": "./dist-lib/lib/tools/exec/video-tools.d.ts",
353
+ "default": "./dist-lib/lib/tools/exec/video-tools.js"
354
+ },
331
355
  "./lib/tools/file-glob.ts": {
332
356
  "types": "./dist-lib/lib/tools/file-glob.d.ts",
333
357
  "default": "./dist-lib/lib/tools/file-glob.js"
@@ -412,6 +436,10 @@
412
436
  "types": "./dist-lib/lib/tools/operations/compile.d.ts",
413
437
  "default": "./dist-lib/lib/tools/operations/compile.js"
414
438
  },
439
+ "./lib/tools/operations/decoders.ts": {
440
+ "types": "./dist-lib/lib/tools/operations/decoders.d.ts",
441
+ "default": "./dist-lib/lib/tools/operations/decoders.js"
442
+ },
415
443
  "./lib/tools/operations/gmail-message.ts": {
416
444
  "types": "./dist-lib/lib/tools/operations/gmail-message.d.ts",
417
445
  "default": "./dist-lib/lib/tools/operations/gmail-message.js"
@@ -540,6 +568,10 @@
540
568
  "types": "./dist-lib/lib/tools/skills/tool-grants.d.ts",
541
569
  "default": "./dist-lib/lib/tools/skills/tool-grants.js"
542
570
  },
571
+ "./lib/tools/translate.ts": {
572
+ "types": "./dist-lib/lib/tools/translate.d.ts",
573
+ "default": "./dist-lib/lib/tools/translate.js"
574
+ },
543
575
  "./lib/tools/url-guard.ts": {
544
576
  "types": "./dist-lib/lib/tools/url-guard.d.ts",
545
577
  "default": "./dist-lib/lib/tools/url-guard.js"
@@ -565,6 +597,7 @@
565
597
  "lint": "prettier . --check && lunte && tsc --noEmit",
566
598
  "build:bundle": "node scripts/build-bundle.mjs",
567
599
  "skill-eval": "bare examples/skill-eval/run.ts",
600
+ "translate-eval": "bare examples/translate-eval/run.ts",
568
601
  "prepack": "node scripts/vendor-python-wheels.mjs && node scripts/build-lib.mjs && node scripts/build-bundle.mjs --minify",
569
602
  "vendor:wheels": "node scripts/vendor-python-wheels.mjs",
570
603
  "build:lib": "node scripts/build-lib.mjs",
@@ -656,7 +689,7 @@
656
689
  "@qvac/inference": "0.19.0",
657
690
  "@qvac/langdetect-text": "0.1.2",
658
691
  "@qvac/sdk": "0.19.0",
659
- "@qvac/skills": "^0.1.6",
692
+ "@qvac/skills": "0.1.7",
660
693
  "asenion": "^0.1.0",
661
694
  "b4a": "^1.8.1",
662
695
  "bare-abort-controller": "^1.1.2",
@@ -3,6 +3,9 @@
3
3
  "packages": {
4
4
  "fpdf2": {
5
5
  "version": "2.8.8",
6
+ "imports": [
7
+ "fpdf"
8
+ ],
6
9
  "pypi": [
7
10
  "defusedxml-0.7.1-py2.py3-none-any.whl",
8
11
  "fpdf2-2.8.8-py3-none-any.whl"
@@ -14,6 +17,9 @@
14
17
  },
15
18
  "pypdf": {
16
19
  "version": "6.15.0",
20
+ "imports": [
21
+ "pypdf"
22
+ ],
17
23
  "pypi": [
18
24
  "pypdf-6.15.0-py3-none-any.whl"
19
25
  ],
@@ -21,6 +27,9 @@
21
27
  },
22
28
  "openpyxl": {
23
29
  "version": "3.1.5",
30
+ "imports": [
31
+ "openpyxl"
32
+ ],
24
33
  "pypi": [
25
34
  "et_xmlfile-2.0.0-py3-none-any.whl",
26
35
  "openpyxl-3.1.5-py2.py3-none-any.whl"
@@ -29,6 +38,9 @@
29
38
  },
30
39
  "python-docx": {
31
40
  "version": "1.2.0",
41
+ "imports": [
42
+ "docx"
43
+ ],
32
44
  "pypi": [
33
45
  "python_docx-1.2.0-py3-none-any.whl"
34
46
  ],
@@ -39,6 +51,9 @@
39
51
  },
40
52
  "python-pptx": {
41
53
  "version": "1.0.2",
54
+ "imports": [
55
+ "pptx"
56
+ ],
42
57
  "pypi": [
43
58
  "xlsxwriter-3.2.9-py3-none-any.whl",
44
59
  "python_pptx-1.0.2-py3-none-any.whl"