stitchkit 0.119.0 → 0.121.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 +68 -0
- package/README.md +10 -7
- package/dist/agent-runtime/coding-discovery.d.ts +25 -0
- package/dist/agent-runtime/coding-discovery.d.ts.map +1 -0
- package/dist/agent-runtime/coding-search-automaton.d.ts +37 -0
- package/dist/agent-runtime/coding-search-automaton.d.ts.map +1 -0
- package/dist/agent-runtime/coding-search-case-fold.d.ts +4 -0
- package/dist/agent-runtime/coding-search-case-fold.d.ts.map +1 -0
- package/dist/agent-runtime/coding-search-class-ranges.d.ts +10 -0
- package/dist/agent-runtime/coding-search-class-ranges.d.ts.map +1 -0
- package/dist/agent-runtime/coding-search-contract.d.ts +86 -0
- package/dist/agent-runtime/coding-search-contract.d.ts.map +1 -0
- package/dist/agent-runtime/coding-search-limits.d.ts +13 -0
- package/dist/agent-runtime/coding-search-limits.d.ts.map +1 -0
- package/dist/agent-runtime/coding-search-matcher.d.ts +33 -0
- package/dist/agent-runtime/coding-search-matcher.d.ts.map +1 -0
- package/dist/agent-runtime/coding-search-output.d.ts +5 -0
- package/dist/agent-runtime/coding-search-output.d.ts.map +1 -0
- package/dist/agent-runtime/coding-search-regex-syntax.d.ts +39 -0
- package/dist/agent-runtime/coding-search-regex-syntax.d.ts.map +1 -0
- package/dist/agent-runtime/coding-search-unit-classes.d.ts +31 -0
- package/dist/agent-runtime/coding-search-unit-classes.d.ts.map +1 -0
- package/dist/agent-runtime/coding-shell-process.d.ts +1 -0
- package/dist/agent-runtime/coding-shell-process.d.ts.map +1 -1
- package/dist/agent-runtime/coding-tool-contract.d.ts +8 -3
- package/dist/agent-runtime/coding-tool-contract.d.ts.map +1 -1
- package/dist/agent-runtime/coding-tool-files.d.ts.map +1 -1
- package/dist/agent-runtime/coding-tool-listing.d.ts +1 -11
- package/dist/agent-runtime/coding-tool-listing.d.ts.map +1 -1
- package/dist/agent-runtime/coding-tool-paths.d.ts +6 -2
- package/dist/agent-runtime/coding-tool-paths.d.ts.map +1 -1
- package/dist/agent-runtime/coding-tool-refusals.d.ts +6 -0
- package/dist/agent-runtime/coding-tool-refusals.d.ts.map +1 -1
- package/dist/agent-runtime/coding-tool-search-patch.d.ts.map +1 -1
- package/dist/agent-runtime/coding-tool-search.d.ts +113 -0
- package/dist/agent-runtime/coding-tool-search.d.ts.map +1 -0
- package/dist/agent-runtime/coding-tool-shell.d.ts.map +1 -1
- package/dist/agent-runtime/contained-scan-budget.d.ts +32 -0
- package/dist/agent-runtime/contained-scan-budget.d.ts.map +1 -0
- package/dist/agent-runtime/contained-scan-contract.d.ts +52 -0
- package/dist/agent-runtime/contained-scan-contract.d.ts.map +1 -0
- package/dist/agent-runtime/contained-scan.d.ts +48 -13
- package/dist/agent-runtime/contained-scan.d.ts.map +1 -1
- package/dist/agent-runtime/sandbox.d.ts +5 -1
- package/dist/agent-runtime/sandbox.d.ts.map +1 -1
- package/dist/agent-runtime/workspace-glob.d.ts +6 -0
- package/dist/agent-runtime/workspace-glob.d.ts.map +1 -0
- package/dist/entrypoints/agent-runtime/coding-tools.js +7 -7
- package/dist/entrypoints/agent-runtime/harness.js +5 -5
- package/dist/entrypoints/agent-runtime/realtime.js +3 -3
- package/dist/entrypoints/agent-runtime/sandbox.js +8 -8
- package/dist/entrypoints/agent-runtime/sqlite/bun.js +9 -9
- package/dist/entrypoints/agent-runtime/sqlite/node.js +9 -9
- package/dist/entrypoints/agent-runtime/testing.js +9 -9
- package/dist/entrypoints/agent-runtime.js +16 -14
- package/dist/entrypoints/application/diagnostic-journal.js +3 -3
- package/dist/entrypoints/application/directory-inbox.js +5 -5
- package/dist/entrypoints/application.js +6 -6
- package/dist/entrypoints/cli/publish.js +5 -5
- package/dist/entrypoints/cli.js +8 -8
- package/dist/entrypoints/contract.js +4 -4
- package/dist/entrypoints/files.js +4 -4
- package/dist/entrypoints/http.js +2 -2
- package/dist/entrypoints/index.js +2 -2
- package/dist/entrypoints/node.js +1 -1
- package/dist/entrypoints/process/owner-loss.js +2 -1
- package/dist/entrypoints/process.js +4 -4
- package/dist/entrypoints/remote.js +1 -1
- package/dist/entrypoints/server.js +12 -12
- package/dist/entrypoints/telegram/screens.js +5 -5
- package/dist/entrypoints/telegram.js +8 -8
- package/dist/entrypoints/testing.js +2 -2
- package/dist/entrypoints/tools/agent.d.ts +9 -0
- package/dist/entrypoints/tools/agent.d.ts.map +1 -0
- package/dist/entrypoints/tools/agent.js +16 -0
- package/dist/entrypoints/tools/connections.js +4 -4
- package/dist/entrypoints/tools/mcp.js +104 -4
- package/dist/entrypoints/tools/toolkit.d.ts +9 -0
- package/dist/entrypoints/tools/toolkit.d.ts.map +1 -0
- package/dist/entrypoints/tools/toolkit.js +40 -0
- package/dist/entrypoints/tools.d.ts +0 -10
- package/dist/entrypoints/tools.d.ts.map +1 -1
- package/dist/entrypoints/tools.js +25 -69
- package/dist/{index-s0qjs6ee.js → index-0fra8xvy.js} +9 -81
- package/dist/{index-rxcgp4b9.js → index-10rg78vf.js} +1 -1
- package/dist/index-1psbyyhj.js +21 -0
- package/dist/index-3prvb42w.js +30 -0
- package/dist/{index-ba7are04.js → index-4tyt1qya.js} +1 -1
- package/dist/index-568w258r.js +76 -0
- package/dist/{index-fqd4yqwd.js → index-6j15ktag.js} +1 -1
- package/dist/{index-zrdcmg6j.js → index-72xtvcvr.js} +40 -6
- package/dist/{index-6a69xzrx.js → index-7zwtbak8.js} +5 -46
- package/dist/{index-fcqj44mb.js → index-8ryydawp.js} +4 -4
- package/dist/{index-q968hy6y.js → index-aqmadanx.js} +2 -2
- package/dist/{index-s20s2mad.js → index-bgcwxhxh.js} +16 -14
- package/dist/index-bph35vpy.js +77 -0
- package/dist/{index-arjmb6de.js → index-eeahxwvg.js} +60 -76
- package/dist/{index-57gqaq8b.js → index-f6pw75e1.js} +1 -1
- package/dist/{index-f4njz9j0.js → index-gq3fnq3f.js} +1 -1
- package/dist/{index-ynrf908v.js → index-gtx3eknx.js} +1 -1
- package/dist/index-h1j71dr1.js +48 -0
- package/dist/{index-nn9qvkww.js → index-j95jp7ee.js} +45 -9
- package/dist/{index-mgb7r8b8.js → index-jswst0h3.js} +1 -1
- package/dist/{index-bbvc59gw.js → index-knmnj11j.js} +9 -180
- package/dist/{index-2kbysk9s.js → index-m5m9rmvt.js} +2 -0
- package/dist/{index-g444vfz2.js → index-nwm3ww60.js} +1 -1
- package/dist/{index-yk4g8805.js → index-pq7rkwkk.js} +1 -30
- package/dist/index-qaqxdbxf.js +2857 -0
- package/dist/{index-x8d9fdeg.js → index-qctbzmg9.js} +8 -4
- package/dist/index-s9a0fjh3.js +305 -0
- package/dist/index-sb9dr3tq.js +14 -0
- package/dist/{index-tvtacc9a.js → index-zyc64nbh.js} +1 -34
- package/dist/internal/contained-directory.d.ts +1 -1
- package/dist/internal/contained-directory.d.ts.map +1 -1
- package/dist/internal/contained-files.d.ts +18 -51
- package/dist/internal/contained-files.d.ts.map +1 -1
- package/dist/internal/contained-read.d.ts +17 -0
- package/dist/internal/contained-read.d.ts.map +1 -0
- package/dist/internal/darwin-binding.d.ts +3 -1
- package/dist/internal/darwin-binding.d.ts.map +1 -1
- package/dist/process/bun-child.d.ts.map +1 -1
- package/dist/process/command-owner.d.ts.map +1 -1
- package/dist/process/group.d.ts +2 -0
- package/dist/process/group.d.ts.map +1 -1
- package/dist/process/launch.d.ts +1 -0
- package/dist/process/launch.d.ts.map +1 -1
- package/dist/process/owned-child.d.ts.map +1 -1
- package/dist/process/owner-loss-guard.d.ts.map +1 -1
- package/dist/process/owner-loss-protocol.d.ts +1 -0
- package/dist/process/owner-loss-protocol.d.ts.map +1 -1
- package/llms/agent-runtime-coding-tools.txt +9 -9
- package/llms/agent-runtime-harness.txt +4 -3
- package/llms/agent-runtime-sandbox.txt +1 -1
- package/llms/agent-runtime.2.txt +20 -2
- package/llms/agent-runtime.3.txt +4 -46
- package/llms/agent-runtime.4.txt +113 -0
- package/llms/agent-runtime.txt +70 -37
- package/llms/application.3.txt +5 -2
- package/llms/cli.txt +1 -1
- package/llms/contract.txt +1 -1
- package/llms/process.txt +3 -1
- package/llms/server.5.txt +2 -0
- package/llms/stitchkit.txt +15 -9
- package/llms/testing.txt +4 -6
- package/llms/tools-agent.txt +24 -0
- package/llms/tools-mcp.txt +71 -6
- package/llms/tools-toolkit.txt +23 -0
- package/llms/tools.2.txt +6 -3
- package/llms/tools.3.txt +8 -77
- package/llms/tools.txt +8 -8
- package/llms/{upgrading-0.106.0-0.119.0.txt → upgrading-0.106.0-0.121.0.txt} +84 -3
- package/llms/upgrading.txt +1 -1
- package/llms-full.txt +360 -139
- package/llms.txt +11 -9
- package/native/darwin-arm64.node +0 -0
- package/native/darwin-x64.node +0 -0
- package/native-assets.json +4 -4
- package/package.json +10 -2
- package/dist/index-1k18qzqa.js +0 -1478
- package/dist/index-6f49krb5.js +0 -107
- package/dist/{index-2dfvv1jg.js → index-2fc1k9k2.js} +0 -0
- package/dist/{index-qndsr7f0.js → index-5efrpfmj.js} +3 -3
- /package/dist/{index-cyxp8rbf.js → index-mtwh9hyp.js} +0 -0
|
@@ -17,11 +17,11 @@ import {
|
|
|
17
17
|
import {
|
|
18
18
|
createBoundedChannel2
|
|
19
19
|
} from "../../index-w0eqdhyd.js";
|
|
20
|
-
import"../../index-
|
|
21
|
-
import"../../index-
|
|
20
|
+
import"../../index-m5m9rmvt.js";
|
|
21
|
+
import"../../index-gq3fnq3f.js";
|
|
22
22
|
import {
|
|
23
23
|
attemptExclusiveLock
|
|
24
|
-
} from "../../index-
|
|
24
|
+
} from "../../index-gtx3eknx.js";
|
|
25
25
|
import {
|
|
26
26
|
BoundedFileReadError,
|
|
27
27
|
openRegularFile
|
|
@@ -13,16 +13,16 @@ import {
|
|
|
13
13
|
import {
|
|
14
14
|
backoffDelay
|
|
15
15
|
} from "../../index-g6a3na27.js";
|
|
16
|
-
import"../../index-
|
|
17
|
-
import"../../index-
|
|
18
|
-
import"../../index-
|
|
16
|
+
import"../../index-m5m9rmvt.js";
|
|
17
|
+
import"../../index-gq3fnq3f.js";
|
|
18
|
+
import"../../index-gtx3eknx.js";
|
|
19
19
|
import {
|
|
20
20
|
defineManagedResource2
|
|
21
21
|
} from "../../index-50ejfz75.js";
|
|
22
22
|
import {
|
|
23
23
|
createFileStateStore2
|
|
24
|
-
} from "../../index-
|
|
25
|
-
import"../../index-
|
|
24
|
+
} from "../../index-6j15ktag.js";
|
|
25
|
+
import"../../index-nwm3ww60.js";
|
|
26
26
|
import {
|
|
27
27
|
isJsonData
|
|
28
28
|
} from "../../index-m6w6jtda.js";
|
|
@@ -77,7 +77,7 @@ import {
|
|
|
77
77
|
ApplicationRestartResultSchema2,
|
|
78
78
|
ApplicationAdmissionError2,
|
|
79
79
|
createApplication2
|
|
80
|
-
} from "../index-
|
|
80
|
+
} from "../index-mtwh9hyp.js";
|
|
81
81
|
import"../index-rfkh44ss.js";
|
|
82
82
|
import {
|
|
83
83
|
diff,
|
|
@@ -89,21 +89,21 @@ import {
|
|
|
89
89
|
managedResourceDependencyId2,
|
|
90
90
|
defineManagedResource2
|
|
91
91
|
} from "../index-50ejfz75.js";
|
|
92
|
+
import {
|
|
93
|
+
measureSize2
|
|
94
|
+
} from "../index-e6c2spsd.js";
|
|
92
95
|
import {
|
|
93
96
|
withDeadline
|
|
94
97
|
} from "../index-9tqbxv5p.js";
|
|
95
98
|
import {
|
|
96
|
-
|
|
97
|
-
} from "../index-
|
|
99
|
+
argumentsDigest
|
|
100
|
+
} from "../index-r7a7r7ha.js";
|
|
98
101
|
import {
|
|
99
102
|
MAX_TIMER_MS
|
|
100
103
|
} from "../index-eemvahkc.js";
|
|
101
104
|
import {
|
|
102
105
|
AppError2
|
|
103
106
|
} from "../index-qcn84byh.js";
|
|
104
|
-
import {
|
|
105
|
-
argumentsDigest
|
|
106
|
-
} from "../index-r7a7r7ha.js";
|
|
107
107
|
import {
|
|
108
108
|
serializeCanonicalJson
|
|
109
109
|
} from "../index-zsvzhjtk.js";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import"../../index-xqhede6x.js";
|
|
2
|
-
import"../../index-
|
|
3
|
-
import"../../index-
|
|
4
|
-
import"../../index-
|
|
2
|
+
import"../../index-m5m9rmvt.js";
|
|
3
|
+
import"../../index-gq3fnq3f.js";
|
|
4
|
+
import"../../index-gtx3eknx.js";
|
|
5
5
|
import {
|
|
6
6
|
signCliManifest2,
|
|
7
7
|
verifyCliManifest2,
|
|
@@ -15,10 +15,10 @@ import {
|
|
|
15
15
|
gzipCliAsset,
|
|
16
16
|
decodeCliAsset,
|
|
17
17
|
compareCliVersions2
|
|
18
|
-
} from "../../index-
|
|
18
|
+
} from "../../index-8ryydawp.js";
|
|
19
19
|
import {
|
|
20
20
|
withExclusiveLock2
|
|
21
|
-
} from "../../index-
|
|
21
|
+
} from "../../index-nwm3ww60.js";
|
|
22
22
|
import {
|
|
23
23
|
ManagedFileError2,
|
|
24
24
|
createManagedFileBoundary2
|
package/dist/entrypoints/cli.js
CHANGED
|
@@ -16,14 +16,14 @@ import {
|
|
|
16
16
|
renderCliView2,
|
|
17
17
|
pollUntilDone2,
|
|
18
18
|
createCli2
|
|
19
|
-
} from "../index-
|
|
19
|
+
} from "../index-0fra8xvy.js";
|
|
20
20
|
import"../index-k42ckyzx.js";
|
|
21
21
|
import"../index-ct75c3at.js";
|
|
22
22
|
import"../index-x4p3kw1p.js";
|
|
23
23
|
import"../index-s3yxw6kt.js";
|
|
24
24
|
import"../index-69t14s4a.js";
|
|
25
25
|
import"../index-ycqhyars.js";
|
|
26
|
-
import"../index-
|
|
26
|
+
import"../index-m5m9rmvt.js";
|
|
27
27
|
import {
|
|
28
28
|
CliBuildSignatureSchema2,
|
|
29
29
|
cliManifestSigningPayload2,
|
|
@@ -42,9 +42,12 @@ import {
|
|
|
42
42
|
checkCliUpdate2,
|
|
43
43
|
applyCliUpdate2,
|
|
44
44
|
rollbackCliUpdate2
|
|
45
|
-
} from "../index-
|
|
46
|
-
import"../index-
|
|
47
|
-
import"../index-
|
|
45
|
+
} from "../index-8ryydawp.js";
|
|
46
|
+
import"../index-aqmadanx.js";
|
|
47
|
+
import"../index-eeahxwvg.js";
|
|
48
|
+
import {
|
|
49
|
+
argumentsDigest
|
|
50
|
+
} from "../index-r7a7r7ha.js";
|
|
48
51
|
import"../index-ff39f9dr.js";
|
|
49
52
|
import"../index-aqwg2dm5.js";
|
|
50
53
|
import {
|
|
@@ -56,9 +59,6 @@ import {
|
|
|
56
59
|
import {
|
|
57
60
|
AppError2
|
|
58
61
|
} from "../index-qcn84byh.js";
|
|
59
|
-
import {
|
|
60
|
-
argumentsDigest
|
|
61
|
-
} from "../index-r7a7r7ha.js";
|
|
62
62
|
import {
|
|
63
63
|
isRecord
|
|
64
64
|
} from "../index-9jfdm5tg.js";
|
|
@@ -13,14 +13,14 @@ import {
|
|
|
13
13
|
withToolView2,
|
|
14
14
|
defineContract2
|
|
15
15
|
} from "../index-4jpykzvw.js";
|
|
16
|
-
import {
|
|
17
|
-
ManagedFilePathSchema2,
|
|
18
|
-
ManagedFileRefSchema2
|
|
19
|
-
} from "../index-xqhede6x.js";
|
|
20
16
|
import {
|
|
21
17
|
ALL_TRANSPORTS2,
|
|
22
18
|
TOOL_TRANSPORTS2
|
|
23
19
|
} from "../index-69t14s4a.js";
|
|
20
|
+
import {
|
|
21
|
+
ManagedFilePathSchema2,
|
|
22
|
+
ManagedFileRefSchema2
|
|
23
|
+
} from "../index-xqhede6x.js";
|
|
24
24
|
import"../index-m38ej7e5.js";
|
|
25
25
|
import {
|
|
26
26
|
AppError2,
|
|
@@ -2,13 +2,13 @@ import {
|
|
|
2
2
|
ManagedFilePathSchema2,
|
|
3
3
|
ManagedFileRefSchema2
|
|
4
4
|
} from "../index-xqhede6x.js";
|
|
5
|
-
import"../index-
|
|
6
|
-
import"../index-
|
|
7
|
-
import"../index-
|
|
5
|
+
import"../index-m5m9rmvt.js";
|
|
6
|
+
import"../index-gq3fnq3f.js";
|
|
7
|
+
import"../index-gtx3eknx.js";
|
|
8
8
|
import {
|
|
9
9
|
ExclusiveLockError2,
|
|
10
10
|
withExclusiveLock2
|
|
11
|
-
} from "../index-
|
|
11
|
+
} from "../index-nwm3ww60.js";
|
|
12
12
|
import {
|
|
13
13
|
ManagedFileError2,
|
|
14
14
|
createManagedFileBoundary2
|
package/dist/entrypoints/http.js
CHANGED
|
@@ -14,13 +14,13 @@ import {
|
|
|
14
14
|
createUrlBuilder2,
|
|
15
15
|
createUrlBuilders2,
|
|
16
16
|
createScopedUrlBuilders2
|
|
17
|
-
} from "../index-
|
|
17
|
+
} from "../index-2fc1k9k2.js";
|
|
18
18
|
import {
|
|
19
19
|
ApiError2
|
|
20
20
|
} from "../index-kfjkb396.js";
|
|
21
21
|
import {
|
|
22
22
|
readBoundedBody2
|
|
23
|
-
} from "../index-
|
|
23
|
+
} from "../index-5efrpfmj.js";
|
|
24
24
|
export {
|
|
25
25
|
ApiError2 as ApiError,
|
|
26
26
|
contractEndpointMatchers2 as contractEndpointMatchers,
|
|
@@ -73,7 +73,7 @@ import {
|
|
|
73
73
|
createUrlBuilder2,
|
|
74
74
|
createUrlBuilders2,
|
|
75
75
|
createScopedUrlBuilders2
|
|
76
|
-
} from "../index-
|
|
76
|
+
} from "../index-2fc1k9k2.js";
|
|
77
77
|
import {
|
|
78
78
|
createRetainedTopics2,
|
|
79
79
|
createRealtimeClientWithPeer,
|
|
@@ -87,7 +87,7 @@ import {
|
|
|
87
87
|
} from "../index-kfjkb396.js";
|
|
88
88
|
import {
|
|
89
89
|
readBoundedBody2
|
|
90
|
-
} from "../index-
|
|
90
|
+
} from "../index-5efrpfmj.js";
|
|
91
91
|
import {
|
|
92
92
|
sleep
|
|
93
93
|
} from "../index-eemvahkc.js";
|
package/dist/entrypoints/node.js
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import"../index-
|
|
1
|
+
import"../index-m5m9rmvt.js";
|
|
2
2
|
import {
|
|
3
3
|
ProcessInstanceSchema2,
|
|
4
4
|
observeProcessInstance2,
|
|
5
5
|
probeProcessOwner2
|
|
6
|
-
} from "../index-
|
|
6
|
+
} from "../index-gq3fnq3f.js";
|
|
7
7
|
import {
|
|
8
8
|
NativeCommandError2
|
|
9
|
-
} from "../index-
|
|
9
|
+
} from "../index-72xtvcvr.js";
|
|
10
10
|
import {
|
|
11
11
|
startNativeCommand
|
|
12
|
-
} from "../index-
|
|
12
|
+
} from "../index-j95jp7ee.js";
|
|
13
13
|
import {
|
|
14
14
|
untilAborted
|
|
15
15
|
} from "../index-a5qr2rj6.js";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import"../index-
|
|
2
|
-
import"../index-
|
|
3
|
-
import"../index-
|
|
1
|
+
import"../index-m5m9rmvt.js";
|
|
2
|
+
import"../index-gq3fnq3f.js";
|
|
3
|
+
import"../index-gtx3eknx.js";
|
|
4
4
|
import {
|
|
5
5
|
errorCode2,
|
|
6
6
|
normalizeError2
|
|
@@ -50,14 +50,14 @@ import {
|
|
|
50
50
|
socketIoLane2,
|
|
51
51
|
UnixClientTransportError2,
|
|
52
52
|
createUnixClientTransport2
|
|
53
|
-
} from "../index-
|
|
53
|
+
} from "../index-bgcwxhxh.js";
|
|
54
54
|
import {
|
|
55
55
|
createFileStateStore2
|
|
56
|
-
} from "../index-
|
|
56
|
+
} from "../index-6j15ktag.js";
|
|
57
57
|
import {
|
|
58
58
|
bindRealtimeServer2
|
|
59
59
|
} from "../index-2bqf0a74.js";
|
|
60
|
-
import"../index-
|
|
60
|
+
import"../index-nwm3ww60.js";
|
|
61
61
|
import {
|
|
62
62
|
withDeadline
|
|
63
63
|
} from "../index-9tqbxv5p.js";
|
|
@@ -79,12 +79,13 @@ import {
|
|
|
79
79
|
import {
|
|
80
80
|
deriveCodeChallenge2
|
|
81
81
|
} from "../index-ap3gqe56.js";
|
|
82
|
+
import"../index-pfvde2fz.js";
|
|
82
83
|
import {
|
|
83
84
|
DEFAULT_CORS_ALLOW_HEADERS2,
|
|
84
85
|
DEFAULT_CORS_EXPOSE_HEADERS2,
|
|
85
86
|
corsHeaders2,
|
|
86
87
|
corsPreflightResponse2
|
|
87
|
-
} from "../index-
|
|
88
|
+
} from "../index-pq7rkwkk.js";
|
|
88
89
|
import {
|
|
89
90
|
getTraceId2
|
|
90
91
|
} from "../index-r6v4mc67.js";
|
|
@@ -100,14 +101,13 @@ import {
|
|
|
100
101
|
isWithinDir2,
|
|
101
102
|
realPathWithinDir
|
|
102
103
|
} from "../index-5cc6r990.js";
|
|
103
|
-
import"../index-pfvde2fz.js";
|
|
104
|
-
import {
|
|
105
|
-
readBoundedChunks,
|
|
106
|
-
concatChunks
|
|
107
|
-
} from "../index-qndsr7f0.js";
|
|
108
104
|
import {
|
|
109
105
|
isUnsafeKey
|
|
110
106
|
} from "../index-zsarb5xp.js";
|
|
107
|
+
import {
|
|
108
|
+
readBoundedChunks,
|
|
109
|
+
concatChunks
|
|
110
|
+
} from "../index-5efrpfmj.js";
|
|
111
111
|
import {
|
|
112
112
|
assertPositiveSafeInteger
|
|
113
113
|
} from "../index-0s4xebbg.js";
|
|
@@ -16,19 +16,19 @@ import {
|
|
|
16
16
|
import {
|
|
17
17
|
createMutationQueue
|
|
18
18
|
} from "../../index-sykb5ag7.js";
|
|
19
|
+
import {
|
|
20
|
+
argumentsDigest
|
|
21
|
+
} from "../../index-r7a7r7ha.js";
|
|
19
22
|
import {
|
|
20
23
|
bytesToBase64Url,
|
|
21
24
|
base64UrlToBytes
|
|
22
25
|
} from "../../index-dwfv9a85.js";
|
|
23
|
-
import {
|
|
24
|
-
MAX_TIMER_MS
|
|
25
|
-
} from "../../index-eemvahkc.js";
|
|
26
26
|
import {
|
|
27
27
|
isUnsafeKey
|
|
28
28
|
} from "../../index-zsarb5xp.js";
|
|
29
29
|
import {
|
|
30
|
-
|
|
31
|
-
} from "../../index-
|
|
30
|
+
MAX_TIMER_MS
|
|
31
|
+
} from "../../index-eemvahkc.js";
|
|
32
32
|
import {
|
|
33
33
|
compareCodeUnits
|
|
34
34
|
} from "../../index-zsvzhjtk.js";
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import {
|
|
2
2
|
backoffDelay
|
|
3
3
|
} from "../index-g6a3na27.js";
|
|
4
|
-
import"../index-
|
|
5
|
-
import"../index-
|
|
4
|
+
import"../index-m5m9rmvt.js";
|
|
5
|
+
import"../index-gq3fnq3f.js";
|
|
6
6
|
import {
|
|
7
7
|
attemptExclusiveLock
|
|
8
|
-
} from "../index-
|
|
8
|
+
} from "../index-gtx3eknx.js";
|
|
9
9
|
import {
|
|
10
10
|
TELEGRAM_SEND_FAILURE_REASONS2,
|
|
11
11
|
classifyTelegramSendFailure2
|
|
@@ -21,6 +21,9 @@ import {
|
|
|
21
21
|
import {
|
|
22
22
|
BOT_TOKEN_SECRET
|
|
23
23
|
} from "../index-sznqf8fx.js";
|
|
24
|
+
import {
|
|
25
|
+
argumentsDigest
|
|
26
|
+
} from "../index-r7a7r7ha.js";
|
|
24
27
|
import {
|
|
25
28
|
writeFileAtomic2
|
|
26
29
|
} from "../index-ac6vvm30.js";
|
|
@@ -34,15 +37,12 @@ import {
|
|
|
34
37
|
MAX_TIMER_MS,
|
|
35
38
|
sleep
|
|
36
39
|
} from "../index-eemvahkc.js";
|
|
37
|
-
import {
|
|
38
|
-
untilAborted
|
|
39
|
-
} from "../index-a5qr2rj6.js";
|
|
40
40
|
import {
|
|
41
41
|
assertPositiveSafeInteger
|
|
42
42
|
} from "../index-0s4xebbg.js";
|
|
43
43
|
import {
|
|
44
|
-
|
|
45
|
-
} from "../index-
|
|
44
|
+
untilAborted
|
|
45
|
+
} from "../index-a5qr2rj6.js";
|
|
46
46
|
import {
|
|
47
47
|
isRecord,
|
|
48
48
|
transportResult
|
|
@@ -6,7 +6,7 @@ import"../index-9frf01t9.js";
|
|
|
6
6
|
import"../index-9mjrnqxs.js";
|
|
7
7
|
import {
|
|
8
8
|
createApplication2
|
|
9
|
-
} from "../index-
|
|
9
|
+
} from "../index-mtwh9hyp.js";
|
|
10
10
|
import"../index-w5s3xftz.js";
|
|
11
11
|
import {
|
|
12
12
|
RealtimeRequestTimeoutError2,
|
|
@@ -36,7 +36,7 @@ import"../index-k42ckyzx.js";
|
|
|
36
36
|
import {
|
|
37
37
|
createClient2,
|
|
38
38
|
createClients2
|
|
39
|
-
} from "../index-
|
|
39
|
+
} from "../index-2fc1k9k2.js";
|
|
40
40
|
import {
|
|
41
41
|
assertPositiveSafeInteger
|
|
42
42
|
} from "../index-0s4xebbg.js";
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* `stitchkit/tools/agent` — mount a contract's operations as AI SDK tools.
|
|
3
|
+
*
|
|
4
|
+
* Its own subpath because the AI SDK (`ai`) is an optional peer: an application
|
|
5
|
+
* that exposes its operations over HTTP and CLI imports `stitchkit/tools` and
|
|
6
|
+
* installs neither the AI SDK nor the MCP server SDK. → ADR 0284.
|
|
7
|
+
*/
|
|
8
|
+
export { type AgentContext, type AgentMountConfig, mountAgent } from '../../tools/agent.js';
|
|
9
|
+
//# sourceMappingURL=agent.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"agent.d.ts","sourceRoot":"","sources":["../../../src/entrypoints/tools/agent.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AACH,OAAO,EAAE,KAAK,YAAY,EAAE,KAAK,gBAAgB,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import"../../index-k42ckyzx.js";
|
|
2
|
+
import"../../index-dsa676h8.js";
|
|
3
|
+
import"../../index-rbzq0q16.js";
|
|
4
|
+
import"../../index-ct75c3at.js";
|
|
5
|
+
import"../../index-x4p3kw1p.js";
|
|
6
|
+
import"../../index-s3yxw6kt.js";
|
|
7
|
+
import"../../index-69t14s4a.js";
|
|
8
|
+
import"../../index-ycqhyars.js";
|
|
9
|
+
import {
|
|
10
|
+
mountAgent2
|
|
11
|
+
} from "../../index-7zwtbak8.js";
|
|
12
|
+
import"../../index-ff39f9dr.js";
|
|
13
|
+
import"../../index-aqwg2dm5.js";
|
|
14
|
+
export {
|
|
15
|
+
mountAgent2 as mountAgent
|
|
16
|
+
};
|
|
@@ -21,16 +21,16 @@ import {
|
|
|
21
21
|
import {
|
|
22
22
|
raceAbort
|
|
23
23
|
} from "../../index-b0kddvzw.js";
|
|
24
|
+
import {
|
|
25
|
+
safeJsonParse
|
|
26
|
+
} from "../../index-zsarb5xp.js";
|
|
24
27
|
import {
|
|
25
28
|
readBoundedChunks,
|
|
26
29
|
concatChunks
|
|
27
|
-
} from "../../index-
|
|
30
|
+
} from "../../index-5efrpfmj.js";
|
|
28
31
|
import {
|
|
29
32
|
MAX_TIMER_MS
|
|
30
33
|
} from "../../index-eemvahkc.js";
|
|
31
|
-
import {
|
|
32
|
-
safeJsonParse
|
|
33
|
-
} from "../../index-zsarb5xp.js";
|
|
34
34
|
import {
|
|
35
35
|
assertPositiveSafeInteger
|
|
36
36
|
} from "../../index-0s4xebbg.js";
|
|
@@ -19,16 +19,116 @@ import {
|
|
|
19
19
|
mountMcpResource2,
|
|
20
20
|
createMcpHandler2,
|
|
21
21
|
createMcpHttpRoute2,
|
|
22
|
-
createStdioMcpServer2
|
|
23
|
-
|
|
24
|
-
|
|
22
|
+
createStdioMcpServer2
|
|
23
|
+
} from "../../index-knmnj11j.js";
|
|
24
|
+
import {
|
|
25
|
+
DEFAULT_PROCESS_SIGNALS,
|
|
26
|
+
defaultSignalSource,
|
|
27
|
+
reportSignalError,
|
|
28
|
+
guardSignalCallback
|
|
29
|
+
} from "../../index-3prvb42w.js";
|
|
25
30
|
import"../../index-ff39f9dr.js";
|
|
26
31
|
import"../../index-aqwg2dm5.js";
|
|
32
|
+
// src/tools/mcp/stdio-signals.ts
|
|
33
|
+
var bound = new WeakSet;
|
|
34
|
+
function bindStdioProcessSignals(handle, options = {}) {
|
|
35
|
+
if (bound.has(handle)) {
|
|
36
|
+
throw new Error("[stitchkit] bindStdioProcessSignals: this stdio handle is already bound; close the first binding before creating another");
|
|
37
|
+
}
|
|
38
|
+
bound.add(handle);
|
|
39
|
+
const signals = [...new Set(options.signals ?? DEFAULT_PROCESS_SIGNALS)];
|
|
40
|
+
const source = options.signalSource ?? defaultSignalSource;
|
|
41
|
+
const handlers = [];
|
|
42
|
+
let started = false;
|
|
43
|
+
let sameTurnAsStart = false;
|
|
44
|
+
let closed = false;
|
|
45
|
+
let resolveChain = () => {
|
|
46
|
+
return;
|
|
47
|
+
};
|
|
48
|
+
let rejectChain = () => {
|
|
49
|
+
return;
|
|
50
|
+
};
|
|
51
|
+
const promise = new Promise((resolve, reject) => {
|
|
52
|
+
resolveChain = resolve;
|
|
53
|
+
rejectChain = reject;
|
|
54
|
+
});
|
|
55
|
+
promise.catch(() => {
|
|
56
|
+
return;
|
|
57
|
+
});
|
|
58
|
+
const removeListeners = () => {
|
|
59
|
+
if (closed)
|
|
60
|
+
return;
|
|
61
|
+
closed = true;
|
|
62
|
+
for (const [signal, handler] of handlers)
|
|
63
|
+
source.off(signal, handler);
|
|
64
|
+
if (!started)
|
|
65
|
+
bound.delete(handle);
|
|
66
|
+
};
|
|
67
|
+
const close = () => {
|
|
68
|
+
const hadStarted = started;
|
|
69
|
+
removeListeners();
|
|
70
|
+
if (!hadStarted)
|
|
71
|
+
resolveChain();
|
|
72
|
+
};
|
|
73
|
+
const run = async (signal) => {
|
|
74
|
+
try {
|
|
75
|
+
await options.onClose?.(signal);
|
|
76
|
+
} catch (error) {
|
|
77
|
+
reportSignalError("prepare", error, options.onError);
|
|
78
|
+
}
|
|
79
|
+
try {
|
|
80
|
+
await handle.close();
|
|
81
|
+
} catch (error) {
|
|
82
|
+
rejectChain(error);
|
|
83
|
+
reportSignalError("close", error, options.onError);
|
|
84
|
+
removeListeners();
|
|
85
|
+
return;
|
|
86
|
+
}
|
|
87
|
+
resolveChain();
|
|
88
|
+
try {
|
|
89
|
+
await options.onComplete?.();
|
|
90
|
+
} catch (error) {
|
|
91
|
+
reportSignalError("complete", error, options.onError);
|
|
92
|
+
} finally {
|
|
93
|
+
removeListeners();
|
|
94
|
+
}
|
|
95
|
+
};
|
|
96
|
+
const onSignal = (signal) => {
|
|
97
|
+
if (!started) {
|
|
98
|
+
started = true;
|
|
99
|
+
sameTurnAsStart = true;
|
|
100
|
+
queueMicrotask(() => {
|
|
101
|
+
sameTurnAsStart = false;
|
|
102
|
+
});
|
|
103
|
+
run(signal).catch((error) => reportSignalError("close", error, options.onError));
|
|
104
|
+
return;
|
|
105
|
+
}
|
|
106
|
+
if (sameTurnAsStart)
|
|
107
|
+
return;
|
|
108
|
+
removeListeners();
|
|
109
|
+
guardSignalCallback(() => options.onRepeatedSignal?.(signal), "close", options.onError);
|
|
110
|
+
let restored = false;
|
|
111
|
+
try {
|
|
112
|
+
restored = source.raiseDefault(signal);
|
|
113
|
+
} catch (error) {
|
|
114
|
+
reportSignalError("close", error, options.onError);
|
|
115
|
+
}
|
|
116
|
+
if (!restored) {
|
|
117
|
+
guardSignalCallback(() => options.onEscalationBlocked?.(signal), "close", options.onError);
|
|
118
|
+
}
|
|
119
|
+
};
|
|
120
|
+
for (const signal of signals) {
|
|
121
|
+
const handler = () => onSignal(signal);
|
|
122
|
+
handlers.push([signal, handler]);
|
|
123
|
+
source.on(signal, handler);
|
|
124
|
+
}
|
|
125
|
+
return { promise, close };
|
|
126
|
+
}
|
|
27
127
|
export {
|
|
28
128
|
EXT_APPS_BUNDLE_PLACEHOLDER2 as EXT_APPS_BUNDLE_PLACEHOLDER,
|
|
29
129
|
MCP_CATALOG_META_KEY2 as MCP_CATALOG_META_KEY,
|
|
30
130
|
RESOURCE_MIME_TYPE2 as RESOURCE_MIME_TYPE,
|
|
31
|
-
|
|
131
|
+
bindStdioProcessSignals,
|
|
32
132
|
buildMcpServer2 as buildMcpServer,
|
|
33
133
|
createMcpHandler2 as createMcpHandler,
|
|
34
134
|
createMcpHttpRoute2 as createMcpHttpRoute,
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* `stitchkit/tools/toolkit` — one tool set served over MCP and to an AI SDK agent.
|
|
3
|
+
*
|
|
4
|
+
* The toolkit composes both adapters, so this subpath needs both optional peers,
|
|
5
|
+
* `@modelcontextprotocol/server` and `ai`. A server that needs only one of them
|
|
6
|
+
* imports `stitchkit/tools/mcp` or `stitchkit/tools/agent`. → ADR 0284.
|
|
7
|
+
*/
|
|
8
|
+
export { createToolkit, type Toolkit } from '../../tools/toolkit.js';
|
|
9
|
+
//# sourceMappingURL=toolkit.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"toolkit.d.ts","sourceRoot":"","sources":["../../../src/entrypoints/tools/toolkit.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AACH,OAAO,EAAE,aAAa,EAAE,KAAK,OAAO,EAAE,MAAM,qBAAqB,CAAC"}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import"../../index-k42ckyzx.js";
|
|
2
|
+
import"../../index-dsa676h8.js";
|
|
3
|
+
import"../../index-rbzq0q16.js";
|
|
4
|
+
import"../../index-ct75c3at.js";
|
|
5
|
+
import"../../index-x4p3kw1p.js";
|
|
6
|
+
import"../../index-s3yxw6kt.js";
|
|
7
|
+
import"../../index-69t14s4a.js";
|
|
8
|
+
import"../../index-ycqhyars.js";
|
|
9
|
+
import {
|
|
10
|
+
mountAgent2
|
|
11
|
+
} from "../../index-7zwtbak8.js";
|
|
12
|
+
import {
|
|
13
|
+
createCli2
|
|
14
|
+
} from "../../index-0fra8xvy.js";
|
|
15
|
+
import"../../index-m5m9rmvt.js";
|
|
16
|
+
import {
|
|
17
|
+
mountMcp2,
|
|
18
|
+
buildMcpServer2,
|
|
19
|
+
createMcpHandler2,
|
|
20
|
+
createStdioMcpServer2
|
|
21
|
+
} from "../../index-knmnj11j.js";
|
|
22
|
+
import"../../index-aqmadanx.js";
|
|
23
|
+
import"../../index-eeahxwvg.js";
|
|
24
|
+
import"../../index-ff39f9dr.js";
|
|
25
|
+
import"../../index-aqwg2dm5.js";
|
|
26
|
+
|
|
27
|
+
// src/tools/toolkit.ts
|
|
28
|
+
function createToolkit() {
|
|
29
|
+
return {
|
|
30
|
+
mountMcp: (server, services, config) => mountMcp2(server, services, config),
|
|
31
|
+
mountAgent: (services, config) => mountAgent2(services, config),
|
|
32
|
+
buildMcpServer: (config, auth) => buildMcpServer2(config, auth),
|
|
33
|
+
createMcpHandler: (config) => createMcpHandler2(config),
|
|
34
|
+
createStdioMcpServer: (config) => createStdioMcpServer2(config),
|
|
35
|
+
createCli: (config) => createCli2(config)
|
|
36
|
+
};
|
|
37
|
+
}
|
|
38
|
+
export {
|
|
39
|
+
createToolkit
|
|
40
|
+
};
|