OpenaiEx.Beta.Assistants (openai_ex v0.9.4)

View Source

This module provides an implementation of the OpenAI assistants API. The API reference can be found at https://platform.openai.com/docs/api-reference/assistants.

Summary

Functions

Calls the assistant 'create' endpoint.

Calls the assistant delete endpoint.

Returns a list of assistant objects.

Creates a new assistants request

Creates a new list assistants request

Calls the assistant retrieve endpoint.

Calls the assistant update endpoint.

Functions

create(openai, assistant)

create!(openai, assistant)

Calls the assistant 'create' endpoint.

See https://platform.openai.com/docs/api-reference/assistants/createAssistant for more information.

delete(openai, assistant_id)

delete!(openai, assistant_id)

Calls the assistant delete endpoint.

https://platform.openai.com/docs/api-reference/assistants/deleteAssistant

list(openai, params \\ %{})

list!(openai, params \\ %{})

Returns a list of assistant objects.

https://platform.openai.com/docs/api-reference/assistants/listAssistants

new(args)

Creates a new assistants request

Example usage:

iex> _request = OpenaiEx.Beta.Assistants.new(model: "gpt-4-turbo")
%{model: "gpt-4-turbo"}

new_list(args)

Creates a new list assistants request

retrieve(openai, assistant_id)

retrieve!(openai, assistant_id)

Calls the assistant retrieve endpoint.

https://platform.openai.com/docs/api-reference/assistants/getAssistant

update(openai, assistant_id, assistant)

update!(openai, assistant_id, assistant)

Calls the assistant update endpoint.

See https://platform.openai.com/docs/api-reference/assistants/modifyAssistant for more information.