@linxiraos/pi-catalog 1.0.0 → 1.0.2

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 (86) hide show
  1. package/CHANGELOG.md +88 -6
  2. package/package.json +98 -99
  3. package/src/build.ts +3 -3
  4. package/src/compat/openai.ts +0 -6
  5. package/src/discovery/antigravity.ts +5 -1
  6. package/src/discovery/openai-compatible.ts +21 -4
  7. package/src/identity/classify.ts +32 -9
  8. package/src/identity/family.ts +18 -4
  9. package/src/model-manager.ts +13 -2
  10. package/src/model-thinking.ts +15 -7
  11. package/src/models.json +7999 -2099
  12. package/src/models.ts +28 -14
  13. package/src/provider-models/bundled-references.ts +4 -2
  14. package/src/provider-models/openai-compat.ts +379 -301
  15. package/src/types.ts +24 -16
  16. package/src/variant-collapse.ts +34 -17
  17. package/src/wire/gemini-headers.ts +79 -18
  18. package/dist/types/build.d.ts +0 -14
  19. package/dist/types/compat/anthropic.d.ts +0 -18
  20. package/dist/types/compat/apply.d.ts +0 -7
  21. package/dist/types/compat/bedrock.d.ts +0 -3
  22. package/dist/types/compat/devin.d.ts +0 -9
  23. package/dist/types/compat/openai.d.ts +0 -26
  24. package/dist/types/discovery/antigravity.d.ts +0 -70
  25. package/dist/types/discovery/codex.d.ts +0 -36
  26. package/dist/types/discovery/cursor-gen/agent_pb.d.ts +0 -16769
  27. package/dist/types/discovery/cursor.d.ts +0 -23
  28. package/dist/types/discovery/devin-gen/buf/validate/validate_pb.d.ts +0 -1715
  29. package/dist/types/discovery/devin-gen/exa/analytics_pb/analytics_pb.d.ts +0 -693
  30. package/dist/types/discovery/devin-gen/exa/api_server_pb/api_server_pb.d.ts +0 -9158
  31. package/dist/types/discovery/devin-gen/exa/auth_pb/auth_pb.d.ts +0 -52
  32. package/dist/types/discovery/devin-gen/exa/auto_cascade_common_pb/auto_cascade_common_pb.d.ts +0 -276
  33. package/dist/types/discovery/devin-gen/exa/bug_checker_pb/bug_checker_pb.d.ts +0 -78
  34. package/dist/types/discovery/devin-gen/exa/cascade_plugins_pb/cascade_plugins_pb.d.ts +0 -999
  35. package/dist/types/discovery/devin-gen/exa/chat_pb/chat_pb.d.ts +0 -1704
  36. package/dist/types/discovery/devin-gen/exa/code_edit/code_edit_pb/code_edit_pb.d.ts +0 -656
  37. package/dist/types/discovery/devin-gen/exa/codeium_common_pb/codeium_common_pb.d.ts +0 -15014
  38. package/dist/types/discovery/devin-gen/exa/context_module_pb/context_module_pb.d.ts +0 -607
  39. package/dist/types/discovery/devin-gen/exa/cortex_pb/cortex_pb.d.ts +0 -11830
  40. package/dist/types/discovery/devin-gen/exa/diff_action_pb/diff_action_pb.d.ts +0 -248
  41. package/dist/types/discovery/devin-gen/exa/index_pb/index_pb.d.ts +0 -1747
  42. package/dist/types/discovery/devin-gen/exa/knowledge_base_pb/knowledge_base_pb.d.ts +0 -509
  43. package/dist/types/discovery/devin-gen/exa/language_server_pb/language_server_pb.d.ts +0 -9048
  44. package/dist/types/discovery/devin-gen/exa/opensearch_clients_pb/opensearch_clients_pb.d.ts +0 -1760
  45. package/dist/types/discovery/devin-gen/exa/prompt_pb/prompt_pb.d.ts +0 -286
  46. package/dist/types/discovery/devin-gen/exa/reactive_component_pb/reactive_component_pb.d.ts +0 -405
  47. package/dist/types/discovery/devin-gen/exa/trust_pb/trust_pb.d.ts +0 -582
  48. package/dist/types/discovery/devin.d.ts +0 -24
  49. package/dist/types/discovery/gemini.d.ts +0 -25
  50. package/dist/types/discovery/gitlab-duo-workflow.d.ts +0 -30
  51. package/dist/types/discovery/index.d.ts +0 -5
  52. package/dist/types/discovery/openai-compatible.d.ts +0 -74
  53. package/dist/types/effort.d.ts +0 -10
  54. package/dist/types/fireworks-model-id.d.ts +0 -23
  55. package/dist/types/hosts.d.ts +0 -164
  56. package/dist/types/identity/bundled.d.ts +0 -3
  57. package/dist/types/identity/classify.d.ts +0 -69
  58. package/dist/types/identity/dialect.d.ts +0 -3
  59. package/dist/types/identity/family.d.ts +0 -181
  60. package/dist/types/identity/id.d.ts +0 -12
  61. package/dist/types/identity/index.d.ts +0 -8
  62. package/dist/types/identity/markers.d.ts +0 -4
  63. package/dist/types/identity/priority.d.ts +0 -1
  64. package/dist/types/identity/reference.d.ts +0 -29
  65. package/dist/types/index.d.ts +0 -17
  66. package/dist/types/model-cache.d.ts +0 -23
  67. package/dist/types/model-manager.d.ts +0 -77
  68. package/dist/types/model-thinking.d.ts +0 -66
  69. package/dist/types/models.d.ts +0 -12
  70. package/dist/types/provider-models/bundled-references.d.ts +0 -13
  71. package/dist/types/provider-models/cache-provider-id.d.ts +0 -9
  72. package/dist/types/provider-models/descriptor-types.d.ts +0 -76
  73. package/dist/types/provider-models/descriptors.d.ts +0 -504
  74. package/dist/types/provider-models/google.d.ts +0 -27
  75. package/dist/types/provider-models/index.d.ts +0 -7
  76. package/dist/types/provider-models/ollama.d.ts +0 -22
  77. package/dist/types/provider-models/openai-compat.d.ts +0 -599
  78. package/dist/types/provider-models/special.d.ts +0 -53
  79. package/dist/types/types.d.ts +0 -811
  80. package/dist/types/utils.d.ts +0 -20
  81. package/dist/types/variant-collapse.d.ts +0 -133
  82. package/dist/types/wire/alibaba-token-plan.d.ts +0 -22
  83. package/dist/types/wire/codex.d.ts +0 -42
  84. package/dist/types/wire/coreweave.d.ts +0 -12
  85. package/dist/types/wire/gemini-headers.d.ts +0 -37
  86. package/dist/types/wire/github-copilot.d.ts +0 -39
