5.4. 유추 끝점


이 예제에서는 유추 끝점을 사용하여 모델을 쿼리하는 방법을 보여줍니다.

참고

모델을 배포할 때 토큰 인증을 활성화한 경우 Authorization 헤더를 추가하고 토큰 값을 지정합니다.

5.4.1. KServe를 위한 Cainitiatort TGIS ServingRuntime

  • :443/api/v1/task/text-generation
  • :443/api/v1/task/server-streaming-text-generation

명령 예

curl --json '{"model_id": "<model_name__>", "inputs": "<text>"}' https://<inference_endpoint_url>:443/api/v1/task/server-streaming-text-generation -H 'Authorization: Bearer <token>'
Copy to Clipboard Toggle word wrap

5.4.2. KServe 용 카피네트 Standalone ServingRuntime

여러 모델을 제공하는 경우 /info/models 또는 :443 cactlplanet.runtime.info.InfoService/GetModelsInfo 를 쿼리하여 제공된 모델 목록을 볼 수 있습니다.

REST 끝점

  • /api/v1/task/embedding
  • /api/v1/task/embedding-tasks
  • /API/v1/task/sentence-similarity
  • /api/v1/task/sentence-similarity-tasks
  • /api/v1/task/rerank
  • /api/v1/task/rerank-tasks
  • /info/models
  • /info/version
  • /info/runtime

gRPC endpoints

  • :443 caikit.runtime.Nlp.NlpService/EmbeddingTaskPredict
  • :443 caikit.runtime.Nlp.NlpService/EmbeddingTasksPredict
  • :443 caikit.runtime.Nlp.NlpService/SentenceSimilarityTaskPredict
  • :443 caikit.runtime.Nlp.NlpService/SentenceSimilarityTasksPredict
  • :443 caikit.runtime.Nlp.NlpService/RerankTaskPredict
  • :443 caikit.runtime.Nlp.NlpService/RerankTasksPredict
  • :443 caikit.runtime.info.InfoService/GetModelsInfo
  • :443 caikit.runtime.info.InfoService/GetRuntimeInfo
참고

기본적으로 Cakeygent Standalone Runtime은 REST 엔드포인트를 노출합니다. gRPC 프로토콜을 사용하려면 사용자 정의 Cakeygent Standalone ServingRuntime을 수동으로 배포합니다. 자세한 내용은 단일 모델 제공 플랫폼의 사용자 지정 모델 서비스 런타임 추가를 참조하십시오.

예제 매니페스트는 canit -tgis-serving GitHub 리포지토리에서 사용할 수 있습니다.

REST

curl -H 'Content-Type: application/json' -d '{"inputs": "<text>", "model_id": "<model_id>"}' <inference_endpoint_url>/api/v1/task/embedding -H 'Authorization: Bearer <token>'
Copy to Clipboard Toggle word wrap

gRPC

grpcurl -d '{"text": "<text>"}' -H \"mm-model-id: <model_id>\" <inference_endpoint_url>:443 caikit.runtime.Nlp.NlpService/EmbeddingTaskPredict -H 'Authorization: Bearer <token>'
Copy to Clipboard Toggle word wrap

5.4.3. KServe 용 TGIS Standalone ServingRuntime

중요

KServe의 text Generation Inference Server (TGIS) Standalone ServingRuntime 은 더 이상 사용되지 않습니다. 자세한 내용은 OpenShift AI 릴리스 노트를 참조하십시오.

  • :443 fmaas.GenerationService/Generate
  • :443 fmaas.GenerationService/GenerateStream

    참고

    TGIS 독립 실행형 런타임의 끝점을 쿼리하려면 OpenShift AI 텍스트 생성 유추 리포지토리의 proto 디렉터리에 파일을 다운로드해야 합니다.

명령 예

grpcurl -proto text-generation-inference/proto/generation.proto -d '{"requests": [{"text":"<text>"}]}' -H 'Authorization: Bearer <token>' -insecure <inference_endpoint_url>:443 fmaas.GenerationService/Generate
Copy to Clipboard Toggle word wrap

5.4.4. OpenVino Model Server

  • /v2/models/<model-name>/infer

명령 예

