Package ai.pipestream.data.v1
Class ChunkEmbedding.Builder
java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<ChunkEmbedding.Builder>
com.google.protobuf.GeneratedMessage.Builder<ChunkEmbedding.Builder>
ai.pipestream.data.v1.ChunkEmbedding.Builder
- All Implemented Interfaces:
ChunkEmbeddingOrBuilder,com.google.protobuf.Message.Builder,com.google.protobuf.MessageLite.Builder,com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder,Cloneable
- Enclosing class:
ChunkEmbedding
public static final class ChunkEmbedding.Builder
extends com.google.protobuf.GeneratedMessage.Builder<ChunkEmbedding.Builder>
implements ChunkEmbeddingOrBuilder
Text content and vector embedding for a single chunk.Protobuf type
ai.pipestream.data.v1.ChunkEmbedding-
Method Summary
Modifier and TypeMethodDescriptionaddAllVector(Iterable<? extends Float> values) Vector embedding for this chunk's text.addVector(float value) Vector embedding for this chunk's text.build()clear()Identifier for the chunking configuration used.Identifier for a group of related chunks.Unique identifier for this chunk.Character offset where chunk ends in original document.Character offset where chunk starts in original document.Actual text content of the chunk.Vector embedding for this chunk's text.Identifier for the chunking configuration used.com.google.protobuf.ByteStringIdentifier for the chunking configuration used.Identifier for a group of related chunks.com.google.protobuf.ByteStringIdentifier for a group of related chunks.Unique identifier for this chunk.com.google.protobuf.ByteStringUnique identifier for this chunk.static final com.google.protobuf.Descriptors.Descriptorcom.google.protobuf.Descriptors.DescriptorintCharacter offset where chunk ends in original document.intCharacter offset where chunk starts in original document.Actual text content of the chunk.com.google.protobuf.ByteStringActual text content of the chunk.floatgetVector(int index) Vector embedding for this chunk's text.intVector embedding for this chunk's text.Vector embedding for this chunk's text.booleanIdentifier for the chunking configuration used.booleanIdentifier for a group of related chunks.booleanUnique identifier for this chunk.booleanCharacter offset where chunk ends in original document.booleanCharacter offset where chunk starts in original document.protected com.google.protobuf.GeneratedMessage.FieldAccessorTablefinal booleanmergeFrom(ChunkEmbedding other) mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) mergeFrom(com.google.protobuf.Message other) setChunkConfigId(String value) Identifier for the chunking configuration used.setChunkConfigIdBytes(com.google.protobuf.ByteString value) Identifier for the chunking configuration used.setChunkGroupId(String value) Identifier for a group of related chunks.setChunkGroupIdBytes(com.google.protobuf.ByteString value) Identifier for a group of related chunks.setChunkId(String value) Unique identifier for this chunk.setChunkIdBytes(com.google.protobuf.ByteString value) Unique identifier for this chunk.setOriginalCharEndOffset(int value) Character offset where chunk ends in original document.setOriginalCharStartOffset(int value) Character offset where chunk starts in original document.setTextContent(String value) Actual text content of the chunk.setTextContentBytes(com.google.protobuf.ByteString value) Actual text content of the chunk.setVector(int index, float value) Vector embedding for this chunk's text.Methods inherited from class com.google.protobuf.GeneratedMessage.Builder
addRepeatedField, clearField, clearOneof, clone, getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, getUnknownFieldSetBuilder, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, internalGetMutableMapField, internalGetMutableMapFieldReflection, isClean, markClean, mergeUnknownFields, mergeUnknownLengthDelimitedField, mergeUnknownVarintField, newBuilderForField, onBuilt, onChanged, parseUnknownField, setField, setRepeatedField, setUnknownFields, setUnknownFieldSetBuilder, setUnknownFieldsProto3Methods inherited from class com.google.protobuf.AbstractMessage.Builder
findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toStringMethods inherited from class com.google.protobuf.AbstractMessageLite.Builder
addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, newUninitializedMessageExceptionMethods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface com.google.protobuf.Message.Builder
mergeDelimitedFrom, mergeDelimitedFromMethods inherited from interface com.google.protobuf.MessageLite.Builder
mergeFromMethods inherited from interface com.google.protobuf.MessageOrBuilder
findInitializationErrors, getAllFields, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
-
Method Details
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() -
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()- Specified by:
internalGetFieldAccessorTablein classcom.google.protobuf.GeneratedMessage.Builder<ChunkEmbedding.Builder>
-
clear
- Specified by:
clearin interfacecom.google.protobuf.Message.Builder- Specified by:
clearin interfacecom.google.protobuf.MessageLite.Builder- Overrides:
clearin classcom.google.protobuf.GeneratedMessage.Builder<ChunkEmbedding.Builder>
-
getDescriptorForType
public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.Message.Builder- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.MessageOrBuilder- Overrides:
getDescriptorForTypein classcom.google.protobuf.GeneratedMessage.Builder<ChunkEmbedding.Builder>
-
getDefaultInstanceForType
- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageLiteOrBuilder- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageOrBuilder
-
build
- Specified by:
buildin interfacecom.google.protobuf.Message.Builder- Specified by:
buildin interfacecom.google.protobuf.MessageLite.Builder
-
buildPartial
- Specified by:
buildPartialin interfacecom.google.protobuf.Message.Builder- Specified by:
buildPartialin interfacecom.google.protobuf.MessageLite.Builder
-
mergeFrom
- Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<ChunkEmbedding.Builder>
-
mergeFrom
-
isInitialized
public final boolean isInitialized()- Specified by:
isInitializedin interfacecom.google.protobuf.MessageLiteOrBuilder- Overrides:
isInitializedin classcom.google.protobuf.GeneratedMessage.Builder<ChunkEmbedding.Builder>
-
mergeFrom
public ChunkEmbedding.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Specified by:
mergeFromin interfacecom.google.protobuf.MessageLite.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<ChunkEmbedding.Builder>- Throws:
IOException
-
getTextContent
Actual text content of the chunk.
string text_content = 1 [json_name = "textContent"];- Specified by:
getTextContentin interfaceChunkEmbeddingOrBuilder- Returns:
- The textContent.
-
getTextContentBytes
public com.google.protobuf.ByteString getTextContentBytes()Actual text content of the chunk.
string text_content = 1 [json_name = "textContent"];- Specified by:
getTextContentBytesin interfaceChunkEmbeddingOrBuilder- Returns:
- The bytes for textContent.
-
setTextContent
Actual text content of the chunk.
string text_content = 1 [json_name = "textContent"];- Parameters:
value- The textContent to set.- Returns:
- This builder for chaining.
-
clearTextContent
Actual text content of the chunk.
string text_content = 1 [json_name = "textContent"];- Returns:
- This builder for chaining.
-
setTextContentBytes
Actual text content of the chunk.
string text_content = 1 [json_name = "textContent"];- Parameters:
value- The bytes for textContent to set.- Returns:
- This builder for chaining.
-
getVectorList
Vector embedding for this chunk's text.
repeated float vector = 2 [json_name = "vector"];- Specified by:
getVectorListin interfaceChunkEmbeddingOrBuilder- Returns:
- A list containing the vector.
-
getVectorCount
public int getVectorCount()Vector embedding for this chunk's text.
repeated float vector = 2 [json_name = "vector"];- Specified by:
getVectorCountin interfaceChunkEmbeddingOrBuilder- Returns:
- The count of vector.
-
getVector
public float getVector(int index) Vector embedding for this chunk's text.
repeated float vector = 2 [json_name = "vector"];- Specified by:
getVectorin interfaceChunkEmbeddingOrBuilder- Parameters:
index- The index of the element to return.- Returns:
- The vector at the given index.
-
setVector
Vector embedding for this chunk's text.
repeated float vector = 2 [json_name = "vector"];- Parameters:
index- The index to set the value at.value- The vector to set.- Returns:
- This builder for chaining.
-
addVector
Vector embedding for this chunk's text.
repeated float vector = 2 [json_name = "vector"];- Parameters:
value- The vector to add.- Returns:
- This builder for chaining.
-
addAllVector
Vector embedding for this chunk's text.
repeated float vector = 2 [json_name = "vector"];- Parameters:
values- The vector to add.- Returns:
- This builder for chaining.
-
clearVector
Vector embedding for this chunk's text.
repeated float vector = 2 [json_name = "vector"];- Returns:
- This builder for chaining.
-
hasChunkId
public boolean hasChunkId()Unique identifier for this chunk.
optional string chunk_id = 3 [json_name = "chunkId"];- Specified by:
hasChunkIdin interfaceChunkEmbeddingOrBuilder- Returns:
- Whether the chunkId field is set.
-
getChunkId
Unique identifier for this chunk.
optional string chunk_id = 3 [json_name = "chunkId"];- Specified by:
getChunkIdin interfaceChunkEmbeddingOrBuilder- Returns:
- The chunkId.
-
getChunkIdBytes
public com.google.protobuf.ByteString getChunkIdBytes()Unique identifier for this chunk.
optional string chunk_id = 3 [json_name = "chunkId"];- Specified by:
getChunkIdBytesin interfaceChunkEmbeddingOrBuilder- Returns:
- The bytes for chunkId.
-
setChunkId
Unique identifier for this chunk.
optional string chunk_id = 3 [json_name = "chunkId"];- Parameters:
value- The chunkId to set.- Returns:
- This builder for chaining.
-
clearChunkId
Unique identifier for this chunk.
optional string chunk_id = 3 [json_name = "chunkId"];- Returns:
- This builder for chaining.
-
setChunkIdBytes
Unique identifier for this chunk.
optional string chunk_id = 3 [json_name = "chunkId"];- Parameters:
value- The bytes for chunkId to set.- Returns:
- This builder for chaining.
-
hasOriginalCharStartOffset
public boolean hasOriginalCharStartOffset()Character offset where chunk starts in original document.
optional int32 original_char_start_offset = 4 [json_name = "originalCharStartOffset"];- Specified by:
hasOriginalCharStartOffsetin interfaceChunkEmbeddingOrBuilder- Returns:
- Whether the originalCharStartOffset field is set.
-
getOriginalCharStartOffset
public int getOriginalCharStartOffset()Character offset where chunk starts in original document.
optional int32 original_char_start_offset = 4 [json_name = "originalCharStartOffset"];- Specified by:
getOriginalCharStartOffsetin interfaceChunkEmbeddingOrBuilder- Returns:
- The originalCharStartOffset.
-
setOriginalCharStartOffset
Character offset where chunk starts in original document.
optional int32 original_char_start_offset = 4 [json_name = "originalCharStartOffset"];- Parameters:
value- The originalCharStartOffset to set.- Returns:
- This builder for chaining.
-
clearOriginalCharStartOffset
Character offset where chunk starts in original document.
optional int32 original_char_start_offset = 4 [json_name = "originalCharStartOffset"];- Returns:
- This builder for chaining.
-
hasOriginalCharEndOffset
public boolean hasOriginalCharEndOffset()Character offset where chunk ends in original document.
optional int32 original_char_end_offset = 5 [json_name = "originalCharEndOffset"];- Specified by:
hasOriginalCharEndOffsetin interfaceChunkEmbeddingOrBuilder- Returns:
- Whether the originalCharEndOffset field is set.
-
getOriginalCharEndOffset
public int getOriginalCharEndOffset()Character offset where chunk ends in original document.
optional int32 original_char_end_offset = 5 [json_name = "originalCharEndOffset"];- Specified by:
getOriginalCharEndOffsetin interfaceChunkEmbeddingOrBuilder- Returns:
- The originalCharEndOffset.
-
setOriginalCharEndOffset
Character offset where chunk ends in original document.
optional int32 original_char_end_offset = 5 [json_name = "originalCharEndOffset"];- Parameters:
value- The originalCharEndOffset to set.- Returns:
- This builder for chaining.
-
clearOriginalCharEndOffset
Character offset where chunk ends in original document.
optional int32 original_char_end_offset = 5 [json_name = "originalCharEndOffset"];- Returns:
- This builder for chaining.
-
hasChunkGroupId
public boolean hasChunkGroupId()Identifier for a group of related chunks.
optional string chunk_group_id = 6 [json_name = "chunkGroupId"];- Specified by:
hasChunkGroupIdin interfaceChunkEmbeddingOrBuilder- Returns:
- Whether the chunkGroupId field is set.
-
getChunkGroupId
Identifier for a group of related chunks.
optional string chunk_group_id = 6 [json_name = "chunkGroupId"];- Specified by:
getChunkGroupIdin interfaceChunkEmbeddingOrBuilder- Returns:
- The chunkGroupId.
-
getChunkGroupIdBytes
public com.google.protobuf.ByteString getChunkGroupIdBytes()Identifier for a group of related chunks.
optional string chunk_group_id = 6 [json_name = "chunkGroupId"];- Specified by:
getChunkGroupIdBytesin interfaceChunkEmbeddingOrBuilder- Returns:
- The bytes for chunkGroupId.
-
setChunkGroupId
Identifier for a group of related chunks.
optional string chunk_group_id = 6 [json_name = "chunkGroupId"];- Parameters:
value- The chunkGroupId to set.- Returns:
- This builder for chaining.
-
clearChunkGroupId
Identifier for a group of related chunks.
optional string chunk_group_id = 6 [json_name = "chunkGroupId"];- Returns:
- This builder for chaining.
-
setChunkGroupIdBytes
Identifier for a group of related chunks.
optional string chunk_group_id = 6 [json_name = "chunkGroupId"];- Parameters:
value- The bytes for chunkGroupId to set.- Returns:
- This builder for chaining.
-
hasChunkConfigId
public boolean hasChunkConfigId()Identifier for the chunking configuration used.
optional string chunk_config_id = 7 [json_name = "chunkConfigId"];- Specified by:
hasChunkConfigIdin interfaceChunkEmbeddingOrBuilder- Returns:
- Whether the chunkConfigId field is set.
-
getChunkConfigId
Identifier for the chunking configuration used.
optional string chunk_config_id = 7 [json_name = "chunkConfigId"];- Specified by:
getChunkConfigIdin interfaceChunkEmbeddingOrBuilder- Returns:
- The chunkConfigId.
-
getChunkConfigIdBytes
public com.google.protobuf.ByteString getChunkConfigIdBytes()Identifier for the chunking configuration used.
optional string chunk_config_id = 7 [json_name = "chunkConfigId"];- Specified by:
getChunkConfigIdBytesin interfaceChunkEmbeddingOrBuilder- Returns:
- The bytes for chunkConfigId.
-
setChunkConfigId
Identifier for the chunking configuration used.
optional string chunk_config_id = 7 [json_name = "chunkConfigId"];- Parameters:
value- The chunkConfigId to set.- Returns:
- This builder for chaining.
-
clearChunkConfigId
Identifier for the chunking configuration used.
optional string chunk_config_id = 7 [json_name = "chunkConfigId"];- Returns:
- This builder for chaining.
-
setChunkConfigIdBytes
Identifier for the chunking configuration used.
optional string chunk_config_id = 7 [json_name = "chunkConfigId"];- Parameters:
value- The bytes for chunkConfigId to set.- Returns:
- This builder for chaining.
-