@@ -63,9 +63,9 @@ const GEMINI_3_FLASH_EFFORTS: readonly Effort[] = [Effort.Minimal, Effort.Low, E
63
63
  const GPT_5_2_PLUS_EFFORTS: readonly Effort[] = [Effort.Low, Effort.Medium, Effort.High, Effort.XHigh];
64
64
  const GPT_5_1_CODEX_MINI_EFFORTS: readonly Effort[] = [Effort.Medium, Effort.High];
65
65
  const LOW_MEDIUM_HIGH_REASONING_EFFORTS: readonly Effort[] = [Effort.Low, Effort.Medium, Effort.High];
66
- /** Wire-exact `low`/`high`/`max` scale used by Kimi K3 and DeepSeek V4 Flash (direct API and aggregators). */
66
+ /** Wire-exact `low`/`high`/`max` scale used by Kimi K3 and DeepSeek V4 (Flash and Pro, direct API and aggregators). */
67
67
  const LOW_HIGH_MAX_REASONING_EFFORTS: readonly Effort[] = [Effort.Low, Effort.High, Effort.Max];
68
- /** Wire-exact two-tier scale (`high`/`max`): GLM-5.2 on Z.ai/Umans/Ollama Cloud/Baseten, Sakana Fugu, DeepSeek V4 Pro. */
68
+ /** Wire-exact two-tier scale (`high`/`max`): GLM-5.2 on Z.ai/Umans/Ollama Cloud/Baseten, Sakana Fugu, older DeepSeek reasoners (V3.x/R1). */
69
69
  const HIGH_MAX_REASONING_EFFORTS: readonly Effort[] = [Effort.High, Effort.Max];
70
70
  /** OpenRouter's DeepSeek route accepts only `high`. */
71
71
  const HIGH_ONLY_REASONING_EFFORTS: readonly Effort[] = [Effort.High];
@@ -366,14 +366,22 @@ function getModelDefinedEfforts<TApi extends Api>(
366
366
  if (spec.provider === "ollama") {
367
367
  return OLLAMA_REASONING_EFFORTS;
368
368
  }
369
- if (isOpenAICompatReasoningApi(spec.api) && isDeepseekReasoningModel(spec)) {
370
- // DeepSeek V4 Flash accepts the wire-exact low/high/max ladder on every
371
- // host — the direct API and aggregators alike (medium/xhigh map to
372
- // high). V4 Pro and the older reasoners top out at high/max, and
373
- // OpenRouter's non-flash DeepSeek route exposes only high.
369
+ if (
370
+ (isOpenAICompatReasoningApi(spec.api) || (spec.api === "ollama-chat" && spec.provider === "ollama-cloud")) &&
371
+ isDeepseekReasoningModel(spec)
372
+ ) {
373
+ // DeepSeek V4 (Flash and Pro) accepts the wire-exact low/high/max ladder
374
+ // on every first-party/aggregator host — the direct API, aggregators, and
375
+ // Ollama Cloud alike (medium/xhigh fold into high, max is a real wire
376
+ // tier). See https://api-docs.deepseek.com/api/create-chat-completion.
377
+ // OpenRouter's non-Flash V4 route still exposes only high; the older
378
+ // reasoners (V3.x, R1, deepseek-reasoner) top out at high/max.
374
379
  if (isDeepseekV4FlashModelId(spec.id)) {
375
380
  return LOW_HIGH_MAX_REASONING_EFFORTS;
376
381
  }
382
+ if (bareModelId(spec.id).toLowerCase().includes("deepseek-v4")) {
383
+ return isOpenRouterThinkingFormat(compat) ? HIGH_ONLY_REASONING_EFFORTS : LOW_HIGH_MAX_REASONING_EFFORTS;
384
+ }
377
385
  return isOpenRouterThinkingFormat(compat) ? HIGH_ONLY_REASONING_EFFORTS : HIGH_MAX_REASONING_EFFORTS;
378
386
  }
379
387
  if (spec.provider === "baseten" && isOpenAIGptOssModelId(spec.id)) {