@jeffreyjyz/opencode-command-code 0.3.18 → 0.3.19

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/catalog.d.ts CHANGED
@@ -15,7 +15,7 @@ export interface CatalogEntry {
15
15
  /** Cheapest plan that serves the model; plans.md names this the access rule. */
16
16
  minPlan: string | null;
17
17
  }
18
- export declare const CATALOG_VERSION: "1.65.2";
18
+ export declare const CATALOG_VERSION: "1.74.1";
19
19
  /** Every model the CLI table carried, keyed by the API's model id. */
20
20
  export declare const MODEL_CATALOG: Readonly<Record<string, CatalogEntry>>;
21
21
  /** Text-only default for any id this table does not list. */
package/dist/index.js CHANGED
@@ -2414,7 +2414,7 @@ function superRefine(fn) {
2414
2414
  // package.json
2415
2415
  var package_default = {
2416
2416
  name: "@jeffreyjyz/opencode-command-code",
2417
- version: "0.3.18",
2417
+ version: "0.3.19",
2418
2418
  description: "Command Code provider + usage dashboard for opencode: two providers (Anthropic wire for Claude, OpenAI wire for everything else) against api.commandcode.ai, live model list, plan gating, /cmd-usage. Requires the cmduse CLI for usage rendering.",
2419
2419
  type: "module",
2420
2420
  main: "dist/index.js",
@@ -2579,10 +2579,18 @@ var MODEL_CATALOG = {
2579
2579
  modalities: ["text", "image"],
2580
2580
  minPlan: "Pro"
2581
2581
  },
2582
+ "claude-sonnet-5-5": {
2583
+ name: "Claude Sonnet 5.5",
2584
+ context: 1e6,
2585
+ efforts: ["low", "medium", "high", "xhigh", "max"],
2586
+ cost: { input: 2, output: 10, cacheRead: 0.2, cacheWrite: 2.5 },
2587
+ modalities: ["text", "image"],
2588
+ minPlan: "GOAT"
2589
+ },
2582
2590
  "deepseek/deepseek-v4-flash": {
2583
2591
  name: "DeepSeek V4 Flash (latest)",
2584
2592
  context: 1e6,
2585
- efforts: ["high", "max"],
2593
+ efforts: ["off", "high", "max"],
2586
2594
  cost: { input: 0.15, output: 0.6, cacheRead: 0.003, cacheWrite: 0 },
2587
2595
  modalities: ["text"],
2588
2596
  minPlan: "Go"
@@ -2598,7 +2606,7 @@ var MODEL_CATALOG = {
2598
2606
  "deepseek/deepseek-v4-flash-vision-exp": {
2599
2607
  name: "DeepSeek V4 Flash Vision (exp)",
2600
2608
  context: 1e6,
2601
- efforts: ["high", "max"],
2609
+ efforts: ["off", "high", "max"],
2602
2610
  cost: { input: 0.15, output: 0.6, cacheRead: 0.003, cacheWrite: 0 },
2603
2611
  modalities: ["text", "image"],
2604
2612
  minPlan: "Go"
@@ -2606,7 +2614,7 @@ var MODEL_CATALOG = {
2606
2614
  "deepseek/deepseek-v4-pro": {
2607
2615
  name: "DeepSeek V4 Pro (latest)",
2608
2616
  context: 1e6,
2609
- efforts: ["high", "max"],
2617
+ efforts: ["off", "high", "max"],
2610
2618
  cost: { input: 0.66, output: 1.98, cacheRead: 0.022, cacheWrite: 0 },
2611
2619
  modalities: ["text"],
2612
2620
  minPlan: "Go"
@@ -2614,11 +2622,19 @@ var MODEL_CATALOG = {
2614
2622
  "deepseek/deepseek-v4.1-flash": {
2615
2623
  name: "DeepSeek V4.1 Flash",
2616
2624
  context: 1e6,
2617
- efforts: ["low", "high", "max"],
2625
+ efforts: ["off", "low", "high", "max"],
2618
2626
  cost: { input: 0.15, output: 0.6, cacheRead: 0.003, cacheWrite: 0 },
2619
2627
  modalities: ["text", "image"],
2620
2628
  minPlan: "Go"
2621
2629
  },
2630
+ "deepseek/deepseek-v4.1-flash-fast": {
2631
+ name: "DeepSeek V4.1 Flash Fast",
2632
+ context: 1e6,
2633
+ efforts: ["off", "low", "high", "max"],
2634
+ cost: { input: 0.16, output: 0.58, cacheRead: 0.016, cacheWrite: 0 },
2635
+ modalities: ["text", "image"],
2636
+ minPlan: "Go"
2637
+ },
2622
2638
  "google/gemini-3.1-flash-lite": {
2623
2639
  name: "Gemini 3.1 Flash Lite",
2624
2640
  context: 1e6,
@@ -2747,6 +2763,14 @@ var MODEL_CATALOG = {
2747
2763
  modalities: ["text", "image"],
2748
2764
  minPlan: "Pro"
2749
2765
  },
2766
+ "gpt-6.1-sol": {
2767
+ name: "GPT-6.1 Sol",
2768
+ context: 1050000,
2769
+ efforts: ["low", "medium", "high", "xhigh", "max"],
2770
+ cost: { input: 2, output: 10, cacheRead: 0.1, cacheWrite: 2.5 },
2771
+ modalities: ["text", "image"],
2772
+ minPlan: "Max"
2773
+ },
2750
2774
  "inclusionai/ling-3.0-flash-sante:free": {
2751
2775
  name: "Ling 3.0 Flash Sante",
2752
2776
  context: 262000,
@@ -2755,6 +2779,14 @@ var MODEL_CATALOG = {
2755
2779
  modalities: ["text"],
2756
2780
  minPlan: "Go"
2757
2781
  },
2782
+ "inclusionai/ling-3.1-flash:free": {
2783
+ name: "Ling 3.1 Flash",
2784
+ context: 262000,
2785
+ efforts: ["low", "medium", "high"],
2786
+ cost: { input: 0, output: 0, cacheRead: 0, cacheWrite: 0 },
2787
+ modalities: ["text"],
2788
+ minPlan: "Go"
2789
+ },
2758
2790
  "meituan/LongCat-2.0": {
2759
2791
  name: "LongCat 2.0",
2760
2792
  context: 1050000,
@@ -2974,7 +3006,7 @@ var MODEL_CATALOG = {
2974
3006
  "stealth/space-bunny-alpha": {
2975
3007
  name: "Space Bunny Alpha",
2976
3008
  context: 1e6,
2977
- efforts: ["low", "medium", "high"],
3009
+ efforts: ["low", "medium", "high", "max"],
2978
3010
  cost: { input: 0, output: 0, cacheRead: 0, cacheWrite: 0 },
2979
3011
  modalities: ["text", "image"],
2980
3012
  minPlan: "Go"
@@ -3055,7 +3087,7 @@ var MODEL_CATALOG = {
3055
3087
  name: "Grok 4.7",
3056
3088
  context: 500000,
3057
3089
  efforts: ["low", "medium", "high", "xhigh"],
3058
- cost: { input: 1.2, output: 3.6, cacheRead: 0.3, cacheWrite: 0 },
3090
+ cost: { input: 2, output: 6, cacheRead: 0.5, cacheWrite: 0 },
3059
3091
  modalities: ["text", "image"],
3060
3092
  minPlan: "GOAT"
3061
3093
  },
@@ -3318,9 +3350,10 @@ async function resolveKey(getAuth) {
3318
3350
  }
3319
3351
  // ../core/gating.json
3320
3352
  var gating_default = {
3321
- extractedAt: "2026-09-27T06:27:06.878Z",
3322
- cliVersion: "1.66.0",
3353
+ extractedAt: "2026-10-03T05:21:43.847Z",
3354
+ cliVersion: "1.74.1",
3323
3355
  categories: {
3356
+ "claude-sonnet-5-5": "opensource",
3324
3357
  "claude-sonnet-5": "premium",
3325
3358
  "claude-sonnet-4-6": "premium",
3326
3359
  "claude-fable-5-1": "premium",
@@ -3334,6 +3367,7 @@ var gating_default = {
3334
3367
  "gpt-5.6-terra": "premium",
3335
3368
  "gpt-5.6-luna": "opensource",
3336
3369
  "gpt-6-astra": "premium",
3370
+ "gpt-6.1-sol": "premium",
3337
3371
  "gpt-6-sol": "premium",
3338
3372
  "gpt-6-luna": "opensource",
3339
3373
  "gpt-5.5": "premium",
@@ -3367,6 +3401,7 @@ var gating_default = {
3367
3401
  "deepseek/deepseek-v4-pro": "opensource",
3368
3402
  "deepseek/deepseek-v4-flash": "opensource",
3369
3403
  "deepseek/deepseek-v4.1-flash": "opensource",
3404
+ "deepseek/deepseek-v4.1-flash-fast": "opensource",
3370
3405
  "moonshotai/Kimi-K3": "opensource",
3371
3406
  "moonshotai/Kimi-K2.7-Code": "opensource",
3372
3407
  "moonshotai/Kimi-K2.7-Code-Highspeed": "opensource",
@@ -3395,6 +3430,7 @@ var gating_default = {
3395
3430
  "meituan/LongCat-2.0": "opensource",
3396
3431
  "meituan/LongCat-2.0:free": "opensource",
3397
3432
  "inclusionai/ling-3.0-flash-sante:free": "opensource",
3433
+ "inclusionai/ling-3.1-flash:free": "opensource",
3398
3434
  "stepfun/Step-5-Preview": "opensource",
3399
3435
  "stepfun/Step-3.7-Flash": "opensource",
3400
3436
  "stepfun/Step-3.5-Flash": "opensource",
@@ -3416,7 +3452,24 @@ var gating_default = {
3416
3452
  "vercel-ai-gateway:xiaomi/mimo-v2.6-pro-ultraspeed",
3417
3453
  "openrouter:google/gemini-3.7-flash",
3418
3454
  "vercel-ai-gateway:google/gemini-3.8-flash",
3419
- "vercel-ai-gateway:gpt-5.6-sol"
3455
+ "vercel-ai-gateway:gpt-5.6-sol",
3456
+ "anthropic:claude-sonnet-5-5"
3457
+ ]
3458
+ },
3459
+ "individual-go-v1": {
3460
+ allowedCategories: [
3461
+ "opensource"
3462
+ ],
3463
+ blockedModels: [
3464
+ "vercel-ai-gateway:meta/muse-spark-1.2",
3465
+ "vercel-ai-gateway:meta/muse-spark-1.3",
3466
+ "vercel-ai-gateway:xai/grok-4.6",
3467
+ "vercel-ai-gateway:xai/grok-4.7",
3468
+ "vercel-ai-gateway:xiaomi/mimo-v2.6-pro-ultraspeed",
3469
+ "openrouter:google/gemini-3.7-flash",
3470
+ "vercel-ai-gateway:google/gemini-3.8-flash",
3471
+ "vercel-ai-gateway:gpt-5.6-sol",
3472
+ "anthropic:claude-sonnet-5-5"
3420
3473
  ]
3421
3474
  },
3422
3475
  "individual-goat": {
@@ -3440,6 +3493,7 @@ var gating_default = {
3440
3493
  "anthropic:claude-opus-4-6",
3441
3494
  "anthropic:claude-opus-4-5-20251101",
3442
3495
  "openai:gpt-6-astra",
3496
+ "openai:gpt-6.1-sol",
3443
3497
  "vercel-ai-gateway:sakana/fugu-ultra"
3444
3498
  ]
3445
3499
  },
@@ -3458,6 +3512,7 @@ var gating_default = {
3458
3512
  "anthropic:claude-opus-4-6",
3459
3513
  "anthropic:claude-opus-4-5-20251101",
3460
3514
  "openai:gpt-6-astra",
3515
+ "openai:gpt-6.1-sol",
3461
3516
  "vercel-ai-gateway:sakana/fugu-ultra"
3462
3517
  ]
3463
3518
  },
@@ -3466,7 +3521,9 @@ var gating_default = {
3466
3521
  "premium",
3467
3522
  "opensource"
3468
3523
  ],
3469
- blockedModels: []
3524
+ blockedModels: [
3525
+ "openai:gpt-6.1-sol"
3526
+ ]
3470
3527
  },
3471
3528
  "individual-max": {
3472
3529
  allowedCategories: [
@@ -3491,6 +3548,7 @@ var gating_default = {
3491
3548
  }
3492
3549
  },
3493
3550
  knownModels: [
3551
+ "claude-sonnet-5",
3494
3552
  "claude-sonnet-4-6",
3495
3553
  "claude-fable-5-1",
3496
3554
  "claude-fable-5",
@@ -3500,6 +3558,7 @@ var gating_default = {
3500
3558
  "claude-opus-4-7",
3501
3559
  "claude-haiku-4-5-20251001",
3502
3560
  "gpt-6-astra",
3561
+ "gpt-6.1-sol",
3503
3562
  "gpt-6-sol",
3504
3563
  "gpt-6-luna",
3505
3564
  "gpt-5.6-sol",
@@ -3517,6 +3576,7 @@ var gating_default = {
3517
3576
  "deepseek/deepseek-v4-flash-vision-exp",
3518
3577
  "deepseek/deepseek-v4-flash-fast",
3519
3578
  "deepseek/deepseek-v4.1-flash",
3579
+ "deepseek/deepseek-v4.1-flash-fast",
3520
3580
  "moonshotai/Kimi-K2.7-Code",
3521
3581
  "moonshotai/Kimi-K2.7-Code-Highspeed",
3522
3582
  "moonshotai/Kimi-K2.6",
@@ -3562,9 +3622,10 @@ var gating_default = {
3562
3622
  "poolside/laguna-s-2.1-free",
3563
3623
  "inclusionai/ling-3.0-flash-free",
3564
3624
  "inclusionai/ling-3.0-flash-sante:free",
3625
+ "inclusionai/ling-3.1-flash:free",
3565
3626
  "stealth/space-bunny-alpha",
3566
3627
  "stealth/pixel-canary",
3567
- "claude-sonnet-5",
3628
+ "claude-sonnet-5-5",
3568
3629
  "MiniMaxAI/MiniMax-M3-Free",
3569
3630
  "MiniMaxAI/MiniMax-M3",
3570
3631
  "MiniMaxAI/MiniMax-M2.7",
@@ -15,15 +15,20 @@ export declare function rememberSnapshot(snapshot: Usage): void;
15
15
  export declare function seededRows(): SidebarRow[];
16
16
  /**
17
17
  * Keep the last figure for a model. Keyed canonically because the session's id
18
- * and the stored `modelID` differ by vendor prefix and punctuation.
18
+ * and the stored `modelID` differ by vendor prefix and punctuation, and by the
19
+ * session too: the figure is the model's spend *in a conversation*, which the
20
+ * panel divides by that session's own total, so reusing it in another session
21
+ * counted one conversation's spend against another's and read as "over 100% of
22
+ * session".
19
23
  */
20
- export declare function rememberModelUsage(id: string, usage: ModelUsage): void;
24
+ export declare function rememberModelUsage(id: string, usage: ModelUsage, session?: string): void;
21
25
  /**
22
- * The remembered figure for `id`, or undefined when that model is unseen. An
23
- * undefined id is the frame during a session switch: keeping the previous row up
24
- * beats blanking it, the same call `wasOurs` makes for the account block.
26
+ * The remembered figure for `id` in `session`, or undefined when that model is
27
+ * unseen or the figure belongs to a different conversation. An undefined id is
28
+ * the frame during a session switch: keeping the previous row up beats blanking
29
+ * it, the same call `wasOurs` makes for the account block.
25
30
  */
26
- export declare function seededModelUsage(id: string | undefined): ModelUsage | undefined;
31
+ export declare function seededModelUsage(id: string | undefined, session?: string): ModelUsage | undefined;
27
32
  /** Keep a catalog for the next panel that needs it. An empty map is never
28
33
  * remembered: it cannot be distinguished from "mpc returned nothing" and would
29
34
  * wipe a good catalog. */
package/dist/tui.js CHANGED
@@ -131,9 +131,10 @@ import { RGBA } from "@opentui/core";
131
131
  import { For, Show } from "solid-js";
132
132
  // ../core/gating.json
133
133
  var gating_default = {
134
- extractedAt: "2026-09-27T06:27:06.878Z",
135
- cliVersion: "1.66.0",
134
+ extractedAt: "2026-10-03T05:21:43.847Z",
135
+ cliVersion: "1.74.1",
136
136
  categories: {
137
+ "claude-sonnet-5-5": "opensource",
137
138
  "claude-sonnet-5": "premium",
138
139
  "claude-sonnet-4-6": "premium",
139
140
  "claude-fable-5-1": "premium",
@@ -147,6 +148,7 @@ var gating_default = {
147
148
  "gpt-5.6-terra": "premium",
148
149
  "gpt-5.6-luna": "opensource",
149
150
  "gpt-6-astra": "premium",
151
+ "gpt-6.1-sol": "premium",
150
152
  "gpt-6-sol": "premium",
151
153
  "gpt-6-luna": "opensource",
152
154
  "gpt-5.5": "premium",
@@ -180,6 +182,7 @@ var gating_default = {
180
182
  "deepseek/deepseek-v4-pro": "opensource",
181
183
  "deepseek/deepseek-v4-flash": "opensource",
182
184
  "deepseek/deepseek-v4.1-flash": "opensource",
185
+ "deepseek/deepseek-v4.1-flash-fast": "opensource",
183
186
  "moonshotai/Kimi-K3": "opensource",
184
187
  "moonshotai/Kimi-K2.7-Code": "opensource",
185
188
  "moonshotai/Kimi-K2.7-Code-Highspeed": "opensource",
@@ -208,6 +211,7 @@ var gating_default = {
208
211
  "meituan/LongCat-2.0": "opensource",
209
212
  "meituan/LongCat-2.0:free": "opensource",
210
213
  "inclusionai/ling-3.0-flash-sante:free": "opensource",
214
+ "inclusionai/ling-3.1-flash:free": "opensource",
211
215
  "stepfun/Step-5-Preview": "opensource",
212
216
  "stepfun/Step-3.7-Flash": "opensource",
213
217
  "stepfun/Step-3.5-Flash": "opensource",
@@ -229,7 +233,24 @@ var gating_default = {
229
233
  "vercel-ai-gateway:xiaomi/mimo-v2.6-pro-ultraspeed",
230
234
  "openrouter:google/gemini-3.7-flash",
231
235
  "vercel-ai-gateway:google/gemini-3.8-flash",
232
- "vercel-ai-gateway:gpt-5.6-sol"
236
+ "vercel-ai-gateway:gpt-5.6-sol",
237
+ "anthropic:claude-sonnet-5-5"
238
+ ]
239
+ },
240
+ "individual-go-v1": {
241
+ allowedCategories: [
242
+ "opensource"
243
+ ],
244
+ blockedModels: [
245
+ "vercel-ai-gateway:meta/muse-spark-1.2",
246
+ "vercel-ai-gateway:meta/muse-spark-1.3",
247
+ "vercel-ai-gateway:xai/grok-4.6",
248
+ "vercel-ai-gateway:xai/grok-4.7",
249
+ "vercel-ai-gateway:xiaomi/mimo-v2.6-pro-ultraspeed",
250
+ "openrouter:google/gemini-3.7-flash",
251
+ "vercel-ai-gateway:google/gemini-3.8-flash",
252
+ "vercel-ai-gateway:gpt-5.6-sol",
253
+ "anthropic:claude-sonnet-5-5"
233
254
  ]
234
255
  },
235
256
  "individual-goat": {
@@ -253,6 +274,7 @@ var gating_default = {
253
274
  "anthropic:claude-opus-4-6",
254
275
  "anthropic:claude-opus-4-5-20251101",
255
276
  "openai:gpt-6-astra",
277
+ "openai:gpt-6.1-sol",
256
278
  "vercel-ai-gateway:sakana/fugu-ultra"
257
279
  ]
258
280
  },
@@ -271,6 +293,7 @@ var gating_default = {
271
293
  "anthropic:claude-opus-4-6",
272
294
  "anthropic:claude-opus-4-5-20251101",
273
295
  "openai:gpt-6-astra",
296
+ "openai:gpt-6.1-sol",
274
297
  "vercel-ai-gateway:sakana/fugu-ultra"
275
298
  ]
276
299
  },
@@ -279,7 +302,9 @@ var gating_default = {
279
302
  "premium",
280
303
  "opensource"
281
304
  ],
282
- blockedModels: []
305
+ blockedModels: [
306
+ "openai:gpt-6.1-sol"
307
+ ]
283
308
  },
284
309
  "individual-max": {
285
310
  allowedCategories: [
@@ -304,6 +329,7 @@ var gating_default = {
304
329
  }
305
330
  },
306
331
  knownModels: [
332
+ "claude-sonnet-5",
307
333
  "claude-sonnet-4-6",
308
334
  "claude-fable-5-1",
309
335
  "claude-fable-5",
@@ -313,6 +339,7 @@ var gating_default = {
313
339
  "claude-opus-4-7",
314
340
  "claude-haiku-4-5-20251001",
315
341
  "gpt-6-astra",
342
+ "gpt-6.1-sol",
316
343
  "gpt-6-sol",
317
344
  "gpt-6-luna",
318
345
  "gpt-5.6-sol",
@@ -330,6 +357,7 @@ var gating_default = {
330
357
  "deepseek/deepseek-v4-flash-vision-exp",
331
358
  "deepseek/deepseek-v4-flash-fast",
332
359
  "deepseek/deepseek-v4.1-flash",
360
+ "deepseek/deepseek-v4.1-flash-fast",
333
361
  "moonshotai/Kimi-K2.7-Code",
334
362
  "moonshotai/Kimi-K2.7-Code-Highspeed",
335
363
  "moonshotai/Kimi-K2.6",
@@ -375,9 +403,10 @@ var gating_default = {
375
403
  "poolside/laguna-s-2.1-free",
376
404
  "inclusionai/ling-3.0-flash-free",
377
405
  "inclusionai/ling-3.0-flash-sante:free",
406
+ "inclusionai/ling-3.1-flash:free",
378
407
  "stealth/space-bunny-alpha",
379
408
  "stealth/pixel-canary",
380
- "claude-sonnet-5",
409
+ "claude-sonnet-5-5",
381
410
  "MiniMaxAI/MiniMax-M3-Free",
382
411
  "MiniMaxAI/MiniMax-M3",
383
412
  "MiniMaxAI/MiniMax-M2.7",
@@ -611,7 +640,7 @@ function modelRows(meta, usage, session, fallbackName) {
611
640
  if (usage) {
612
641
  rows.push(["Usage (this model)", `${count(usage.requests)} req`, "base"]);
613
642
  const spend = usage.cost > 0 ? money(usage.cost) : "";
614
- const share = usage.cost > 0 && session && session.cost > 0 ? `${Math.round(usage.cost / session.cost * 100)}% of session` : "";
643
+ const share = usage.cost > 0 && session && session.cost > 0 ? `${Math.min(100, Math.round(usage.cost / session.cost * 100))}% of session` : "";
615
644
  const detail = [spend, share].filter(Boolean).join(" \xB7 ");
616
645
  if (detail)
617
646
  rows.push(["", detail, "muted"]);
@@ -925,10 +954,23 @@ var MODEL_CATALOG = {
925
954
  modalities: ["text", "image"],
926
955
  minPlan: "Pro"
927
956
  },
957
+ "claude-sonnet-5-5": {
958
+ name: "Claude Sonnet 5.5",
959
+ context: 1e6,
960
+ efforts: ["low", "medium", "high", "xhigh", "max"],
961
+ cost: {
962
+ input: 2,
963
+ output: 10,
964
+ cacheRead: 0.2,
965
+ cacheWrite: 2.5
966
+ },
967
+ modalities: ["text", "image"],
968
+ minPlan: "GOAT"
969
+ },
928
970
  "deepseek/deepseek-v4-flash": {
929
971
  name: "DeepSeek V4 Flash (latest)",
930
972
  context: 1e6,
931
- efforts: ["high", "max"],
973
+ efforts: ["off", "high", "max"],
932
974
  cost: {
933
975
  input: 0.15,
934
976
  output: 0.6,
@@ -954,7 +996,7 @@ var MODEL_CATALOG = {
954
996
  "deepseek/deepseek-v4-flash-vision-exp": {
955
997
  name: "DeepSeek V4 Flash Vision (exp)",
956
998
  context: 1e6,
957
- efforts: ["high", "max"],
999
+ efforts: ["off", "high", "max"],
958
1000
  cost: {
959
1001
  input: 0.15,
960
1002
  output: 0.6,
@@ -967,7 +1009,7 @@ var MODEL_CATALOG = {
967
1009
  "deepseek/deepseek-v4-pro": {
968
1010
  name: "DeepSeek V4 Pro (latest)",
969
1011
  context: 1e6,
970
- efforts: ["high", "max"],
1012
+ efforts: ["off", "high", "max"],
971
1013
  cost: {
972
1014
  input: 0.66,
973
1015
  output: 1.98,
@@ -980,7 +1022,7 @@ var MODEL_CATALOG = {
980
1022
  "deepseek/deepseek-v4.1-flash": {
981
1023
  name: "DeepSeek V4.1 Flash",
982
1024
  context: 1e6,
983
- efforts: ["low", "high", "max"],
1025
+ efforts: ["off", "low", "high", "max"],
984
1026
  cost: {
985
1027
  input: 0.15,
986
1028
  output: 0.6,
@@ -990,6 +1032,19 @@ var MODEL_CATALOG = {
990
1032
  modalities: ["text", "image"],
991
1033
  minPlan: "Go"
992
1034
  },
1035
+ "deepseek/deepseek-v4.1-flash-fast": {
1036
+ name: "DeepSeek V4.1 Flash Fast",
1037
+ context: 1e6,
1038
+ efforts: ["off", "low", "high", "max"],
1039
+ cost: {
1040
+ input: 0.16,
1041
+ output: 0.58,
1042
+ cacheRead: 0.016,
1043
+ cacheWrite: 0
1044
+ },
1045
+ modalities: ["text", "image"],
1046
+ minPlan: "Go"
1047
+ },
993
1048
  "google/gemini-3.1-flash-lite": {
994
1049
  name: "Gemini 3.1 Flash Lite",
995
1050
  context: 1e6,
@@ -1198,6 +1253,19 @@ var MODEL_CATALOG = {
1198
1253
  modalities: ["text", "image"],
1199
1254
  minPlan: "Pro"
1200
1255
  },
1256
+ "gpt-6.1-sol": {
1257
+ name: "GPT-6.1 Sol",
1258
+ context: 1050000,
1259
+ efforts: ["low", "medium", "high", "xhigh", "max"],
1260
+ cost: {
1261
+ input: 2,
1262
+ output: 10,
1263
+ cacheRead: 0.1,
1264
+ cacheWrite: 2.5
1265
+ },
1266
+ modalities: ["text", "image"],
1267
+ minPlan: "Max"
1268
+ },
1201
1269
  "inclusionai/ling-3.0-flash-sante:free": {
1202
1270
  name: "Ling 3.0 Flash Sante",
1203
1271
  context: 262000,
@@ -1211,6 +1279,19 @@ var MODEL_CATALOG = {
1211
1279
  modalities: ["text"],
1212
1280
  minPlan: "Go"
1213
1281
  },
1282
+ "inclusionai/ling-3.1-flash:free": {
1283
+ name: "Ling 3.1 Flash",
1284
+ context: 262000,
1285
+ efforts: ["low", "medium", "high"],
1286
+ cost: {
1287
+ input: 0,
1288
+ output: 0,
1289
+ cacheRead: 0,
1290
+ cacheWrite: 0
1291
+ },
1292
+ modalities: ["text"],
1293
+ minPlan: "Go"
1294
+ },
1214
1295
  "meituan/LongCat-2.0": {
1215
1296
  name: "LongCat 2.0",
1216
1297
  context: 1050000,
@@ -1565,7 +1646,7 @@ var MODEL_CATALOG = {
1565
1646
  "stealth/space-bunny-alpha": {
1566
1647
  name: "Space Bunny Alpha",
1567
1648
  context: 1e6,
1568
- efforts: ["low", "medium", "high"],
1649
+ efforts: ["low", "medium", "high", "max"],
1569
1650
  cost: {
1570
1651
  input: 0,
1571
1652
  output: 0,
@@ -1697,9 +1778,9 @@ var MODEL_CATALOG = {
1697
1778
  context: 500000,
1698
1779
  efforts: ["low", "medium", "high", "xhigh"],
1699
1780
  cost: {
1700
- input: 1.2,
1701
- output: 3.6,
1702
- cacheRead: 0.3,
1781
+ input: 2,
1782
+ output: 6,
1783
+ cacheRead: 0.5,
1703
1784
  cacheWrite: 0
1704
1785
  },
1705
1786
  modalities: ["text", "image"],
@@ -1937,9 +2018,10 @@ function zenRows(usage, meta, session, fallbackName) {
1937
2018
  const rows = [["Plan", `${oc?.plan ?? "Go"} \xB7 limits per model`, "base"]];
1938
2019
  const mine = meta ? usage.models.get(modelKey(meta.name)) : undefined;
1939
2020
  const limit = oc?.allowance ?? mine?.limit;
1940
- rows.push(...windowRows2("5-hour", mine?.fiveHour ?? usage.totals.fiveHour, limit, GO_WINDOW_SHARE.fiveHour));
1941
- rows.push(...windowRows2("Weekly", mine?.weekly ?? usage.totals.weekly, limit, GO_WINDOW_SHARE.weekly));
1942
- rows.push(...windowRows2("Month", mine?.month ?? usage.totals.month, limit, GO_WINDOW_SHARE.month));
2021
+ const cap = mine ? limit : undefined;
2022
+ rows.push(...windowRows2("5-hour", mine?.fiveHour ?? usage.totals.fiveHour, cap, GO_WINDOW_SHARE.fiveHour));
2023
+ rows.push(...windowRows2("Weekly", mine?.weekly ?? usage.totals.weekly, cap, GO_WINDOW_SHARE.weekly));
2024
+ rows.push(...windowRows2("Month", mine?.month ?? usage.totals.month, cap, GO_WINDOW_SHARE.month));
1943
2025
  rows.push(["Period", `${count(usage.totals.month.requests)} requests \xB7 ${money(usage.totals.month.cost)}`, "base"]);
1944
2026
  rows.push(separator());
1945
2027
  const name = meta?.name ?? fallbackName;
@@ -2281,15 +2363,19 @@ function seededRows() {
2281
2363
  return lastSnapshot ? usageRows(lastSnapshot) : [];
2282
2364
  }
2283
2365
  var lastModelUsage;
2284
- function rememberModelUsage(id, usage) {
2366
+ function rememberModelUsage(id, usage, session) {
2285
2367
  lastModelUsage = {
2286
2368
  key: modelKey(id),
2369
+ session,
2287
2370
  usage
2288
2371
  };
2289
2372
  }
2290
- function seededModelUsage(id) {
2373
+ function seededModelUsage(id, session) {
2291
2374
  if (!lastModelUsage)
2292
2375
  return;
2376
+ if (session !== undefined && lastModelUsage.session !== undefined && lastModelUsage.session !== session) {
2377
+ return;
2378
+ }
2293
2379
  if (id === undefined)
2294
2380
  return lastModelUsage.usage;
2295
2381
  return lastModelUsage.key === modelKey(id) ? lastModelUsage.usage : undefined;
@@ -2320,9 +2406,12 @@ function useRows(activeModelId, providerID, sessionID) {
2320
2406
  const refreshModelUsage = (id) => {
2321
2407
  if (!id)
2322
2408
  return;
2323
- const fresh = loadModelUsage(id, 0, usageDbPath(), sessionID());
2409
+ const session = sessionID();
2410
+ if (!session)
2411
+ return;
2412
+ const fresh = loadModelUsage(id, 0, usageDbPath(), session);
2324
2413
  if (fresh)
2325
- rememberModelUsage(id, fresh);
2414
+ rememberModelUsage(id, fresh, session);
2326
2415
  setModelUsage(lastModelUsage);
2327
2416
  };
2328
2417
  let inFlight = false;
@@ -2365,11 +2454,12 @@ function useRows(activeModelId, providerID, sessionID) {
2365
2454
  refreshModelUsage(id);
2366
2455
  });
2367
2456
  const usageFor = (id) => {
2457
+ const session = sessionID();
2368
2458
  const seen = modelUsage();
2369
- if (seen && (id === undefined || seen.key === modelKey(id))) {
2459
+ if (seen && (id === undefined || seen.key === modelKey(id)) && (seen.session === undefined || session === undefined || seen.session === session)) {
2370
2460
  return seen.usage;
2371
2461
  }
2372
- return seededModelUsage(id);
2462
+ return seededModelUsage(id, session);
2373
2463
  };
2374
2464
  return createMemo(() => {
2375
2465
  const kind = sessionKind(providerID());
package/package.json CHANGED
@@ -1,48 +1,48 @@
1
1
  {
2
- "name": "@jeffreyjyz/opencode-command-code",
3
- "version": "0.3.18",
4
- "description": "Command Code provider + usage dashboard for opencode: two providers (Anthropic wire for Claude, OpenAI wire for everything else) against api.commandcode.ai, live model list, plan gating, /cmd-usage. Requires the cmduse CLI for usage rendering.",
5
- "type": "module",
6
- "main": "dist/index.js",
7
- "types": "dist/index.d.ts",
8
- "exports": {
9
- ".": "./dist/index.js",
10
- "./tui": "./dist/tui.js"
11
- },
12
- "scripts": {
13
- "build": "rm -rf dist && bun build src/index.ts --outdir dist --target bun --external @opencode-ai/plugin --external @opencode/plugin --external @opencode/plugin/tui && bun scripts/build-tui.ts && tsc -p tsconfig.build.json",
14
- "test": "bun test",
15
- "typecheck": "tsc --noEmit",
16
- "build:tui": "bun scripts/build-tui.ts",
17
- "extract:catalog": "bun scripts/extract-catalog.ts"
18
- },
19
- "dependencies": {
20
- "@opentui/core": "^0.5.4",
21
- "@opentui/solid": "^0.5.4",
22
- "solid-js": "1.9.12",
23
- "zod": "4.1.8"
24
- },
25
- "devDependencies": {
26
- "@types/bun": "latest",
27
- "typescript": "^5",
28
- "@opencode-ai/plugin": "*",
29
- "@opencode/plugin": "^2.0.11",
30
- "@ai-sdk/provider": "3.0.8"
31
- },
32
- "files": [
33
- "dist",
34
- "tui.js",
35
- "LICENSE"
36
- ],
37
- "keywords": [
38
- "opencode",
39
- "command-code",
40
- "plugin",
41
- "provider",
42
- "ai-sdk"
43
- ],
44
- "license": "MIT",
45
- "publishConfig": {
46
- "access": "public"
47
- }
2
+ "name": "@jeffreyjyz/opencode-command-code",
3
+ "version": "0.3.19",
4
+ "description": "Command Code provider + usage dashboard for opencode: two providers (Anthropic wire for Claude, OpenAI wire for everything else) against api.commandcode.ai, live model list, plan gating, /cmd-usage. Requires the cmduse CLI for usage rendering.",
5
+ "type": "module",
6
+ "main": "dist/index.js",
7
+ "types": "dist/index.d.ts",
8
+ "exports": {
9
+ ".": "./dist/index.js",
10
+ "./tui": "./dist/tui.js"
11
+ },
12
+ "scripts": {
13
+ "build": "rm -rf dist && bun build src/index.ts --outdir dist --target bun --external @opencode-ai/plugin --external @opencode/plugin --external @opencode/plugin/tui && bun scripts/build-tui.ts && tsc -p tsconfig.build.json",
14
+ "test": "bun test",
15
+ "typecheck": "tsc --noEmit",
16
+ "build:tui": "bun scripts/build-tui.ts",
17
+ "extract:catalog": "bun scripts/extract-catalog.ts"
18
+ },
19
+ "dependencies": {
20
+ "@opentui/core": "^0.5.4",
21
+ "@opentui/solid": "^0.5.4",
22
+ "solid-js": "1.9.12",
23
+ "zod": "4.1.8"
24
+ },
25
+ "devDependencies": {
26
+ "@types/bun": "latest",
27
+ "typescript": "^5",
28
+ "@opencode-ai/plugin": "*",
29
+ "@opencode/plugin": "^2.0.11",
30
+ "@ai-sdk/provider": "3.0.8"
31
+ },
32
+ "files": [
33
+ "dist",
34
+ "tui.js",
35
+ "LICENSE"
36
+ ],
37
+ "keywords": [
38
+ "opencode",
39
+ "command-code",
40
+ "plugin",
41
+ "provider",
42
+ "ai-sdk"
43
+ ],
44
+ "license": "MIT",
45
+ "publishConfig": {
46
+ "access": "public"
47
+ }
48
48
  }
package/tui.js CHANGED
@@ -2,4 +2,4 @@
2
2
  // half as a literal `tui.js` beside the package root (package `exports`
3
3
  // are only consulted for npm-installed plugins). Keep this file in sync with
4
4
  // the built ./tui output.
5
- export { default } from "./dist/tui.js"
5
+ export { default } from "./dist/tui.js";