agentsclimarketplace

Routerbase model routing

Skill zenlee123/routerbase-agent-skills/skills/routerbase-model-routing

Agent skills for integrating, routing, and generating media with RouterBase.

Install
npx -y skills add zenlee123/routerbase-agent-skills --skill routerbase-model-routing

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

2 things to look at

  • no licenseNo license file was found in the repository. Code published without one is not open source by default, so using it at work is a question for whoever answers licensing questions where you are.
  • 0 stars0 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.

What its author says it does

Copied from the file, not written here

Choose RouterBase model IDs and routing strategies for chat, image, video, audio, and embeddings workloads. Use when comparing providers, selecting GPT, Claude, Gemini, image, video, or audio models on RouterBase, designing fallback paths, checking pricing or availability, planning cost/latency/quality tradeoffs, querying the RouterBase Models API, or documenting how an app should route model requests through RouterBase.

SKILL.md

3.8 KB, 723 tokens by cl100k_base, as published. Nobody here has run it

RouterBase Model Routing

Overview

Use routerbase to pick and document model choices behind one API key and one OpenAI-compatible integration surface. This skill helps agents turn workload requirements into a practical model shortlist, fallback plan, and validation checklist.

Read references/routerbase-models.md when exact catalog API calls, model examples, or selection heuristics are needed.

Routing Workflow

  1. Classify the task modality: chat, image, video, audio, embeddings, or mixed.
  2. Identify hard constraints: quality target, latency budget, price ceiling, context length, tool calling, vision, JSON mode, region/compliance needs, and fallback tolerance.
  3. Query the live RouterBase catalog when possible:
curl "https://routerbase.com/api/v1/models?task=chat" \
  -H "Authorization: Bearer $ROUTERBASE_API_KEY"
  1. Shortlist one primary model and one or two fallback models. Prefer fallbacks with the same modality and similar capability shape.
  2. Check current pricing before final recommendations:
curl "https://routerbase.com/api/v1/pricing" \
  -H "Authorization: Bearer $ROUTERBASE_API_KEY"
  1. Document the decision as a table: use case, primary model, fallback model, reason, validation test, and known caveats.

Selection Heuristics

  • For general chat, prefer a balanced fast model first, then escalate only when reasoning quality or context length requires it.
  • For high-stakes reasoning, choose a flagship model and require human review of outputs.
  • For latency-sensitive UX, prefer smaller or flash-tier models and keep prompts compact.
  • For tool-heavy agents, choose chat models documented to support tool calling and test the exact tool schema.
  • For JSON outputs, use response_format where the selected model supports JSON mode, and add schema validation in application code.
  • For prompt caching benefits, place stable system prompts, policies, and tool definitions before variable user content.
  • For media workflows, keep routing separate by modality; image, video, and audio endpoints have different sync/async behavior.

Fallback Design

Use explicit application-level fallback logic unless the user has configured RouterBase's smart routing in their account or upstream settings.

const modelPlan = [
  "anthropic/claude-sonnet-4-6",
  "google/gemini-2.5-flash",
];

for (const model of modelPlan) {
  try {
    return await client.chat.completions.create({ model, messages });
  } catch (error) {
    if (!isRetryableRouterBaseError(error)) throw error;
  }
}

Classify retryable errors conservatively: transient network failures, timeouts, 429, and 5xx are reasonable candidates; auth errors, invalid model IDs, validation errors, and policy errors should not be retried blindly.

Recommendation Format

When recommending a routing plan, include:

  • Primary model and why it fits.
  • Fallback model and what tradeoff it makes.
  • Current catalog/pricing check status.
  • Any feature assumptions that must be tested, such as tool calling, vision, JSON mode, context size, prompt caching, or streaming.
  • A minimal eval prompt or request fixture the user can run before production.

Avoid pretending prices or supported model IDs are permanent. RouterBase's docs explicitly describe the model and pricing catalog as changing with upstream providers.

Gives 0 of the 12 instructions most context ai engineering skills give in 723 tokens

Counted across 1,193 of the 1,976 authors here whose files we hold, read 2026-08-06

  • dispatch a fresh implementer subagent per taskin 48 of 1193, across 19 files
  • dispatch final reviewer after all tasksin 37 of 1193, across 11 files
  • provide full task text to the subagentin 31 of 1193, across 10 files
  • review spec compliance before code qualityin 27 of 1193, across 10 files
  • make the hook script executablein 26 of 1193, across 8 files
  • re-snapshot after navigation or DOM changesin 25 of 1193, across 17 files
  • answer subagent questions before proceedingin 22 of 1193, across 7 files
  • mark task complete in TodoWrite after approvalin 22 of 1193, across 6 files
  • merge hook into existing settingsin 21 of 1193, across 3 files
  • read files before editing themin 21 of 1193, across 9 files
  • ask if installation is global or projectin 20 of 1193, across 2 files
  • copy the hook script to target locationin 20 of 1193, across 2 files

Grouped from the skills themselves: near-identical wordings counted once, and counted by distinct author, so one author publishing three of these counts once. Length counted with cl100k_base; the agent that loads this file may tokenize it differently.

Keep looking

Skills are one crate of 328,083. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.