Skip to content

Commit 5989d7b

Browse files
committed
openrouter model generation script
1 parent c293bbe commit 5989d7b

File tree

4 files changed

+811
-2
lines changed

4 files changed

+811
-2
lines changed

README.md

Lines changed: 30 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,31 @@
1-
# @openrouter on hub.continue.dev
1+
# OpenRouter Continue Hub
22

3-
You will find more information in the [Continue 1.0 Partnership Guide](https://continuedev.notion.site/Continue-1-0-Partnership-Guide-1811d55165f7802686fcd0b70464e778).
3+
Auto-generates YAML blocks for OpenRouter models.
4+
5+
## Update Models
6+
7+
Edit `CURATED_MODELS` in `openrouter_models.py`:
8+
9+
```python
10+
CURATED_MODELS = {
11+
"openai/gpt-4o": "gpt-4o",
12+
"anthropic/claude-3.5-sonnet": "claude-3.5-sonnet",
13+
# Add more models...
14+
}
15+
```
16+
17+
Display names are auto-extracted from the API (text after `:` if present).
18+
19+
## Run
20+
21+
```bash
22+
# Generate all curated models
23+
python3 openrouter_models.py --summary
24+
25+
# With API key (optional)
26+
OPENROUTER_API_KEY=your_key python3 openrouter_models.py --summary
27+
```
28+
29+
## Publish
30+
31+
Generated YAML files in `blocks/public/` are automatically published to hub.continue.dev.

blocks/public/kimi-k2.yaml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
---
2+
name: Kimi K2
3+
version: 1.0.0
4+
schema: v1
5+
models:
6+
- name: Kimi K2
7+
provider: openrouter
8+
model: moonshotai/kimi-k2
9+
apiKey: ${{ inputs.OPENROUTER_API_KEY }}
10+
defaultCompletionOptions:
11+
contextLength: 131072
12+
capabilities:
13+
- tool_use
14+
roles:
15+
- apply
16+
- chat
17+
- edit

blocks/public/qwen3-coder.yaml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
---
2+
name: Qwen3 Coder
3+
version: 1.0.0
4+
schema: v1
5+
models:
6+
- name: Qwen3 Coder
7+
provider: openrouter
8+
model: qwen/qwen3-coder
9+
apiKey: ${{ inputs.OPENROUTER_API_KEY }}
10+
defaultCompletionOptions:
11+
contextLength: 262144
12+
capabilities:
13+
- tool_use
14+
roles:
15+
- apply
16+
- chat
17+
- edit

0 commit comments

Comments
 (0)