자동 모델 선택
기본 URL https://arteza.ai/api/v1
OpenAPI 3.1 사양, SDK 생성기 및 에이전트용: /api/v1/openapi.json
TypeScript 및 Python용 공식 SDK, 명령줄 및 에이전트 스킬: SDK 및 CLI
"model": "auto"를 "route" 객체와 함께 전송하면 Arteza가 모델을 선택합니다: 작업을 파악하기 위해 전송한 미디어를 읽고(이미지와 "video"는 이미지-투-비디오, 오디오와 얼굴은 아바타), 해당 필드로 수행할 수 있는 모델만 유지하고, route.priority -- quality(기본값), speed 또는 cost -- 를 기준으로 순위를 매깁니다(선택적으로 route.max_credits 범위 내에서). 응답에는 모델, 이유 및 차순위 선택지를 명시하는 "routing" 객체가 포함됩니다. "model": "auto"를 보낸 POST /v1/estimate는 무료 시뮬레이션입니다.
curl https://arteza.ai/api/v1/generations \
-H "Authorization: Bearer $ARTEZA_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "auto",
"route": { "output": "video", "priority": "cost", "max_credits": 5 },
"input": { "prompt": "A red fox runs through fresh snow at dawn", "image_url": "https://example.com/fox.jpg" }
}'
# 202 ... "routing": {
# "task": "image-to-video", "priority": "cost",
# "chosen": { "model": "...", "credits": 1.7, "seconds": 90 },
# "reason": "the lowest price for image-to-video with these inputs ...",
# "alternatives": [ ... ], "dropped_fields": []
# }