@cloudflare/codemode 0.5.4 → 0.5.5
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 +26 -14
- package/dist/ai.d.ts +3 -3
- package/dist/ai.js +1 -1
- package/dist/ai.js.map +1 -1
- package/dist/browser.d.ts +2 -2
- package/dist/{executor-DLwvEPC7.d.ts → executor-xSJFaECq.d.ts} +2 -2
- package/dist/index.d.ts +3 -3
- package/dist/index.js +65 -2
- package/dist/index.js.map +1 -1
- package/dist/mcp.d.ts +1 -1
- package/dist/{resolve-BFB4vzhC.d.ts → resolve-ClRJA8iy.d.ts} +2 -2
- package/dist/{shared-B1Rs0ONk.d.ts → shared-D5qepsss.d.ts} +2 -2
- package/dist/tanstack-ai.d.ts +3 -3
- package/docs/runtime.md +4 -0
- package/package.json +1 -1
package/dist/mcp.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { l as Executor } from "./executor-
|
|
1
|
+
import { l as Executor } from "./executor-xSJFaECq.js";
|
|
2
2
|
import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
|
|
3
3
|
import { RequestHandlerExtra } from "@modelcontextprotocol/sdk/shared/protocol.js";
|
|
4
4
|
import {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
i as ToolProvider,
|
|
3
3
|
u as ResolvedProvider
|
|
4
|
-
} from "./executor-
|
|
4
|
+
} from "./executor-xSJFaECq.js";
|
|
5
5
|
|
|
6
6
|
//#region src/resolve.d.ts
|
|
7
7
|
/**
|
|
@@ -14,4 +14,4 @@ import {
|
|
|
14
14
|
declare function resolveProvider(provider: ToolProvider): ResolvedProvider;
|
|
15
15
|
//#endregion
|
|
16
16
|
export { resolveProvider as t };
|
|
17
|
-
//# sourceMappingURL=resolve-
|
|
17
|
+
//# sourceMappingURL=resolve-ClRJA8iy.d.ts.map
|
|
@@ -2,7 +2,7 @@ import {
|
|
|
2
2
|
a as ToolProviderTools,
|
|
3
3
|
i as ToolProvider,
|
|
4
4
|
l as Executor
|
|
5
|
-
} from "./executor-
|
|
5
|
+
} from "./executor-xSJFaECq.js";
|
|
6
6
|
|
|
7
7
|
//#region src/shared.d.ts
|
|
8
8
|
declare const DEFAULT_DESCRIPTION =
|
|
@@ -37,4 +37,4 @@ export {
|
|
|
37
37
|
CreateCodeToolOptions as r,
|
|
38
38
|
CodeInput as t
|
|
39
39
|
};
|
|
40
|
-
//# sourceMappingURL=shared-
|
|
40
|
+
//# sourceMappingURL=shared-D5qepsss.d.ts.map
|
package/dist/tanstack-ai.d.ts
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { i as ToolProvider } from "./executor-
|
|
1
|
+
import { i as ToolProvider } from "./executor-xSJFaECq.js";
|
|
2
2
|
import {
|
|
3
3
|
a as normalizeProviders,
|
|
4
4
|
i as DEFAULT_DESCRIPTION,
|
|
5
5
|
n as CodeOutput,
|
|
6
6
|
r as CreateCodeToolOptions,
|
|
7
7
|
t as CodeInput
|
|
8
|
-
} from "./shared-
|
|
9
|
-
import { t as resolveProvider } from "./resolve-
|
|
8
|
+
} from "./shared-D5qepsss.js";
|
|
9
|
+
import { t as resolveProvider } from "./resolve-ClRJA8iy.js";
|
|
10
10
|
import { ServerTool, Tool } from "@tanstack/ai";
|
|
11
11
|
|
|
12
12
|
//#region src/tanstack-ai.d.ts
|
package/docs/runtime.md
CHANGED
|
@@ -138,6 +138,10 @@ In practice, model-generated code is naturally deterministic — it fetches data
|
|
|
138
138
|
|
|
139
139
|
**Issue tool calls sequentially.** The replay cursor assigns each call its sequence number when the call reaches the host, so `await a(); await b();` is stable across runs but `await Promise.all([a(), b()])` is not — the two calls can arrive in either order. On a run that never pauses this is harmless, but if such a run later pauses and resumes, the reordered calls trip divergence detection. Await connector calls one at a time in any run that might pause for approval.
|
|
140
140
|
|
|
141
|
+
## Unawaited tool calls
|
|
142
|
+
|
|
143
|
+
A program can return before a tool call it started has finished, for example `async () => { github.ping(); return 1; }`. When `execute()` settles, the sandbox gets an error for each call still pending, so it can exit and free its Dynamic Worker concurrency slot. The host keeps running those calls to completion, so fire-and-forget calls still take effect, but the program never sees their results.
|
|
144
|
+
|
|
141
145
|
## The tool-call log
|
|
142
146
|
|
|
143
147
|
```ts
|