@kenkaiiii/gg-ai 5.75.0 → 5.76.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.js CHANGED
@@ -1242,11 +1242,14 @@ function toAnthropicThinking(level, maxTokens, model) {
1242
1242
  effort = "high";
1243
1243
  }
1244
1244
  return {
1245
- // `display` defaults to "omitted" on Fable/Mythos 5.x, Opus 5.x/4.8/4.7,
1246
- // Sonnet 5.x and Haiku 5.5: the model still thinks (and bills for it) but
1247
- // streams empty thinking blocks, so the app shows no reasoning at all.
1248
- // "summarized" opts back in; on Opus/Sonnet 4.6 it is already the default.
1249
- thinking: { type: "adaptive", display: "summarized" },
1245
+ // "omitted" (what Claude Code sends): the model still thinks, but
1246
+ // thinking blocks stream empty (signature only). The app never renders
1247
+ // reasoning text, and "summarized" costs speed on Haiku 5.5: bench/h2h
1248
+ // measured output tok/s over each whole request at 151 (summarized) vs
1249
+ // 191 (omitted); Claude Code 195. Sonnet/Opus 5.5 measured even either way.
1250
+ // The UI's "Thinking…" timer keys off the empty thinking_delta emitted
1251
+ // when a thinking block opens, so it is unaffected.
1252
+ thinking: { type: "adaptive", display: "omitted" },
1250
1253
  maxTokens,
1251
1254
  outputConfig: { effort }
1252
1255
  };
@@ -4863,10 +4866,11 @@ function registerPalsuProvider(config) {
4863
4866
  },
4864
4867
  state,
4865
4868
  getModel(modelName) {
4866
- if (!modelStates.has(modelName)) {
4867
- modelStates.set(modelName, { responses: [] });
4869
+ let ms = modelStates.get(modelName);
4870
+ if (!ms) {
4871
+ ms = { responses: [] };
4872
+ modelStates.set(modelName, ms);
4868
4873
  }
4869
- const ms = modelStates.get(modelName);
4870
4874
  return {
4871
4875
  setResponses(r) {
4872
4876
  ms.responses.length = 0;