@ouispec/agent-worker 0.13.1 → 0.15.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/README.md +83 -4
- package/dist/approvals/client.d.ts +14 -1
- package/dist/approvals/client.d.ts.map +1 -1
- package/dist/approvals/client.js +9 -0
- package/dist/approvals/client.js.map +1 -1
- package/dist/container/server.d.ts +14 -0
- package/dist/container/server.d.ts.map +1 -1
- package/dist/container/server.js +35 -16
- package/dist/container/server.js.map +1 -1
- package/dist/emit/tee.d.ts +18 -0
- package/dist/emit/tee.d.ts.map +1 -0
- package/dist/emit/tee.js +19 -0
- package/dist/emit/tee.js.map +1 -0
- package/dist/index.d.ts +11 -4
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +8 -2
- package/dist/index.js.map +1 -1
- package/dist/live-call/event-stream.d.ts +20 -0
- package/dist/live-call/event-stream.d.ts.map +1 -0
- package/dist/live-call/event-stream.js +43 -0
- package/dist/live-call/event-stream.js.map +1 -0
- package/dist/live-call/handler.d.ts +121 -0
- package/dist/live-call/handler.d.ts.map +1 -0
- package/dist/live-call/handler.js +338 -0
- package/dist/live-call/handler.js.map +1 -0
- package/dist/live-call/protocol.d.ts +131 -0
- package/dist/live-call/protocol.d.ts.map +1 -0
- package/dist/live-call/protocol.js +138 -0
- package/dist/live-call/protocol.js.map +1 -0
- package/dist/orchestrator.d.ts.map +1 -1
- package/dist/orchestrator.js +39 -6
- package/dist/orchestrator.js.map +1 -1
- package/dist/prompt/spoken-reply.d.ts +28 -0
- package/dist/prompt/spoken-reply.d.ts.map +1 -0
- package/dist/prompt/spoken-reply.js +37 -0
- package/dist/prompt/spoken-reply.js.map +1 -0
- package/dist/reasoning-relay.d.ts +32 -0
- package/dist/reasoning-relay.d.ts.map +1 -0
- package/dist/reasoning-relay.js +96 -0
- package/dist/reasoning-relay.js.map +1 -0
- package/dist/runtime/turn-runner.d.ts +28 -4
- package/dist/runtime/turn-runner.d.ts.map +1 -1
- package/dist/runtime/turn-runner.js +93 -35
- package/dist/runtime/turn-runner.js.map +1 -1
- package/dist/runtime/turn-slots.d.ts +30 -0
- package/dist/runtime/turn-slots.d.ts.map +1 -0
- package/dist/runtime/turn-slots.js +36 -0
- package/dist/runtime/turn-slots.js.map +1 -0
- package/dist/runtime/types.d.ts +10 -0
- package/dist/runtime/types.d.ts.map +1 -1
- package/dist/stop/turn-stop.d.ts +12 -1
- package/dist/stop/turn-stop.d.ts.map +1 -1
- package/dist/stop/turn-stop.js +47 -0
- package/dist/stop/turn-stop.js.map +1 -1
- package/dist/types.d.ts +10 -0
- package/dist/types.d.ts.map +1 -1
- package/dist/ui/snapshot.d.ts +6 -4
- package/dist/ui/snapshot.d.ts.map +1 -1
- package/dist/ui/snapshot.js +8 -6
- package/dist/ui/snapshot.js.map +1 -1
- package/package.json +5 -5
package/dist/ui/snapshot.d.ts
CHANGED
|
@@ -37,10 +37,12 @@ export declare function withoutClientSnapshot(context: Record<string, unknown> |
|
|
|
37
37
|
/**
|
|
38
38
|
* The turn's context without what the client's UI sent for the worker itself:
|
|
39
39
|
* its snapshot (the turn's UI tools), its knowledge (rendered after the host's
|
|
40
|
-
* prompt)
|
|
41
|
-
* prompt/spoken-input.ts
|
|
42
|
-
*
|
|
43
|
-
*
|
|
40
|
+
* prompt), how the message was entered and how the reply reaches the person
|
|
41
|
+
* (each said after the conversation, prompt/spoken-input.ts and
|
|
42
|
+
* prompt/spoken-reply.ts). This is the context the host's prompt renders as
|
|
43
|
+
* prose. How the message was entered, and whether the reply is spoken, change
|
|
44
|
+
* from one turn to the next, so in the system prompt they would invalidate the
|
|
45
|
+
* cached prefix.
|
|
44
46
|
*/
|
|
45
47
|
export declare function withoutClientUI(context: Record<string, unknown> | null | undefined): Record<string, unknown> | null | undefined;
|
|
46
48
|
/** A stable fingerprint of what the page offers: two pages with the same one give the model the same index. */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"snapshot.d.ts","sourceRoot":"","sources":["../../src/ui/snapshot.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AACH,OAAO,KAAK,EAAE,MAAM,EAAE,sBAAsB,EAAc,MAAM,eAAe,CAAC;AAGhF,OAAO,EAGL,eAAe,EAGf,KAAK,eAAe,EACpB,KAAK,WAAW,EACjB,MAAM,iBAAiB,CAAC;AAEzB,yDAAyD;AACzD,eAAO,MAAM,mBAAmB,QAAQ,CAAC;AAEzC,gDAAgD;AAChD,MAAM,WAAW,UAAU;IACzB,sEAAsE;IACtE,IAAI,EAAE,WAAW,EAAE,CAAC;IACpB,YAAY,EAAE,sBAAsB,CAAC;IACrC,yFAAyF;IACzF,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,wEAAwE;IACxE,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,oGAAoG;IACpG,IAAI,EAAE,eAAe,CAAC;CACvB;AAED;;;;;;;;GAQG;AACH,wBAAgB,cAAc,CAAC,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,IAAI,GAAG,SAAS,GAAG,UAAU,GAAG,IAAI,CAsCrG;AAED,+CAA+C;AAC/C,wBAAgB,qBAAqB,CACnC,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,IAAI,GAAG,SAAS,GAClD,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,IAAI,GAAG,SAAS,CAE5C;AAED
|
|
1
|
+
{"version":3,"file":"snapshot.d.ts","sourceRoot":"","sources":["../../src/ui/snapshot.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AACH,OAAO,KAAK,EAAE,MAAM,EAAE,sBAAsB,EAAc,MAAM,eAAe,CAAC;AAGhF,OAAO,EAGL,eAAe,EAGf,KAAK,eAAe,EACpB,KAAK,WAAW,EACjB,MAAM,iBAAiB,CAAC;AAEzB,yDAAyD;AACzD,eAAO,MAAM,mBAAmB,QAAQ,CAAC;AAEzC,gDAAgD;AAChD,MAAM,WAAW,UAAU;IACzB,sEAAsE;IACtE,IAAI,EAAE,WAAW,EAAE,CAAC;IACpB,YAAY,EAAE,sBAAsB,CAAC;IACrC,yFAAyF;IACzF,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,wEAAwE;IACxE,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,oGAAoG;IACpG,IAAI,EAAE,eAAe,CAAC;CACvB;AAED;;;;;;;;GAQG;AACH,wBAAgB,cAAc,CAAC,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,IAAI,GAAG,SAAS,GAAG,UAAU,GAAG,IAAI,CAsCrG;AAED,+CAA+C;AAC/C,wBAAgB,qBAAqB,CACnC,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,IAAI,GAAG,SAAS,GAClD,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,IAAI,GAAG,SAAS,CAE5C;AAED;;;;;;;;;GASG;AACH,wBAAgB,eAAe,CAC7B,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,IAAI,GAAG,SAAS,GAClD,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,IAAI,GAAG,SAAS,CAE5C;AAUD,+GAA+G;AAC/G,eAAO,MAAM,qBAAqB,wBAAkB,CAAC"}
|
package/dist/ui/snapshot.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { MESSAGE_INPUT_CONTEXT_KEY } from '@ouispec/agent-core';
|
|
1
|
+
import { MESSAGE_INPUT_CONTEXT_KEY, REPLY_OUTPUT_CONTEXT_KEY } from '@ouispec/agent-core';
|
|
2
2
|
import { CLIENT_KNOWLEDGE_KEY } from './knowledge.js';
|
|
3
3
|
import { isFullSurface, isSurfaceIndex, pageFingerprint, pageFromIndex, pageFromSurfaces, } from './page-index.js';
|
|
4
4
|
/** The context key a UI client uses for its snapshot. */
|
|
@@ -56,13 +56,15 @@ export function withoutClientSnapshot(context) {
|
|
|
56
56
|
/**
|
|
57
57
|
* The turn's context without what the client's UI sent for the worker itself:
|
|
58
58
|
* its snapshot (the turn's UI tools), its knowledge (rendered after the host's
|
|
59
|
-
* prompt)
|
|
60
|
-
* prompt/spoken-input.ts
|
|
61
|
-
*
|
|
62
|
-
*
|
|
59
|
+
* prompt), how the message was entered and how the reply reaches the person
|
|
60
|
+
* (each said after the conversation, prompt/spoken-input.ts and
|
|
61
|
+
* prompt/spoken-reply.ts). This is the context the host's prompt renders as
|
|
62
|
+
* prose. How the message was entered, and whether the reply is spoken, change
|
|
63
|
+
* from one turn to the next, so in the system prompt they would invalidate the
|
|
64
|
+
* cached prefix.
|
|
63
65
|
*/
|
|
64
66
|
export function withoutClientUI(context) {
|
|
65
|
-
return omitKeys(context, [CLIENT_SNAPSHOT_KEY, CLIENT_KNOWLEDGE_KEY, MESSAGE_INPUT_CONTEXT_KEY]);
|
|
67
|
+
return omitKeys(context, [CLIENT_SNAPSHOT_KEY, CLIENT_KNOWLEDGE_KEY, MESSAGE_INPUT_CONTEXT_KEY, REPLY_OUTPUT_CONTEXT_KEY]);
|
|
66
68
|
}
|
|
67
69
|
function omitKeys(context, keys) {
|
|
68
70
|
if (!context || !keys.some((k) => k in context))
|
package/dist/ui/snapshot.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"snapshot.js","sourceRoot":"","sources":["../../src/ui/snapshot.ts"],"names":[],"mappings":"AASA,OAAO,EAAE,yBAAyB,EAAE,MAAM,qBAAqB,CAAC;
|
|
1
|
+
{"version":3,"file":"snapshot.js","sourceRoot":"","sources":["../../src/ui/snapshot.ts"],"names":[],"mappings":"AASA,OAAO,EAAE,yBAAyB,EAAE,wBAAwB,EAAE,MAAM,qBAAqB,CAAC;AAC1F,OAAO,EAAE,oBAAoB,EAAE,MAAM,gBAAgB,CAAC;AACtD,OAAO,EACL,aAAa,EACb,cAAc,EACd,eAAe,EACf,aAAa,EACb,gBAAgB,GAGjB,MAAM,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E,EAAE,CAAC,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;AACxF,CAAC;AAED,+GAA+G;AAC/G,MAAM,CAAC,MAAM,qBAAqB,GAAG,eAAe,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ouispec/agent-worker",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.15.0",
|
|
4
4
|
"description": "The agent runtime — any `ai` model, UI actions answered by the client, streaming and tool loops; one core on Lambda + SQS or in a container",
|
|
5
5
|
"homepage": "https://github.com/wesreid/oui/tree/main/packages/agent-worker#readme",
|
|
6
6
|
"bugs": {
|
|
@@ -51,9 +51,9 @@
|
|
|
51
51
|
"ajv": "^8.17.0",
|
|
52
52
|
"ajv-formats": "^3.0.1",
|
|
53
53
|
"yaml": "^2.7.0",
|
|
54
|
-
"@ouispec/agent-core": "^0.
|
|
55
|
-
"@ouispec/agent-events": "^0.
|
|
56
|
-
"@ouispec/bindings": "^0.4.
|
|
54
|
+
"@ouispec/agent-core": "^0.15.0",
|
|
55
|
+
"@ouispec/agent-events": "^0.14.0",
|
|
56
|
+
"@ouispec/bindings": "^0.4.7",
|
|
57
57
|
"oui-spec": "^0.11.1"
|
|
58
58
|
},
|
|
59
59
|
"devDependencies": {
|
|
@@ -66,7 +66,7 @@
|
|
|
66
66
|
"typescript": "^5.8.0",
|
|
67
67
|
"vitest": "^3.2.0",
|
|
68
68
|
"zod": "^4.4.3",
|
|
69
|
-
"@ouispec/agent-realtime": "0.
|
|
69
|
+
"@ouispec/agent-realtime": "0.15.0"
|
|
70
70
|
},
|
|
71
71
|
"publishConfig": {
|
|
72
72
|
"access": "public",
|