snow-flow 10.0.121 → 10.0.122

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,6 +1,6 @@
1
1
  {
2
2
  "$schema": "https://json.schemastore.org/package.json",
3
- "version": "10.0.121",
3
+ "version": "10.0.122",
4
4
  "name": "snow-flow",
5
5
  "description": "Snow-Flow - ServiceNow Multi-Agent Development Framework powered by AI",
6
6
  "license": "Elastic-2.0",
@@ -568,6 +568,25 @@ export namespace Provider {
568
568
  const data = (await response.json()) as { models?: Array<{ name: string; details?: { parameter_size?: string; family?: string } }> }
569
569
  if (!data.models?.length) return { autoload: false }
570
570
 
571
+ // Check tool support per model via /api/show (parallel, best-effort)
572
+ const toolSupport = new Map<string, boolean>()
573
+ await Promise.all(
574
+ data.models.map(async (m) => {
575
+ try {
576
+ const res = await fetch(`${host}/api/show`, {
577
+ method: "POST",
578
+ body: JSON.stringify({ name: m.name }),
579
+ signal: AbortSignal.timeout(2000),
580
+ })
581
+ if (!res.ok) return
582
+ const info = (await res.json()) as { template?: string }
583
+ toolSupport.set(m.name, info.template?.includes(".Tools") ?? false)
584
+ } catch {
585
+ // assume no tool support if check fails
586
+ }
587
+ }),
588
+ )
589
+
571
590
  for (const model of data.models) {
572
591
  if (input.models[model.name]) continue
573
592
  input.models[model.name] = fromModelsDevModel(
@@ -578,7 +597,7 @@ export namespace Provider {
578
597
  family: model.details?.family ?? model.name.split(":")[0],
579
598
  attachment: false,
580
599
  reasoning: false,
581
- tool_call: true,
600
+ tool_call: toolSupport.get(model.name) ?? false,
582
601
  temperature: true,
583
602
  release_date: "2024-01-01",
584
603
  modalities: { input: ["text"], output: ["text"] },