Class: Kreuzberg::ElementMetadata

Inherits:
T::Struct
  • Object
show all
Extended by:
T::Sig
Defined in:
lib/kreuzberg/types.rb

Overview

Metadata for a semantic element.

Provides contextual information about an extracted element including its position within the document and custom metadata fields.

Examples:

 = Kreuzberg::ElementMetadata.new(
  page_number: 1,
  filename: "document.pdf",
  coordinates: bbox,
  element_index: 5,
  additional: { "style" => "bold" }
)