이 문서는 영어 원문을 자동 번역한 것으로, 내용이 원문과 다를 수 있습니다.영어 원문 보기
설정 버전의 이름이나 기본 설정 여부를 수정합니다. 처리 단계를 바꾸려면 새 버전을 생성합니다.
import os
from openai import OpenAI
client = OpenAI(
api_key=os.environ["UPSTAGE_API_KEY"],
base_url="https://api.upstage.ai/v2",
)
response = client.post(
"/agents/agt_example/configs/cfg_example",
cast_to=dict[str, object],
body={"name": "Default parse", "is_default": True},
)
print(response)
{
"id": "cfg_example",
"object": "config",
"agent_id": "agt_example",
"external_id": "1",
"name": "Default parse",
"is_default": true,
"steps": [
{
"id": "step_example",
"name": "Parse",
"type": "document-parse",
"data": {
"model": "default"
},
"is_first": true,
"next_steps": [],
"node_id": null
}
],
"created_at": 1794873600,
"updated_at": 1794873600
}
기본 설정은 실행 요청에서 config_id를 생략할 때만 사용합니다. 이전 실행에 사용된 설정은 바뀌지 않습니다.