Current section
Files
Jump to
Current section
Files
lib/schemas/file/create_request.ex
defmodule OpenAi.File.CreateRequest do
@moduledoc """
Provides struct and type for a File.CreateRequest
"""
@type t :: %__MODULE__{file: String.t(), purpose: String.t()}
defstruct [:file, :purpose]
@doc false
@spec __fields__(atom) :: keyword
def __fields__(type \\ :t)
def __fields__(:t) do
[
file: {:string, :generic},
purpose: {:enum, ["assistants", "batch", "fine-tune", "vision", "user_data", "evals"]}
]
end
end