openfox 2.0.126 → 2.0.128

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.
Files changed (46) hide show
  1. package/CHANGELOG.md +24 -0
  2. package/dist/CHANGELOG.md +24 -0
  3. package/dist/{chat-handler-OJ4XBQY4.js → chat-handler-3O6AIOID.js} +11 -11
  4. package/dist/{chunk-ZS55MMG6.js → chunk-4MXY7ELN.js} +81 -48
  5. package/dist/{chunk-76A3E4LK.js → chunk-53R7QNZG.js} +16 -13
  6. package/dist/{chunk-GJL3QSMP.js → chunk-7ZMOP5LS.js} +16 -1
  7. package/dist/{chunk-T3JVYO3Z.js → chunk-B2RPFZ3U.js} +3 -3
  8. package/dist/{chunk-TP2PGZSE.js → chunk-BQNQJE57.js} +3 -3
  9. package/dist/{chunk-2UPFWNC4.js → chunk-CQW4QASE.js} +4 -4
  10. package/dist/{chunk-FNXTJLCZ.js → chunk-D5QVV3LT.js} +2 -2
  11. package/dist/chunk-ES5635OP.js +7 -0
  12. package/dist/{chunk-CTHRGR4O.js → chunk-FYXZRVOL.js} +2 -2
  13. package/dist/{chunk-HOSFRPPI.js → chunk-JEMPUHAA.js} +2 -2
  14. package/dist/{chunk-H2RZDEVL.js → chunk-LWDL7HWL.js} +7 -7
  15. package/dist/{chunk-6VW4BQMP.js → chunk-OWCJRSOU.js} +9 -9
  16. package/dist/{chunk-KSXCOHHW.js → chunk-R5FAEKXQ.js} +16 -1
  17. package/dist/{chunk-UAAFZEIS.js → chunk-S6ATKIT2.js} +2 -2
  18. package/dist/{chunk-77PJWQR7.js → chunk-VHMZBKWY.js} +5 -5
  19. package/dist/{chunk-LJX7KXRU.js → chunk-VJRLIKLE.js} +2 -2
  20. package/dist/cli/dev.js +1 -1
  21. package/dist/cli/index.js +1 -1
  22. package/dist/{client-YHYIWZY7.js → client-VDXO7IIV.js} +3 -3
  23. package/dist/{compactor-7KPBTFZF.js → compactor-B6IVMDES.js} +4 -4
  24. package/dist/{config-TUCHLIWD.js → config-LOK3LXFH.js} +4 -2
  25. package/dist/{dynamic-context-PYAUG2LP.js → dynamic-context-4WVMNJTZ.js} +2 -2
  26. package/dist/{launch-3F2GCRRF.js → launch-AKIMGAGC.js} +11 -11
  27. package/dist/{orchestrator-BRHIA2KE.js → orchestrator-WLNW7TS7.js} +10 -10
  28. package/dist/package.json +1 -1
  29. package/dist/{processor-2IFXIJXG.js → processor-ZMXU5MOT.js} +10 -10
  30. package/dist/{profiles-3YLLEJ2B.js → profiles-HXGJIPF2.js} +2 -2
  31. package/dist/{provider-6LUA73HF.js → provider-QIOTESLB.js} +6 -6
  32. package/dist/{provider-manager-OQTEXZ7X.js → provider-manager-FVI22EWM.js} +4 -4
  33. package/dist/{serve-WJKFUMLI.js → serve-7M4HCERR.js} +16 -16
  34. package/dist/server/index.js +15 -15
  35. package/dist/{server-6LDC4HU6.js → server-RX5JM7IT.js} +14 -14
  36. package/dist/{service-BRKMLM4C.js → service-F4TWYTKE.js} +5 -5
  37. package/dist/{tasks-DEUZ6BNS.js → tasks-36WHYN3H.js} +5 -5
  38. package/dist/{tools-AOLICK5U.js → tools-WAUWG4PE.js} +8 -8
  39. package/dist/{update-VH75MTCP.js → update-AIVWCRXR.js} +2 -2
  40. package/dist/web/assets/{index-DFMllFkv.css → index-CbX8veVW.css} +1 -1
  41. package/dist/web/assets/index-DtQsFnyQ.js +310 -0
  42. package/dist/web/index.html +2 -2
  43. package/dist/web/sw.js +1 -1
  44. package/package.json +1 -1
  45. package/dist/chunk-ABCCTPBC.js +0 -7
  46. package/dist/web/assets/index-DQ3Wg2OF.js +0 -324
package/CHANGELOG.md CHANGED
@@ -1,5 +1,29 @@
1
1
  # Changelog
2
2
 
3
+ ## 2.0.128 - 2026-08-24
4
+
5
+ ### Enhancements
6
+
7
+ - **Qwen3.8 defaults match its model card** — temperature 1.0, top_p 0.95, top_k 20, and vision support
8
+ - **Qwen3.8's default output budget is now 50k** — up from 16k, clamped to the context window
9
+
10
+ ### Bug Fixes
11
+
12
+ - **"Time since last prompt" hidden in terminal states** — no counter on completed or blocked sessions
13
+
14
+ ## 2.0.127 - 2026-08-22
15
+
16
+ ### Features
17
+
18
+ - **Reorder providers with drag & drop or arrows** — Manage Providers list gains drag handles and arrows
19
+ - **Workspace switch reminders include a commit recipe** — the exact git commands to commit and push
20
+
21
+ ### Enhancements
22
+
23
+ - **Chat feed keeps a minimum width** — sidebars collapse left-first on narrow windows
24
+ - **Manage providers opens in a modal** — no longer buried in the onboarding wizard
25
+ - **Starring a model selects it** — the model picker now selects a starred model for the session
26
+
3
27
  ## 2.0.126 - 2026-08-21
4
28
 
5
29
  ### Bug Fixes
package/dist/CHANGELOG.md CHANGED
@@ -1,5 +1,29 @@
1
1
  # Changelog
2
2
 
