Current section

Files

Jump to
xberg lib xberg chunk.ex
Raw

lib/xberg/chunk.ex

# This file is auto-generated by alef — DO NOT EDIT.
# alef:hash:c42b3ed17053806bdcf42dea768a2aecba67c8ec1370751ea7323b02483cbce1
# To regenerate: alef generate
# To verify freshness: alef verify --exit-code
defmodule Xberg.Chunk do
@moduledoc """
A text chunk with optional embedding and metadata.
Chunks are created when chunking is enabled in `ExtractionConfig`. Each chunk
contains the text content, optional embedding vector (if embedding generation
is configured), and metadata about its position in the document.
"""
@typedoc "A text chunk with optional embedding and metadata."
@type t :: %__MODULE__{
content: String.t() | nil,
chunk_type: String.t() | nil,
embedding: [float()] | nil,
metadata: Xberg.ChunkMetadata.t()
}
defstruct content: nil,
chunk_type: :unknown,
embedding: nil,
metadata: nil
end