@oh-my-pi/pi-catalog 17.1.8 → 17.2.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/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "type": "module",
3
3
  "name": "@oh-my-pi/pi-catalog",
4
- "version": "17.1.8",
4
+ "version": "17.2.0",
5
5
  "description": "Model catalog for omp: bundled model database, provider discovery descriptors, model identity, classification, and equivalence",
6
6
  "homepage": "https://omp.sh",
7
7
  "author": "Can Boluk",
@@ -30,16 +30,17 @@
30
30
  "test": "bun test --parallel",
31
31
  "fix": "biome check --write --unsafe .",
32
32
  "fmt": "biome format --write .",
33
- "gen:models": "bun scripts/generate-models.ts"
33
+ "gen:models": "bun scripts/generate-models.ts",
34
+ "gen:cursor-proto": "protoc --plugin=protoc-gen-es=../../node_modules/.bin/protoc-gen-es --es_out=src/discovery/cursor-gen --es_opt=target=ts -I ../ai/src/providers/cursor/proto ../ai/src/providers/cursor/proto/agent.proto"
34
35
  },
35
36
  "dependencies": {
36
37
  "@bufbuild/protobuf": "^2.12.1",
37
- "@oh-my-pi/pi-utils": "17.1.8",
38
+ "@oh-my-pi/pi-utils": "17.2.0",
38
39
  "arktype": "2.2.3",
39
40
  "zod": "^4"
40
41
  },
41
42
  "devDependencies": {
42
- "@oh-my-pi/pi-ai": "17.1.8",
43
+ "@oh-my-pi/pi-ai": "17.2.0",
43
44
  "@types/bun": "^1.3.14"
44
45
  },
45
46
  "engines": {
@@ -226,6 +226,12 @@ function detectStrictModeSupport(provider: string, baseUrl: string): boolean {
226
226
  */
227
227
  const LOCAL_OPENAI_COMPAT_PROVIDERS = new Set(["llama.cpp", "lm-studio", "vllm", "ollama"]);
228
228
 
229
+ /** Hosts that accept only none/auto/required rather than a named tool-choice object. */
230
+ const STRING_ONLY_NAMED_TOOL_CHOICE_PROVIDERS: Record<string, true> = {
231
+ "llama.cpp": true,
232
+ "lm-studio": true,
233
+ };
234
+
229
235
  /**
230
236
  * Local proxy providers that share the loopback-default baseUrl but forward
231
237
  * to an unrelated upstream (OpenAI, Anthropic, …) rather than running a
@@ -481,7 +487,7 @@ export function buildOpenAICompat(spec: ModelSpec<"openai-completions">): Resolv
481
487
  disableReasoningOnToolChoice: isDeepseekFamily && Boolean(spec.reasoning) && !isOpenRouter,
482
488
  supportsToolChoice: !isDirectDeepseekReasoning,
483
489
  supportsForcedToolChoice: !requiresEnabledThinking,
484
- supportsNamedToolChoice: provider !== "llama.cpp",
490
+ supportsNamedToolChoice: STRING_ONLY_NAMED_TOOL_CHOICE_PROVIDERS[provider] !== true,
485
491
  maxTokensField: useMaxTokens ? "max_tokens" : "max_completion_tokens",
486
492
  requiresToolResultName: isMistral,
487
493
  requiresAssistantAfterToolResult: isMistral,
@@ -686,7 +692,7 @@ export function buildOpenAIResponsesCompat(spec: OpenAIResponsesSpecLike): Resol
686
692
  disableReasoningOnToolChoice: isDeepseekFamily && reasoningCapable && !isOpenRouter,
687
693
  supportsToolChoice: true,
688
694
  supportsForcedToolChoice: true,
689
- supportsNamedToolChoice: true,
695
+ supportsNamedToolChoice: STRING_ONLY_NAMED_TOOL_CHOICE_PROVIDERS[spec.provider] !== true,
690
696
  reasoningContentField: "reasoning_content",
691
697
  requiresReasoningContentForToolCalls:
692
698
  (isKimiModel || (isDeepseekFamily && reasoningCapable) || (isOpenRouter && reasoningCapable)) &&