pub struct ClientRpcLlmInference<'a> { /* private fields */ }Expand description
llmInference.* RPCs.
Implementations§
Source§impl<'a> ClientRpcLlmInference<'a>
impl<'a> ClientRpcLlmInference<'a>
Sourcepub async fn set_provider(&self) -> Result<LlmInferenceSetProviderResult, Error>
pub async fn set_provider(&self) -> Result<LlmInferenceSetProviderResult, Error>
Registers an SDK client as the LLM inference callback provider.
Wire method: llmInference.setProvider.
§Returns
Indicates whether the calling client was registered as the LLM inference provider.
Experimental. This API is part of an experimental wire-protocol surface and may change or be removed in future SDK or CLI releases. Pin both the SDK and CLI versions if your code depends on it.
Sourcepub async fn http_response_start(
&self,
params: LlmInferenceHttpResponseStartRequest,
) -> Result<LlmInferenceHttpResponseStartResult, Error>
pub async fn http_response_start( &self, params: LlmInferenceHttpResponseStartRequest, ) -> Result<LlmInferenceHttpResponseStartResult, Error>
Delivers the response head (status + headers) for an in-flight request, correlated by the requestId the runtime supplied in httpRequestStart. Must be called exactly once per request before any httpResponseChunk frames.
Wire method: llmInference.httpResponseStart.
§Parameters
params- Response head.
§Returns
Whether the start frame was accepted.
Experimental. This API is part of an experimental wire-protocol surface and may change or be removed in future SDK or CLI releases. Pin both the SDK and CLI versions if your code depends on it.
Sourcepub async fn http_response_chunk(
&self,
params: LlmInferenceHttpResponseChunkRequest,
) -> Result<LlmInferenceHttpResponseChunkResult, Error>
pub async fn http_response_chunk( &self, params: LlmInferenceHttpResponseChunkRequest, ) -> Result<LlmInferenceHttpResponseChunkResult, Error>
Delivers a body byte range (or a terminal transport error) for an in-flight response, correlated by requestId. Set end true on the last chunk. When error is set the response terminates with a transport-level failure and the runtime raises an APIConnectionError.
Wire method: llmInference.httpResponseChunk.
§Parameters
params- A response body chunk or terminal error.
§Returns
Whether the chunk was accepted.
Experimental. This API is part of an experimental wire-protocol surface and may change or be removed in future SDK or CLI releases. Pin both the SDK and CLI versions if your code depends on it.
Trait Implementations§
Source§impl<'a> Clone for ClientRpcLlmInference<'a>
impl<'a> Clone for ClientRpcLlmInference<'a>
Source§fn clone(&self) -> ClientRpcLlmInference<'a>
fn clone(&self) -> ClientRpcLlmInference<'a>
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more