Class FeedbackDatasetItem.Builder
-
- All Implemented Interfaces:
public final class FeedbackDatasetItem.BuilderA builder for FeedbackDatasetItem.
-
-
Method Summary
-
-
Method Detail
-
id
final FeedbackDatasetItem.Builder id(String id)
The id of the dataset event to log feedback for. This is the row
idreturned byPOST /v1/dataset/{dataset_id}/insert
-
id
final FeedbackDatasetItem.Builder id(JsonField<String> id)
Sets Builder.id to an arbitrary JSON value.
You should usually call Builder.id with a well-typed String value instead. This method is primarily for setting the field to an undocumented or not yet supported value.
-
comment
final FeedbackDatasetItem.Builder comment(String comment)
An optional comment string to log about the dataset event
-
comment
final FeedbackDatasetItem.Builder comment(Optional<String> comment)
Alias for calling Builder.comment with
comment.orElse(null).
-
comment
final FeedbackDatasetItem.Builder comment(JsonField<String> comment)
Sets Builder.comment to an arbitrary JSON value.
You should usually call Builder.comment with a well-typed String value instead. This method is primarily for setting the field to an undocumented or not yet supported value.
-
metadata
final FeedbackDatasetItem.Builder metadata(FeedbackDatasetItem.Metadata metadata)
A dictionary with additional data about the feedback. If you have a
user_id, you can log it here and access it in the Braintrust UI. Note, this metadata does not correspond to the main event itself, but rather the audit log attached to the event.
-
metadata
final FeedbackDatasetItem.Builder metadata(Optional<FeedbackDatasetItem.Metadata> metadata)
Alias for calling Builder.metadata with
metadata.orElse(null).
-
metadata
final FeedbackDatasetItem.Builder metadata(JsonField<FeedbackDatasetItem.Metadata> metadata)
Sets Builder.metadata to an arbitrary JSON value.
You should usually call Builder.metadata with a well-typed Metadata value instead. This method is primarily for setting the field to an undocumented or not yet supported value.
-
source
final FeedbackDatasetItem.Builder source(FeedbackDatasetItem.Source source)
The source of the feedback. Must be one of "external" (default), "app", or "api"
-
source
final FeedbackDatasetItem.Builder source(Optional<FeedbackDatasetItem.Source> source)
Alias for calling Builder.source with
source.orElse(null).
-
source
final FeedbackDatasetItem.Builder source(JsonField<FeedbackDatasetItem.Source> source)
Sets Builder.source to an arbitrary JSON value.
You should usually call Builder.source with a well-typed Source value instead. This method is primarily for setting the field to an undocumented or not yet supported value.
-
tags
final FeedbackDatasetItem.Builder tags(List<String> tags)
A list of tags to log
-
tags
final FeedbackDatasetItem.Builder tags(Optional<List<String>> tags)
Alias for calling Builder.tags with
tags.orElse(null).
-
tags
final FeedbackDatasetItem.Builder tags(JsonField<List<String>> tags)
Sets Builder.tags to an arbitrary JSON value.
You should usually call Builder.tags with a well-typed
List<String>value instead. This method is primarily for setting the field to an undocumented or not yet supported value.
-
addTag
final FeedbackDatasetItem.Builder addTag(String tag)
-
additionalProperties
final FeedbackDatasetItem.Builder additionalProperties(Map<String, JsonValue> additionalProperties)
-
putAdditionalProperty
final FeedbackDatasetItem.Builder putAdditionalProperty(String key, JsonValue value)
-
putAllAdditionalProperties
final FeedbackDatasetItem.Builder putAllAdditionalProperties(Map<String, JsonValue> additionalProperties)
-
removeAdditionalProperty
final FeedbackDatasetItem.Builder removeAdditionalProperty(String key)
-
removeAllAdditionalProperties
final FeedbackDatasetItem.Builder removeAllAdditionalProperties(Set<String> keys)
-
build
final FeedbackDatasetItem build()
Returns an immutable instance of FeedbackDatasetItem.
Further updates to this Builder will not mutate the returned instance.
The following fields are required:
.id()
-
-
-
-