curl -ks <inference_endpoint_url>/v2/models/<model_name>/infer -d '{ "model_name": "<model_name>", "inputs": [{ "name": "<name_of_model_input>", "shape": [<shape>], "datatype": "<data_type>", "data": [<data>] }]}' -H 'Authorization: Bearer <token>'
Copy to Clipboard Toggle word wrap

5.4.5. KServe 용 vLLM NVIDIA GPU ServingRuntime

  • :443/version
  • :443/docs
  • :443/v1/models
  • :443/v1/chat/completions
  • :443/v1/completions
  • :443/v1/embeddings
  • :443/tokenize
  • :443/detokenize

    참고
    • vLLM 런타임은 OpenAI REST API와 호환됩니다. vLLM 런타임에서 지원하는 모델 목록은 지원되는 모델을 참조하십시오.
    • vLLM에 삽입된 유추 엔드포인트를 사용하려면 vLLM에서 지원하는 포함 모델을 사용해야 합니다. 유전 모델에는 임베딩 끝점을 사용할 수 없습니다. 자세한 내용은 vLLM의 포함 모델 지원을 참조하십시오.
    • vLLM v0.5.5부터 /v1/chat/completions 엔드포인트를 사용하여 모델을 쿼리하는 동안 채팅 템플릿을 제공해야 합니다. 모델에 사전 정의된 채팅 템플릿이 포함되어 있지 않은 경우 example과 같이 chat-template 명령줄 매개 변수를 사용하여 사용자 지정 vLLM 런타임에 채팅 템플릿을 지정할 수 있습니다. & lt;CHAT_TEMPLATE >를 템플릿 경로로 바꿉니다.

      containers:
        - args:
            - --chat-template=<CHAT_TEMPLATE>
      Copy to Clipboard Toggle word wrap

      여기에서 또는 /app/data/template 아래의 vLLM 이미지로 사용할 수 있는 채팅 템플릿을 사용할 수 있습니다. 자세한 내용은 templates를 참조하십시오.

    표시된 경로에 표시된 대로 단일 모델 제공 플랫폼은 OpenShift 라우터의 HTTPS 포트(일반적으로 포트 443)를 사용하여 외부 API 요청을 처리합니다.

명령 예

curl -v https://<inference_endpoint_url>:443/v1/chat/completions -H "Content-Type: application/json" -d '{ "messages": [{ "role": "<role>", "content": "<content>" }] -H 'Authorization: Bearer <token>'
Copy to Clipboard Toggle word wrap

5.4.6. KServe 용 vLLM Intel Gaudi Accelerator ServingRuntime

KServe의 vLLM NVIDIA GPU ServingRuntime을 참조하십시오.

5.4.7. KServe용 vLLM AMD GPU ServingRuntime

KServe의 vLLM NVIDIA GPU ServingRuntime을 참조하십시오.

5.4.8. KServe의 vLLM Cryostat AI Accelerator ServingRuntime

중요

x86에서 IBM Cryostatre AI Accelerators에 대한 지원은 현재 Red Hat OpenShift AI 3.0에서 기술 프리뷰 기능으로 제공됩니다. 기술 프리뷰 기능은 Red Hat 프로덕션 서비스 수준 계약(SLA)에서 지원되지 않으며 기능적으로 완전하지 않을 수 있습니다. Red Hat은 프로덕션 환경에서 사용하는 것을 권장하지 않습니다. 이러한 기능을 사용하면 향후 제품 기능을 조기에 이용할 수 있어 개발 과정에서 고객이 기능을 테스트하고 피드백을 제공할 수 있습니다.

Red Hat 기술 프리뷰 기능의 지원 범위에 대한 자세한 내용은 기술 프리뷰 기능 지원 범위를 참조하십시오.

KServe 런타임용 vLLM Cryostat AI AcceleratorRuntime을 사용하여 x86에서 IBM Cryostat AI 액셀러레이터 로 모델을 제공할 수 있습니다. 런타임을 사용하려면 Cryostat Operator를 설치하고 하드웨어 프로필을 구성해야 합니다. 자세한 내용은 operator 이미지하드웨어 프로필 작업을 참조하십시오.

5.4.9. KServe의 vLLM Cryostatre s390x ServingRuntime

