@catamorphic/ai-sdk 0.0.0-stage → 0.1.0-alpha.31

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/LICENSE.txt ADDED
@@ -0,0 +1,202 @@
1
+
2
+ Apache License
3
+ Version 2.0, January 2004
4
+ http://www.apache.org/licenses/
5
+
6
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
7
+
8
+ 1. Definitions.
9
+
10
+ "License" shall mean the terms and conditions for use, reproduction,
11
+ and distribution as defined by Sections 1 through 9 of this document.
12
+
13
+ "Licensor" shall mean the copyright owner or entity authorized by
14
+ the copyright owner that is granting the License.
15
+
16
+ "Legal Entity" shall mean the union of the acting entity and all
17
+ other entities that control, are controlled by, or are under common
18
+ control with that entity. For the purposes of this definition,
19
+ "control" means (i) the power, direct or indirect, to cause the
20
+ direction or management of such entity, whether by contract or
21
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
22
+ outstanding shares, or (iii) beneficial ownership of such entity.
23
+
24
+ "You" (or "Your") shall mean an individual or Legal Entity
25
+ exercising permissions granted by this License.
26
+
27
+ "Source" form shall mean the preferred form for making modifications,
28
+ including but not limited to software source code, documentation
29
+ source, and configuration files.
30
+
31
+ "Object" form shall mean any form resulting from mechanical
32
+ transformation or translation of a Source form, including but
33
+ not limited to compiled object code, generated documentation,
34
+ and conversions to other media types.
35
+
36
+ "Work" shall mean the work of authorship, whether in Source or
37
+ Object form, made available under the License, as indicated by a
38
+ copyright notice that is included in or attached to the work
39
+ (an example is provided in the Appendix below).
40
+
41
+ "Derivative Works" shall mean any work, whether in Source or Object
42
+ form, that is based on (or derived from) the Work and for which the
43
+ editorial revisions, annotations, elaborations, or other modifications
44
+ represent, as a whole, an original work of authorship. For the purposes
45
+ of this License, Derivative Works shall not include works that remain
46
+ separable from, or merely link (or bind by name) to the interfaces of,
47
+ the Work and Derivative Works thereof.
48
+
49
+ "Contribution" shall mean any work of authorship, including
50
+ the original version of the Work and any modifications or additions
51
+ to that Work or Derivative Works thereof, that is intentionally
52
+ submitted to Licensor for inclusion in the Work by the copyright owner
53
+ or by an individual or Legal Entity authorized to submit on behalf of
54
+ the copyright owner. For the purposes of this definition, "submitted"
55
+ means any form of electronic, verbal, or written communication sent
56
+ to the Licensor or its representatives, including but not limited to
57
+ communication on electronic mailing lists, source code control systems,
58
+ and issue tracking systems that are managed by, or on behalf of, the
59
+ Licensor for the purpose of discussing and improving the Work, but
60
+ excluding communication that is conspicuously marked or otherwise
61
+ designated in writing by the copyright owner as "Not a Contribution."
62
+
63
+ "Contributor" shall mean Licensor and any individual or Legal Entity
64
+ on behalf of whom a Contribution has been received by Licensor and
65
+ subsequently incorporated within the Work.
66
+
67
+ 2. Grant of Copyright License. Subject to the terms and conditions of
68
+ this License, each Contributor hereby grants to You a perpetual,
69
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
70
+ copyright license to reproduce, prepare Derivative Works of,
71
+ publicly display, publicly perform, sublicense, and distribute the
72
+ Work and such Derivative Works in Source or Object form.
73
+
74
+ 3. Grant of Patent License. Subject to the terms and conditions of
75
+ this License, each Contributor hereby grants to You a perpetual,
76
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
77
+ (except as stated in this section) patent license to make, have made,
78
+ use, offer to sell, sell, import, and otherwise transfer the Work,
79
+ where such license applies only to those patent claims licensable
80
+ by such Contributor that are necessarily infringed by their
81
+ Contribution(s) alone or by combination of their Contribution(s)
82
+ with the Work to which such Contribution(s) was submitted. If You
83
+ institute patent litigation against any entity (including a
84
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
85
+ or a Contribution incorporated within the Work constitutes direct
86
+ or contributory patent infringement, then any patent licenses
87
+ granted to You under this License for that Work shall terminate
88
+ as of the date such litigation is filed.
89
+
90
+ 4. Redistribution. You may reproduce and distribute copies of the
91
+ Work or Derivative Works thereof in any medium, with or without
92
+ modifications, and in Source or Object form, provided that You
93
+ meet the following conditions:
94
+
95
+ (a) You must give any other recipients of the Work or
96
+ Derivative Works a copy of this License; and
97
+
98
+ (b) You must cause any modified files to carry prominent notices
99
+ stating that You changed the files; and
100
+
101
+ (c) You must retain, in the Source form of any Derivative Works
102
+ that You distribute, all copyright, patent, trademark, and
103
+ attribution notices from the Source form of the Work,
104
+ excluding those notices that do not pertain to any part of
105
+ the Derivative Works; and
106
+
107
+ (d) If the Work includes a "NOTICE" text file as part of its
108
+ distribution, then any Derivative Works that You distribute must
109
+ include a readable copy of the attribution notices contained
110
+ within such NOTICE file, excluding those notices that do not
111
+ pertain to any part of the Derivative Works, in at least one
112
+ of the following places: within a NOTICE text file distributed
113
+ as part of the Derivative Works; within the Source form or
114
+ documentation, if provided along with the Derivative Works; or,
115
+ within a display generated by the Derivative Works, if and
116
+ wherever such third-party notices normally appear. The contents
117
+ of the NOTICE file are for informational purposes only and
118
+ do not modify the License. You may add Your own attribution
119
+ notices within Derivative Works that You distribute, alongside
120
+ or as an addendum to the NOTICE text from the Work, provided
121
+ that such additional attribution notices cannot be construed
122
+ as modifying the License.
123
+
124
+ You may add Your own copyright statement to Your modifications and
125
+ may provide additional or different license terms and conditions
126
+ for use, reproduction, or distribution of Your modifications, or
127
+ for any such Derivative Works as a whole, provided Your use,
128
+ reproduction, and distribution of the Work otherwise complies with
129
+ the conditions stated in this License.
130
+
131
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
132
+ any Contribution intentionally submitted for inclusion in the Work
133
+ by You to the Licensor shall be under the terms and conditions of
134
+ this License, without any additional terms or conditions.
135
+ Notwithstanding the above, nothing herein shall supersede or modify
136
+ the terms of any separate license agreement you may have executed
137
+ with Licensor regarding such Contributions.
138
+
139
+ 6. Trademarks. This License does not grant permission to use the trade
140
+ names, trademarks, service marks, or product names of the Licensor,
141
+ except as required for reasonable and customary use in describing the
142
+ origin of the Work and reproducing the content of the NOTICE file.
143
+
144
+ 7. Disclaimer of Warranty. Unless required by applicable law or
145
+ agreed to in writing, Licensor provides the Work (and each
146
+ Contributor provides its Contributions) on an "AS IS" BASIS,
147
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
148
+ implied, including, without limitation, any warranties or conditions
149
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
150
+ PARTICULAR PURPOSE. You are solely responsible for determining the
151
+ appropriateness of using or redistributing the Work and assume any
152
+ risks associated with Your exercise of permissions under this License.
153
+
154
+ 8. Limitation of Liability. In no event and under no legal theory,
155
+ whether in tort (including negligence), contract, or otherwise,
156
+ unless required by applicable law (such as deliberate and grossly
157
+ negligent acts) or agreed to in writing, shall any Contributor be
158
+ liable to You for damages, including any direct, indirect, special,
159
+ incidental, or consequential damages of any character arising as a
160
+ result of this License or out of the use or inability to use the
161
+ Work (including but not limited to damages for loss of goodwill,
162
+ work stoppage, computer failure or malfunction, or any and all
163
+ other commercial damages or losses), even if such Contributor
164
+ has been advised of the possibility of such damages.
165
+
166
+ 9. Accepting Warranty or Additional Liability. While redistributing
167
+ the Work or Derivative Works thereof, You may choose to offer,
168
+ and charge a fee for, acceptance of support, warranty, indemnity,
169
+ or other liability obligations and/or rights consistent with this
170
+ License. However, in accepting such obligations, You may act only
171
+ on Your own behalf and on Your sole responsibility, not on behalf
172
+ of any other Contributor, and only if You agree to indemnify,
173
+ defend, and hold each Contributor harmless for any liability
174
+ incurred by, or claims asserted against, such Contributor by reason
175
+ of your accepting any such warranty or additional liability.
176
+
177
+ END OF TERMS AND CONDITIONS
178
+
179
+ APPENDIX: How to apply the Apache License to your work.
180
+
181
+ To apply the Apache License to your work, attach the following
182
+ boilerplate notice, with the fields enclosed by brackets "[]"
183
+ replaced with your own identifying information. (Don't include
184
+ the brackets!) The text should be enclosed in the appropriate
185
+ comment syntax for the file format. We also recommend that a
186
+ file or class name and description of purpose be included on the
187
+ same "printed page" as the copyright notice for easier
188
+ identification within third-party archives.
189
+
190
+ Copyright [yyyy] [name of copyright owner]
191
+
192
+ Licensed under the Apache License, Version 2.0 (the "License");
193
+ you may not use this file except in compliance with the License.
194
+ You may obtain a copy of the License at
195
+
196
+ http://www.apache.org/licenses/LICENSE-2.0
197
+
198
+ Unless required by applicable law or agreed to in writing, software
199
+ distributed under the License is distributed on an "AS IS" BASIS,
200
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
201
+ See the License for the specific language governing permissions and
202
+ limitations under the License.
package/NOTICE.txt ADDED
@@ -0,0 +1,32 @@
1
+ Catamorphic
2
+ Copyright 2026 The Catamorphic Authors
3
+
4
+ This product is licensed under the Apache License, Version 2.0 (the
5
+ "License"); see the LICENSE file for the full text.
6
+
7
+ --------------------------------------------------------------------------------
8
+ This product includes third-party software under separate license terms:
9
+
10
+ command-score
11
+ apps/desktop/src/renderer/lib/command-score.ts is a port of Superhuman's
12
+ command-score fuzzy matcher.
13
+
14
+ Copyright (c) 2016 Superhuman
15
+
16
+ Permission is hereby granted, free of charge, to any person obtaining a copy
17
+ of this software and associated documentation files (the "Software"), to deal
18
+ in the Software without restriction, including without limitation the rights
19
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
20
+ copies of the Software, and to permit persons to whom the Software is
21
+ furnished to do so, subject to the following conditions:
22
+
23
+ The above copyright notice and this permission notice shall be included in all
24
+ copies or substantial portions of the Software.
25
+
26
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
27
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
28
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
29
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
30
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
31
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
32
+ SOFTWARE.
package/README.md CHANGED
@@ -1,3 +1,74 @@
1
- # Temporary Holding Version
1
+ # @catamorphic/ai-sdk
2
2
 
3
- This version is a temporary placeholder for this package. An operational version to replace this has been submitted for review and is awaiting a staged release.
3
+ The built-in agent: Vercel AI SDK's tool loop as a harness adapter
4
+ (`HarnessAdapter`, ADR 0198) with the id `ai-sdk`. It always runs in the
5
+ host's own process (the desktop, the control plane) through an in-process
6
+ agent runner. Model calls run in the host; the `read`, `write`, `edit` and
7
+ shell tools run on the session's sandbox through the vendor-neutral
8
+ `SandboxProvider` contract. Model credentials never enter the sandbox.
9
+
10
+ ## Usage
11
+
12
+ ```ts
13
+ import { anthropic } from "@ai-sdk/anthropic";
14
+ import { createAiSdkAdapter, type AiSdkLocal } from "@catamorphic/ai-sdk";
15
+ import { InProcessRunner } from "@catamorphic/agent-runner";
16
+
17
+ const adapter = createAiSdkAdapter({
18
+ model: anthropic("claude-sonnet-4-5"),
19
+ resolveModel: (id) => anthropic(id), // enables per-attempt model overrides
20
+ effort: "medium",
21
+ instructions: "Optional host-level instructions.",
22
+ });
23
+
24
+ const local: AiSdkLocal = {
25
+ sandbox: { provider: sandboxProvider, sandboxId, workingDirectory },
26
+ readableRoots: [pastedFilesDirectory],
27
+ shell: chatShellState, // kept by the host across a chat's attempts
28
+ };
29
+ const runner = new InProcessRunner({
30
+ adapters: { [adapter.id]: adapter },
31
+ version,
32
+ local,
33
+ });
34
+ runner.send({ id: commandId, command: { kind: "start", attempt } });
35
+ ```
36
+
37
+ The host constructs the `LanguageModel`; this package never selects
38
+ providers or reads model credentials. Everything per turn arrives in the
39
+ `AttemptStart`: model and effort overrides, the system prompt, turn context,
40
+ input, MCP servers and their tool policies, host tools, plugins.
41
+
42
+ ## What it does
43
+
44
+ - Streams assistant text and reasoning as items, shell commands as
45
+ `command` items, file writes and edits as `file_change` items, and MCP and
46
+ host tools as `tool_call` items; reasoning headings become the live status.
47
+ - Asks questions (`ask_user`), approvals (policed MCP servers) and MCP
48
+ elicitations as runtime requests through the host.
49
+ - Takes steered input before its next model step, and stops on interrupt.
50
+ - Stores its native thread, the AI SDK message history, with Work one step
51
+ at a time (`nativeState: "store"`), so a later turn resumes on any
52
+ replica or after a restart. A native retry (`input: null`) re-runs the
53
+ last turn on that history, and a fork copies a thread through a turn.
54
+
55
+ ## Tests
56
+
57
+ `@catamorphic/ai-sdk/testing` replays recorded model transcripts (the
58
+ provider's stream parts, call by call) as a `LanguageModel`, so tests
59
+ replace only the model transport. `recordModel` captures a transcript from
60
+ a live model; `replyCall`, `toolCallsCall`, `rejectedCall` and friends
61
+ write one by hand.
62
+
63
+ ```ts
64
+ import { replayModel, replyCall, toolCallsCall } from "@catamorphic/ai-sdk/testing";
65
+
66
+ const replay = replayModel({
67
+ calls: [
68
+ toolCallsCall([{ id: "c1", name: "bash", input: { command: "ls" } }]),
69
+ replyCall("Listed."),
70
+ ],
71
+ });
72
+ const adapter = createAiSdkAdapter({ model: replay.model });
73
+ // ...drive a real runner and host; replay.calls holds what the model saw.
74
+ ```
@@ -0,0 +1,86 @@
1
+ import type { AgentEffort } from "@catamorphic/agent-protocol";
2
+ import { type HarnessAdapter, type McpServerSpec } from "@catamorphic/agent-protocol/runner";
3
+ import { type ConnectedMcpServer, type ElicitHandler } from "@catamorphic/mcp";
4
+ import { type LanguageModel } from "ai";
5
+ import type { ShellState } from "./shell.js";
6
+ import { type AiSdkSandboxProvider } from "./tools.js";
7
+ /** The adapter id: an attempt's `harness` names it. */
8
+ export declare const AI_SDK_HARNESS = "ai-sdk";
9
+ /** Connects one MCP server for an attempt; `onElicit` asks the person. */
10
+ export type McpConnector = (input: {
11
+ name: string;
12
+ spec: McpServerSpec;
13
+ onElicit: ElicitHandler;
14
+ }) => Promise<ConnectedMcpServer>;
15
+ export interface AiSdkAdapterOptions {
16
+ /** The AI SDK model the host constructed and configured. */
17
+ model: LanguageModel;
18
+ /**
19
+ * Turn a model id into a model, enabling an attempt's `model` override
20
+ * (the host binds provider and key). Without it, overrides are ignored.
21
+ */
22
+ resolveModel?: (modelId: string) => LanguageModel;
23
+ /**
24
+ * Default reasoning effort, mapped onto the provider's native knob
25
+ * (Anthropic thinking budgets, OpenAI reasoning effort). An attempt's
26
+ * `effort` overrides it.
27
+ */
28
+ effort?: AgentEffort;
29
+ /** Host-level instructions, after the built-in ones, before the attempt's. */
30
+ instructions?: string;
31
+ /** Model steps one turn may take before it stops; 150 by default. */
32
+ maxSteps?: number;
33
+ /**
34
+ * How an attempt connects its MCP servers; `@catamorphic/mcp` by
35
+ * default. Hosts that pool connections, and tests, supply their own.
36
+ */
37
+ connectMcp?: McpConnector;
38
+ }
39
+ /**
40
+ * Host objects for one attempt (`local` of an in-process runner, never
41
+ * serialized). Without `sandbox` the agent has no file or shell tools,
42
+ * only the host's.
43
+ */
44
+ export type AiSdkLocal = {
45
+ /** The session's sandbox: file and shell tools run on it. */
46
+ sandbox?: {
47
+ provider: AiSdkSandboxProvider;
48
+ sandboxId: string;
49
+ /** The project folder in the provider's filesystem. */
50
+ workingDirectory: string;
51
+ /** The Environment's budget for one foreground command (ADR 0174). */
52
+ commandBudgetSeconds?: number;
53
+ /**
54
+ * The session's environment files (ADRs 0206, 0212), relative to
55
+ * `workingDirectory` or absolute: every shell command loads each that
56
+ * exists first.
57
+ */
58
+ envFiles?: readonly string[];
59
+ };
60
+ /**
61
+ * Directories outside the working directory the `read` tool may read
62
+ * (never write): the host's store of files pasted into the chat.
63
+ */
64
+ readableRoots?: readonly string[];
65
+ /**
66
+ * The chat's shell: where the next command starts and the background
67
+ * commands it owns. Kept by the host across attempts, so a command
68
+ * started in one turn is read or stopped in the next; end them with
69
+ * `stopBackgroundCommands` when the chat closes.
70
+ */
71
+ shell?: ShellState;
72
+ /** The person the attempt runs for, for telemetry. */
73
+ userId?: string;
74
+ };
75
+ /**
76
+ * The built-in agent as a harness adapter (ADR 0198): the Vercel AI SDK
77
+ * tool loop, run in the host's own process (the desktop, the control
78
+ * plane), never in a sandbox bundle. Model calls run in the host; project
79
+ * IO runs on the session's sandbox (`local.sandbox`).
80
+ *
81
+ * Its native thread is the AI SDK message history, stored with Work
82
+ * through `nativeState` one step at a time, so a later turn on another
83
+ * replica or after a restart continues the same history.
84
+ */
85
+ export declare function createAiSdkAdapter(options: AiSdkAdapterOptions): HarnessAdapter;
86
+ //# sourceMappingURL=adapter.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"adapter.d.ts","sourceRoot":"","sources":["../src/adapter.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAEV,WAAW,EAKZ,MAAM,6BAA6B,CAAC;AACrC,OAAO,EAIL,KAAK,cAAc,EAInB,KAAK,aAAa,EAGnB,MAAM,oCAAoC,CAAC;AAC5C,OAAO,EACL,KAAK,kBAAkB,EAEvB,KAAK,aAAa,EAGnB,MAAM,kBAAkB,CAAC;AAO1B,OAAO,EACL,KAAK,aAAa,EAOnB,MAAM,IAAI,CAAC;AAGZ,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAW7C,OAAO,EACL,KAAK,oBAAoB,EAW1B,MAAM,YAAY,CAAC;AAEpB,uDAAuD;AACvD,eAAO,MAAM,cAAc,WAAW,CAAC;AAiCvC,0EAA0E;AAC1E,MAAM,MAAM,YAAY,GAAG,CAAC,KAAK,EAAE;IACjC,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,aAAa,CAAC;IACpB,QAAQ,EAAE,aAAa,CAAC;CACzB,KAAK,OAAO,CAAC,kBAAkB,CAAC,CAAC;AAElC,MAAM,WAAW,mBAAmB;IAClC,4DAA4D;IAC5D,KAAK,EAAE,aAAa,CAAC;IACrB;;;OAGG;IACH,YAAY,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,aAAa,CAAC;IAClD;;;;OAIG;IACH,MAAM,CAAC,EAAE,WAAW,CAAC;IACrB,8EAA8E;IAC9E,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,qEAAqE;IACrE,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB;;;OAGG;IACH,UAAU,CAAC,EAAE,YAAY,CAAC;CAC3B;AAED;;;;GAIG;AACH,MAAM,MAAM,UAAU,GAAG;IACvB,6DAA6D;IAC7D,OAAO,CAAC,EAAE;QACR,QAAQ,EAAE,oBAAoB,CAAC;QAC/B,SAAS,EAAE,MAAM,CAAC;QAClB,uDAAuD;QACvD,gBAAgB,EAAE,MAAM,CAAC;QACzB,sEAAsE;QACtE,oBAAoB,CAAC,EAAE,MAAM,CAAC;QAC9B;;;;WAIG;QACH,QAAQ,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;KAC9B,CAAC;IACF;;;OAGG;IACH,aAAa,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;IAClC;;;;;OAKG;IACH,KAAK,CAAC,EAAE,UAAU,CAAC;IACnB,sDAAsD;IACtD,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB,CAAC;AAEF;;;;;;;;;GASG;AACH,wBAAgB,kBAAkB,CAChC,OAAO,EAAE,mBAAmB,GAC3B,cAAc,CAOhB"}
@@ -0,0 +1,18 @@
1
+ import type { AgentErrorKind } from "@catamorphic/agent-protocol";
2
+ export interface ClassifiedError {
3
+ message: string;
4
+ kind?: AgentErrorKind;
5
+ /**
6
+ * The model provider answered the request with a refusal (a status code,
7
+ * or a recognized provider failure): nothing ran on its side.
8
+ */
9
+ providerRejected: boolean;
10
+ }
11
+ /**
12
+ * Classify a failed model call (ADR 0057's error kinds): `auth` offers a
13
+ * re-connect path, `rate_limit` and `unavailable` explain an outage,
14
+ * `model_incompat` retries with sanitized reasoning history.
15
+ */
16
+ export declare function classifyModelError(error: unknown): ClassifiedError;
17
+ export declare function errorMessage(error: unknown): string;
18
+ //# sourceMappingURL=errors.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../src/errors.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,6BAA6B,CAAC;AAiClE,MAAM,WAAW,eAAe;IAC9B,OAAO,EAAE,MAAM,CAAC;IAChB,IAAI,CAAC,EAAE,cAAc,CAAC;IACtB;;;OAGG;IACH,gBAAgB,EAAE,OAAO,CAAC;CAC3B;AAED;;;;GAIG;AACH,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,OAAO,GAAG,eAAe,CAclE;AAkBD,wBAAgB,YAAY,CAAC,KAAK,EAAE,OAAO,GAAG,MAAM,CAEnD"}
@@ -0,0 +1,6 @@
1
+ export { AI_SDK_HARNESS, type AiSdkAdapterOptions, type AiSdkLocal, createAiSdkAdapter, type McpConnector, } from "./adapter.js";
2
+ export { classifyModelError } from "./errors.js";
3
+ export { type ShellState, stopBackgroundCommands, } from "./shell.js";
4
+ export { entriesThroughTurn, foldThread, parseThreadEntries, type ThreadEntry, } from "./thread.js";
5
+ export { type AiSdkSandboxProvider, mcpModelToolName, pruneEmptyOptionalArgs, } from "./tools.js";
6
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,cAAc,EACd,KAAK,mBAAmB,EACxB,KAAK,UAAU,EACf,kBAAkB,EAClB,KAAK,YAAY,GAClB,MAAM,cAAc,CAAC;AACtB,OAAO,EAAE,kBAAkB,EAAE,MAAM,aAAa,CAAC;AACjD,OAAO,EACL,KAAK,UAAU,EACf,sBAAsB,GACvB,MAAM,YAAY,CAAC;AACpB,OAAO,EACL,kBAAkB,EAClB,UAAU,EACV,kBAAkB,EAClB,KAAK,WAAW,GACjB,MAAM,aAAa,CAAC;AACrB,OAAO,EACL,KAAK,oBAAoB,EACzB,gBAAgB,EAChB,sBAAsB,GACvB,MAAM,YAAY,CAAC"}