@hiper2d/ai-agents 0.11.0 → 0.12.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/dist/index.mjs CHANGED
@@ -969,6 +969,7 @@ var SupportedAiModels = {
969
969
  modelApiName: "grok-4.7",
970
970
  apiKeyName: API_KEY_CONSTANTS.GROK,
971
971
  hasThinking: true,
972
+ reasoningEffort: "high",
972
973
  temperature: 0.7
973
974
  },
974
975
  // Mistral models. Two hybrid entries since 2026-09-18: reasoning is off by default on the
@@ -1017,6 +1018,9 @@ var SupportedAiModels = {
1017
1018
  hasThinking: true,
1018
1019
  // Temperature is omitted from the request: kimi-k3 rejects any value other than 1.
1019
1020
  // Speed samples: 17s (2026-08-04) and 28.9s (2026-08-05) — graded into the >25s tier.
1021
+ // Pinned 'high' 2026-09-22, down from Moonshot's 'max' default: K3 had no levels at
1022
+ // launch and the agent hardcoded max, so this is the first time the knob exists.
1023
+ reasoningEffort: "high",
1020
1024
  tags: ["very-slow", "expensive"]
1021
1025
  },
1022
1026
  // Z.AI models — thinking-only entry (non-thinking variant retired 2026-08-05)
@@ -1531,6 +1535,7 @@ var FUGU_REASONING_EFFORTS = ["high", "xhigh", "max"];
1531
1535
  var META_REASONING_EFFORTS = ["minimal", "low", "medium", "high", "xhigh", "max"];
1532
1536
  var MISTRAL_REASONING_EFFORTS = ["minimal", "low", "medium", "high", "xhigh"];
1533
1537
  var XAI_REASONING_EFFORTS = ["low", "medium", "high", "xhigh"];
1538
+ var KIMI_REASONING_EFFORTS = ["low", "high", "max"];
1534
1539
  function clampReasoningEffort(effort, allowed) {
1535
1540
  const rank = REASONING_EFFORT_SCALE.indexOf(effort);
1536
1541
  let best = allowed[0];
@@ -1553,6 +1558,7 @@ var toMetaEffort = (effort) => clampReasoningEffort(effort, META_REASONING_EFFOR
1553
1558
  var toFuguEffort = (effort) => clampReasoningEffort(effort, FUGU_REASONING_EFFORTS);
1554
1559
  var toMistralEffort = (effort) => clampReasoningEffort(effort, MISTRAL_REASONING_EFFORTS);
1555
1560
  var toXaiEffort = (effort) => clampReasoningEffort(effort, XAI_REASONING_EFFORTS);
1561
+ var toKimiEffort = (effort) => clampReasoningEffort(effort, KIMI_REASONING_EFFORTS);
1556
1562
 
1557
1563
  // src/pricing/token-usage-utils.ts
1558
1564
  function extractTokenUsage(response) {
@@ -3927,8 +3933,8 @@ var KimiAgent = class extends AbstractAgent {
3927
3933
  model: this.model,
3928
3934
  stream: false,
3929
3935
  max_tokens: this.maxOutputTokens,
3930
- // Moonshot's only accepted level; "max" is not in the OpenAI SDK's ReasoningEffort union.
3931
- reasoning_effort: "max"
3936
+ // "max" is not in the OpenAI SDK's ReasoningEffort union, hence the cast.
3937
+ reasoning_effort: toKimiEffort(this.reasoningEffort ?? "max")
3932
3938
  };
3933
3939
  }
3934
3940
  // Log message templates
@@ -5204,6 +5210,7 @@ export {
5204
5210
  Gpt5Agent,
5205
5211
  GrokAgent,
5206
5212
  InMemorySpendStore,
5213
+ KIMI_REASONING_EFFORTS,
5207
5214
  KimiAgent,
5208
5215
  LLM_CONSTANTS,
5209
5216
  MESSAGE_ROLE,
@@ -5310,6 +5317,7 @@ export {
5310
5317
  toFuguEffort,
5311
5318
  toGeminiEffort,
5312
5319
  toGlmEffort,
5320
+ toKimiEffort,
5313
5321
  toMetaEffort,
5314
5322
  toMistralEffort,
5315
5323
  toOpenAIEffort,