Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,15 @@
# ============================================
# OpenRouter Configuration
# ============================================
OPENROUTER_API_KEY=your_openrouter_api_key
OPENROUTER_API_KEY=your_openrouter_key
OPENROUTER_BASE_URL=https://openrouter.ai/api/v1

# ============================================
# Requesty Configuration (OpenAI-compatible router)
# ============================================
REQUESTY_API_KEY=your_requesty_key
REQUESTY_BASE_URL=https://router.requesty.ai/v1

# ============================================
# Native API Configuration (Optional)
# ============================================
Expand Down
6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,10 @@ cp .env.example .env
OPENROUTER_API_KEY=sk-or-...
OPENROUTER_BASE_URL=https://openrouter.ai/api/v1

# Requesty — OpenAI-compatible router (one key, most models)
REQUESTY_API_KEY=rqsty-sk-...
REQUESTY_BASE_URL=https://router.requesty.ai/v1

# Native providers (only if you call them directly)
OPENAI_API_KEY=sk-...
# OPENAI_BASE_URL=https://api.openai.com/v1 # override for OpenAI-compatible gateways
Expand Down Expand Up @@ -120,7 +124,7 @@ python -m mingli_bench.cli \
--year 2025 --cot --astro --max-workers 8
```

`--platform` accepts: `openai`, `openrouter`, `anthropic`, `google`, `deepseek`, `doubao`.
`--platform` accepts: `openai`, `openrouter`, `requesty`, `anthropic`, `google`, `deepseek`, `doubao`.

---

Expand Down
2 changes: 2 additions & 0 deletions mingli_bench/models/factory.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
_PROVIDER_INSTALL_HINT = {
'openai': 'pip install openai',
'openrouter': 'pip install openai',
'requesty': 'pip install openai',
'deepseek': 'pip install openai',
'anthropic': 'pip install anthropic',
'google': 'pip install google-generativeai',
Expand All @@ -35,6 +36,7 @@ class ModelFactory:
'deepseek': ('.deepseek_client', 'DeepSeekClient'),
'doubao': ('.doubao_client', 'DoubaoClient'),
'openrouter': ('.openai_client', 'OpenAIClient'), # OpenAI-compatible API
'requesty': ('.openai_client', 'OpenAIClient'), # OpenAI-compatible API
}

@classmethod
Expand Down
8 changes: 8 additions & 0 deletions mingli_bench/utils/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,14 @@ def load_config(env_file: Optional[str] = None) -> Dict[str, Any]:
"max_tokens": default_max_tokens,
},

# Requesty configuration (OpenAI-compatible router)
"requesty": {
"api_key": os.getenv("REQUESTY_API_KEY"),
"base_url": os.getenv("REQUESTY_BASE_URL", "https://router.requesty.ai/v1"),
"temperature": default_temperature,
"max_tokens": default_max_tokens,
},

# Native OpenAI configuration
"openai": {
"api_key": os.getenv("OPENAI_API_KEY"),
Expand Down