KServe 런타임용 vLLM Cryostatre s390x ServingRuntime을 사용하여 IBM Z(s390x 아키텍처)에서 IBM 192.0.2.re AI 액셀러레이터로 모델을 제공할 수 있습니다. 런타임을 사용하려면 Cryostat Operator를 설치하고 하드웨어 프로필을 구성해야 합니다. 자세한 내용은 operator 이미지하드웨어 프로필 작업을 참조하십시오.

5.4.10. NVIDIA Triton Inference Server

REST 끝점

  • v2/models/[/versions/<model_version>]/infer
  • v2/models/<model_name>[/versions/<model_version>]
  • v2/health/ready
  • v2/health/live
  • v2/models/<model_name>[/versions/]/ready
  • v2
참고

ModelMesh는 다음 REST 끝점을 지원하지 않습니다.

  • v2/health/live
  • v2/health/ready
  • v2/models/<model_name>[/versions/]/ready

명령 예

curl -ks <inference_endpoint_url>/v2/models/<model_name>/infer -d '{ "model_name": "<model_name>", "inputs": [{ "name": "<name_of_model_input>", "shape": [<shape>], "datatype": "<data_type>", "data": [<data>] }]}' -H 'Authorization: Bearer <token>'
Copy to Clipboard Toggle word wrap

gRPC endpoints

  • :443 inference.GRPCInferenceService/ModelInfer
  • :443 inference.GRPCInferenceService/ModelReady
  • :443 inference.GRPCInferenceService/ModelMetadata
  • :443 inference.GRPCInferenceService/ServerReady
  • :443 inference.GRPCInferenceService/ServerLive
  • :443 inference.GRPCInferenceService/ServerMetadata

명령 예

grpcurl -cacert ./openshift_ca_istio_knative.crt -proto ./grpc_predict_v2.proto -d @ -H "Authorization: Bearer <token>" <inference_endpoint_url>:443 inference.GRPCInferenceService/ModelMetadata
Copy to Clipboard Toggle word wrap

5.4.11. Seldon MLServer

REST 끝점

  • v2/models/[/versions/<model_version>]/infer
  • v2/models/<model_name>[/versions/<model_version>]
  • v2/health/ready
  • v2/health/live
  • v2/models/<model_name>[/versions/]/ready
  • v2

명령 예

curl -ks <inference_endpoint_url>/v2/models/<model_name>/infer -d '{ "model_name": "<model_name>", "inputs": [{ "name": "<name_of_model_input>", "shape": [<shape>], "datatype": "<data_type>", "data": [<data>] }]}' -H 'Authorization: Bearer <token>'
Copy to Clipboard Toggle word wrap

gRPC endpoints

  • :443 inference.GRPCInferenceService/ModelInfer
  • :443 inference.GRPCInferenceService/ModelReady
  • :443 inference.GRPCInferenceService/ModelMetadata
  • :443 inference.GRPCInferenceService/ServerReady
  • :443 inference.GRPCInferenceService/ServerLive
  • :443 inference.GRPCInferenceService/ServerMetadata

명령 예

grpcurl -cacert ./openshift_ca_istio_knative.crt -proto ./grpc_predict_v2.proto -d @ -H "Authorization: Bearer <token>" <inference_endpoint_url>:443 inference.GRPCInferenceService/ModelMetadata
Copy to Clipboard Toggle word wrap

맨 위로 이동
Red Hat logoGithubredditYoutubeTwitter

자세한 정보

평가판, 구매 및 판매

커뮤니티

Red Hat 문서 정보

Red Hat을 사용하는 고객은 신뢰할 수 있는 콘텐츠가 포함된 제품과 서비스를 통해 혁신하고 목표를 달성할 수 있습니다. 최신 업데이트를 확인하세요.

보다 포괄적 수용을 위한 오픈 소스 용어 교체

Red Hat은 코드, 문서, 웹 속성에서 문제가 있는 언어를 교체하기 위해 최선을 다하고 있습니다. 자세한 내용은 다음을 참조하세요.Red Hat 블로그.

Red Hat 소개

Red Hat은 기업이 핵심 데이터 센터에서 네트워크 에지에 이르기까지 플랫폼과 환경 전반에서 더 쉽게 작업할 수 있도록 강화된 솔루션을 제공합니다.

Theme

© 2025 Red Hat