workerd 1.20260524.1 → 1.20260526.1
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/bin/workerd +1 -1
- package/install.js +4 -4
- package/lib/main.js +3 -3
- package/package.json +6 -6
- package/worker.mjs +22 -17
package/bin/workerd
CHANGED
|
@@ -122,7 +122,7 @@ by workerd to install the correct binary executable for your current platform.`)
|
|
|
122
122
|
"node_modules",
|
|
123
123
|
".cache",
|
|
124
124
|
"workerd",
|
|
125
|
-
`pnpapi-${pkg.replace("/", "-")}-${"1.
|
|
125
|
+
`pnpapi-${pkg.replace("/", "-")}-${"1.20260526.1"}-${import_path.default.basename(subpath)}`
|
|
126
126
|
);
|
|
127
127
|
if (!import_fs.default.existsSync(binTargetPath)) {
|
|
128
128
|
import_fs.default.mkdirSync(import_path.default.dirname(binTargetPath), { recursive: true });
|
package/install.js
CHANGED
|
@@ -94,10 +94,10 @@ operating system, or missing some shared libraries.`;
|
|
|
94
94
|
console.error(msg);
|
|
95
95
|
return;
|
|
96
96
|
}
|
|
97
|
-
if (stdout !== `workerd ${"2026-05-
|
|
97
|
+
if (stdout !== `workerd ${"2026-05-26"}`) {
|
|
98
98
|
throw new Error(
|
|
99
99
|
`Expected ${JSON.stringify(
|
|
100
|
-
"2026-05-
|
|
100
|
+
"2026-05-26"
|
|
101
101
|
)} but got ${JSON.stringify(stdout)}`
|
|
102
102
|
);
|
|
103
103
|
}
|
|
@@ -152,7 +152,7 @@ function installUsingNPM(pkg, subpath, binPath) {
|
|
|
152
152
|
try {
|
|
153
153
|
import_fs.default.writeFileSync(import_path2.default.join(installDir, "package.json"), "{}");
|
|
154
154
|
import_child_process.default.execSync(
|
|
155
|
-
`npm install --loglevel=error --prefer-offline --no-audit --progress=false ${pkg}@${"1.
|
|
155
|
+
`npm install --loglevel=error --prefer-offline --no-audit --progress=false ${pkg}@${"1.20260526.1"}`,
|
|
156
156
|
{ cwd: installDir, stdio: "pipe", env }
|
|
157
157
|
);
|
|
158
158
|
const installedBinPath = import_path2.default.join(
|
|
@@ -197,7 +197,7 @@ function maybeOptimizePackage(binPath) {
|
|
|
197
197
|
}
|
|
198
198
|
async function downloadDirectlyFromNPM(pkg, subpath, binPath) {
|
|
199
199
|
const unscopedPkg = pkg.substring(pkg.indexOf("/") + 1);
|
|
200
|
-
const url = `https://registry.npmjs.org/${pkg}/-/${unscopedPkg}-${"1.
|
|
200
|
+
const url = `https://registry.npmjs.org/${pkg}/-/${unscopedPkg}-${"1.20260526.1"}.tgz`;
|
|
201
201
|
console.error(`[workerd] Trying to download ${JSON.stringify(url)}`);
|
|
202
202
|
try {
|
|
203
203
|
import_fs.default.writeFileSync(
|
package/lib/main.js
CHANGED
|
@@ -136,7 +136,7 @@ by workerd to install the correct binary executable for your current platform.`)
|
|
|
136
136
|
"node_modules",
|
|
137
137
|
".cache",
|
|
138
138
|
"workerd",
|
|
139
|
-
`pnpapi-${pkg.replace("/", "-")}-${"1.
|
|
139
|
+
`pnpapi-${pkg.replace("/", "-")}-${"1.20260526.1"}-${import_path.default.basename(subpath)}`
|
|
140
140
|
);
|
|
141
141
|
if (!import_fs.default.existsSync(binTargetPath)) {
|
|
142
142
|
import_fs.default.mkdirSync(import_path.default.dirname(binTargetPath), { recursive: true });
|
|
@@ -151,8 +151,8 @@ by workerd to install the correct binary executable for your current platform.`)
|
|
|
151
151
|
// npm/lib/node-path.ts
|
|
152
152
|
var { binPath } = generateBinPath();
|
|
153
153
|
var node_path_default = binPath;
|
|
154
|
-
var compatibilityDate = "2026-05-
|
|
155
|
-
var version = "1.
|
|
154
|
+
var compatibilityDate = "2026-05-26";
|
|
155
|
+
var version = "1.20260526.1";
|
|
156
156
|
// Annotate the CommonJS export names for ESM import in node:
|
|
157
157
|
0 && (module.exports = {
|
|
158
158
|
compatibilityDate,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "workerd",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.20260526.1",
|
|
4
4
|
"description": "👷 workerd, Cloudflare's JavaScript/Wasm Runtime",
|
|
5
5
|
"repository": "https://github.com/cloudflare/workerd",
|
|
6
6
|
"scripts": {
|
|
@@ -14,11 +14,11 @@
|
|
|
14
14
|
"workerd": "bin/workerd"
|
|
15
15
|
},
|
|
16
16
|
"optionalDependencies": {
|
|
17
|
-
"@cloudflare/workerd-darwin-arm64": "1.
|
|
18
|
-
"@cloudflare/workerd-darwin-64": "1.
|
|
19
|
-
"@cloudflare/workerd-linux-arm64": "1.
|
|
20
|
-
"@cloudflare/workerd-linux-64": "1.
|
|
21
|
-
"@cloudflare/workerd-windows-64": "1.
|
|
17
|
+
"@cloudflare/workerd-darwin-arm64": "1.20260526.1",
|
|
18
|
+
"@cloudflare/workerd-darwin-64": "1.20260526.1",
|
|
19
|
+
"@cloudflare/workerd-linux-arm64": "1.20260526.1",
|
|
20
|
+
"@cloudflare/workerd-linux-64": "1.20260526.1",
|
|
21
|
+
"@cloudflare/workerd-windows-64": "1.20260526.1"
|
|
22
22
|
},
|
|
23
23
|
"license": "Apache-2.0"
|
|
24
24
|
}
|
package/worker.mjs
CHANGED
|
@@ -1933,12 +1933,11 @@ export type ChatCompletionChoice = {
|
|
|
1933
1933
|
finish_reason: "stop" | "length" | "tool_calls" | "content_filter" | "function_call";
|
|
1934
1934
|
logprobs: ChatCompletionLogprobs | null;
|
|
1935
1935
|
};
|
|
1936
|
-
|
|
1937
|
-
prompt: string;
|
|
1938
|
-
} & ChatCompletionsCommonOptions;
|
|
1936
|
+
|
|
1939
1937
|
export type ChatCompletionsMessagesInput = {
|
|
1940
1938
|
messages: Array<ChatCompletionMessageParam>;
|
|
1941
1939
|
} & ChatCompletionsCommonOptions;
|
|
1940
|
+
|
|
1942
1941
|
export type ChatCompletionsOutput = {
|
|
1943
1942
|
id: string;
|
|
1944
1943
|
object: string;
|
|
@@ -1949,6 +1948,7 @@ export type ChatCompletionsOutput = {
|
|
|
1949
1948
|
system_fingerprint?: string | null;
|
|
1950
1949
|
service_tier?: "auto" | "default" | "flex" | "scale" | "priority" | null;
|
|
1951
1950
|
};
|
|
1951
|
+
|
|
1952
1952
|
/**
|
|
1953
1953
|
* Workers AI support for OpenAI's Responses API
|
|
1954
1954
|
* Reference: https://github.com/openai/openai-node/blob/master/src/resources/responses/responses.ts
|
|
@@ -6031,11 +6031,11 @@ export declare abstract class Base_Ai_Cf_Pipecat_Ai_Smart_Turn_V2 {
|
|
|
6031
6031
|
postProcessedOutputs: Ai_Cf_Pipecat_Ai_Smart_Turn_V2_Output;
|
|
6032
6032
|
}
|
|
6033
6033
|
export declare abstract class Base_Ai_Cf_Openai_Gpt_Oss_120B {
|
|
6034
|
-
inputs: XOR<ResponsesInput,
|
|
6034
|
+
inputs: XOR<ResponsesInput, ChatCompletionsMessagesInput>;
|
|
6035
6035
|
postProcessedOutputs: XOR<ResponsesOutput, ChatCompletionsOutput>;
|
|
6036
6036
|
}
|
|
6037
6037
|
export declare abstract class Base_Ai_Cf_Openai_Gpt_Oss_20B {
|
|
6038
|
-
inputs: XOR<ResponsesInput,
|
|
6038
|
+
inputs: XOR<ResponsesInput, ChatCompletionsMessagesInput>;
|
|
6039
6039
|
postProcessedOutputs: XOR<ResponsesOutput, ChatCompletionsOutput>;
|
|
6040
6040
|
}
|
|
6041
6041
|
export interface Ai_Cf_Leonardo_Phoenix_1_0_Input {
|
|
@@ -7125,7 +7125,7 @@ export declare abstract class Base_Ai_Cf_Moonshotai_Kimi_K2_5 {
|
|
|
7125
7125
|
postProcessedOutputs: ChatCompletionsOutput;
|
|
7126
7126
|
}
|
|
7127
7127
|
export declare abstract class Base_Ai_Cf_Moonshotai_Kimi_K2_6 {
|
|
7128
|
-
inputs:
|
|
7128
|
+
inputs: ChatCompletionsInput;
|
|
7129
7129
|
postProcessedOutputs: ChatCompletionsOutput;
|
|
7130
7130
|
}
|
|
7131
7131
|
export declare abstract class Base_Ai_Cf_Nvidia_Nemotron_3_120B_A12B {
|
|
@@ -7133,9 +7133,10 @@ export declare abstract class Base_Ai_Cf_Nvidia_Nemotron_3_120B_A12B {
|
|
|
7133
7133
|
postProcessedOutputs: ChatCompletionsOutput;
|
|
7134
7134
|
}
|
|
7135
7135
|
export declare abstract class Base_Ai_Cf_Google_Gemma_4_26B_A4B_IT {
|
|
7136
|
-
inputs:
|
|
7136
|
+
inputs: ChatCompletionsInput;
|
|
7137
7137
|
postProcessedOutputs: ChatCompletionsOutput;
|
|
7138
7138
|
}
|
|
7139
|
+
|
|
7139
7140
|
export interface AiModels {
|
|
7140
7141
|
"@cf/huggingface/distilbert-sst-2-int8": BaseAiTextClassification;
|
|
7141
7142
|
"@cf/stabilityai/stable-diffusion-xl-base-1.0": BaseAiTextToImage;
|
|
@@ -7280,13 +7281,10 @@ export type AiModelsSearchObject = {
|
|
|
7280
7281
|
value: string;
|
|
7281
7282
|
}[];
|
|
7282
7283
|
};
|
|
7283
|
-
|
|
7284
|
-
export type
|
|
7285
|
-
|
|
7286
|
-
|
|
7287
|
-
requests: ChatCompletionsBase[];
|
|
7288
|
-
}
|
|
7289
|
-
>;
|
|
7284
|
+
|
|
7285
|
+
export type ChatCompletionsBase = ChatCompletionsMessagesInput;
|
|
7286
|
+
export type ChatCompletionsInput = ChatCompletionsMessagesInput;
|
|
7287
|
+
|
|
7290
7288
|
export interface InferenceUpstreamError extends Error {}
|
|
7291
7289
|
export interface AiInternalError extends Error {}
|
|
7292
7290
|
export type AiModelListType = Record<string, any>;
|
|
@@ -7347,9 +7345,16 @@ export declare abstract class Ai<
|
|
|
7347
7345
|
options?: AiOptions
|
|
7348
7346
|
): Promise<AiModelList[Name]['postProcessedOutputs']>;
|
|
7349
7347
|
|
|
7350
|
-
// Unknown model (
|
|
7351
|
-
|
|
7352
|
-
|
|
7348
|
+
// Unknown model (fallback).
|
|
7349
|
+
//
|
|
7350
|
+
// The \`Exclude<..., keyof AiModelList>\` constraint forces TypeScript to
|
|
7351
|
+
// route any model name that is a literal key of \`AiModelList\` to one of
|
|
7352
|
+
// the known-model overloads above (so input/output mismatches surface as
|
|
7353
|
+
// type errors rather than silently falling back to \`Record<string, unknown>\`).
|
|
7354
|
+
// Names that aren't in \`AiModelList\` \u2014 e.g. third-party gateway models
|
|
7355
|
+
// like \`"google/nano-banana"\` \u2014 still hit this overload.
|
|
7356
|
+
run<Model extends string>(
|
|
7357
|
+
model: Model extends keyof AiModelList ? never : Model,
|
|
7353
7358
|
inputs: Record<string, unknown>,
|
|
7354
7359
|
options?: AiOptions
|
|
7355
7360
|
): Promise<Record<string, unknown>>;
|