Anthropic: Claude Opus 5
Claude Opus 5 用於深入思考的開發、資訊分析及多步驟專業工作。支援自適應推理,以及透過應用程式工具檢查結果。
關於模型
此說明介紹模型的能力。Ailoot 可用的輸入、輸出與選項,依所選方法列於下方。
Claude Opus 5 是 Anthropic 的模型,用於需要研究資訊、做出有依據的選擇,並連續完成任務的日常專業工作。模型開發商著重軟體工程、多步驟商務流程、科學工作及視覺資料分析。介紹核心是深入思考的執行方式,以及自身結果的檢查。
找出原因、檢查並修正
開發中,Opus 5 可研究錯誤根因,並透過檢查評估提出的變更。若缺乏足夠的現成比對素材,描述的用途包括建立自己的檢查,例如測試剖析器行為。工作圍繞取得的資料進行:模型讀取資料、選擇動作、觀察結果,再修正發現的問題。
命令執行、檔案編輯及檢查執行須由應用程式提供對應工具。模型的主動性是指在所提供環境中選擇及安排動作,不代表能自行存取專案或在應用程式之外執行操作。
將圖片作為程式資料
Opus 5 接受文字與圖片,輸出文字。模型開發商的視覺範例包括從圖片擷取幾何資訊,再透過撰寫的程式碼重建零件。其他範例包括以程式設計建立互動式空氣動力學模擬及細胞圖示。
模型開發商的一般視覺輸入格式為 JPEG/PNG/GIF/WebP,動畫使用第一個影格。原生分析時,長邊為 2576 像素,使用 4784 個視覺 Token;較大圖片會在分析前縮小。檔案與參數支援取決於應用程式的方法。
這些任務展示分析與工程的結合:圖片可作為素材,文字結果可作為程式碼或解法說明。模擬執行、圖形建立及完成檔案產出,須使用環境工具;模型沒有獨立的內建圖片或影片輸出。
可控制的深度
預設啟用自適應推理,effort 標準為 high。支援 low、medium、high、xhigh 及 max。high 或較低等級可停用推理,xhigh 及 max 則須啟用。此版本未提供使用獨立預算的手動 extended thinking。
調整投入量會影響推理量,但不是可靠的可見文字長度控制方式。需要簡短回應或特定結構時,須在指令中明確指定。脈絡為1 百萬個 Token,一般模式下回應上限為128 千個 Token;深入分析時須為推理與最終內容保留空間。
科學與敏感任務
可靠的內建知識界線為五月 2026 年。Anthropic 描述的科學用途包括結構生物學、有機化學及生物資訊學。但模型開發商也指出,長時間自主生物研究仍有重大限制;能討論科學素材,不代表能自主完成任何研究。
防護機制允許尋找原始程式碼錯誤,但會限制部分敏感任務。最新資訊須透過提供的素材或搜尋取得,技術與科學結果也須在對應領域的環境中檢查。
Ailoot Ultra · OpenAI Chat POST /v1/chat/completions claude-opus-5-thinking
claude-opus-5-thinking入門
Claude Opus 5 用於深入思考的開發、資訊分析及多步驟專業工作。支援自適應推理,以及透過應用程式工具檢查結果。
- 接受的輸入
- 文字
- 結果
- 文字
Ailoot 可用 · 輸入與方法
Ailoot Ultra · OpenAI Chat POST /v1/chat/completions
- 輸入
text- 輸出
text- 輸出格式
- json 或 SSE
| 欄位 | 類型 | 要求 | 值與限制 | 預設值 |
|---|---|---|---|---|
欄位model | 類型string | 要求必填 | 值與限制 claude-opus-5-thinking | 預設值— |
欄位messages | 類型message[] | 要求必填 | 值與限制 項目數下限: 1 | 預設值— |
欄位messages[].role | 類型string | 要求必填 | 值與限制 依模型而定 | 預設值— |
欄位messages[].content | 類型string | 要求選填 | 值與限制 適用條件: 文字對話 | 預設值— |
欄位stream | 類型boolean | 要求選填 | 值與限制 | 預設值false |
輸入素材組合
文字 · UTF8 文字
messages[].content
方法參數與生命週期
| 參數 | 規格 |
|---|---|
參數content_type | 規格application/json |
參數required | 規格model, messages |
參數material_types | 規格text |
參數messages | 規格具有 role/content 結構的訊息陣列 |
參數file_material | 規格實際 UTF-8 文件以原文文字插入;不推定檔案 ID |
參數optional_controls | 規格stream |
參數control_scope | 規格文字對話;stream 是布林值,預設為 false。 |
參數output_modalities | 規格text |
參數hosted_operations | 規格false |
參數multimodal_input_binding | 規格null |
方法別名: /chat/completions
生命週期: synchronous_or_streamed
將確切模型 ID 與 messages 一併送出。
上下文長度不是輸出上限。
文字檔案可提供原文文字;圖片/音訊/檔案物件輸入需要精確綁定。
方案
費率資訊不會增加請求選項。支援的參數列於所選方法中。
- 快速模式
- 未指定 選取快速模式時
- flex 模式
- 未指定 選取 flex 模式時
- 最高推理強度
- 未指定 最高推理強度採用 default 調整值時
Ailoot 費率
各設定的價格
| 設定 | 費率表 | 費用 |
|---|---|---|
| 設定詞元基本費率 | 費率表基本費率 | 費用 輸入 · 輸入 Token $0.01 / 1K Token 輸出 · 輸出 Token $0.05 / 1K Token 輸入 · 讀取快取 $0.001 / 1K Token 輸入 · 寫入快取 $0.0125 / 1K Token 輸入 · 寫入快取,1 小時 — / 1K Token |
Ailoot 會在請求前預留估算金額。取得結果後,依實測用量結算最終費用。串流結算採用最終用量紀錄。預留金額與結算的運作方式 →
請求範例
Ailoot Ultra · OpenAI Chat
set -eu
: "${AILOOT_API_KEY:?Set your Ailoot API key}"
python3 - <<'PY_REQUEST'
import json,os
from pathlib import Path
p=json.loads('{"model":"claude-opus-5-thinking","messages":[{"role":"user","content":"hello"}],"stream":false}')
Path("request.json").write_text(json.dumps(p,ensure_ascii=False))
PY_REQUEST
curl --fail-with-body --silent --show-error https://api.ailoot.ai/v1/chat/completions \
-H "Authorization: Bearer $AILOOT_API_KEY" -H 'Content-Type: application/json' \
--data-binary @request.json -D response-headers.txt -o result.json
python3 - <<'PY_RESULT'
import json
from pathlib import Path
r=json.loads(Path("result.json").read_text())
for x in r.get("choices",[]):
if x.get("message",{}).get("content"): print(x["message"]["content"])
PY_RESULT
from openai import OpenAI
import os
if not os.environ.get("AILOOT_API_KEY", "").strip(): raise SystemExit("Set AILOOT_API_KEY before making a request")
client=OpenAI(base_url="https://api.ailoot.ai/v1",api_key=os.environ["AILOOT_API_KEY"],max_retries=0)
result=client.chat.completions.create(model="claude-opus-5-thinking", messages=[{"role":"user","content":"hello"}], stream=False)
import base64, json
from pathlib import Path
def save_result(data, stem="result"):
# Keep every field, including usage, IDs, reasoning and tool requests.
Path(stem + ".json").write_text(json.dumps(data, ensure_ascii=False, indent=2), encoding="utf-8")
print(json.dumps(data, ensure_ascii=False, indent=2))
def save_blob(encoded, suffix, label):
raw = base64.b64decode(encoded, altchars=b"-_", validate=True)
ext = "png" if raw.startswith(b"\x89PNG\r\n\x1a\n") else "jpg" if raw.startswith(b"\xff\xd8") else "webp" if raw[:4] == b"RIFF" and raw[8:12] == b"WEBP" else suffix
file = Path(stem + "-" + label + "." + ext)
file.write_bytes(raw)
print("Saved", file)
for index, block in enumerate(data.get("content") or []):
print("Content", index, json.dumps(block, ensure_ascii=False))
for choice in data.get("choices") or []:
print("Choice", choice.get("index"), json.dumps(choice.get("message", choice.get("delta", {})), ensure_ascii=False))
for index, item in enumerate(data.get("output") or []):
print("Output", index, json.dumps(item, ensure_ascii=False))
if item.get("type") == "image_generation_call" and item.get("result"):
save_blob(item["result"], item.get("output_format") or "bin", "output-" + str(index))
for ci, candidate in enumerate(data.get("candidates") or []):
for pi, part in enumerate((candidate.get("content") or {}).get("parts") or []):
print("Candidate/part", ci, pi, json.dumps(part, ensure_ascii=False))
blob = part.get("inlineData") or part.get("inline_data")
if blob and blob.get("data"):
mime = blob.get("mimeType") or blob.get("mime_type")
suffix = {"image/png":"png", "image/jpeg":"jpg", "image/webp":"webp", "audio/wav":"wav", "audio/mpeg":"mp3", "video/mp4":"mp4"}.get(mime, "bin")
save_blob(blob["data"], suffix, "candidate-" + str(ci) + "-part-" + str(pi))
save_result(result.to_dict(mode="json"))
接收並儲存結果
Ailoot Ultra · OpenAI Chat
json 或 SSE
保留所有已完成的結果
請保留所有完整傳回的回應、檔案與內容區塊。
保留每個候選項及其內容/工具呼叫/推理。SSE 中依候選項/工具索引組合增量,保留最終完成原因與用量。
需要檢查原始回應時
保留請求/回應 ID 與標頭。未提供通用的文字工作擷取 URL。
回應欄位
| 欄位 | 類型 |
|---|---|
欄位choices[].index | 類型integer |
欄位choices[].message.content | 類型string|null |
欄位choices[].message.tool_calls | 類型tool_call[] |
欄位choices[].message.reasoning_content | 類型string |
欄位choices[].message.reasoning_details | 類型object|array |
欄位choices[].finish_reason | 類型string|null |
欄位usage | 類型object |
錯誤與後續步驟
| 回應 | 條件 | 下一步 |
|---|---|---|
回應400 · invalid_request_error | 條件必要欄位、素材表示方式或參數值無效 | 下一步提出新的建立請求前,先修正指定欄位。 |
別名
模型別名
Ailoot Ultra claude-opus-5-thinking
方法路徑別名
/chat/completions
相關呼叫用 ID
FAQ · Anthropic: Claude Opus 5
- 可以使用哪些輸入與結果?
POST /v1/chat/completions·claude-opus-5-thinking:text→text- 請求使用哪些欄位?
POST /v1/chat/completions·claude-opus-5-thinking:model,messages,stream- 適用哪些限制?
POST /v1/chat/completions·claude-opus-5-thinking:messages.min_items:1