@segmentstream/agent 0.17.17 → 0.17.19
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/dist/_chunks/{build-metadata-9SHckxvW.mjs → build-metadata-CAKNBzXF.mjs} +1 -1
- package/dist/extension/lib/build-metadata.mjs +1 -1
- package/dist/extension/lib/telegram/adapter.mjs +1 -1
- package/dist/extension/lib/telegram/health.mjs +1 -1
- package/dist/extension/lib/telegram/lifecycle.mjs +1 -1
- package/dist/extension/tools/sandbox.d.ts +6 -4
- package/dist/extension/tools/sandbox.mjs +28 -13
- package/package.json +2 -2
|
@@ -4,7 +4,7 @@ import { createRequire as __eveCreateRequire } from "node:module";
|
|
|
4
4
|
const __filename = __eveFileURLToPath(import.meta.url);
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
|
-
var version = "0.17.
|
|
7
|
+
var version = "0.17.19";
|
|
8
8
|
function agentBuild(environment = process.env) {
|
|
9
9
|
return {
|
|
10
10
|
agent: version,
|
|
@@ -4,5 +4,5 @@ import { createRequire as __eveCreateRequire } from "node:module";
|
|
|
4
4
|
const __filename = __eveFileURLToPath(import.meta.url);
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
|
-
import { t as agentBuild } from "../../_chunks/build-metadata-
|
|
7
|
+
import { t as agentBuild } from "../../_chunks/build-metadata-CAKNBzXF.mjs";
|
|
8
8
|
export { agentBuild };
|
|
@@ -22,7 +22,7 @@ import { MAXIMUM_DOWNLOAD_BYTES, connectionProxy } from "../connection-proxy.mjs
|
|
|
22
22
|
import { dispatchStructuredMessage, structuredMessage } from "./structured.mjs";
|
|
23
23
|
import { scopedAddress, sessionPolicy } from "./sessions.mjs";
|
|
24
24
|
import { handleWorkspaceCallback, isWorkspaceCallback } from "./callbacks.mjs";
|
|
25
|
-
import { t as agentBuild } from "../../../_chunks/build-metadata-
|
|
25
|
+
import { t as agentBuild } from "../../../_chunks/build-metadata-CAKNBzXF.mjs";
|
|
26
26
|
import { attachmentLifecycle } from "./lifecycle.mjs";
|
|
27
27
|
import { observedMessages } from "./observed.mjs";
|
|
28
28
|
import { expireDeferredCards, handleDeferredCallback, isDeferredCallback } from "./deferred-confirmations.mjs";
|
|
@@ -4,7 +4,7 @@ import { createRequire as __eveCreateRequire } from "node:module";
|
|
|
4
4
|
const __filename = __eveFileURLToPath(import.meta.url);
|
|
5
5
|
__eveDirname(__filename);
|
|
6
6
|
__eveCreateRequire(import.meta.url);
|
|
7
|
-
import { t as agentBuild } from "../../../_chunks/build-metadata-
|
|
7
|
+
import { t as agentBuild } from "../../../_chunks/build-metadata-CAKNBzXF.mjs";
|
|
8
8
|
import { runtimeRequestFailure } from "./runtime-request.mjs";
|
|
9
9
|
import { GET } from "eve/channels";
|
|
10
10
|
const HEALTH_ROUTE = "/eve/v1/telegram/health";
|
|
@@ -9,7 +9,7 @@ import { object } from "../confirmation-description.mjs";
|
|
|
9
9
|
import { n as currentInboundRequest, p as reportTelegramError } from "../../../_chunks/inbound-request-Buuv7b1I.mjs";
|
|
10
10
|
import { needsConfirmation } from "../confirmations.mjs";
|
|
11
11
|
import { OntologyActionNotPermitted, actionToolName, ontologyTools } from "../ontology-tools.mjs";
|
|
12
|
-
import { t as agentBuild } from "../../../_chunks/build-metadata-
|
|
12
|
+
import { t as agentBuild } from "../../../_chunks/build-metadata-CAKNBzXF.mjs";
|
|
13
13
|
var AttachmentLifecycleNotPermitted = class extends Error {
|
|
14
14
|
code = "attachment_lifecycle_not_permitted";
|
|
15
15
|
};
|
|
@@ -1,7 +1,9 @@
|
|
|
1
|
-
import { type
|
|
1
|
+
import { type BashToolOutput } from "eve/tools/bash";
|
|
2
|
+
import { type ReadFileToolOutput } from "eve/tools/read_file";
|
|
3
|
+
import { type WriteFileToolOutput } from "eve/tools/write_file";
|
|
2
4
|
declare const _default: import("eve").DynamicSentinel<{
|
|
3
|
-
bash:
|
|
4
|
-
read_file:
|
|
5
|
-
write_file:
|
|
5
|
+
bash: import("eve/tools").ToolDefinition<import("eve/tools/bash").BashToolInput, BashToolOutput>;
|
|
6
|
+
read_file: import("eve/tools").ToolDefinition<import("eve/tools/read_file").ReadFileToolInput, ReadFileToolOutput>;
|
|
7
|
+
write_file: import("eve/tools").ToolDefinition<import("eve/tools/write_file").WriteFileToolInput, WriteFileToolOutput>;
|
|
6
8
|
} | null>;
|
|
7
9
|
export default _default;
|
|
@@ -10,22 +10,37 @@ import { defineDynamic, defineTool } from "eve/tools";
|
|
|
10
10
|
import { bash } from "eve/tools/bash";
|
|
11
11
|
import { readFile } from "eve/tools/read_file";
|
|
12
12
|
import { writeFile } from "eve/tools/write_file";
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
inputSchema:
|
|
16
|
-
outputSchema:
|
|
17
|
-
label:
|
|
18
|
-
description,
|
|
13
|
+
const tools = {
|
|
14
|
+
bash: defineTool({
|
|
15
|
+
inputSchema: bash.inputSchema,
|
|
16
|
+
outputSchema: bash.outputSchema,
|
|
17
|
+
label: bash.label,
|
|
18
|
+
description: "Run a shell command in this conversation's isolated sandbox, which has no network. A command still running after 30 seconds keeps running and returns status \"running\" with its output so far and the directory of its stdout, stderr and exit files.",
|
|
19
19
|
async execute(input, ctx) {
|
|
20
20
|
await sessionSandbox(ctx);
|
|
21
|
-
return await
|
|
21
|
+
return await bash.execute(input, ctx);
|
|
22
22
|
}
|
|
23
|
-
})
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
23
|
+
}),
|
|
24
|
+
read_file: defineTool({
|
|
25
|
+
inputSchema: readFile.inputSchema,
|
|
26
|
+
outputSchema: readFile.outputSchema,
|
|
27
|
+
label: readFile.label,
|
|
28
|
+
description: readFile.description,
|
|
29
|
+
async execute(input, ctx) {
|
|
30
|
+
await sessionSandbox(ctx);
|
|
31
|
+
return await readFile.execute(input, ctx);
|
|
32
|
+
}
|
|
33
|
+
}),
|
|
34
|
+
write_file: defineTool({
|
|
35
|
+
inputSchema: writeFile.inputSchema,
|
|
36
|
+
outputSchema: writeFile.outputSchema,
|
|
37
|
+
label: writeFile.label,
|
|
38
|
+
description: "Write a complete file in this conversation's isolated sandbox, creating directories as needed. Read an existing file with read_file before overwriting it.",
|
|
39
|
+
async execute(input, ctx) {
|
|
40
|
+
await sessionSandbox(ctx);
|
|
41
|
+
return await writeFile.execute(input, ctx);
|
|
42
|
+
}
|
|
43
|
+
})
|
|
29
44
|
};
|
|
30
45
|
var sandbox_default = defineDynamic({ events: { "turn.started": () => segmentstream.config.sandbox ? tools : null } });
|
|
31
46
|
export { sandbox_default as default };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@segmentstream/agent",
|
|
3
|
-
"version": "0.17.
|
|
3
|
+
"version": "0.17.19",
|
|
4
4
|
"description": "Mount a SegmentStream workspace's agent on eve: the ontology as tools, acting as the member who writes, and Telegram through the workspace's connection.",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"author": "SegmentStream",
|
|
@@ -66,7 +66,7 @@
|
|
|
66
66
|
},
|
|
67
67
|
"dependencies": {
|
|
68
68
|
"@chat-adapter/telegram": "4.41.0",
|
|
69
|
-
"@segmentstream-cloud/ontology": "0.56.
|
|
69
|
+
"@segmentstream-cloud/ontology": "0.56.3",
|
|
70
70
|
"@vercel/oidc": "^3.8.4",
|
|
71
71
|
"ai": "^7.0.128",
|
|
72
72
|
"csv-parse": "^7.0.3",
|