Base64 encoding

Base64 is a binary-to-text encoding scheme that represents binary data in an ASCII string format by translating it into a radix-64 representation. It is commonly used to transmit data over media that are designed to deal with text, such as email (MIME) or JSON payloads.

Core Concepts

  • Radix-64: Uses 64 printable ASCII characters (A-Z, a-z, 0-9, +, /) and padding with ’=‘.
  • Purpose: Ensures data integrity during transmission over text-based protocols.
  • Decoding: Reverses the process to retrieve original binary data.

Integration with Multimodal Models

In the context of modern AI and Multimodal AI workflows, Base64 is frequently used to embed images directly into API requests or JSON responses, avoiding the need for separate file uploads.

References