llm-router

Route LLM requests to OpenAI, Grok, Groq, DeepSeek, and OpenRouter via SwiftOpenAI-CLI.

194|26|Updated Oct 20, 2025
One-click install
npx skills add https://github.com/jamesrochabrun/skills --skill llm-router
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: llm-router
Source: https://github.com/jamesrochabrun/skills/tree/main/llm-router
Command: npx skills add https://github.com/jamesrochabrun/skills --skill llm-router

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires swiftopenai-cli, and includes scripts (resource) and references (resource) components.

What problem does it solve?

Tired of being locked into one AI model? This Skill liberates you, allowing seamless switching between top LLM providers like OpenAI, Grok, Groq, DeepSeek, and OpenRouter. It eliminates the hassle of manual configuration and ensures your AI tools are always ready, letting you pick the perfect model for any task without interruption.

Core Features & Use Cases

  • Multi-Provider Routing: Instantly switch between OpenAI, Grok, Groq, DeepSeek, and OpenRouter to leverage their unique strengths.
  • Automated Tool Management: Automatically installs and updates SwiftOpenAI-CLI to keep your AI tools current and functional.
  • API Key Guidance: Provides clear, actionable instructions for managing API keys across diverse providers, simplifying setup.
  • Use Case: Need a quick, creative brainstorm? Route to Grok. Solving a complex coding problem? Switch to DeepSeek Reasoner. This skill ensures you always have the right AI for the job, without ever leaving your workflow.

Quick Start

Example: Route a request to Grok

1. Ensure SwiftOpenAI-CLI is installed and updated

scripts/check_install_cli.sh

2. Configure for Grok (e.g., using grok-4-0709 model)

scripts/configure_provider.sh grok grok-4-0709

3. Execute your task with Grok

swiftopenai agent "Explain quantum computing"

Frequently Asked Questions about llm-router

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I route LLM requests between multiple AI providers like OpenAI, Grok, and DeepSeek?

LLM routing lets you switch between providers for different tasks. This Skill routes requests to OpenAI, Grok, Groq, DeepSeek, and OpenRouter using SwiftOpenAI-CLI, letting you pick the best model for coding, brainstorming, or reasoning without reconfiguring your workflow.

Can I use different LLM providers without manually reconfiguring API keys each time?

Yes. This Skill automates provider switching by managing API key verification and configuration across OpenAI, Grok, Groq, DeepSeek, and OpenRouter, so you change providers with a single command rather than manual setup.

What do I need to set up before routing requests to multiple LLM providers?

You need SwiftOpenAI-CLI installed and updated, valid API keys for your chosen providers, and the ability to run shell scripts. The Skill includes scripts to verify installation and configure each provider.

How does LLM routing work with agent tasks like coding assistance or explanations?

The Skill executes one-shot agent tasks by routing your request to a specified provider using SwiftOpenAI-CLI agent mode, optionally adding MCP tools and managing session output in multiple formats for coding, brainstorming, or problem-solving tasks.

Can I route to specialized models like DeepSeek Reasoner for complex problems?

Yes. You can configure and route to DeepSeek Reasoner or other specialized models per provider. Select the model during provider configuration, then route your task to leverage that model's specific strengths.

What are the limitations of switching between LLM providers in a single workflow?

You must maintain active API keys and valid credentials for each provider you switch to. Provider availability, rate limits, and pricing vary by service; routing does not bypass provider-specific constraints or quotas.