3
+ ## 2.0.128 - 2026-08-24
4
+
5
+ ### Enhancements
6
+
7
+ - **Qwen3.8 defaults match its model card** — temperature 1.0, top_p 0.95, top_k 20, and vision support
8
+ - **Qwen3.8's default output budget is now 50k** — up from 16k, clamped to the context window
9
+
10
+ ### Bug Fixes
11
+
12
+ - **"Time since last prompt" hidden in terminal states** — no counter on completed or blocked sessions
13
+
14
+ ## 2.0.127 - 2026-08-22
15
+
16
+ ### Features
17
+
18
+ - **Reorder providers with drag & drop or arrows** — Manage Providers list gains drag handles and arrows
19
+ - **Workspace switch reminders include a commit recipe** — the exact git commands to commit and push
20
+
21
+ ### Enhancements
22
+
23
+ - **Chat feed keeps a minimum width** — sidebars collapse left-first on narrow windows
24
+ - **Manage providers opens in a modal** — no longer buried in the onboarding wizard
25
+ - **Starring a model selects it** — the model picker now selects a starred model for the session
26
+
3
27
  ## 2.0.126 - 2026-08-21
4
28
 
5
29
  ### Bug Fixes
@@ -2,14 +2,14 @@ import {
2
2
  buildRunChatTurnParams,
3
3
  finalizeTurnCompletion,
4
4
  generateSessionNameForSession
5
- } from "./chunk-HOSFRPPI.js";
5
+ } from "./chunk-JEMPUHAA.js";
6
6
  import {
7
7
  runChatTurn
8
- } from "./chunk-2UPFWNC4.js";
9
- import "./chunk-76A3E4LK.js";
10
- import "./chunk-TP2PGZSE.js";
8
+ } from "./chunk-CQW4QASE.js";
9
+ import "./chunk-53R7QNZG.js";
10
+ import "./chunk-BQNQJE57.js";
11
11
  import "./chunk-ZIL6VKLU.js";
12
- import "./chunk-LJX7KXRU.js";
12
+ import "./chunk-VJRLIKLE.js";
13
13
  import "./chunk-GIJUWPRQ.js";
14
14
  import "./chunk-EHFIUXWZ.js";
15
15
  import "./chunk-RV5G7QQU.js";
@@ -18,7 +18,7 @@ import "./chunk-JE7LW7Y6.js";
18
18
  import "./chunk-OAN4BXEW.js";
19
19
  import "./chunk-Y3BSBKHY.js";
20
20
  import "./chunk-J7GAZGZT.js";
21
- import "./chunk-CTHRGR4O.js";
21
+ import "./chunk-FYXZRVOL.js";
22
22
  import "./chunk-7YP4O4XE.js";
23
23
  import "./chunk-KD4W3I6C.js";
24
24
  import {
@@ -34,14 +34,14 @@ import {
34
34
  import "./chunk-66MG44TF.js";
35
35
  import "./chunk-JURM3RPZ.js";
36
36
  import "./chunk-LCLH6ZUL.js";
37
- import "./chunk-T3JVYO3Z.js";
37
+ import "./chunk-B2RPFZ3U.js";
38
38
  import "./chunk-K2QKX4ZJ.js";
39
39
  import "./chunk-J2GP3J3X.js";
40
40
  import "./chunk-KBESUA3W.js";
41
41
  import "./chunk-OSXPQSLW.js";
42
42
  import "./chunk-3B232XG4.js";
43
- import "./chunk-FNXTJLCZ.js";
44
- import "./chunk-GJL3QSMP.js";
43
+ import "./chunk-D5QVV3LT.js";
44
+ import "./chunk-7ZMOP5LS.js";
45
45
  import "./chunk-PBFGJFGC.js";
46
46
  import "./chunk-HNCM3D7Y.js";
47
47
  import "./chunk-KAZWU73N.js";
@@ -51,7 +51,7 @@ import "./chunk-OYBUJIC3.js";
51
51
  import "./chunk-ISE55FOR.js";
52
52
  import "./chunk-K44MW7JJ.js";
53
53
  import "./chunk-KSDWQ6IZ.js";
54
- import "./chunk-KSXCOHHW.js";
54
+ import "./chunk-R5FAEKXQ.js";
55
55
  import "./chunk-CQGTEGKL.js";
56
56
  import "./chunk-YLJ4XMA6.js";
57
57
 
@@ -174,4 +174,4 @@ export {
174
174
  startChatSession,
175
175
  stopSessionExecution
176
176
  };
177
- //# sourceMappingURL=chat-handler-OJ4XBQY4.js.map
177
+ //# sourceMappingURL=chat-handler-3O6AIOID.js.map
@@ -16,10 +16,10 @@ import {
16
16
  terminalManager,
17
17
  tokenFromPassword,
18
18
  verifyPassword
19
- } from "./chunk-6VW4BQMP.js";
19
+ } from "./chunk-OWCJRSOU.js";
20
20
  import {
21
21
  TEMPLATE_VARIABLES
22
- } from "./chunk-77PJWQR7.js";
22
+ } from "./chunk-VHMZBKWY.js";
23
23
  import {
24
24
  createToolRegistry,
25
25
  devServerManager,
@@ -33,7 +33,7 @@ import {
33
33
  setMcpManagerForTools,
34
34
  setMcpTools,
35
35
  setNotifyMcpServersChanged
36
- } from "./chunk-76A3E4LK.js";
36
+ } from "./chunk-53R7QNZG.js";
37
37
  import {
38
38
  deleteOwnedSkill,
39
39
  deleteProjectSkill,
@@ -107,7 +107,7 @@ import {
107
107
  saveWorkflow,
108
108
  saveWorkflowToProject,
109
109
  workflowExists
110
- } from "./chunk-CTHRGR4O.js";
110
+ } from "./chunk-FYXZRVOL.js";
111
111
  import {
112
112
  getSessionDisabledServers,
113
113
  setSessionDisabledServers
@@ -171,10 +171,10 @@ import {
171
171
  detectModel,
172
172
  getLlmStatus,
173
173
  parseDefaultModelSelection
174
- } from "./chunk-T3JVYO3Z.js";
174
+ } from "./chunk-B2RPFZ3U.js";
175
175
  import {
176
176
  VERSION
177
- } from "./chunk-ABCCTPBC.js";
177
+ } from "./chunk-ES5635OP.js";
178
178
  import {
179
179
  agentExists,
180
180
  deleteAgent,
@@ -203,7 +203,7 @@ import {
203
203
  } from "./chunk-3B232XG4.js";
204
204
  import {
205
205
  getModelProfile
206
- } from "./chunk-GJL3QSMP.js";
206
+ } from "./chunk-7ZMOP5LS.js";
207
207
  import {
208
208
  getBackendDisplayName
209
209
  } from "./chunk-PBFGJFGC.js";
