pub struct CreateKnowledgeRequest { /* private fields */ }Expand description
Implementations§
Source§impl CreateKnowledgeRequest
impl CreateKnowledgeRequest
Sourcepub fn new(embedding_id: EmbeddingId, name: impl Into<String>) -> Self
pub fn new(embedding_id: EmbeddingId, name: impl Into<String>) -> Self
Build a create request with required fields
Sourcepub fn with_description(self, desc: impl Into<String>) -> Self
pub fn with_description(self, desc: impl Into<String>) -> Self
Optional fields setters Set the knowledge-base description.
Sourcepub fn with_background(self, bg: BackgroundColor) -> Self
pub fn with_background(self, bg: BackgroundColor) -> Self
Set the background color.
Sourcepub fn with_icon(self, icon: KnowledgeIcon) -> Self
pub fn with_icon(self, icon: KnowledgeIcon) -> Self
Set the icon.
Sourcepub fn with_embedding_model(self, model: impl Into<String>) -> Self
pub fn with_embedding_model(self, model: impl Into<String>) -> Self
Set the embedding model name (optional). When given alongside
embedding_id, the two must be consistent (plan §13.5).
Sourcepub fn with_contextual(self, contextual: u8) -> Self
pub fn with_contextual(self, contextual: u8) -> Self
Set the contextual-retrieval flag (0 or 1; plan §13.5).
Auto Trait Implementations§
impl Freeze for CreateKnowledgeRequest
impl RefUnwindSafe for CreateKnowledgeRequest
impl Send for CreateKnowledgeRequest
impl Sync for CreateKnowledgeRequest
impl Unpin for CreateKnowledgeRequest
impl UnsafeUnpin for CreateKnowledgeRequest
impl UnwindSafe for CreateKnowledgeRequest
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