pub struct GoogleCloudAiplatformV1GenerationConfig {
pub response_mime_type: Option<String>,
pub top_k: Option<f32>,
pub top_p: Option<f32>,
pub temperature: Option<f32>,
pub max_output_tokens: Option<i32>,
pub response_schema: Option<GoogleCloudAiplatformV1Schema>,
pub presence_penalty: Option<f32>,
pub candidate_count: Option<i32>,
pub stop_sequences: Option<Vec<String>>,
pub frequency_penalty: Option<f32>,
}Expand description
Generation config.
This type is not used in any activity, and only used as part of another schema.
Fields§
§response_mime_type: Option<String>Optional. Output response mimetype of the generated candidate text. Supported mimetype: - text/plain: (default) Text output. - application/json: JSON response in the candidates. The model needs to be prompted to output the appropriate response type, otherwise the behavior is undefined. This is a preview feature.
top_k: Option<f32>Optional. If specified, top-k sampling will be used.
top_p: Option<f32>Optional. If specified, nucleus sampling will be used.
temperature: Option<f32>Optional. Controls the randomness of predictions.
max_output_tokens: Option<i32>Optional. The maximum number of output tokens to generate per message.
response_schema: Option<GoogleCloudAiplatformV1Schema>Optional. The Schema object allows the definition of input and output data types. These types can be objects, but also primitives and arrays. Represents a select subset of an OpenAPI 3.0 schema object. If set, a compatible response_mime_type must also be set. Compatible mimetypes: application/json: Schema for JSON response.
presence_penalty: Option<f32>Optional. Positive penalties.
candidate_count: Option<i32>Optional. Number of candidates to generate.
stop_sequences: Option<Vec<String>>Optional. Stop sequences.
frequency_penalty: Option<f32>Optional. Frequency penalties.
Trait Implementations§
Source§impl Clone for GoogleCloudAiplatformV1GenerationConfig
impl Clone for GoogleCloudAiplatformV1GenerationConfig
Source§fn clone(&self) -> GoogleCloudAiplatformV1GenerationConfig
fn clone(&self) -> GoogleCloudAiplatformV1GenerationConfig
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Default for GoogleCloudAiplatformV1GenerationConfig
impl Default for GoogleCloudAiplatformV1GenerationConfig
Source§fn default() -> GoogleCloudAiplatformV1GenerationConfig
fn default() -> GoogleCloudAiplatformV1GenerationConfig
Source§impl<'de> Deserialize<'de> for GoogleCloudAiplatformV1GenerationConfig
impl<'de> Deserialize<'de> for GoogleCloudAiplatformV1GenerationConfig
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>,
impl Part for GoogleCloudAiplatformV1GenerationConfig
Auto Trait Implementations§
impl Freeze for GoogleCloudAiplatformV1GenerationConfig
impl RefUnwindSafe for GoogleCloudAiplatformV1GenerationConfig
impl Send for GoogleCloudAiplatformV1GenerationConfig
impl Sync for GoogleCloudAiplatformV1GenerationConfig
impl Unpin for GoogleCloudAiplatformV1GenerationConfig
impl UnwindSafe for GoogleCloudAiplatformV1GenerationConfig
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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>
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>
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