@@ -2749,6 +2749,12 @@ function canCompact(currentTokens, maxTokens) {
2749
2749
  }
2750
2750
 
2751
2751
  // src/server/session/manager.ts
2752
+ var WORKSPACE_COMMIT_RECIPE = `
2753
+ To land changes from this workspace into the original repo (its origin is the local repo itself):
2754
+ 1. Commit your work.
2755
+ 2. If the original repo has this branch checked out, a direct push is refused \u2014 push to a temp branch, then in the original repo merge it back and clean up: \`git push origin HEAD:<feature-slug>\` then \`git merge --ff-only <feature-slug> && git branch -d <feature-slug>\`
2756
+ 3. If the original repo is on a different branch, push directly instead: \`git push origin <branch>\`
2757
+ 4. To reach the remote, push from the original repo: \`git push origin <branch>\``;
2752
2758
  var SessionManager = class {
2753
2759
  events = new EventEmitter();
2754
2760
  activeSessionId = null;
@@ -4014,9 +4020,10 @@ var SessionManager = class {
4014
4020
  }
4015
4021
  }
4016
4022
  const wsLabel = target === "original" ? "original" : target;
4023
+ const commitHint = target === "original" ? "" : WORKSPACE_COMMIT_RECIPE;
4017
4024
  const reminderContent = `<system-reminder>
4018
4025
  This session is now operating in workspace "${wsLabel}" on branch "${actualBranch ?? "unknown"}" at ${effectiveWorkdir}.${stalenessHint}
4019
- All file and git operations should use this directory.
4026
+ All file and git operations should use this directory.${commitHint}
4020
4027
  </system-reminder>`;
