pub struct DeepSeek { /* private fields */ }Expand description
DeepSeek API client
Implementations§
Source§impl DeepSeek
impl DeepSeek
Sourcepub async fn create_chat_session(&mut self) -> Result<String>
pub async fn create_chat_session(&mut self) -> Result<String>
Create a new chat session
Sourcepub async fn chat_completion(
&mut self,
chat_session_id: &str,
prompt: &str,
parent_message_id: Option<&str>,
thinking_mode: ThinkingMode,
search_mode: SearchMode,
system_prompt: Option<&str>,
) -> Result<String>
pub async fn chat_completion( &mut self, chat_session_id: &str, prompt: &str, parent_message_id: Option<&str>, thinking_mode: ThinkingMode, search_mode: SearchMode, system_prompt: Option<&str>, ) -> Result<String>
Send a message and get a streaming response
Sourcepub async fn get_chat_history(&mut self, chat_session_id: &str) -> Result<Value>
pub async fn get_chat_history(&mut self, chat_session_id: &str) -> Result<Value>
Get conversation history for a chat session
Auto Trait Implementations§
impl Freeze for DeepSeek
impl !RefUnwindSafe for DeepSeek
impl Send for DeepSeek
impl Sync for DeepSeek
impl Unpin for DeepSeek
impl !UnwindSafe for DeepSeek
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more