tooyoung:easy-openrouter
Easy OpenRouter
Quickly test LLM models and find the best one for your task.
Prerequisites
export OPENROUTER_API_KEY="sk-or-v1-xxxx"
Quick Model Testing
Use scripts/call_openrouter.sh:
# Basic test
bash scripts/call_openrouter.sh \
--model "anthropic/claude-sonnet-4" \
--prompt "Explain quantum computing in one sentence" \
--json
# With parameters
bash scripts/call_openrouter.sh \
--model "openai/gpt-4o" \
--prompt "Write a haiku about code" \
--max-tokens 100 \
--temperature 0.7 \
--json
Output includes: response time (ms), cost ($), token usage, full response
Parameters:
--model: Model ID (required)--prompt: Prompt text (required)--system: System prompt (optional)--max-tokens: Max tokens--temperature: Temperature 0.0-2.0--json: JSON output
Model Naming Format
provider/model-name[:modifier]
Common models:
anthropic/claude-sonnet-4openai/gpt-4oopenai/gpt-4o-minigoogle/gemini-2.0-flash-001deepseek/deepseek-chat
Modifiers:
:nitro- Use fastest provider:online- Enable web search- Combinable:
anthropic/claude-sonnet-4:nitro:online
Find Optimal Models
Find Best Model by Category (Rankings)
https://openrouter.ai/rankings?category=<category>#categories
| Category | URL |
|---|---|
| Programming | https://openrouter.ai/rankings?category=programming#categories |
| Translation | https://openrouter.ai/rankings?category=translation#categories |
| Science | https://openrouter.ai/rankings?category=science#categories |
| Finance | https://openrouter.ai/rankings?category=finance#categories |
| Legal | https://openrouter.ai/rankings?category=legal#categories |
| Academia | https://openrouter.ai/rankings?category=academia#categories |
| Marketing | https://openrouter.ai/rankings?category=marketing#categories |
| SEO | https://openrouter.ai/rankings?category=marketing/seo#categories |
Find Provider by Performance/Price
https://openrouter.ai/<model-slug>/providers?sort=<sort>
Sort options:
throughput- By throughput (tokens/sec)latency- By latencyprice- By price
Example: Find fastest provider for claude-sonnet-4
https://openrouter.ai/anthropic/claude-sonnet-4/providers?sort=throughput
Get Full Model List
curl -s https://openrouter.ai/api/v1/models \
-H "Authorization: Bearer $OPENROUTER_API_KEY" \
| jq '.data | sort_by(.pricing.prompt) | .[:10] | .[].id'
# Output: top 10 cheapest models
Typical Workflows
1. Quick Model Comparison
# Test Claude
bash scripts/call_openrouter.sh --model "anthropic/claude-sonnet-4" --prompt "Explain microservices architecture" --json > claude.json
# Test GPT-4o
bash scripts/call_openrouter.sh --model "openai/gpt-4o" --prompt "Explain microservices architecture" --json > gpt4o.json
# Compare results
jq -s '[.[0], .[1]] | map({model, response_time_ms, cost})' claude.json gpt4o.json
2. Find Best Model for Programming Tasks
- Open
https://openrouter.ai/rankings?category=programming#categories - Note the top-ranked models
- Test actual performance with the script
3. Choose Model for Chainlit Demo
Considerations:
- For demos: Prioritize speed → use
:nitromodifier - Cost-sensitive: Use
gpt-4o-miniordeepseek-chat - Quality-first: Use
claude-sonnet-4orgpt-4o
Advanced
For API details, query OpenRouter documentation via Context7.
More from shiqkuangsan/oh-my-daily-skills
tooyoung:excalidraw-artist
Create Excalidraw hand-drawn style diagrams, including architecture, flowchart, swimlane/timeline, sequence, basic wireframe, ERD/data model, state machine, matrix/comparison table, tree/hierarchy, and CI/CD pipeline. Trigger words: draw diagram, architecture diagram, flowchart, swimlane, timeline, roadmap, Gantt, sequence diagram, excalidraw, ERD, data model, state machine, comparison table, matrix, tree, hierarchy, CI/CD pipeline
24tooyoung:chainlit-builder
Quickly build Chainlit AI chat demos and POCs using OpenAI-compatible chat completion patterns, including streaming, multi-turn memory, file upload, tool-call step visualization, and demo styling. Trigger words: chainlit, build demo, chat demo, conversation demo, Chainlit 演示, AI 聊天 demo, 对话式 POC
24tooyoung:threejs-builder
Create simple Three.js web apps with scene setup, lighting, geometries, materials, animations, OrbitControls, particles, and responsive rendering. Use for Three.js scenes, WebGL demos, 3D showcases, and interactive 3D web content. Trigger: threejs, Three.js, 3D scene, WebGL, 三维展示, 3D showcase, interactive 3D
23tooyoung:openclash-merger
将 vless+reality 等新协议配置转换为带 GEOSITE 规则的配置文件,支持 11 地区分组 + AI/媒体/游戏分流,可直接上传 OpenClash 使用。触发词:合并 OpenClash、转换订阅、Clash 配置
23tooyoung:nano-banana-builder
Build Next.js App Router image-generation apps using Gemini Nano Banana / Nano Banana Pro with AI SDK. Covers exact model names, Server Actions/API routes, conversational multi-turn image editing, storage, rate limiting, safety, and cost controls. Trigger: nano banana, Gemini image, AI 生图, 图片生成, text-to-image, image generation app, iterative image editor, multi-turn image editing
23tooyoung:ink-reader
Read public or accessible URLs into clean Markdown using platform-aware fallback strategies. Covers common Chinese platforms, X/Twitter, and generic websites; login or anti-bot pages are best-effort. Trigger words: read url, read link, fetch article, extract content, clean markdown, WeChat article, 搜公众号文章, ink-reader
22