pub struct CreateEvalCustomDataSourceConfig {
pub item_schema: HashMap<String, Value>,
pub include_sample_schema: Option<bool>,
}
Expand description
A CustomDataSourceConfig object that defines the schema for the data source used for the evaluation runs. This schema is used to define the shape of the data that will be:
- Used to define your testing criteria and
- What data is required when creating a run
Fields§
§item_schema: HashMap<String, Value>
The json schema for each row in the data source.
include_sample_schema: Option<bool>
Whether the eval should expect you to populate the sample namespace (ie, by generating responses off of your data source)
Implementations§
Source§impl CreateEvalCustomDataSourceConfig
impl CreateEvalCustomDataSourceConfig
Sourcepub fn builder() -> CreateEvalCustomDataSourceConfigBuilder<((), ())>
pub fn builder() -> CreateEvalCustomDataSourceConfigBuilder<((), ())>
Create a builder for building CreateEvalCustomDataSourceConfig
.
On the builder, call .item_schema(...)
, .include_sample_schema(...)
(optional) to set the values of the fields.
Finally, call .build()
to create the instance of CreateEvalCustomDataSourceConfig
.
Trait Implementations§
Source§impl Clone for CreateEvalCustomDataSourceConfig
impl Clone for CreateEvalCustomDataSourceConfig
Source§fn clone(&self) -> CreateEvalCustomDataSourceConfig
fn clone(&self) -> CreateEvalCustomDataSourceConfig
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl<'de> Deserialize<'de> for CreateEvalCustomDataSourceConfig
impl<'de> Deserialize<'de> for CreateEvalCustomDataSourceConfig
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 PartialEq for CreateEvalCustomDataSourceConfig
impl PartialEq for CreateEvalCustomDataSourceConfig
Source§fn eq(&self, other: &CreateEvalCustomDataSourceConfig) -> bool
fn eq(&self, other: &CreateEvalCustomDataSourceConfig) -> bool
Tests for
self
and other
values to be equal, and is used by ==
.impl StructuralPartialEq for CreateEvalCustomDataSourceConfig
Auto Trait Implementations§
impl Freeze for CreateEvalCustomDataSourceConfig
impl RefUnwindSafe for CreateEvalCustomDataSourceConfig
impl Send for CreateEvalCustomDataSourceConfig
impl Sync for CreateEvalCustomDataSourceConfig
impl Unpin for CreateEvalCustomDataSourceConfig
impl UnwindSafe for CreateEvalCustomDataSourceConfig
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