Class: Protege::DocumentPart

Inherits:
Data
  • Object
show all
Defined in:
lib/protege/types/document_part.rb

Overview

One document-typed message part — a sibling of TextPart for multimodal content, used for PDFs. Carries the filename, MIME type, and Base64-encoded bytes; the provider renders it into the wire format its API expects (e.g. an OpenAI file block). Document-capable models read the PDF itself — text and layout — rather than a server-side text extraction.

Instance Attribute Summary collapse

Instance Attribute Details

#dataObject (readonly)

Returns the value of attribute data

Returns:

  • (Object)

    the current value of data



8
9
10
# File 'lib/protege/types/document_part.rb', line 8

def data
  @data
end

#filenameObject (readonly)

Returns the value of attribute filename

Returns:

  • (Object)

    the current value of filename



8
9
10
# File 'lib/protege/types/document_part.rb', line 8

def filename
  @filename
end

#media_typeObject (readonly)

Returns the value of attribute media_type

Returns:

  • (Object)

    the current value of media_type



8
9
10
# File 'lib/protege/types/document_part.rb', line 8

def media_type
  @media_type
end