ACPex.Schema.Types.ContentBlock.Text (ACPex v0.1.1)

Copy Markdown View Source

Text content block.

Represents plain text content in a prompt or message.

Required Fields

  • type - Always "text" for this variant
  • text - The text content

Optional Fields

  • annotations - Additional annotations (map)
  • meta - Additional metadata (map)

Example

%ACPex.Schema.Types.ContentBlock.Text{
  type: "text",
  text: "Hello, world!"
}

JSON Representation

{
  "type": "text",
  "text": "Hello, world!"
}

Summary

Functions

Creates a changeset for validation.

Types

t()

@type t() :: %ACPex.Schema.Types.ContentBlock.Text{
  annotations: map() | nil,
  meta: map() | nil,
  text: String.t(),
  type: String.t()
}

Functions

changeset(struct \\ %__MODULE__{}, params)

@spec changeset(t(), map()) :: Ecto.Changeset.t()

Creates a changeset for validation.

Required Fields

  • text - Must be present

The type field defaults to "text".