@corbat-tech/coco 2.25.3 → 2.25.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/dist/cli/index.js +78 -19
- package/dist/cli/index.js.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +10 -4
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -502,10 +502,10 @@ declare const CocoConfigSchema: z.ZodObject<{
|
|
|
502
502
|
kimi: "kimi";
|
|
503
503
|
"kimi-code": "kimi-code";
|
|
504
504
|
lmstudio: "lmstudio";
|
|
505
|
+
codex: "codex";
|
|
505
506
|
qwen: "qwen";
|
|
506
507
|
deepseek: "deepseek";
|
|
507
508
|
mistral: "mistral";
|
|
508
|
-
codex: "codex";
|
|
509
509
|
copilot: "copilot";
|
|
510
510
|
ollama: "ollama";
|
|
511
511
|
groq: "groq";
|
package/dist/index.js
CHANGED
|
@@ -13323,6 +13323,8 @@ var MODELS_WITHOUT_TEMPERATURE = [
|
|
|
13323
13323
|
"o3",
|
|
13324
13324
|
"o3-mini",
|
|
13325
13325
|
"o4-mini",
|
|
13326
|
+
"gpt-5",
|
|
13327
|
+
"codex",
|
|
13326
13328
|
"kimi-k2.5",
|
|
13327
13329
|
"kimi-k2-0324",
|
|
13328
13330
|
"kimi-latest"
|
|
@@ -14029,12 +14031,13 @@ var OpenAIProvider = class {
|
|
|
14029
14031
|
try {
|
|
14030
14032
|
const model = options?.model ?? this.config.model ?? DEFAULT_MODEL2;
|
|
14031
14033
|
const { input, instructions } = this.convertToResponsesInput(messages, options?.system);
|
|
14034
|
+
const supportsTemp = this.supportsTemperature(model);
|
|
14032
14035
|
const response = await this.client.responses.create({
|
|
14033
14036
|
model,
|
|
14034
14037
|
input,
|
|
14035
14038
|
instructions: instructions ?? void 0,
|
|
14036
14039
|
max_output_tokens: options?.maxTokens ?? this.config.maxTokens ?? 8192,
|
|
14037
|
-
temperature: options?.temperature ?? this.config.temperature ?? 0,
|
|
14040
|
+
...supportsTemp && { temperature: options?.temperature ?? this.config.temperature ?? 0 },
|
|
14038
14041
|
store: false
|
|
14039
14042
|
});
|
|
14040
14043
|
return {
|
|
@@ -14062,13 +14065,14 @@ var OpenAIProvider = class {
|
|
|
14062
14065
|
const model = options?.model ?? this.config.model ?? DEFAULT_MODEL2;
|
|
14063
14066
|
const { input, instructions } = this.convertToResponsesInput(messages, options?.system);
|
|
14064
14067
|
const tools = this.convertToolsForResponses(options.tools);
|
|
14068
|
+
const supportsTemp = this.supportsTemperature(model);
|
|
14065
14069
|
const response = await this.client.responses.create({
|
|
14066
14070
|
model,
|
|
14067
14071
|
input,
|
|
14068
14072
|
instructions: instructions ?? void 0,
|
|
14069
14073
|
tools,
|
|
14070
14074
|
max_output_tokens: options?.maxTokens ?? this.config.maxTokens ?? 8192,
|
|
14071
|
-
temperature: options?.temperature ?? this.config.temperature ?? 0,
|
|
14075
|
+
...supportsTemp && { temperature: options?.temperature ?? this.config.temperature ?? 0 },
|
|
14072
14076
|
store: false
|
|
14073
14077
|
});
|
|
14074
14078
|
let content = "";
|
|
@@ -14113,12 +14117,13 @@ var OpenAIProvider = class {
|
|
|
14113
14117
|
try {
|
|
14114
14118
|
const model = options?.model ?? this.config.model ?? DEFAULT_MODEL2;
|
|
14115
14119
|
const { input, instructions } = this.convertToResponsesInput(messages, options?.system);
|
|
14120
|
+
const supportsTemp = this.supportsTemperature(model);
|
|
14116
14121
|
const stream = await this.client.responses.create({
|
|
14117
14122
|
model,
|
|
14118
14123
|
input,
|
|
14119
14124
|
instructions: instructions ?? void 0,
|
|
14120
14125
|
max_output_tokens: options?.maxTokens ?? this.config.maxTokens ?? 8192,
|
|
14121
|
-
temperature: options?.temperature ?? this.config.temperature ?? 0,
|
|
14126
|
+
...supportsTemp && { temperature: options?.temperature ?? this.config.temperature ?? 0 },
|
|
14122
14127
|
store: false,
|
|
14123
14128
|
stream: true
|
|
14124
14129
|
});
|
|
@@ -14175,12 +14180,13 @@ var OpenAIProvider = class {
|
|
|
14175
14180
|
const model = options?.model ?? this.config.model ?? DEFAULT_MODEL2;
|
|
14176
14181
|
const { input, instructions } = this.convertToResponsesInput(messages, options?.system);
|
|
14177
14182
|
const tools = options.tools.length > 0 ? this.convertToolsForResponses(options.tools) : void 0;
|
|
14183
|
+
const supportsTemp = this.supportsTemperature(model);
|
|
14178
14184
|
const requestParams = {
|
|
14179
14185
|
model,
|
|
14180
14186
|
input,
|
|
14181
14187
|
instructions: instructions ?? void 0,
|
|
14182
14188
|
max_output_tokens: options?.maxTokens ?? this.config.maxTokens ?? 8192,
|
|
14183
|
-
temperature: options?.temperature ?? this.config.temperature ?? 0,
|
|
14189
|
+
...supportsTemp && { temperature: options?.temperature ?? this.config.temperature ?? 0 },
|
|
14184
14190
|
store: false,
|
|
14185
14191
|
stream: true
|
|
14186
14192
|
};
|