Integration request from AIML API (#11758)
Co-authored-by: Stan <stan@aimlapi.com> Co-authored-by: Lookoff123 <bataryshkinairina@gmail.com> Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
@@ -13,6 +13,7 @@ pub(crate) mod declarative_providers {
|
||||
use super::*;
|
||||
|
||||
expose_declarative_providers!(
|
||||
aimlapi,
|
||||
alibaba,
|
||||
atomic_chat,
|
||||
celeris,
|
||||
|
||||
@@ -0,0 +1,57 @@
|
||||
{
|
||||
"name": "aimlapi",
|
||||
"engine": "openai",
|
||||
"display_name": "AI/ML API",
|
||||
"description": "300+ chat models from many creators behind one OpenAI-compatible API key.",
|
||||
"api_key_env": "AIMLAPI_API_KEY",
|
||||
"base_url": "https://api.aimlapi.com/v1",
|
||||
"headers": {
|
||||
"x-aimlapi-source": "agent/goose",
|
||||
"x-aimlapi-partner-id": "part_R2KG8QMDBjtWAubVMgG0GF9L",
|
||||
"http-referer": "https://goose-docs.ai",
|
||||
"x-title": "goose"
|
||||
},
|
||||
"catalog_provider_id": "aimlapi",
|
||||
"dynamic_models": true,
|
||||
"models": [
|
||||
{
|
||||
"name": "openai/gpt-5-5",
|
||||
"context_limit": 1050000
|
||||
},
|
||||
{
|
||||
"name": "anthropic/claude-sonnet-5",
|
||||
"context_limit": 1000000
|
||||
},
|
||||
{
|
||||
"name": "anthropic/claude-opus-5",
|
||||
"context_limit": 1000000
|
||||
},
|
||||
{
|
||||
"name": "google/gemini-3.6-flash",
|
||||
"context_limit": 1048576
|
||||
},
|
||||
{
|
||||
"name": "deepseek/deepseek-v4-pro",
|
||||
"context_limit": 1000000
|
||||
},
|
||||
{
|
||||
"name": "moonshot/kimi-k3",
|
||||
"context_limit": 1048576
|
||||
},
|
||||
{
|
||||
"name": "x-ai/grok-4-5",
|
||||
"context_limit": 500000
|
||||
},
|
||||
{
|
||||
"name": "alibaba/qwen3.8-max",
|
||||
"context_limit": 1000000
|
||||
}
|
||||
],
|
||||
"supports_streaming": true,
|
||||
"model_doc_link": "https://aimlapi.com/models",
|
||||
"setup_steps": [
|
||||
"Create an account at https://aimlapi.com",
|
||||
"Open https://aimlapi.com/app/keys and create an API key",
|
||||
"Copy the key and paste it above"
|
||||
]
|
||||
}
|
||||
@@ -330,6 +330,22 @@ mod tests {
|
||||
.any(|key| key.name == "HF_TOKEN" && key.secret));
|
||||
}
|
||||
|
||||
#[tokio::test]
|
||||
async fn test_aimlapi_provider_registry_wiring() {
|
||||
let aimlapi = get_from_registry("aimlapi")
|
||||
.await
|
||||
.expect("aimlapi provider should be registered");
|
||||
let meta = aimlapi.metadata();
|
||||
|
||||
assert_eq!(meta.name, "aimlapi");
|
||||
assert_eq!(meta.display_name, "AI/ML API");
|
||||
assert_eq!(meta.default_model, "openai/gpt-5-5");
|
||||
assert!(meta
|
||||
.config_keys
|
||||
.iter()
|
||||
.any(|key| key.name == "AIMLAPI_API_KEY" && key.secret));
|
||||
}
|
||||
|
||||
#[tokio::test]
|
||||
async fn test_gondola_provider_registry_wiring() {
|
||||
let gondola = get_from_registry("gondola")
|
||||
|
||||
@@ -22,6 +22,7 @@ goose is compatible with a wide range of LLM providers, allowing you to choose a
|
||||
|
||||
| Provider | Description | Parameters |
|
||||
|-----------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
||||
| [AI/ML API](https://aimlapi.com/) | One API key for 300+ chat, image, video, audio, and embedding models from many providers, OpenAI-compatible. | `AIMLAPI_API_KEY` |
|
||||
| [Amazon Bedrock](https://aws.amazon.com/bedrock/) | Offers a variety of foundation models, including Claude, Jurassic-2, and others. **AWS environment variables must be set in advance, not configured through `goose configure`** | Credential auth: `AWS_PROFILE`, or `AWS_ACCESS_KEY_ID`, `AWS_SECRET_ACCESS_KEY`, `AWS_REGION`<br /><br />Bearer token auth: `AWS_BEARER_TOKEN_BEDROCK` and `AWS_REGION`, `AWS_DEFAULT_REGION`, or `AWS_PROFILE` |
|
||||
| [Amazon SageMaker TGI](https://docs.aws.amazon.com/sagemaker/latest/dg/realtime-endpoints.html) | Run Text Generation Inference models through Amazon SageMaker endpoints. **AWS credentials must be configured in advance.** | `SAGEMAKER_ENDPOINT_NAME`, `AWS_REGION` (optional), `AWS_PROFILE` (optional) |
|
||||
| [Anthropic](https://www.anthropic.com/) | Offers Claude, an advanced AI model for natural language tasks. | `ANTHROPIC_API_KEY`, `ANTHROPIC_HOST` (optional) |
|
||||
|
||||
Reference in New Issue
Block a user