@qvac/harness 1.0.0-rc.21 → 1.0.0-rc.23

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 (61) hide show
  1. package/CHANGELOG.md +103 -0
  2. package/README.md +2 -0
  3. package/dist-lib/index.d.ts +4 -1
  4. package/dist-lib/index.js +12 -4
  5. package/dist-lib/lib/capabilities/completion-engine/actors/execution-plan.js +3 -1
  6. package/dist-lib/lib/capabilities/completion-engine/tool-outcome.js +2 -4
  7. package/dist-lib/lib/capabilities/tool-turns/answered.d.ts +15 -0
  8. package/dist-lib/lib/capabilities/tool-turns/answered.js +16 -0
  9. package/dist-lib/lib/capabilities/tool-turns.d.ts +2 -0
  10. package/dist-lib/lib/capabilities/tool-turns.js +1 -0
  11. package/dist-lib/lib/contract/completion.d.ts +2 -1
  12. package/dist-lib/lib/contract/drive.d.ts +24 -0
  13. package/dist-lib/lib/contract/root-search.d.ts +34 -0
  14. package/dist-lib/lib/contract/root-search.js +1 -0
  15. package/dist-lib/lib/contract/run.d.ts +2 -0
  16. package/dist-lib/lib/helpers/root-search.d.ts +3 -0
  17. package/dist-lib/lib/helpers/root-search.js +74 -0
  18. package/dist-lib/lib/machine/completion/actions/tools.js +7 -1
  19. package/dist-lib/lib/machine/completion/metrics.js +3 -1
  20. package/dist-lib/lib/machine/completion/types.d.ts +2 -0
  21. package/dist-lib/lib/models/model-catalog-constants.d.ts +1 -0
  22. package/dist-lib/lib/models/model-catalog-constants.js +5 -1
  23. package/dist-lib/lib/models/model-catalog.d.ts +10 -3
  24. package/dist-lib/lib/models/model-catalog.js +14 -8
  25. package/dist-lib/lib/models/model-delete.js +3 -0
  26. package/dist-lib/lib/models/model-list.d.ts +2 -1
  27. package/dist-lib/lib/models/model-list.js +5 -1
  28. package/dist-lib/lib/models/model-pool.d.ts +5 -0
  29. package/dist-lib/lib/models/model-pool.js +16 -4
  30. package/dist-lib/lib/plugins/registry.d.ts +2 -0
  31. package/dist-lib/lib/residency/index.js +9 -6
  32. package/dist-lib/lib/spawn.d.ts +9 -0
  33. package/dist-lib/lib/tools/files/glob.js +71 -10
  34. package/dist-lib/lib/tools/files/grep.js +65 -22
  35. package/dist-lib/lib/tools/files/read-file.js +120 -76
  36. package/dist-lib/lib/tools/fs/engine.d.ts +9 -0
  37. package/dist-lib/lib/tools/fs/engine.js +28 -0
  38. package/dist-lib/lib/tools/fs/suggest.d.ts +8 -0
  39. package/dist-lib/lib/tools/fs/suggest.js +110 -0
  40. package/dist-lib/lib/tools/fs/tool-path.d.ts +3 -0
  41. package/dist-lib/lib/tools/fs/tool-path.js +13 -0
  42. package/dist-lib/lib/tools/fs/walk.d.ts +3 -0
  43. package/dist-lib/lib/tools/fs/walk.js +20 -20
  44. package/dist-lib/lib/tools/toolsets.d.ts +1 -1
  45. package/dist-lib/lib/tools/toolsets.js +2 -0
  46. package/dist-lib/plugins/charts/chart-tool.d.ts +8 -0
  47. package/dist-lib/plugins/charts/chart-tool.js +175 -0
  48. package/dist-lib/plugins/charts/index.d.ts +16 -0
  49. package/dist-lib/plugins/charts/index.js +21 -0
  50. package/dist-lib/plugins/diagrams/draw.d.ts +10 -0
  51. package/dist-lib/plugins/diagrams/draw.js +90 -0
  52. package/dist-lib/plugins/diagrams/index.d.ts +13 -0
  53. package/dist-lib/plugins/diagrams/index.js +15 -0
  54. package/dist-lib/plugins/diagrams/render.d.ts +16 -0
  55. package/dist-lib/plugins/diagrams/render.js +285 -0
  56. package/dist-lib/plugins/ripgrep/index.d.ts +15 -0
  57. package/dist-lib/plugins/ripgrep/index.js +28 -0
  58. package/dist-lib/plugins/sandbox-windows/prebuilds/win32-arm64/qvac-sandbox.exe +0 -0
  59. package/dist-lib/plugins/sandbox-windows/prebuilds/win32-x64/qvac-sandbox.exe +0 -0
  60. package/package.json +28 -2
  61. package/worker/harness-sidecar.mjs +5 -0
