Class DocumentChunk

DocumentChunk class

Represents a single chunk of content extracted from a document.

public sealed class DocumentChunk

Constructors

NameDescription
DocumentChunk(string, string, int, string)Initializes a new instance of the DocumentChunk class.

Properties

NameDescription
Content { get; }Gets the text content of the chunk.
Context { get; }Gets the structural context of this chunk, typically the header path indicating where this chunk appears in the document hierarchy.
Embedding { get; set; }Gets or sets the embedding vector for this chunk.
Id { get; }Gets the unique identifier of the chunk.
Index { get; }Gets the zero-based index of the chunk within the document.
Metadata { get; }Gets the metadata associated with this chunk.

Methods

NameDescription
static GetVectorDefinition(int)Returns a VectorStoreCollectionDefinition describing the schema of DocumentChunk for use with a vector store collection.

Remarks

Document chunks are the fundamental units used for AI processing, embedding generation, and vector indexing operations.

See Also