all repos — nixfiles @ d95e2987bfb0144db24e365464cde230e55a830b

System and user configuration, managed by nix and home-manager

move script to sd's folder

Alan Pearce
commit

d95e2987bfb0144db24e365464cde230e55a830b

parent

9a193cf7afa21d6df46a06ebf801923faf92fed5

1 file changed, 23 insertions(+), 0 deletions(-)

changed files
A scripts/raycast/update-ai-providers
@@ -0,0 +1,23 @@
+#!/usr/bin/env fish +# tell raycast which models are available in lm studio + +set --local lms_base_url http://localhost:28100 +set --local lms_models_path /api/v0/models +set --local lms_openai_path /v1/ + +xh $lms_base_url$lms_models_path | fx .data '?.type != "embeddings"' 'map(m => ({ + id: m.id, name: m.id, context: m.max_context_length, + abilities: { + tools: { supported: m.capabilities?.includes("tool_use") || false }, + temperature: { supported: true }, + system_message: { supported: true }, + vision: { supported: m.type == "vlm" }, + } +}))' "x => ({ + providers: [{ + id: 'lm-studio', + name: 'LM Studio', + base_url: '$lms_base_url$lms_openai_path', + models: x + }] +})" YAML.stringify >~/.config/raycast/ai/providers.yaml