@@ -0,0 +1,28 @@
1
+ import { PluginRegistry } from '../../lib/plugins/index.js';
2
+ const MAX_ENTRIES = 1_000_000;
3
+ export class Ripgrep {
4
+ name = 'ripgrep';
5
+ api = PluginRegistry.API_VERSION;
6
+ provides = ['rootSearch'];
7
+ addons = {
8
+ 'bare-ripgrep': async () => {
9
+ await import('bare-ripgrep');
10
+ }
11
+ };
12
+ #maxEntries;
13
+ constructor({ maxEntries = MAX_ENTRIES } = {}) {
14
+ PluginRegistry.requirePeers('ripgrep', {
15
+ 'bare-ripgrep': () => import.meta.resolve('bare-ripgrep')
16
+ });
17
+ this.#maxEntries = maxEntries;
18
+ }
19
+ async setup() {
20
+ const { search, walk } = await import('bare-ripgrep');
21
+ const maxEntries = this.#maxEntries;
22
+ const engine = {
23
+ search: (query) => search({ ...query, deny: [...query.deny], maxEntries }),
24
+ walk: (scope) => walk({ ...scope, deny: [...scope.deny], maxEntries })
25
+ };
26
+ return { services: { rootSearch: engine } };
27
+ }
28
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@qvac/harness",
3
- "version": "1.0.0-rc.21",
3
+ "version": "1.0.0-rc.23",
4
4
  "type": "module",
5
5
  "engines": {
6
6
  "bare": ">=1.33.4",
@@ -92,6 +92,10 @@
92
92
  "types": "./dist-lib/lib/contract/models.d.ts",
93
93
  "default": "./dist-lib/lib/contract/models.js"
94
94
  },
95
+ "./lib/contract/root-search.ts": {
96
+ "types": "./dist-lib/lib/contract/root-search.d.ts",
97
+ "default": "./dist-lib/lib/contract/root-search.js"
98
+ },
95
99
  "./lib/contract/sandbox.ts": {
96
100
  "types": "./dist-lib/lib/contract/sandbox.d.ts",
97
101
  "default": "./dist-lib/lib/contract/sandbox.js"
@@ -316,6 +320,10 @@
316
320
  "types": "./dist-lib/plugins/code-mode/index.d.ts",
317
321
  "default": "./dist-lib/plugins/code-mode/index.js"
318
322
  },
323
+ "./plugins/charts": {
324
+ "types": "./dist-lib/plugins/charts/index.d.ts",
325
+ "default": "./dist-lib/plugins/charts/index.js"
326
+ },
319
327
  "./plugins/coding": {
320
328
  "types": "./dist-lib/plugins/coding/index.d.ts",
321
329
  "default": "./dist-lib/plugins/coding/index.js"
@@ -380,6 +388,10 @@
380
388
  "types": "./dist-lib/plugins/quickjs/index.d.ts",
381
389
  "default": "./dist-lib/plugins/quickjs/index.js"
382
390
  },
391
+ "./plugins/ripgrep": {
392
+ "types": "./dist-lib/plugins/ripgrep/index.d.ts",
393
+ "default": "./dist-lib/plugins/ripgrep/index.js"
394
+ },
383
395
  "./plugins/sandbox-linux": {
384
396
  "types": "./dist-lib/plugins/sandbox-linux/index.d.ts",
385
397
  "default": "./dist-lib/plugins/sandbox-linux/index.js"
@@ -404,6 +416,10 @@
404
416
  "types": "./dist-lib/plugins/translation/index.d.ts",
405
417
  "default": "./dist-lib/plugins/translation/index.js"
406
418
  },
419
+ "./plugins/diagrams": {
420
+ "types": "./dist-lib/plugins/diagrams/index.d.ts",
421
+ "default": "./dist-lib/plugins/diagrams/index.js"
422
+ },
407
423
  "./plugins/weather": {
408
424
  "types": "./dist-lib/plugins/weather/index.d.ts",
409
425
  "default": "./dist-lib/plugins/weather/index.js"
@@ -658,12 +674,14 @@
658
674
  "bare-image-resample": "^1.0.2",
659
675
  "bare-media": "^2.10.0",
660
676
  "bare-net": "^2.3.2",
677
+ "bare-ripgrep": "^0.0.1",
661
678
  "barevisor": "0.1.0",
662
679
  "elkjs": "^0.11.1",
663
680
  "hypercore-crypto": "^3.7.0",
664
681
  "hyperswarm": "^4.17.1",
665
682
  "pyodide": "314.0.2",
666
- "quickjs-emscripten-core": "0.32.0"
683
+ "quickjs-emscripten-core": "0.32.0",
684
+ "qvac-charts": "^0.2.0"
667
685
  },
668
686
  "peerDependenciesMeta": {
669
687
  "@jitl/quickjs-singlefile-mjs-release-sync": {
@@ -717,6 +735,9 @@
717
735
  "bare-net": {
718
736
  "optional": true
719
737
  },
738
+ "bare-ripgrep": {
739
+ "optional": true
740
+ },
720
741
  "barevisor": {
721
742
  "optional": true
722
743
  },
@@ -734,6 +755,9 @@
734
755
  },
735
756
  "quickjs-emscripten-core": {
736
757
  "optional": true
758
+ },
759
+ "qvac-charts": {
760
+ "optional": true
737
761
  }
738
762
  },
739
763
  "devDependencies": {
@@ -757,6 +781,7 @@
757
781
  "bare-media": "^2.10.0",
758
782
  "bare-module-traverse": "~2.5.8",
759
783
  "bare-net": "^2.3.2",
784
+ "bare-ripgrep": "^0.0.1",
760
785
  "bare-runtime": "1.36.0",
761
786
  "bare-semver": "^1.1.0",
762
787
  "bare-tui": "0.3.0",
@@ -777,6 +802,7 @@
777
802
  "prettier-config-holepunch": "^2.0.0",
778
803
  "pyodide": "314.0.2",
779
804
  "quickjs-emscripten-core": "0.32.0",
805
+ "qvac-charts": "^0.2.0",
780
806
  "typescript": "^7.0.2"
781
807
  },
782
808
  "patchedDependencies": {
@@ -1,6 +1,8 @@
1
1
  // bare-stow entry: the first-party plugins on the shared boot; a host entry composes the same two
2
2
  import '../dist-lib/lib/hardware/gpu-probe-entry.js'
3
3
  import { HarnessSidecar } from '../dist-lib/lib/sidecar/index.js'
4
+ import { Charts } from '../dist-lib/plugins/charts/index.js'
5
+ import { Diagrams } from '../dist-lib/plugins/diagrams/index.js'
4
6
  import { Image } from '../dist-lib/plugins/image/index.js'
5
7
  import { Knowledge } from '../dist-lib/plugins/knowledge/index.js'
6
8
  import { McpPlugin } from '../dist-lib/plugins/mcp/index.js'
@@ -29,6 +31,9 @@ export function firstPartyPlugins({
29
31
  new Speech(pluginOptions.speech),
30
32
  new TranslationPlugin(),
31
33
  new Weather({ read: ['weather_lookup'] }),
34
+ new Diagrams({ read: ['draw_diagram'] }),
35
+ // the host passes its theme and brand mark; the package ships no logo
36
+ new Charts({ ...pluginOptions.charts, read: ['create_chart'] }),
32
37
  new WebSearchPlugin({ read: ['web_search'] }),
33
38
  // granted read so a skill's declared read methods on its server do not ask
34
39
  new McpPlugin({