pub struct Input {
pub dimensions: Option<i64>,
pub encoding_format: Option<InputEncodingFormat>,
pub input: InputInput,
pub model: InputModel,
}Expand description
Generates embeddings for one or more input texts. These embeddings can be used for semantic search, clustering, and other machine learning applications.
Fields§
§dimensions: Option<i64>Number of dimensions for output embeddings (Matryoshka). Model-specific ranges: 128–1024 for pplx-embed-v1-0.6b; 128–2560 for pplx-embed-v1-4b. Defaults to the model’s full dimensions (1024 or 2560).
encoding_format: Option<InputEncodingFormat>Output encoding format for embeddings. base64_int8 returns base64-encoded signed int8 values. base64_binary returns base64-encoded packed binary (1 bit per dimension). Default: base64_int8.
input: InputInputInput text(s) to embed.
model: InputModelEmbedding model to use.
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Input
impl<'de> Deserialize<'de> for Input
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl IntoOperation for Input
impl IntoOperation for Input
Auto Trait Implementations§
impl Forget for Input
impl Freeze for Input
impl Move for Input
impl RefUnwindSafe for Input
impl Send for Inputwhere
RawVecInner: Send,
impl Sync for Inputwhere
RawVecInner: Sync,
impl Unpin for Input
impl UnsafeUnpin for Inputwhere
*const u8 is !null: UnsafeUnpin,
PhantomData<u8>: UnsafeUnpin,
PhantomData<String>: UnsafeUnpin,
impl UnwindSafe for Inputwhere
RawVecInner: UnwindSafe,
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