4021
4028
  this.addMessage(sessionId, {
4022
4029
  role: "user",
@@ -5494,7 +5501,7 @@ function createProviderAuthRoutes(config3, providerManager, registry) {
5494
5501
  try {
5495
5502
  const { challenge, completion } = await adapter.beginLogin({ providerId: provider.id });
5496
5503
  void completion.then(async ({ credentialRef }) => {
5497
- const { loadGlobalConfig, saveGlobalConfig, updateProvider } = await import("./config-TUCHLIWD.js");
5504
+ const { loadGlobalConfig, saveGlobalConfig, updateProvider } = await import("./config-LOK3LXFH.js");
5498
5505
  const globalConfig = await loadGlobalConfig(config3.mode ?? "production", config3.globalConfigPath);
5499
5506
  const updatedConfig = updateProvider(globalConfig, provider.id, { credentialRef, authAdapter: adapter.id });
5500
5507
  await saveGlobalConfig(config3.mode ?? "production", updatedConfig, config3.globalConfigPath);
@@ -5531,7 +5538,7 @@ function createProviderAuthRoutes(config3, providerManager, registry) {
5531
5538
  const ref = provider.credentialRef ?? provider.id;
5532
5539
  await adapter.logout(ref);
5533
5540
  }
5534
- const { loadGlobalConfig, saveGlobalConfig } = await import("./config-TUCHLIWD.js");
5541
+ const { loadGlobalConfig, saveGlobalConfig } = await import("./config-LOK3LXFH.js");
5535
5542
  const globalConfig = await loadGlobalConfig(config3.mode ?? "production", config3.globalConfigPath);
5536
5543
  const updatedConfig = {
5537
5544
  ...globalConfig,
@@ -6031,7 +6038,7 @@ async function createServerHandle(config3) {
6031
6038
  const mcpManager = new McpManager({
6032
6039
  onToolsDiscovered: async (name, tools) => {
6033
6040
  try {
6034
- const { loadGlobalConfig, saveGlobalConfig } = await import("./config-TUCHLIWD.js");
6041
+ const { loadGlobalConfig, saveGlobalConfig } = await import("./config-LOK3LXFH.js");
6035
6042
  const mode = config3.mode ?? "production";
6036
6043
  const globalConfig = await loadGlobalConfig(mode, config3.globalConfigPath);
6037
6044
  const mcpServers2 = {
@@ -6065,7 +6072,7 @@ async function createServerHandle(config3) {
6065
6072
  toolRegistry = createToolRegistry();
6066
6073
  logger.info("MCP tools registered", { count: mcpTools.length });
6067
6074
  }
6068
- const { signalMcpReady } = await import("./server-6LDC4HU6.js");
6075
+ const { signalMcpReady } = await import("./server-RX5JM7IT.js");
6069
6076
  signalMcpReady();
6070
6077
  });
6071
6078
  const app = express();
@@ -6261,9 +6268,9 @@ async function createServerHandle(config3) {
6261
6268
  const sessionFavoriteRouter = express.Router();
6262
6269
  registerSessionFavoriteRoute(sessionFavoriteRouter, sessionManager);
6263
6270
  app.use("/api", sessionFavoriteRouter);
6264
- const { createTasksService } = await import("./service-BRKMLM4C.js");
6265
- const { registerTaskRoutes } = await import("./tasks-DEUZ6BNS.js");
6266
- const { setTasksService } = await import("./tools-AOLICK5U.js");
6271
+ const { createTasksService } = await import("./service-F4TWYTKE.js");
6272
+ const { registerTaskRoutes } = await import("./tasks-36WHYN3H.js");
6273
+ const { setTasksService } = await import("./tools-WAUWG4PE.js");
6267
6274
  const tasksService = createTasksService({
6268
6275
  sessionManager,
6269
6276
  config: config3,
@@ -6592,7 +6599,7 @@ All file and git operations should use this branch.
6592
6599
  app.get("/api/sessions/:id", async (req, res) => {
6593
6600
  const { getEventStore: getEventStore2, combineEventsWithSnapshot } = await import("./events-GMHRX4LF.js");
6594
6601
  const { buildMessagesFromStoredEvents, foldPendingConfirmations } = await import("./folding-7K2GRPF4.js");
6595
- const { getPendingQuestionsForSession } = await import("./tools-AOLICK5U.js");
6602
+ const { getPendingQuestionsForSession } = await import("./tools-WAUWG4PE.js");
6596
6603
  const { getMaxVisibleItems } = await import("./settings-VOWWO4VG.js");
6597
6604
  const session = sessionManager.getSession(req.params.id);
6598
6605
  if (!session) {
@@ -6621,7 +6628,7 @@ All file and git operations should use this branch.
6621
6628
  });
6622
6629
  app.get("/api/sessions/:id/status", async (req, res) => {
6623
6630
  const { projectSessionStatus } = await import("./session-status-6Q5B5PEN.js");
6624
- const { getPendingQuestionsForSession } = await import("./tools-AOLICK5U.js");
6631
+ const { getPendingQuestionsForSession } = await import("./tools-WAUWG4PE.js");
6625
6632
  const { getEventStore: getEventStore2, combineEventsWithSnapshot } = await import("./events-GMHRX4LF.js");
6626
6633
  const { foldPendingConfirmations } = await import("./folding-7K2GRPF4.js");
6627
6634
  const sessionId = req.params["id"];
@@ -6653,8 +6660,8 @@ All file and git operations should use this branch.
6653
6660
  if (!session) {
6654
6661
  return res.status(404).json({ error: "Session not found" });
6655
6662
  }
6656
- const { stopSessionExecution } = await import("./chat-handler-OJ4XBQY4.js");
6657
- const { cancelQuestionsForSession, cancelPathConfirmationsForSession } = await import("./tools-AOLICK5U.js");
6663
+ const { stopSessionExecution } = await import("./chat-handler-3O6AIOID.js");
6664
+ const { cancelQuestionsForSession, cancelPathConfirmationsForSession } = await import("./tools-WAUWG4PE.js");
6658
6665
  sessionManager.clearMessageQueue(sessionId);
6659
6666
  stopSessionExecution(sessionId, sessionManager);
6660
6667
  abortSession(sessionId);
@@ -6765,7 +6772,7 @@ All file and git operations should use this branch.
6765
6772
  if (!result.success) {
6766
6773
  return res.status(500).json({ error: result.error ?? "Failed to set default model" });
6767
6774
  }
6768
- const { loadGlobalConfig, saveGlobalConfig, setDefaultModelSelection } = await import("./config-TUCHLIWD.js");
6775
+ const { loadGlobalConfig, saveGlobalConfig, setDefaultModelSelection } = await import("./config-LOK3LXFH.js");
6769
6776
  const globalConfig = await loadGlobalConfig(config3.mode ?? "production", config3.globalConfigPath);
6770
6777
  const updatedConfig = setDefaultModelSelection(globalConfig, providerId, model);
6771
6778
  await saveGlobalConfig(config3.mode ?? "production", updatedConfig, config3.globalConfigPath);
@@ -6931,7 +6938,7 @@ All file and git operations should use this branch.
6931
6938
  if (alwaysAllow !== void 0 && typeof alwaysAllow !== "boolean") {
6932
6939
  return res.status(400).json({ error: "alwaysAllow must be a boolean if provided" });
6933
6940
  }
6934
- const { providePathConfirmation, getConfirmationSessionId } = await import("./tools-AOLICK5U.js");
6941
+ const { providePathConfirmation, getConfirmationSessionId } = await import("./tools-WAUWG4PE.js");
6935
6942
  const pendingSessionId = getConfirmationSessionId(callId);
6936
6943
  if (!pendingSessionId) {
6937
6944
  return res.status(404).json({ error: "No pending path confirmation with that ID" });
@@ -6946,7 +6953,7 @@ All file and git operations should use this branch.
6946
6953
  const { getEventStore: getEventStore2, combineEventsWithSnapshot: combineEvents } = await import("./events-GMHRX4LF.js");
6947
6954
  const { buildMessagesFromStoredEvents, foldPendingConfirmations } = await import("./folding-7K2GRPF4.js");
6948
6955
  const { createSessionStateMessage } = await import("./protocol-TLODRZSB.js");
6949
- const { getPendingQuestionsForSession } = await import("./tools-AOLICK5U.js");
6956
+ const { getPendingQuestionsForSession } = await import("./tools-WAUWG4PE.js");
6950
6957
  const { getMaxVisibleItems } = await import("./settings-VOWWO4VG.js");
6951
6958
  const eventStore = getEventStore2();
6952
6959
  const { snapshot, events: eventsSinceSnapshot } = eventStore.getEventsSinceSnapshot(sessionId);
@@ -6984,7 +6991,7 @@ All file and git operations should use this branch.
6984
6991
  if (!skip && typeof answer !== "string") {
6985
6992
  return res.status(400).json({ error: "answer is required when not skipping" });
6986
6993
  }
6987
- const { provideAnswer } = await import("./tools-AOLICK5U.js");
6994
+ const { provideAnswer } = await import("./tools-WAUWG4PE.js");
6988
6995
  const found = provideAnswer(callId, answer ?? "", skip ?? false);
6989
6996
  if (!found) {
6990
6997
  return res.status(404).json({ error: "No pending question with that ID" });
@@ -7050,7 +7057,7 @@ All file and git operations should use this branch.
7050
7057
  backend: activeProvider?.backend ?? llmClient.getBackend(),
7051
7058
  model: llmClient.getModel()
7052
7059
  };
7053
- const { runAgentTurn, TurnMetrics } = await import("./orchestrator-BRHIA2KE.js");
7060
+ const { runAgentTurn, TurnMetrics } = await import("./orchestrator-WLNW7TS7.js");
7054
7061
  runAgentTurn(
7055
7062
  {
7056
7063
  sessionManager,
@@ -7088,8 +7095,8 @@ All file and git operations should use this branch.
7088
7095
  if (!session) {
7089
7096
  return res.status(404).json({ error: "Session not found" });
7090
7097
  }
7091
- const { stopSessionExecution } = await import("./chat-handler-OJ4XBQY4.js");
7092
- const { cancelQuestionsForSession, cancelPathConfirmationsForSession } = await import("./tools-AOLICK5U.js");
7098
+ const { stopSessionExecution } = await import("./chat-handler-3O6AIOID.js");
7099
+ const { cancelQuestionsForSession, cancelPathConfirmationsForSession } = await import("./tools-WAUWG4PE.js");
7093
7100
  const queuedMessages = sessionManager.getQueueState(sessionId);
7094
7101
  sessionManager.clearMessageQueue(sessionId);
7095
7102
  stopSessionExecution(sessionId, sessionManager);
@@ -7266,7 +7273,7 @@ All file and git operations should use this branch.
7266
7273
  let visionFallback;
7267
7274
  let globalWorkdir;
7268
7275
  try {
7269
- const { loadGlobalConfig, getVisionFallback } = await import("./config-TUCHLIWD.js");
7276
+ const { loadGlobalConfig, getVisionFallback } = await import("./config-LOK3LXFH.js");
7270
7277
  const globalConfig = await loadGlobalConfig(config3.mode ?? "production", config3.globalConfigPath);
7271
7278
  const fallback = getVisionFallback(globalConfig);
7272
7279
  if (fallback) {
@@ -7468,8 +7475,8 @@ All file and git operations should use this branch.
7468
7475
  const backend = req.query["backend"];
7469
7476
  if (!url) return res.status(400).json({ error: "url is required" });
7470
7477
  try {
7471
- const { fetchModelsWithContext } = await import("./provider-manager-OQTEXZ7X.js");
7472
- const { getModelProfile: getModelProfile2 } = await import("./profiles-3YLLEJ2B.js");
7478
+ const { fetchModelsWithContext } = await import("./provider-manager-FVI22EWM.js");
7479
+ const { getModelProfile: getModelProfile2 } = await import("./profiles-HXGJIPF2.js");
7473
7480
  const { getCatalogEntry } = await import("./model-catalog-ZLOWTQA7.js");
7474
7481
  const models = await fetchModelsWithContext(
7475
7482
  url,
@@ -7539,7 +7546,7 @@ All file and git operations should use this branch.
7539
7546
  });
7540
7547
  return res.json({ success: true, message: { content: response2.content }, raw: response2 });
7541
7548
  }
7542
- const { getModelProfile: getModelProfile2 } = await import("./profiles-3YLLEJ2B.js");
7549
+ const { getModelProfile: getModelProfile2 } = await import("./profiles-HXGJIPF2.js");
7543
7550
  const { getBackendCapabilities } = await import("./backend-4YPEC3J2.js");
7544
7551
  const { buildNonStreamingCreateParams } = await import("./client-pure-CJKM3ACP.js");
7545
7552
  const { OpenAIHttpClient } = await import("./http-client-ROVNSHF6.js");
@@ -7613,7 +7620,7 @@ All file and git operations should use this branch.
7613
7620
  return res.status(400).json({ error: "name, url, and backend are required" });
7614
7621
  }
7615
7622
  try {
7616
- const { loadGlobalConfig, saveGlobalConfig, addProvider, setDefaultModelSelection } = await import("./config-TUCHLIWD.js");
7623
+ const { loadGlobalConfig, saveGlobalConfig, addProvider, setDefaultModelSelection } = await import("./config-LOK3LXFH.js");
7617
7624
  const globalConfig = await loadGlobalConfig(config3.mode ?? "production", config3.globalConfigPath);
7618
7625
  const providerBackend = backend;
7619
7626
  const providerModels = modelConfigs?.length ? buildModelConfigs(modelConfigs) : model ? [{ id: model, contextWindow: 2e5, source: "user" }] : [];
@@ -7654,7 +7661,7 @@ All file and git operations should use this branch.
7654
7661
  app.post("/api/init/config", async (req, res) => {
7655
7662
  const { workdir, visionFallback } = req.body;
7656
7663
  try {
7657
- const { loadGlobalConfig, saveGlobalConfig } = await import("./config-TUCHLIWD.js");
7664
+ const { loadGlobalConfig, saveGlobalConfig } = await import("./config-LOK3LXFH.js");
7658
7665
  const globalConfig = await loadGlobalConfig(config3.mode ?? "production", config3.globalConfigPath);
7659
7666
  const updatedVf = visionFallback ? { ...globalConfig.visionFallback, ...visionFallback } : globalConfig.visionFallback;
7660
7667
  const updatedConfig = {
@@ -7689,7 +7696,7 @@ All file and git operations should use this branch.
7689
7696
  }
7690
7697
  const updates = parsed.data;
7691
7698
  try {
7692
- const { loadGlobalConfig, saveGlobalConfig } = await import("./config-TUCHLIWD.js");
7699
+ const { loadGlobalConfig, saveGlobalConfig } = await import("./config-LOK3LXFH.js");
7693
7700
  const globalConfig = await loadGlobalConfig(config3.mode ?? "production", config3.globalConfigPath);
7694
7701
  const filteredUpdates = Object.fromEntries(Object.entries(updates).filter(([, v]) => v !== void 0));
7695
7702
  const updatedConfig = {
@@ -7731,8 +7738,8 @@ All file and git operations should use this branch.
7731
7738
  }
7732
7739
  const testConfig = parsed.data;
7733
7740
  try {
7734
- const { resolveVisionFallback } = await import("./config-TUCHLIWD.js");
7735
- const { loadGlobalConfig } = await import("./config-TUCHLIWD.js");
7741
+ const { resolveVisionFallback } = await import("./config-LOK3LXFH.js");
7742
+ const { loadGlobalConfig } = await import("./config-LOK3LXFH.js");
7736
7743
  const globalConfig = await loadGlobalConfig(config3.mode ?? "production", config3.globalConfigPath);
7737
7744
  const filteredTestConfig = Object.fromEntries(Object.entries(testConfig).filter(([, v]) => v !== void 0));
7738
7745
  const testVisionFallback = {
@@ -7781,9 +7788,35 @@ All file and git operations should use this branch.
7781
7788
  activeProviderId: providerManager.getActiveProviderId()
7782
7789
  });
7783
7790
  });
7791
+ app.put("/api/providers/order", async (req, res) => {
7792
+ const { providerIds } = req.body;
7793
+ if (!Array.isArray(providerIds) || providerIds.length === 0) {
7794
+ return res.status(400).json({ error: "providerIds must be a non-empty array" });
7795
+ }
7796
+ try {
7797
+ const { loadGlobalConfig, saveGlobalConfig, reorderProviders } = await import("./config-LOK3LXFH.js");
7798
+ const globalConfig = await loadGlobalConfig(config3.mode ?? "production", config3.globalConfigPath);
7799
+ let updatedConfig;
7800
+ try {
7801
+ updatedConfig = reorderProviders(globalConfig, providerIds);
7802
+ } catch {
7803
+ return res.status(400).json({ error: "providerIds must be a permutation of the current provider ids" });
7804
+ }
7805
+ await saveGlobalConfig(config3.mode ?? "production", updatedConfig, config3.globalConfigPath);
7806
+ providerManager.setProviders(updatedConfig.providers, updatedConfig.defaultModelSelection ?? void 0);
7807
+ config3.defaultModelSelection = updatedConfig.defaultModelSelection;
7808
+ res.json({
7809
+ success: true,
7810
+ providers: updatedConfig.providers,
7811
+ activeProviderId: providerManager.getActiveProviderId()
7812
+ });
7813
+ } catch (error) {
7814
+ res.status(500).json({ error: error instanceof Error ? error.message : "Failed to reorder providers" });
7815
+ }
7816
+ });
7784
7817
  app.delete("/api/providers/:id", async (req, res) => {
7785
7818
  const { id } = req.params;
7786
- const { loadGlobalConfig, saveGlobalConfig, removeProvider } = await import("./config-TUCHLIWD.js");
7819
+ const { loadGlobalConfig, saveGlobalConfig, removeProvider } = await import("./config-LOK3LXFH.js");
7787
7820
  const globalConfig = await loadGlobalConfig(config3.mode ?? "production", config3.globalConfigPath);
7788
7821
  const updatedConfig = removeProvider(globalConfig, id);
7789
7822
  await saveGlobalConfig(config3.mode ?? "production", updatedConfig, config3.globalConfigPath);
@@ -7795,7 +7828,7 @@ All file and git operations should use this branch.
7795
7828
  const { id } = req.params;
7796
7829
  const { isLocal } = req.body;
7797
7830
  try {
7798
- const { loadGlobalConfig, saveGlobalConfig, updateProvider } = await import("./config-TUCHLIWD.js");
7831
+ const { loadGlobalConfig, saveGlobalConfig, updateProvider } = await import("./config-LOK3LXFH.js");
7799
7832
  const globalConfig = await loadGlobalConfig(config3.mode ?? "production", config3.globalConfigPath);
7800
7833
  const provider = globalConfig.providers.find((p) => p.id === id);
7801
7834
  if (!provider) {
@@ -7827,7 +7860,7 @@ All file and git operations should use this branch.
7827
7860
  transportAdapter
7828
7861
  } = req.body;
7829
7862
  try {
7830
- const { loadGlobalConfig, saveGlobalConfig, updateProvider } = await import("./config-TUCHLIWD.js");
7863
+ const { loadGlobalConfig, saveGlobalConfig, updateProvider } = await import("./config-LOK3LXFH.js");
7831
7864
  const globalConfig = await loadGlobalConfig(config3.mode ?? "production", config3.globalConfigPath);
7832
7865
  const provider = globalConfig.providers.find((p) => p.id === id);
7833
7866
  if (!provider) {
@@ -7870,7 +7903,7 @@ All file and git operations should use this branch.
7870
7903
  return res.status(400).json({ error: "thinkingEnabled must be a boolean" });
7871
7904
  }
7872
7905
  try {
7873
- const { loadGlobalConfig, saveGlobalConfig, updateProvider } = await import("./config-TUCHLIWD.js");
7906
+ const { loadGlobalConfig, saveGlobalConfig, updateProvider } = await import("./config-LOK3LXFH.js");
7874
7907
  const globalConfig = await loadGlobalConfig(config3.mode ?? "production", config3.globalConfigPath);
7875
7908
  const provider = globalConfig.providers.find((p) => p.id === id);
7876
7909
  if (!provider) {
@@ -7906,7 +7939,7 @@ All file and git operations should use this branch.
7906
7939
  return res.status(400).json({ error: result.error });
7907
7940
  }
7908
7941
  const llmClient = getLLMClient();
7909
- const { loadGlobalConfig, saveGlobalConfig, setDefaultModelSelection } = await import("./config-TUCHLIWD.js");
7942
+ const { loadGlobalConfig, saveGlobalConfig, setDefaultModelSelection } = await import("./config-LOK3LXFH.js");
7910
7943
  const globalConfig = await loadGlobalConfig(config3.mode ?? "production", config3.globalConfigPath);
7911
7944
  const updatedConfig = setDefaultModelSelection(globalConfig, id, llmClient.getModel());
7912
7945
  await saveGlobalConfig(config3.mode ?? "production", updatedConfig, config3.globalConfigPath);
@@ -7933,7 +7966,7 @@ All file and git operations should use this branch.
7933
7966
  });
7934
7967
  async function rebuildMcpTools() {
7935
7968
  const { createMcpTools: createMcpTools2 } = await import("./tool-adapter-FJAFLDZA.js");
7936
- const { setMcpTools: setMcpTools2 } = await import("./tools-AOLICK5U.js");
7969
+ const { setMcpTools: setMcpTools2 } = await import("./tools-WAUWG4PE.js");
7937
7970
  const mcpTools = createMcpTools2(mcpManager);
7938
7971
  setMcpTools2(mcpTools);
7939
7972
  toolRegistry = createToolRegistry();
@@ -8008,7 +8041,7 @@ All file and git operations should use this branch.
8008
8041
  };
8009
8042
  await mcpManager.addServer(name, serverCfg);
8010
8043
  const server = mcpManager.getServer(name);
8011
- const { loadGlobalConfig, saveGlobalConfig } = await import("./config-TUCHLIWD.js");
8044
+ const { loadGlobalConfig, saveGlobalConfig } = await import("./config-LOK3LXFH.js");
8012
8045
  const globalConfig = await loadGlobalConfig(config3.mode ?? "production", config3.globalConfigPath);
8013
8046
  const updatedMcpServers = { ...globalConfig.mcpServers ?? {}, [name]: serverCfg };
8014
8047
  await saveGlobalConfig(
@@ -8069,7 +8102,7 @@ All file and git operations should use this branch.
8069
8102
  return res.status(400).json({ error: "oauth must be a boolean" });
8070
8103
  }
8071
8104
  try {
8072
- const { loadGlobalConfig, saveGlobalConfig } = await import("./config-TUCHLIWD.js");
8105
+ const { loadGlobalConfig, saveGlobalConfig } = await import("./config-LOK3LXFH.js");
8073
8106
  const { applyMcpServerUpdate } = await import("./update-server-SVPV6ZJZ.js");
8074
8107
  const globalConfig = await loadGlobalConfig(config3.mode ?? "production", config3.globalConfigPath);
8075
8108
  const mcpServers2 = { ...globalConfig.mcpServers ?? {} };
@@ -8118,7 +8151,7 @@ All file and git operations should use this branch.
8118
8151
  mcpManager.removeServer(name);
8119
8152
  const { clearMcpOAuthEntry } = await import("./oauth-store-KECHUT54.js");
8120
8153
  await clearMcpOAuthEntry(name);
8121
- const { loadGlobalConfig, saveGlobalConfig } = await import("./config-TUCHLIWD.js");
8154
+ const { loadGlobalConfig, saveGlobalConfig } = await import("./config-LOK3LXFH.js");
8122
8155
  const globalConfig = await loadGlobalConfig(config3.mode ?? "production", config3.globalConfigPath);
8123
8156
  const updatedMcpServers = { ...globalConfig.mcpServers ?? {} };
8124
8157
  delete updatedMcpServers[name];
@@ -8285,7 +8318,7 @@ All file and git operations should use this branch.
8285
8318
  await mcpManager.setToolEnabled(name, toolName, enabled);
8286
8319
  const server = mcpManager.getServer(name);
8287
8320
  if (server) {
8288
- const { loadGlobalConfig, saveGlobalConfig } = await import("./config-TUCHLIWD.js");
8321
+ const { loadGlobalConfig, saveGlobalConfig } = await import("./config-LOK3LXFH.js");
8289
8322
  const globalConfig = await loadGlobalConfig(config3.mode ?? "production", config3.globalConfigPath);
8290
8323
  const mcpServers2 = { ...globalConfig.mcpServers ?? {} };
8291
8324
  const serverCfg = mcpServers2[name];
@@ -8487,7 +8520,7 @@ All file and git operations should use this branch.
8487
8520
  );
8488
8521
  const wss = wssExports.wss;
8489
8522
  deferTasksBroadcast = (projectId, payload) => wssExports.broadcastForProject(projectId, "", { type: "tasks.update", payload });
8490
- const { launchWorkflowRun, abortRunnerRun } = await import("./launch-3F2GCRRF.js");
8523
+ const { launchWorkflowRun, abortRunnerRun } = await import("./launch-AKIMGAGC.js");
8491
8524
  deferTasksLaunchWorkflow = (sessionId, launch) => {
8492
8525
  const effective = sessionManager.resolveEffectiveProviderModel(sessionId);
8493
8526
  let llmClient = getLLMClient();
@@ -8527,7 +8560,7 @@ All file and git operations should use this branch.
8527
8560
  const state = sessionManager.getContextState(sessionId);
8528
8561
  wssExports.broadcastForSession(sessionId, createContextStateMessage(state));
8529
8562
  });
8530
- const { QueueProcessor } = await import("./processor-2IFXIJXG.js");
8563
+ const { QueueProcessor } = await import("./processor-ZMXU5MOT.js");
8531
8564
  const queueProcessor = new QueueProcessor({
8532
8565
  sessionManager,
8533
8566
  providerManager,
@@ -8613,4 +8646,4 @@ export {
8613
8646
  createServerHandle,
8614
8647
  createServer
8615
8648
  };
8616
- //# sourceMappingURL=chunk-ZS55MMG6.js.map
8649
+ //# sourceMappingURL=chunk-4MXY7ELN.js.map
@@ -18,7 +18,7 @@ import {
18
18
  recordLLMFailure,
19
19
  sleepThroughRetryBackoff,
20
20
  streamLLMPure
21
- } from "./chunk-LJX7KXRU.js";
21
+ } from "./chunk-VJRLIKLE.js";
22
22
  import {
23
23
  COMPACTION_PROMPT,
24
24
  buildBasePrompt,
@@ -61,7 +61,7 @@ import {
61
61
  getGateConfig,
62
62
  isTaskConflictError,
63
63
  isTaskGateError
64
- } from "./chunk-CTHRGR4O.js";
64
+ } from "./chunk-FYXZRVOL.js";
65
65
  import {
66
66
  getSessionDisabledServers
67
67
  } from "./chunk-7YP4O4XE.js";
@@ -108,8 +108,9 @@ import {
108
108
  loadAllAgentsDefault
109
109
  } from "./chunk-KBESUA3W.js";
110
110
  import {
111
+ getModelProfile,
111
112
  modelSupportsVision
112
- } from "./chunk-GJL3QSMP.js";
113
+ } from "./chunk-7ZMOP5LS.js";
113
114
  import {
114
115
  OUTPUT_LIMITS,
115
116
  cacheSet,
@@ -132,7 +133,7 @@ import {
132
133
  import {
133
134
  loadGlobalConfig,
134
135
  saveGlobalConfig
135
- } from "./chunk-KSXCOHHW.js";
136
+ } from "./chunk-R5FAEKXQ.js";
136
137
  import {
137
138
  getGlobalConfigDir
138
139
  } from "./chunk-CQGTEGKL.js";
@@ -1961,6 +1962,8 @@ async function runTopLevelAgentLoop(config, turnMetrics) {
1961
1962
  let assistantMsgId;
1962
1963
  let assistantMessageStarted = false;
1963
1964
  for (; ; ) {
1965
+ const attemptClient = resolveClient();
1966
+ const profileDefaultMaxTokens = getModelProfile(attemptClient.getModel()).defaultMaxTokens;
1964
1967
  const requestMessages = await config.getConversationMessages();
1965
1968
  if (requestFailures === 0 && retryLimiter.count() > 0) {
1966
1969
  const continueMsgId = crypto.randomUUID();
@@ -2015,7 +2018,7 @@ ${CONTINUE_PROMPT}` : CONTINUE_PROMPT;
2015
2018
  modelSettings = { ...modelSettings, maxTokens: currentMaxTokensOverride };
2016
2019
  }
2017
2020
  if (modelSettings) {
2018
- const requestedMaxTokens = modelSettings.maxTokens ?? 16384;
2021
+ const requestedMaxTokens = modelSettings.maxTokens ?? profileDefaultMaxTokens;
2019
2022
  modelSettings = { ...modelSettings, maxTokens: Math.min(requestedMaxTokens, availableForOutput) };
2020
2023
  }
2021
2024
  const allAgents = await loadAllAgentsDefault(sessionManager.getProjectWorkdir(sessionId));
@@ -2023,7 +2026,7 @@ ${CONTINUE_PROMPT}` : CONTINUE_PROMPT;
2023
2026
  const streamGen = streamLLMPure({
2024
2027
  messageId: assistantMsgId,
2025
2028
  systemPrompt: assembledRequest.systemPrompt,
2026
- llmClient: resolveClient(),
2029
+ llmClient: attemptClient,
2027
2030
  messages: assembledRequest.messages,
2028
2031
  tools: assembledRequest.tools,
2029
2032
  toolChoice: "auto",
@@ -2057,7 +2060,7 @@ ${CONTINUE_PROMPT}` : CONTINUE_PROMPT;
2057
2060
  if (signal?.aborted) throw new Error("Aborted");
2058
2061
  if (isContextLengthError(attemptResult.error) && contextRetryCount < MAX_CONTEXT_LENGTH_RETRIES) {
2059
2062
  contextRetryCount += 1;
2060
- const currentMax = modelSettings?.maxTokens ?? currentMaxTokensOverride ?? 16384;
2063
+ const currentMax = modelSettings?.maxTokens ?? currentMaxTokensOverride ?? profileDefaultMaxTokens;
2061
2064
  currentMaxTokensOverride = Math.max(256, Math.floor(currentMax / 2));
2062
2065
  continue;
2063
2066
  }
@@ -2143,7 +2146,7 @@ ${CONTINUE_PROMPT}` : CONTINUE_PROMPT;
2143
2146
  currentMaxTokensOverride = void 0;
2144
2147
  if (!compacting) {
2145
2148
  const contextState = sessionManager.getContextState(sessionId);
2146
- const { shouldCompact, appendCompactionPrompt } = await import("./compactor-7KPBTFZF.js");
2149
+ const { shouldCompact, appendCompactionPrompt } = await import("./compactor-B6IVMDES.js");
2147
2150
  if (shouldCompact(
2148
2151
  contextState.currentTokens,
2149
2152
  contextState.maxTokens,
@@ -2157,7 +2160,7 @@ ${CONTINUE_PROMPT}` : CONTINUE_PROMPT;
2157
2160
  if (!compacting && result.finishReason === "length" && result.toolCalls.length === 0) {
2158
2161
  if (truncationRetryCount < MAX_TRUNCATION_RETRIES) {
2159
2162
  truncationRetryCount += 1;
2160
- const currentMaxTokens = result.modelParams?.maxTokens ?? 16384;
2163
+ const currentMaxTokens = result.modelParams?.maxTokens ?? getModelProfile(resolveClient().getModel()).defaultMaxTokens;
2161
2164
  const promptTokens = result.usage.promptTokens;
2162
2165
  const contextWindow = sessionManager.getCurrentModelContext(sessionId, config.mode);
2163
2166
  const newMaxTokens = Math.min(
@@ -2519,7 +2522,7 @@ async function describeImageFromDataUrl(dataUrl, visionModel, options) {
2519
2522
  // src/server/context/image-processor.ts
2520
2523
  async function loadVisionModelFromGlobalConfig() {
2521
2524
  try {
2522
- const { loadGlobalConfig: loadGlobalConfig2, resolveVisionFallback } = await import("./config-TUCHLIWD.js");
2525
+ const { loadGlobalConfig: loadGlobalConfig2, resolveVisionFallback } = await import("./config-LOK3LXFH.js");
2523
2526
  const runtimeConfig = getRuntimeConfig();
2524
2527
  const mode = runtimeConfig.mode ?? "production";
2525
2528
  const globalConfig = await loadGlobalConfig2(mode);
@@ -3168,7 +3171,7 @@ var callSubAgentTool = {
3168
3171
  };
3169
3172
  }
3170
3173
  try {
3171
- const { getToolRegistryForAgent: getToolRegistryForAgent2 } = await import("./tools-AOLICK5U.js");
3174
+ const { getToolRegistryForAgent: getToolRegistryForAgent2 } = await import("./tools-WAUWG4PE.js");
3172
3175
  const toolRegistry = getToolRegistryForAgent2(agentDef);
3173
3176
  const turnMetrics = new TurnMetrics();
3174
3177
  const result = await executeSubAgent({
@@ -4190,7 +4193,7 @@ var mcpConfigTool = createTool(
4190
4193
  mcpNotifyChanged?.(sessionId);
4191
4194
  }
4192
4195
  async function rebuildTools() {
4193
- const { setMcpTools: setMcpTools2 } = await import("./tools-AOLICK5U.js");
4196
+ const { setMcpTools: setMcpTools2 } = await import("./tools-WAUWG4PE.js");
4194
4197
  const mcpTools = createMcpTools(mcpManagerForTools);
4195
4198
  setMcpTools2(mcpTools);
4196
4199
  }
@@ -5115,4 +5118,4 @@ export {
5115
5118
  getToolRegistryForAgent,
5116
5119
  createToolRegistry
5117
5120
  };
5118
- //# sourceMappingURL=chunk-76A3E4LK.js.map
5121
+ //# sourceMappingURL=chunk-53R7QNZG.js.map