@qvac/harness 0.3.2 → 0.4.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.
- package/CHANGELOG.md +56 -1
- package/README.md +134 -0
- package/dist/harness.bundle +304 -175
- package/dist-lib/index.d.ts +6 -1
- package/dist-lib/index.js +29 -4
- package/dist-lib/lib/capabilities/completion.js +2 -5
- package/dist-lib/lib/capabilities/preview-model-source.d.ts +67 -0
- package/dist-lib/lib/capabilities/preview-model-source.js +387 -0
- package/dist-lib/lib/connect.d.ts +4 -5
- package/dist-lib/lib/connect.js +9 -0
- package/dist-lib/lib/contract-types.d.ts +4 -5
- package/dist-lib/lib/models/custom-model-cache.d.ts +4 -0
- package/dist-lib/lib/models/custom-model-cache.js +42 -0
- package/dist-lib/lib/models/gguf-header.d.ts +30 -0
- package/dist-lib/lib/models/gguf-header.js +208 -0
- package/dist-lib/lib/models/model-catalog.d.ts +6 -1
- package/dist-lib/lib/models/model-catalog.js +7 -2
- package/dist-lib/lib/models/model-delete.d.ts +4 -1
- package/dist-lib/lib/models/model-delete.js +19 -14
- package/dist-lib/lib/models/model-list.d.ts +6 -0
- package/dist-lib/lib/models/model-list.js +23 -1
- package/dist-lib/lib/models/model-source.js +1 -1
- package/dist-lib/lib/serve.js +21 -5
- package/dist-lib/schema/harness.js +42 -1
- package/dist-lib/spec/bind.js +3 -0
- package/dist-lib/spec/calls.js +1 -0
- package/dist-lib/spec/hrpc/hrpc.json +13 -0
- package/dist-lib/spec/hrpc/index.js +15 -3
- package/dist-lib/spec/hrpc/messages.js +173 -5
- package/dist-lib/spec/hyperschema/index.js +173 -5
- package/dist-lib/spec/hyperschema/schema.json +136 -1
- package/dist-lib/spec/hyperschema/types.d.ts +34 -1
- package/package.json +6 -7
- package/worker/harness-sidecar.mjs +1 -0
- package/dist-lib/lib/capabilities/vision-history.d.ts +0 -3
- package/dist-lib/lib/capabilities/vision-history.js +0 -21
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@qvac/harness",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.4.0",
|
|
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": {
|
|
@@ -694,10 +694,10 @@
|
|
|
694
694
|
}
|
|
695
695
|
},
|
|
696
696
|
"dependencies": {
|
|
697
|
-
"@qvac/inference": "0.
|
|
697
|
+
"@qvac/inference": "0.20.0",
|
|
698
698
|
"@qvac/langdetect-text": "0.1.2",
|
|
699
|
-
"@qvac/sdk": "0.
|
|
700
|
-
"@qvac/skills": "0.1.
|
|
699
|
+
"@qvac/sdk": "0.20.0",
|
|
700
|
+
"@qvac/skills": "0.1.9",
|
|
701
701
|
"asenion": "^0.1.0",
|
|
702
702
|
"b4a": "^1.8.1",
|
|
703
703
|
"bare-abort-controller": "^1.1.2",
|
|
@@ -771,8 +771,8 @@
|
|
|
771
771
|
"localwatch@1.4.3": "patches/localwatch@1.4.3.patch",
|
|
772
772
|
"hypercore-blob-server@1.15.0": "patches/hypercore-blob-server@1.15.0.patch",
|
|
773
773
|
"bare-stow@0.1.5": "patches/bare-stow@0.1.5.patch",
|
|
774
|
-
"@
|
|
775
|
-
"
|
|
774
|
+
"brittle@4.1.0": "patches/brittle@4.1.0.patch",
|
|
775
|
+
"@qvac/inference@0.20.0": "patches/@qvac%2Finference@0.20.0.patch"
|
|
776
776
|
},
|
|
777
777
|
"repository": {
|
|
778
778
|
"type": "git",
|
|
@@ -785,7 +785,6 @@
|
|
|
785
785
|
},
|
|
786
786
|
"homepage": "https://github.com/tetherto/qvac-harness",
|
|
787
787
|
"overrides": {
|
|
788
|
-
"@qvac/asr-ggml": "0.4.2",
|
|
789
788
|
"bare-runtime": "^1.30.0",
|
|
790
789
|
"bare-module": "6.4.0",
|
|
791
790
|
"bare-process": "4.4.1",
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
const CACHE_VERSION = 'vision-history-v1';
|
|
2
|
-
export function projectVisionHistory(history) {
|
|
3
|
-
return history.flatMap((message) => {
|
|
4
|
-
const attachments = message.attachments;
|
|
5
|
-
if (message.role !== 'user' || !attachments || attachments.length < 2)
|
|
6
|
-
return [message];
|
|
7
|
-
return attachments.map((attachment, index) => ({
|
|
8
|
-
...message,
|
|
9
|
-
content: index === attachments.length - 1 ? message.content : '\n',
|
|
10
|
-
attachments: [attachment]
|
|
11
|
-
}));
|
|
12
|
-
});
|
|
13
|
-
}
|
|
14
|
-
export function visionHistoryCacheKey(cacheKey, history) {
|
|
15
|
-
if (!cacheKey || !history.some(hasMultipleImages))
|
|
16
|
-
return cacheKey;
|
|
17
|
-
return `${cacheKey}-${CACHE_VERSION}`;
|
|
18
|
-
}
|
|
19
|
-
function hasMultipleImages(message) {
|
|
20
|
-
return message.role === 'user' && (message.attachments?.length ?? 0) > 1;
|
|
21
|
-
}
|