List Context Management API
출처: 문서
본문
컨텍스트 관리 목록 API
3.5부터 도입 {: .label .label-purple }
이 API를 사용하면 클러스터에 있는 모든 컨텍스트 관리 구성 목록을 조회할 수 있어요.
엔드포인트
GET /_plugins/_ml/context_management
쿼리 파라미터
사용할 수 있는 쿼리 파라미터는 다음 표에 정리되어 있어요.
| 파라미터 | 데이터 타입 | 필수/선택 | 설명 |
|---|---|---|---|
size |
Integer | 선택 | 반환할 결과의 최대 개수예요. 기본값은 10이에요. |
from |
Integer | 선택 | 페이지네이션의 시작 인덱스예요. 기본값은 0이에요. |
요청 예제
GET /_plugins/_ml/context_management
{% include copy-curl.html %}
페이지네이션을 사용한 요청 예제
GET /_plugins/_ml/context_management?size=20&from=0
{% include copy-curl.html %}
응답 예제
{
"total": 1,
"context_management": [
{
"name": "sliding_window_max_40000_tokens_managers",
"description": "Context management for truncating tool outputs to prevent input length issues",
"hooks": {
"pre_llm": [
{
"type": "SlidingWindowManager",
"config": {
"max_messages": 8,
"activation": {
"rule_type": "always"
}
}
}
],
"post_tool": [
{
"type": "ToolsOutputTruncateManager",
"config": {
"max_output_length": 40000,
"activation": {
"rule_type": "always"
}
}
}
]
},
"created_time": 1769457277774,
"last_modified": 1769457277774
}
]
}
관련 문서
자세한 내용은 Context management 문서를 참고하세요.