openai 0.130.0 → 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +36 -0
- data/README.md +39 -3
- data/lib/openai/client.rb +0 -4
- data/lib/openai/internal/type/union.rb +5 -1
- data/lib/openai/models/batch_create_params.rb +6 -19
- data/lib/openai/models/beta/beta_compacted_response.rb +3 -3
- data/lib/openai/models/beta/beta_response.rb +0 -18
- data/lib/openai/models/beta/beta_responses_client_event.rb +0 -26
- data/lib/openai/models/beta/response_compact_params.rb +0 -18
- data/lib/openai/models/beta/response_create_params.rb +0 -18
- data/lib/openai/models/chat/completion_create_params.rb +8 -6
- data/lib/openai/models/chat_model.rb +0 -12
- data/lib/openai/models/completion_create_params.rb +4 -2
- data/lib/openai/models/graders/multi_grader.rb +11 -15
- data/lib/openai/models/image_edit_completed_event.rb +9 -17
- data/lib/openai/models/image_edit_partial_image_event.rb +9 -17
- data/lib/openai/models/image_gen_completed_event.rb +9 -17
- data/lib/openai/models/image_gen_partial_image_event.rb +9 -17
- data/lib/openai/models/images_response.rb +8 -14
- data/lib/openai/models/live/responses_delegation_config.rb +47 -21
- data/lib/openai/models/live/responses_delegation_update_config.rb +47 -21
- data/lib/openai/models/responses/compacted_response.rb +3 -3
- data/lib/openai/models/responses/response_compact_params.rb +0 -18
- data/lib/openai/models.rb +0 -32
- data/lib/openai/providers/vertex.rb +9 -6
- data/lib/openai/resources/batches.rb +2 -6
- data/lib/openai/resources/beta.rb +0 -10
- data/lib/openai/resources/chat/completions.rb +8 -6
- data/lib/openai/resources/completions.rb +4 -2
- data/lib/openai/version.rb +1 -1
- data/lib/openai.rb +0 -114
- data/rbi/openai/client.rbi +0 -3
- data/rbi/openai/models/batch_create_params.rbi +6 -19
- data/rbi/openai/models/beta/beta_compacted_response.rbi +22 -20
- data/rbi/openai/models/beta/beta_response.rbi +0 -3
- data/rbi/openai/models/beta/beta_responses_client_event.rbi +0 -12
- data/rbi/openai/models/beta/response_compact_params.rbi +0 -9
- data/rbi/openai/models/beta/response_create_params.rbi +0 -6
- data/rbi/openai/models/chat/completion_create_params.rbi +8 -6
- data/rbi/openai/models/chat_model.rbi +0 -3
- data/rbi/openai/models/completion_create_params.rbi +4 -2
- data/rbi/openai/models/graders/multi_grader.rbi +32 -27
- data/rbi/openai/models/image_edit_completed_event.rbi +11 -8
- data/rbi/openai/models/image_edit_partial_image_event.rbi +11 -8
- data/rbi/openai/models/image_gen_completed_event.rbi +11 -8
- data/rbi/openai/models/image_gen_partial_image_event.rbi +11 -8
- data/rbi/openai/models/images_response.rbi +6 -6
- data/rbi/openai/models/live/responses_delegation_config.rbi +54 -30
- data/rbi/openai/models/live/responses_delegation_update_config.rbi +54 -30
- data/rbi/openai/models/responses/compacted_response.rbi +19 -17
- data/rbi/openai/models/responses/response_compact_params.rbi +0 -12
- data/rbi/openai/models.rbi +0 -32
- data/rbi/openai/resources/batches.rbi +2 -6
- data/rbi/openai/resources/beta.rbi +0 -8
- data/rbi/openai/resources/chat/completions.rbi +8 -6
- data/rbi/openai/resources/completions.rbi +4 -2
- data/sig/openai/client.rbs +0 -2
- data/sig/openai/models/batch_create_params.rbs +4 -14
- data/sig/openai/models/beta/beta_compacted_response.rbs +4 -4
- data/sig/openai/models/beta/beta_response.rbs +0 -6
- data/sig/openai/models/beta/beta_responses_client_event.rbs +0 -6
- data/sig/openai/models/beta/response_compact_params.rbs +0 -6
- data/sig/openai/models/beta/response_create_params.rbs +0 -6
- data/sig/openai/models/chat/completion_create_params.rbs +8 -6
- data/sig/openai/models/chat_model.rbs +0 -6
- data/sig/openai/models/completion_create_params.rbs +4 -2
- data/sig/openai/models/graders/multi_grader.rbs +7 -12
- data/sig/openai/models/image_edit_completed_event.rbs +11 -9
- data/sig/openai/models/image_edit_partial_image_event.rbs +11 -9
- data/sig/openai/models/image_gen_completed_event.rbs +11 -9
- data/sig/openai/models/image_gen_partial_image_event.rbs +11 -9
- data/sig/openai/models/images_response.rbs +5 -7
- data/sig/openai/models/live/responses_delegation_config.rbs +50 -18
- data/sig/openai/models/live/responses_delegation_update_config.rbs +50 -18
- data/sig/openai/models/responses/compacted_response.rbs +4 -4
- data/sig/openai/models/responses/response_compact_params.rbs +0 -6
- data/sig/openai/models.rbs +0 -32
- data/sig/openai/resources/beta.rbs +0 -4
- metadata +1 -343
- data/lib/openai/models/beta/assistant.rb +0 -270
- data/lib/openai/models/beta/assistant_create_params.rb +0 -448
- data/lib/openai/models/beta/assistant_delete_params.rb +0 -22
- data/lib/openai/models/beta/assistant_deleted.rb +0 -30
- data/lib/openai/models/beta/assistant_list_params.rb +0 -80
- data/lib/openai/models/beta/assistant_response_format_option.rb +0 -50
- data/lib/openai/models/beta/assistant_retrieve_params.rb +0 -22
- data/lib/openai/models/beta/assistant_stream_event.rb +0 -688
- data/lib/openai/models/beta/assistant_tool.rb +0 -22
- data/lib/openai/models/beta/assistant_tool_choice.rb +0 -43
- data/lib/openai/models/beta/assistant_tool_choice_function.rb +0 -19
- data/lib/openai/models/beta/assistant_tool_choice_option.rb +0 -42
- data/lib/openai/models/beta/assistant_update_params.rb +0 -450
- data/lib/openai/models/beta/code_interpreter_tool.rb +0 -19
- data/lib/openai/models/beta/file_search_tool.rb +0 -123
- data/lib/openai/models/beta/function_tool.rb +0 -26
- data/lib/openai/models/beta/message_stream_event.rb +0 -159
- data/lib/openai/models/beta/run_step_stream_event.rb +0 -201
- data/lib/openai/models/beta/run_stream_event.rb +0 -288
- data/lib/openai/models/beta/thread.rb +0 -133
- data/lib/openai/models/beta/thread_create_and_run_params.rb +0 -857
- data/lib/openai/models/beta/thread_create_params.rb +0 -443
- data/lib/openai/models/beta/thread_delete_params.rb +0 -22
- data/lib/openai/models/beta/thread_deleted.rb +0 -30
- data/lib/openai/models/beta/thread_retrieve_params.rb +0 -22
- data/lib/openai/models/beta/thread_stream_event.rb +0 -41
- data/lib/openai/models/beta/thread_update_params.rb +0 -114
- data/lib/openai/models/beta/threads/annotation.rb +0 -27
- data/lib/openai/models/beta/threads/annotation_delta.rb +0 -27
- data/lib/openai/models/beta/threads/file_citation_annotation.rb +0 -68
- data/lib/openai/models/beta/threads/file_citation_delta_annotation.rb +0 -86
- data/lib/openai/models/beta/threads/file_path_annotation.rb +0 -67
- data/lib/openai/models/beta/threads/file_path_delta_annotation.rb +0 -76
- data/lib/openai/models/beta/threads/image_file.rb +0 -51
- data/lib/openai/models/beta/threads/image_file_content_block.rb +0 -32
- data/lib/openai/models/beta/threads/image_file_delta.rb +0 -51
- data/lib/openai/models/beta/threads/image_file_delta_block.rb +0 -41
- data/lib/openai/models/beta/threads/image_url.rb +0 -49
- data/lib/openai/models/beta/threads/image_url_content_block.rb +0 -30
- data/lib/openai/models/beta/threads/image_url_delta.rb +0 -49
- data/lib/openai/models/beta/threads/image_url_delta_block.rb +0 -39
- data/lib/openai/models/beta/threads/message.rb +0 -272
- data/lib/openai/models/beta/threads/message_content.rb +0 -33
- data/lib/openai/models/beta/threads/message_content_delta.rb +0 -33
- data/lib/openai/models/beta/threads/message_content_part_param.rb +0 -30
- data/lib/openai/models/beta/threads/message_create_params.rb +0 -172
- data/lib/openai/models/beta/threads/message_delete_params.rb +0 -30
- data/lib/openai/models/beta/threads/message_deleted.rb +0 -32
- data/lib/openai/models/beta/threads/message_delta.rb +0 -48
- data/lib/openai/models/beta/threads/message_delta_event.rb +0 -42
- data/lib/openai/models/beta/threads/message_list_params.rb +0 -98
- data/lib/openai/models/beta/threads/message_retrieve_params.rb +0 -30
- data/lib/openai/models/beta/threads/message_update_params.rb +0 -51
- data/lib/openai/models/beta/threads/refusal_content_block.rb +0 -30
- data/lib/openai/models/beta/threads/refusal_delta_block.rb +0 -39
- data/lib/openai/models/beta/threads/required_action_function_tool_call.rb +0 -73
- data/lib/openai/models/beta/threads/run.rb +0 -557
- data/lib/openai/models/beta/threads/run_cancel_params.rb +0 -30
- data/lib/openai/models/beta/threads/run_create_params.rb +0 -565
- data/lib/openai/models/beta/threads/run_list_params.rb +0 -89
- data/lib/openai/models/beta/threads/run_retrieve_params.rb +0 -30
- data/lib/openai/models/beta/threads/run_status.rb +0 -29
- data/lib/openai/models/beta/threads/run_submit_tool_outputs_params.rb +0 -69
- data/lib/openai/models/beta/threads/run_update_params.rb +0 -51
- data/lib/openai/models/beta/threads/runs/code_interpreter_logs.rb +0 -43
- data/lib/openai/models/beta/threads/runs/code_interpreter_output_image.rb +0 -54
- data/lib/openai/models/beta/threads/runs/code_interpreter_tool_call.rb +0 -161
- data/lib/openai/models/beta/threads/runs/code_interpreter_tool_call_delta.rb +0 -107
- data/lib/openai/models/beta/threads/runs/file_search_tool_call.rb +0 -207
- data/lib/openai/models/beta/threads/runs/file_search_tool_call_delta.rb +0 -52
- data/lib/openai/models/beta/threads/runs/function_tool_call.rb +0 -78
- data/lib/openai/models/beta/threads/runs/function_tool_call_delta.rb +0 -87
- data/lib/openai/models/beta/threads/runs/message_creation_step_details.rb +0 -48
- data/lib/openai/models/beta/threads/runs/run_step.rb +0 -311
- data/lib/openai/models/beta/threads/runs/run_step_delta.rb +0 -45
- data/lib/openai/models/beta/threads/runs/run_step_delta_event.rb +0 -46
- data/lib/openai/models/beta/threads/runs/run_step_delta_message_delta.rb +0 -47
- data/lib/openai/models/beta/threads/runs/run_step_include.rb +0 -22
- data/lib/openai/models/beta/threads/runs/step_list_params.rb +0 -122
- data/lib/openai/models/beta/threads/runs/step_retrieve_params.rb +0 -65
- data/lib/openai/models/beta/threads/runs/tool_call.rb +0 -28
- data/lib/openai/models/beta/threads/runs/tool_call_delta.rb +0 -28
- data/lib/openai/models/beta/threads/runs/tool_call_delta_object.rb +0 -41
- data/lib/openai/models/beta/threads/runs/tool_calls_step_details.rb +0 -38
- data/lib/openai/models/beta/threads/text.rb +0 -28
- data/lib/openai/models/beta/threads/text_content_block.rb +0 -30
- data/lib/openai/models/beta/threads/text_content_block_param.rb +0 -32
- data/lib/openai/models/beta/threads/text_delta.rb +0 -31
- data/lib/openai/models/beta/threads/text_delta_block.rb +0 -39
- data/lib/openai/models/image_input_reference_param.rb +0 -24
- data/lib/openai/models/video.rb +0 -161
- data/lib/openai/models/video_create_character_params.rb +0 -40
- data/lib/openai/models/video_create_character_response.rb +0 -36
- data/lib/openai/models/video_create_error.rb +0 -166
- data/lib/openai/models/video_create_params.rb +0 -85
- data/lib/openai/models/video_delete_params.rb +0 -20
- data/lib/openai/models/video_delete_response.rb +0 -38
- data/lib/openai/models/video_download_content_params.rb +0 -42
- data/lib/openai/models/video_edit_params.rb +0 -68
- data/lib/openai/models/video_extend_params.rb +0 -79
- data/lib/openai/models/video_get_character_params.rb +0 -20
- data/lib/openai/models/video_get_character_response.rb +0 -36
- data/lib/openai/models/video_list_params.rb +0 -55
- data/lib/openai/models/video_model.rb +0 -38
- data/lib/openai/models/video_remix_params.rb +0 -30
- data/lib/openai/models/video_retrieve_params.rb +0 -20
- data/lib/openai/models/video_seconds.rb +0 -16
- data/lib/openai/models/video_size.rb +0 -17
- data/lib/openai/resources/beta/assistants.rb +0 -320
- data/lib/openai/resources/beta/threads/messages.rb +0 -236
- data/lib/openai/resources/beta/threads/runs/steps.rb +0 -141
- data/lib/openai/resources/beta/threads/runs.rb +0 -623
- data/lib/openai/resources/beta/threads.rb +0 -444
- data/lib/openai/resources/videos.rb +0 -354
- data/rbi/openai/models/beta/assistant.rbi +0 -411
- data/rbi/openai/models/beta/assistant_create_params.rbi +0 -776
- data/rbi/openai/models/beta/assistant_delete_params.rbi +0 -53
- data/rbi/openai/models/beta/assistant_deleted.rbi +0 -60
- data/rbi/openai/models/beta/assistant_list_params.rbi +0 -132
- data/rbi/openai/models/beta/assistant_response_format_option.rbi +0 -49
- data/rbi/openai/models/beta/assistant_retrieve_params.rbi +0 -53
- data/rbi/openai/models/beta/assistant_stream_event.rbi +0 -1277
- data/rbi/openai/models/beta/assistant_tool.rbi +0 -28
- data/rbi/openai/models/beta/assistant_tool_choice.rbi +0 -79
- data/rbi/openai/models/beta/assistant_tool_choice_function.rbi +0 -49
- data/rbi/openai/models/beta/assistant_tool_choice_option.rbi +0 -53
- data/rbi/openai/models/beta/assistant_update_params.rbi +0 -556
- data/rbi/openai/models/beta/code_interpreter_tool.rbi +0 -49
- data/rbi/openai/models/beta/file_search_tool.rbi +0 -223
- data/rbi/openai/models/beta/function_tool.rbi +0 -59
- data/rbi/openai/models/beta/message_stream_event.rbi +0 -288
- data/rbi/openai/models/beta/run_step_stream_event.rbi +0 -378
- data/rbi/openai/models/beta/run_stream_event.rbi +0 -537
- data/rbi/openai/models/beta/thread.rbi +0 -255
- data/rbi/openai/models/beta/thread_create_and_run_params.rbi +0 -1461
- data/rbi/openai/models/beta/thread_create_params.rbi +0 -823
- data/rbi/openai/models/beta/thread_delete_params.rbi +0 -53
- data/rbi/openai/models/beta/thread_deleted.rbi +0 -60
- data/rbi/openai/models/beta/thread_retrieve_params.rbi +0 -53
- data/rbi/openai/models/beta/thread_stream_event.rbi +0 -75
- data/rbi/openai/models/beta/thread_update_params.rbi +0 -240
- data/rbi/openai/models/beta/threads/annotation.rbi +0 -34
- data/rbi/openai/models/beta/threads/annotation_delta.rbi +0 -34
- data/rbi/openai/models/beta/threads/file_citation_annotation.rbi +0 -132
- data/rbi/openai/models/beta/threads/file_citation_delta_annotation.rbi +0 -166
- data/rbi/openai/models/beta/threads/file_path_annotation.rbi +0 -131
- data/rbi/openai/models/beta/threads/file_path_delta_annotation.rbi +0 -153
- data/rbi/openai/models/beta/threads/image_file.rbi +0 -88
- data/rbi/openai/models/beta/threads/image_file_content_block.rbi +0 -66
- data/rbi/openai/models/beta/threads/image_file_delta.rbi +0 -91
- data/rbi/openai/models/beta/threads/image_file_delta_block.rbi +0 -75
- data/rbi/openai/models/beta/threads/image_url.rbi +0 -86
- data/rbi/openai/models/beta/threads/image_url_content_block.rbi +0 -64
- data/rbi/openai/models/beta/threads/image_url_delta.rbi +0 -89
- data/rbi/openai/models/beta/threads/image_url_delta_block.rbi +0 -73
- data/rbi/openai/models/beta/threads/message.rbi +0 -433
- data/rbi/openai/models/beta/threads/message_content.rbi +0 -36
- data/rbi/openai/models/beta/threads/message_content_delta.rbi +0 -36
- data/rbi/openai/models/beta/threads/message_content_part_param.rbi +0 -35
- data/rbi/openai/models/beta/threads/message_create_params.rbi +0 -299
- data/rbi/openai/models/beta/threads/message_delete_params.rbi +0 -64
- data/rbi/openai/models/beta/threads/message_deleted.rbi +0 -64
- data/rbi/openai/models/beta/threads/message_delta.rbi +0 -106
- data/rbi/openai/models/beta/threads/message_delta_event.rbi +0 -76
- data/rbi/openai/models/beta/threads/message_list_params.rbi +0 -157
- data/rbi/openai/models/beta/threads/message_retrieve_params.rbi +0 -64
- data/rbi/openai/models/beta/threads/message_update_params.rbi +0 -88
- data/rbi/openai/models/beta/threads/refusal_content_block.rbi +0 -61
- data/rbi/openai/models/beta/threads/refusal_delta_block.rbi +0 -73
- data/rbi/openai/models/beta/threads/required_action_function_tool_call.rbi +0 -130
- data/rbi/openai/models/beta/threads/run.rbi +0 -803
- data/rbi/openai/models/beta/threads/run_cancel_params.rbi +0 -64
- data/rbi/openai/models/beta/threads/run_create_params.rbi +0 -825
- data/rbi/openai/models/beta/threads/run_list_params.rbi +0 -144
- data/rbi/openai/models/beta/threads/run_retrieve_params.rbi +0 -64
- data/rbi/openai/models/beta/threads/run_status.rbi +0 -39
- data/rbi/openai/models/beta/threads/run_submit_tool_outputs_params.rbi +0 -132
- data/rbi/openai/models/beta/threads/run_update_params.rbi +0 -88
- data/rbi/openai/models/beta/threads/runs/code_interpreter_logs.rbi +0 -79
- data/rbi/openai/models/beta/threads/runs/code_interpreter_output_image.rbi +0 -118
- data/rbi/openai/models/beta/threads/runs/code_interpreter_tool_call.rbi +0 -315
- data/rbi/openai/models/beta/threads/runs/code_interpreter_tool_call_delta.rbi +0 -210
- data/rbi/openai/models/beta/threads/runs/file_search_tool_call.rbi +0 -409
- data/rbi/openai/models/beta/threads/runs/file_search_tool_call_delta.rbi +0 -89
- data/rbi/openai/models/beta/threads/runs/function_tool_call.rbi +0 -138
- data/rbi/openai/models/beta/threads/runs/function_tool_call_delta.rbi +0 -161
- data/rbi/openai/models/beta/threads/runs/message_creation_step_details.rbi +0 -111
- data/rbi/openai/models/beta/threads/runs/run_step.rbi +0 -422
- data/rbi/openai/models/beta/threads/runs/run_step_delta.rbi +0 -91
- data/rbi/openai/models/beta/threads/runs/run_step_delta_event.rbi +0 -82
- data/rbi/openai/models/beta/threads/runs/run_step_delta_message_delta.rbi +0 -113
- data/rbi/openai/models/beta/threads/runs/run_step_include.rbi +0 -37
- data/rbi/openai/models/beta/threads/runs/step_list_params.rbi +0 -181
- data/rbi/openai/models/beta/threads/runs/step_retrieve_params.rbi +0 -105
- data/rbi/openai/models/beta/threads/runs/tool_call.rbi +0 -37
- data/rbi/openai/models/beta/threads/runs/tool_call_delta.rbi +0 -37
- data/rbi/openai/models/beta/threads/runs/tool_call_delta_object.rbi +0 -91
- data/rbi/openai/models/beta/threads/runs/tool_calls_step_details.rbi +0 -77
- data/rbi/openai/models/beta/threads/text.rbi +0 -65
- data/rbi/openai/models/beta/threads/text_content_block.rbi +0 -64
- data/rbi/openai/models/beta/threads/text_content_block_param.rbi +0 -63
- data/rbi/openai/models/beta/threads/text_delta.rbi +0 -81
- data/rbi/openai/models/beta/threads/text_delta_block.rbi +0 -73
- data/rbi/openai/models/image_input_reference_param.rbi +0 -58
- data/rbi/openai/models/video.rbi +0 -203
- data/rbi/openai/models/video_create_character_params.rbi +0 -68
- data/rbi/openai/models/video_create_character_response.rbi +0 -63
- data/rbi/openai/models/video_create_error.rbi +0 -255
- data/rbi/openai/models/video_create_params.rbi +0 -132
- data/rbi/openai/models/video_delete_params.rbi +0 -49
- data/rbi/openai/models/video_delete_response.rbi +0 -64
- data/rbi/openai/models/video_download_content_params.rbi +0 -81
- data/rbi/openai/models/video_edit_params.rbi +0 -122
- data/rbi/openai/models/video_extend_params.rbi +0 -134
- data/rbi/openai/models/video_get_character_params.rbi +0 -49
- data/rbi/openai/models/video_get_character_response.rbi +0 -63
- data/rbi/openai/models/video_list_params.rbi +0 -101
- data/rbi/openai/models/video_model.rbi +0 -35
- data/rbi/openai/models/video_remix_params.rbi +0 -58
- data/rbi/openai/models/video_retrieve_params.rbi +0 -49
- data/rbi/openai/models/video_seconds.rbi +0 -22
- data/rbi/openai/models/video_size.rbi +0 -23
- data/rbi/openai/resources/beta/assistants.rbi +0 -285
- data/rbi/openai/resources/beta/threads/messages.rbi +0 -161
- data/rbi/openai/resources/beta/threads/runs/steps.rbi +0 -107
- data/rbi/openai/resources/beta/threads/runs.rbi +0 -527
- data/rbi/openai/resources/beta/threads.rbi +0 -391
- data/rbi/openai/resources/videos.rbi +0 -205
- data/sig/openai/models/beta/assistant.rbs +0 -278
- data/sig/openai/models/beta/assistant_create_params.rbs +0 -485
- data/sig/openai/models/beta/assistant_delete_params.rbs +0 -25
- data/sig/openai/models/beta/assistant_deleted.rbs +0 -28
- data/sig/openai/models/beta/assistant_list_params.rbs +0 -104
- data/sig/openai/models/beta/assistant_response_format_option.rbs +0 -17
- data/sig/openai/models/beta/assistant_retrieve_params.rbs +0 -25
- data/sig/openai/models/beta/assistant_stream_event.rbs +0 -645
- data/sig/openai/models/beta/assistant_tool.rbs +0 -16
- data/sig/openai/models/beta/assistant_tool_choice.rbs +0 -46
- data/sig/openai/models/beta/assistant_tool_choice_function.rbs +0 -18
- data/sig/openai/models/beta/assistant_tool_choice_option.rbs +0 -27
- data/sig/openai/models/beta/assistant_update_params.rbs +0 -396
- data/sig/openai/models/beta/code_interpreter_tool.rbs +0 -18
- data/sig/openai/models/beta/file_search_tool.rbs +0 -159
- data/sig/openai/models/beta/function_tool.rbs +0 -27
- data/sig/openai/models/beta/message_stream_event.rbs +0 -153
- data/sig/openai/models/beta/run_step_stream_event.rbs +0 -197
- data/sig/openai/models/beta/run_stream_event.rbs +0 -269
- data/sig/openai/models/beta/thread.rbs +0 -150
- data/sig/openai/models/beta/thread_create_and_run_params.rbs +0 -885
- data/sig/openai/models/beta/thread_create_params.rbs +0 -492
- data/sig/openai/models/beta/thread_delete_params.rbs +0 -25
- data/sig/openai/models/beta/thread_deleted.rbs +0 -28
- data/sig/openai/models/beta/thread_retrieve_params.rbs +0 -25
- data/sig/openai/models/beta/thread_stream_event.rbs +0 -43
- data/sig/openai/models/beta/thread_update_params.rbs +0 -137
- data/sig/openai/models/beta/threads/annotation.rbs +0 -17
- data/sig/openai/models/beta/threads/annotation_delta.rbs +0 -17
- data/sig/openai/models/beta/threads/file_citation_annotation.rbs +0 -63
- data/sig/openai/models/beta/threads/file_citation_delta_annotation.rbs +0 -93
- data/sig/openai/models/beta/threads/file_path_annotation.rbs +0 -63
- data/sig/openai/models/beta/threads/file_path_delta_annotation.rbs +0 -85
- data/sig/openai/models/beta/threads/image_file.rbs +0 -59
- data/sig/openai/models/beta/threads/image_file_content_block.rbs +0 -29
- data/sig/openai/models/beta/threads/image_file_delta.rbs +0 -64
- data/sig/openai/models/beta/threads/image_file_delta_block.rbs +0 -44
- data/sig/openai/models/beta/threads/image_url.rbs +0 -57
- data/sig/openai/models/beta/threads/image_url_content_block.rbs +0 -29
- data/sig/openai/models/beta/threads/image_url_delta.rbs +0 -61
- data/sig/openai/models/beta/threads/image_url_delta_block.rbs +0 -44
- data/sig/openai/models/beta/threads/message.rbs +0 -275
- data/sig/openai/models/beta/threads/message_content.rbs +0 -19
- data/sig/openai/models/beta/threads/message_content_delta.rbs +0 -19
- data/sig/openai/models/beta/threads/message_content_part_param.rbs +0 -18
- data/sig/openai/models/beta/threads/message_create_params.rbs +0 -167
- data/sig/openai/models/beta/threads/message_delete_params.rbs +0 -35
- data/sig/openai/models/beta/threads/message_deleted.rbs +0 -30
- data/sig/openai/models/beta/threads/message_delta.rbs +0 -56
- data/sig/openai/models/beta/threads/message_delta_event.rbs +0 -43
- data/sig/openai/models/beta/threads/message_list_params.rbs +0 -122
- data/sig/openai/models/beta/threads/message_retrieve_params.rbs +0 -35
- data/sig/openai/models/beta/threads/message_update_params.rbs +0 -53
- data/sig/openai/models/beta/threads/refusal_content_block.rbs +0 -22
- data/sig/openai/models/beta/threads/refusal_delta_block.rbs +0 -34
- data/sig/openai/models/beta/threads/required_action_function_tool_call.rbs +0 -69
- data/sig/openai/models/beta/threads/run.rbs +0 -545
- data/sig/openai/models/beta/threads/run_cancel_params.rbs +0 -35
- data/sig/openai/models/beta/threads/run_create_params.rbs +0 -524
- data/sig/openai/models/beta/threads/run_list_params.rbs +0 -111
- data/sig/openai/models/beta/threads/run_retrieve_params.rbs +0 -35
- data/sig/openai/models/beta/threads/run_status.rbs +0 -34
- data/sig/openai/models/beta/threads/run_submit_tool_outputs_params.rbs +0 -70
- data/sig/openai/models/beta/threads/run_update_params.rbs +0 -53
- data/sig/openai/models/beta/threads/runs/code_interpreter_logs.rbs +0 -40
- data/sig/openai/models/beta/threads/runs/code_interpreter_output_image.rbs +0 -65
- data/sig/openai/models/beta/threads/runs/code_interpreter_tool_call.rbs +0 -147
- data/sig/openai/models/beta/threads/runs/code_interpreter_tool_call_delta.rbs +0 -115
- data/sig/openai/models/beta/threads/runs/file_search_tool_call.rbs +0 -228
- data/sig/openai/models/beta/threads/runs/file_search_tool_call_delta.rbs +0 -58
- data/sig/openai/models/beta/threads/runs/function_tool_call.rbs +0 -80
- data/sig/openai/models/beta/threads/runs/function_tool_call_delta.rbs +0 -103
- data/sig/openai/models/beta/threads/runs/message_creation_step_details.rbs +0 -47
- data/sig/openai/models/beta/threads/runs/run_step.rbs +0 -290
- data/sig/openai/models/beta/threads/runs/run_step_delta.rbs +0 -46
- data/sig/openai/models/beta/threads/runs/run_step_delta_event.rbs +0 -47
- data/sig/openai/models/beta/threads/runs/run_step_delta_message_delta.rbs +0 -56
- data/sig/openai/models/beta/threads/runs/run_step_include.rbs +0 -22
- data/sig/openai/models/beta/threads/runs/step_list_params.rbs +0 -149
- data/sig/openai/models/beta/threads/runs/step_retrieve_params.rbs +0 -73
- data/sig/openai/models/beta/threads/runs/tool_call.rbs +0 -20
- data/sig/openai/models/beta/threads/runs/tool_call_delta.rbs +0 -20
- data/sig/openai/models/beta/threads/runs/tool_call_delta_object.rbs +0 -48
- data/sig/openai/models/beta/threads/runs/tool_calls_step_details.rbs +0 -41
- data/sig/openai/models/beta/threads/text.rbs +0 -32
- data/sig/openai/models/beta/threads/text_content_block.rbs +0 -26
- data/sig/openai/models/beta/threads/text_content_block_param.rbs +0 -25
- data/sig/openai/models/beta/threads/text_delta.rbs +0 -39
- data/sig/openai/models/beta/threads/text_delta_block.rbs +0 -44
- data/sig/openai/models/image_input_reference_param.rbs +0 -23
- data/sig/openai/models/video.rbs +0 -142
- data/sig/openai/models/video_create_character_params.rbs +0 -45
- data/sig/openai/models/video_create_character_response.rbs +0 -27
- data/sig/openai/models/video_create_error.rbs +0 -163
- data/sig/openai/models/video_create_params.rbs +0 -104
- data/sig/openai/models/video_delete_params.rbs +0 -23
- data/sig/openai/models/video_delete_response.rbs +0 -31
- data/sig/openai/models/video_download_content_params.rbs +0 -51
- data/sig/openai/models/video_edit_params.rbs +0 -77
- data/sig/openai/models/video_extend_params.rbs +0 -87
- data/sig/openai/models/video_get_character_params.rbs +0 -23
- data/sig/openai/models/video_get_character_response.rbs +0 -27
- data/sig/openai/models/video_list_params.rbs +0 -70
- data/sig/openai/models/video_model.rbs +0 -23
- data/sig/openai/models/video_remix_params.rbs +0 -34
- data/sig/openai/models/video_retrieve_params.rbs +0 -23
- data/sig/openai/models/video_seconds.rbs +0 -15
- data/sig/openai/models/video_size.rbs +0 -16
- data/sig/openai/resources/beta/assistants.rbs +0 -58
- data/sig/openai/resources/beta/threads/messages.rbs +0 -49
- data/sig/openai/resources/beta/threads/runs/steps.rbs +0 -32
- data/sig/openai/resources/beta/threads/runs.rbs +0 -99
- data/sig/openai/resources/beta/threads.rbs +0 -75
- data/sig/openai/resources/videos.rbs +0 -69
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
# frozen_string_literal: true
|
|
2
|
-
|
|
3
|
-
module OpenAI
|
|
4
|
-
module Models
|
|
5
|
-
module Beta
|
|
6
|
-
module Threads
|
|
7
|
-
class ImageURLDeltaBlock < OpenAI::Internal::Type::BaseModel
|
|
8
|
-
# @!attribute index
|
|
9
|
-
# The index of the content part in the message.
|
|
10
|
-
#
|
|
11
|
-
# @return [Integer]
|
|
12
|
-
required :index, Integer
|
|
13
|
-
|
|
14
|
-
# @!attribute type
|
|
15
|
-
# Always `image_url`.
|
|
16
|
-
#
|
|
17
|
-
# @return [Symbol, :image_url]
|
|
18
|
-
required :type, const: :image_url
|
|
19
|
-
|
|
20
|
-
# @!attribute image_url
|
|
21
|
-
#
|
|
22
|
-
# @return [OpenAI::Models::Beta::Threads::ImageURLDelta, nil]
|
|
23
|
-
optional :image_url, -> { OpenAI::Beta::Threads::ImageURLDelta }
|
|
24
|
-
|
|
25
|
-
# @!method initialize(index:, image_url: nil, type: :image_url)
|
|
26
|
-
# References an image URL in the content of a message.
|
|
27
|
-
#
|
|
28
|
-
# @param index [Integer]
|
|
29
|
-
# The index of the content part in the message.
|
|
30
|
-
#
|
|
31
|
-
# @param image_url [OpenAI::Models::Beta::Threads::ImageURLDelta]
|
|
32
|
-
#
|
|
33
|
-
# @param type [Symbol, :image_url]
|
|
34
|
-
# Always `image_url`.
|
|
35
|
-
end
|
|
36
|
-
end
|
|
37
|
-
end
|
|
38
|
-
end
|
|
39
|
-
end
|
|
@@ -1,272 +0,0 @@
|
|
|
1
|
-
# frozen_string_literal: true
|
|
2
|
-
|
|
3
|
-
module OpenAI
|
|
4
|
-
module Models
|
|
5
|
-
module Beta
|
|
6
|
-
module Threads
|
|
7
|
-
# @see OpenAI::Resources::Beta::Threads::Messages#create
|
|
8
|
-
class Message < OpenAI::Internal::Type::BaseModel
|
|
9
|
-
# @!attribute id
|
|
10
|
-
# The identifier, which can be referenced in API endpoints.
|
|
11
|
-
#
|
|
12
|
-
# @return [String]
|
|
13
|
-
required :id, String
|
|
14
|
-
|
|
15
|
-
# @!attribute assistant_id
|
|
16
|
-
# If applicable, the ID of the
|
|
17
|
-
# [assistant](https://developers.openai.com/api/docs/assistants/migration) that
|
|
18
|
-
# authored this message.
|
|
19
|
-
#
|
|
20
|
-
# @return [String, nil]
|
|
21
|
-
required :assistant_id, String, nil?: true
|
|
22
|
-
|
|
23
|
-
# @!attribute attachments
|
|
24
|
-
# A list of files attached to the message, and the tools they were added to.
|
|
25
|
-
#
|
|
26
|
-
# @return [Array<OpenAI::Models::Beta::Threads::Message::Attachment>, nil]
|
|
27
|
-
required(
|
|
28
|
-
:attachments,
|
|
29
|
-
-> { OpenAI::Internal::Type::ArrayOf[OpenAI::Beta::Threads::Message::Attachment] },
|
|
30
|
-
nil?: true
|
|
31
|
-
)
|
|
32
|
-
|
|
33
|
-
# @!attribute completed_at
|
|
34
|
-
# The Unix timestamp (in seconds) for when the message was completed.
|
|
35
|
-
#
|
|
36
|
-
# @return [Integer, nil]
|
|
37
|
-
required :completed_at, Integer, nil?: true
|
|
38
|
-
|
|
39
|
-
# @!attribute content
|
|
40
|
-
# The content of the message in array of text and/or images.
|
|
41
|
-
#
|
|
42
|
-
# @return [Array<OpenAI::Models::Beta::Threads::ImageFileContentBlock, OpenAI::Models::Beta::Threads::ImageURLContentBlock, OpenAI::Models::Beta::Threads::TextContentBlock, OpenAI::Models::Beta::Threads::RefusalContentBlock>]
|
|
43
|
-
required :content, -> { OpenAI::Internal::Type::ArrayOf[union: OpenAI::Beta::Threads::MessageContent] }
|
|
44
|
-
|
|
45
|
-
# @!attribute created_at
|
|
46
|
-
# The Unix timestamp (in seconds) for when the message was created.
|
|
47
|
-
#
|
|
48
|
-
# @return [Integer]
|
|
49
|
-
required :created_at, Integer
|
|
50
|
-
|
|
51
|
-
# @!attribute incomplete_at
|
|
52
|
-
# The Unix timestamp (in seconds) for when the message was marked as incomplete.
|
|
53
|
-
#
|
|
54
|
-
# @return [Integer, nil]
|
|
55
|
-
required :incomplete_at, Integer, nil?: true
|
|
56
|
-
|
|
57
|
-
# @!attribute incomplete_details
|
|
58
|
-
# On an incomplete message, details about why the message is incomplete.
|
|
59
|
-
#
|
|
60
|
-
# @return [OpenAI::Models::Beta::Threads::Message::IncompleteDetails, nil]
|
|
61
|
-
required :incomplete_details, -> { OpenAI::Beta::Threads::Message::IncompleteDetails }, nil?: true
|
|
62
|
-
|
|
63
|
-
# @!attribute metadata
|
|
64
|
-
# Set of 16 key-value pairs that can be attached to an object. This can be useful
|
|
65
|
-
# for storing additional information about the object in a structured format, and
|
|
66
|
-
# querying for objects via API or the dashboard.
|
|
67
|
-
#
|
|
68
|
-
# Keys are strings with a maximum length of 64 characters. Values are strings with
|
|
69
|
-
# a maximum length of 512 characters.
|
|
70
|
-
#
|
|
71
|
-
# @return [Hash{Symbol=>String}, nil]
|
|
72
|
-
required :metadata, OpenAI::Internal::Type::HashOf[String], nil?: true
|
|
73
|
-
|
|
74
|
-
# @!attribute object
|
|
75
|
-
# The object type, which is always `thread.message`.
|
|
76
|
-
#
|
|
77
|
-
# @return [Symbol, :"thread.message"]
|
|
78
|
-
required :object, const: :"thread.message"
|
|
79
|
-
|
|
80
|
-
# @!attribute role
|
|
81
|
-
# The entity that produced the message. One of `user` or `assistant`.
|
|
82
|
-
#
|
|
83
|
-
# @return [Symbol, OpenAI::Models::Beta::Threads::Message::Role]
|
|
84
|
-
required :role, enum: -> { OpenAI::Beta::Threads::Message::Role }
|
|
85
|
-
|
|
86
|
-
# @!attribute run_id
|
|
87
|
-
# The ID of the [run](https://developers.openai.com/api/docs/assistants/migration)
|
|
88
|
-
# associated with the creation of this message. Value is `null` when messages are
|
|
89
|
-
# created manually using the create message or create thread endpoints.
|
|
90
|
-
#
|
|
91
|
-
# @return [String, nil]
|
|
92
|
-
required :run_id, String, nil?: true
|
|
93
|
-
|
|
94
|
-
# @!attribute status
|
|
95
|
-
# The status of the message, which can be either `in_progress`, `incomplete`, or
|
|
96
|
-
# `completed`.
|
|
97
|
-
#
|
|
98
|
-
# @return [Symbol, OpenAI::Models::Beta::Threads::Message::Status]
|
|
99
|
-
required :status, enum: -> { OpenAI::Beta::Threads::Message::Status }
|
|
100
|
-
|
|
101
|
-
# @!attribute thread_id
|
|
102
|
-
# The [thread](https://developers.openai.com/api/docs/assistants/migration) ID
|
|
103
|
-
# that this message belongs to.
|
|
104
|
-
#
|
|
105
|
-
# @return [String]
|
|
106
|
-
required :thread_id, String
|
|
107
|
-
|
|
108
|
-
# @!method initialize(id:, assistant_id:, attachments:, completed_at:, content:, created_at:, incomplete_at:, incomplete_details:, metadata:, role:, run_id:, status:, thread_id:, object: :"thread.message")
|
|
109
|
-
# Represents a message within a
|
|
110
|
-
# [thread](https://developers.openai.com/api/docs/assistants/migration).
|
|
111
|
-
#
|
|
112
|
-
# @param id [String]
|
|
113
|
-
# The identifier, which can be referenced in API endpoints.
|
|
114
|
-
#
|
|
115
|
-
# @param assistant_id [String, nil]
|
|
116
|
-
# If applicable, the ID of the
|
|
117
|
-
# [assistant](https://developers.openai.com/api/docs/assistants/migration) that
|
|
118
|
-
# authored this message.
|
|
119
|
-
#
|
|
120
|
-
# @param attachments [Array<OpenAI::Models::Beta::Threads::Message::Attachment>, nil]
|
|
121
|
-
# A list of files attached to the message, and the tools they were added to.
|
|
122
|
-
#
|
|
123
|
-
# @param completed_at [Integer, nil]
|
|
124
|
-
# The Unix timestamp (in seconds) for when the message was completed.
|
|
125
|
-
#
|
|
126
|
-
# @param content [Array<OpenAI::Models::Beta::Threads::ImageFileContentBlock, OpenAI::Models::Beta::Threads::ImageURLContentBlock, OpenAI::Models::Beta::Threads::TextContentBlock, OpenAI::Models::Beta::Threads::RefusalContentBlock>]
|
|
127
|
-
# The content of the message in array of text and/or images.
|
|
128
|
-
#
|
|
129
|
-
# @param created_at [Integer]
|
|
130
|
-
# The Unix timestamp (in seconds) for when the message was created.
|
|
131
|
-
#
|
|
132
|
-
# @param incomplete_at [Integer, nil]
|
|
133
|
-
# The Unix timestamp (in seconds) for when the message was marked as incomplete.
|
|
134
|
-
#
|
|
135
|
-
# @param incomplete_details [OpenAI::Models::Beta::Threads::Message::IncompleteDetails, nil]
|
|
136
|
-
# On an incomplete message, details about why the message is incomplete.
|
|
137
|
-
#
|
|
138
|
-
# @param metadata [Hash{Symbol=>String}, nil]
|
|
139
|
-
# Set of 16 key-value pairs that can be attached to an object. This can be useful
|
|
140
|
-
# for storing additional information about the object in a structured format, and
|
|
141
|
-
# querying for objects via API or the dashboard.
|
|
142
|
-
#
|
|
143
|
-
# Keys are strings with a maximum length of 64 characters. Values are strings with
|
|
144
|
-
# a maximum length of 512 characters.
|
|
145
|
-
#
|
|
146
|
-
# @param role [Symbol, OpenAI::Models::Beta::Threads::Message::Role]
|
|
147
|
-
# The entity that produced the message. One of `user` or `assistant`.
|
|
148
|
-
#
|
|
149
|
-
# @param run_id [String, nil]
|
|
150
|
-
# The ID of the [run](https://developers.openai.com/api/docs/assistants/migration)
|
|
151
|
-
# associated with the creation of this message. Value is `null` when messages are
|
|
152
|
-
# created manually using the create message or create thread endpoints.
|
|
153
|
-
#
|
|
154
|
-
# @param status [Symbol, OpenAI::Models::Beta::Threads::Message::Status]
|
|
155
|
-
# The status of the message, which can be either `in_progress`, `incomplete`, or
|
|
156
|
-
# `completed`.
|
|
157
|
-
#
|
|
158
|
-
# @param thread_id [String]
|
|
159
|
-
# The [thread](https://developers.openai.com/api/docs/assistants/migration) ID
|
|
160
|
-
# that this message belongs to.
|
|
161
|
-
#
|
|
162
|
-
# @param object [Symbol, :"thread.message"]
|
|
163
|
-
# The object type, which is always `thread.message`.
|
|
164
|
-
class Attachment < OpenAI::Internal::Type::BaseModel
|
|
165
|
-
# @!attribute file_id
|
|
166
|
-
# The ID of the file to attach to the message.
|
|
167
|
-
#
|
|
168
|
-
# @return [String, nil]
|
|
169
|
-
optional :file_id, String
|
|
170
|
-
|
|
171
|
-
# @!attribute tools
|
|
172
|
-
# The tools to add this file to.
|
|
173
|
-
#
|
|
174
|
-
# @return [Array<OpenAI::Models::Beta::CodeInterpreterTool, OpenAI::Models::Beta::Threads::Message::Attachment::Tool::AssistantToolsFileSearchTypeOnly>, nil]
|
|
175
|
-
optional(
|
|
176
|
-
:tools,
|
|
177
|
-
-> { OpenAI::Internal::Type::ArrayOf[union: OpenAI::Beta::Threads::Message::Attachment::Tool] }
|
|
178
|
-
)
|
|
179
|
-
|
|
180
|
-
# @!method initialize(file_id: nil, tools: nil)
|
|
181
|
-
# @param file_id [String]
|
|
182
|
-
# The ID of the file to attach to the message.
|
|
183
|
-
#
|
|
184
|
-
# @param tools [Array<OpenAI::Models::Beta::CodeInterpreterTool, OpenAI::Models::Beta::Threads::Message::Attachment::Tool::AssistantToolsFileSearchTypeOnly>]
|
|
185
|
-
# The tools to add this file to.
|
|
186
|
-
module Tool
|
|
187
|
-
extend OpenAI::Internal::Type::Union
|
|
188
|
-
|
|
189
|
-
variant -> { OpenAI::Beta::CodeInterpreterTool }
|
|
190
|
-
|
|
191
|
-
variant -> { OpenAI::Beta::Threads::Message::Attachment::Tool::AssistantToolsFileSearchTypeOnly }
|
|
192
|
-
|
|
193
|
-
class AssistantToolsFileSearchTypeOnly < OpenAI::Internal::Type::BaseModel
|
|
194
|
-
# @!attribute type
|
|
195
|
-
# The type of tool being defined: `file_search`
|
|
196
|
-
#
|
|
197
|
-
# @return [Symbol, :file_search]
|
|
198
|
-
required :type, const: :file_search
|
|
199
|
-
|
|
200
|
-
# @!method initialize(type: :file_search)
|
|
201
|
-
# @param type [Symbol, :file_search]
|
|
202
|
-
# The type of tool being defined: `file_search`
|
|
203
|
-
end
|
|
204
|
-
|
|
205
|
-
# @!method self.variants
|
|
206
|
-
# @return [Array(OpenAI::Models::Beta::CodeInterpreterTool, OpenAI::Models::Beta::Threads::Message::Attachment::Tool::AssistantToolsFileSearchTypeOnly)]
|
|
207
|
-
end
|
|
208
|
-
end
|
|
209
|
-
|
|
210
|
-
# @see OpenAI::Models::Beta::Threads::Message#incomplete_details
|
|
211
|
-
class IncompleteDetails < OpenAI::Internal::Type::BaseModel
|
|
212
|
-
# @!attribute reason
|
|
213
|
-
# The reason the message is incomplete.
|
|
214
|
-
#
|
|
215
|
-
# @return [Symbol, OpenAI::Models::Beta::Threads::Message::IncompleteDetails::Reason]
|
|
216
|
-
required :reason, enum: -> { OpenAI::Beta::Threads::Message::IncompleteDetails::Reason }
|
|
217
|
-
|
|
218
|
-
# @!method initialize(reason:)
|
|
219
|
-
# On an incomplete message, details about why the message is incomplete.
|
|
220
|
-
#
|
|
221
|
-
# @param reason [Symbol, OpenAI::Models::Beta::Threads::Message::IncompleteDetails::Reason]
|
|
222
|
-
# The reason the message is incomplete.
|
|
223
|
-
|
|
224
|
-
# The reason the message is incomplete.
|
|
225
|
-
#
|
|
226
|
-
# @see OpenAI::Models::Beta::Threads::Message::IncompleteDetails#reason
|
|
227
|
-
module Reason
|
|
228
|
-
extend OpenAI::Internal::Type::Enum
|
|
229
|
-
|
|
230
|
-
CONTENT_FILTER = :content_filter
|
|
231
|
-
MAX_TOKENS = :max_tokens
|
|
232
|
-
RUN_CANCELLED = :run_cancelled
|
|
233
|
-
RUN_EXPIRED = :run_expired
|
|
234
|
-
RUN_FAILED = :run_failed
|
|
235
|
-
|
|
236
|
-
# @!method self.values
|
|
237
|
-
# @return [Array<Symbol>]
|
|
238
|
-
end
|
|
239
|
-
end
|
|
240
|
-
|
|
241
|
-
# The entity that produced the message. One of `user` or `assistant`.
|
|
242
|
-
#
|
|
243
|
-
# @see OpenAI::Models::Beta::Threads::Message#role
|
|
244
|
-
module Role
|
|
245
|
-
extend OpenAI::Internal::Type::Enum
|
|
246
|
-
|
|
247
|
-
USER = :user
|
|
248
|
-
ASSISTANT = :assistant
|
|
249
|
-
|
|
250
|
-
# @!method self.values
|
|
251
|
-
# @return [Array<Symbol>]
|
|
252
|
-
end
|
|
253
|
-
|
|
254
|
-
# The status of the message, which can be either `in_progress`, `incomplete`, or
|
|
255
|
-
# `completed`.
|
|
256
|
-
#
|
|
257
|
-
# @see OpenAI::Models::Beta::Threads::Message#status
|
|
258
|
-
module Status
|
|
259
|
-
extend OpenAI::Internal::Type::Enum
|
|
260
|
-
|
|
261
|
-
IN_PROGRESS = :in_progress
|
|
262
|
-
INCOMPLETE = :incomplete
|
|
263
|
-
COMPLETED = :completed
|
|
264
|
-
|
|
265
|
-
# @!method self.values
|
|
266
|
-
# @return [Array<Symbol>]
|
|
267
|
-
end
|
|
268
|
-
end
|
|
269
|
-
end
|
|
270
|
-
end
|
|
271
|
-
end
|
|
272
|
-
end
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
# frozen_string_literal: true
|
|
2
|
-
|
|
3
|
-
module OpenAI
|
|
4
|
-
module Models
|
|
5
|
-
module Beta
|
|
6
|
-
module Threads
|
|
7
|
-
# References an image
|
|
8
|
-
# [File](https://developers.openai.com/api/reference/resources/files) in the
|
|
9
|
-
# content of a message.
|
|
10
|
-
module MessageContent
|
|
11
|
-
extend OpenAI::Internal::Type::Union
|
|
12
|
-
|
|
13
|
-
discriminator :type
|
|
14
|
-
|
|
15
|
-
# References an image [File](https://developers.openai.com/api/reference/resources/files) in the content of a message.
|
|
16
|
-
variant :image_file, -> { OpenAI::Beta::Threads::ImageFileContentBlock }
|
|
17
|
-
|
|
18
|
-
# References an image URL in the content of a message.
|
|
19
|
-
variant :image_url, -> { OpenAI::Beta::Threads::ImageURLContentBlock }
|
|
20
|
-
|
|
21
|
-
# The text content that is part of a message.
|
|
22
|
-
variant :text, -> { OpenAI::Beta::Threads::TextContentBlock }
|
|
23
|
-
|
|
24
|
-
# The refusal content generated by the assistant.
|
|
25
|
-
variant :refusal, -> { OpenAI::Beta::Threads::RefusalContentBlock }
|
|
26
|
-
|
|
27
|
-
# @!method self.variants
|
|
28
|
-
# @return [Array(OpenAI::Models::Beta::Threads::ImageFileContentBlock, OpenAI::Models::Beta::Threads::ImageURLContentBlock, OpenAI::Models::Beta::Threads::TextContentBlock, OpenAI::Models::Beta::Threads::RefusalContentBlock)]
|
|
29
|
-
end
|
|
30
|
-
end
|
|
31
|
-
end
|
|
32
|
-
end
|
|
33
|
-
end
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
# frozen_string_literal: true
|
|
2
|
-
|
|
3
|
-
module OpenAI
|
|
4
|
-
module Models
|
|
5
|
-
module Beta
|
|
6
|
-
module Threads
|
|
7
|
-
# References an image
|
|
8
|
-
# [File](https://developers.openai.com/api/reference/resources/files) in the
|
|
9
|
-
# content of a message.
|
|
10
|
-
module MessageContentDelta
|
|
11
|
-
extend OpenAI::Internal::Type::Union
|
|
12
|
-
|
|
13
|
-
discriminator :type
|
|
14
|
-
|
|
15
|
-
# References an image [File](https://developers.openai.com/api/reference/resources/files) in the content of a message.
|
|
16
|
-
variant :image_file, -> { OpenAI::Beta::Threads::ImageFileDeltaBlock }
|
|
17
|
-
|
|
18
|
-
# The text content that is part of a message.
|
|
19
|
-
variant :text, -> { OpenAI::Beta::Threads::TextDeltaBlock }
|
|
20
|
-
|
|
21
|
-
# The refusal content that is part of a message.
|
|
22
|
-
variant :refusal, -> { OpenAI::Beta::Threads::RefusalDeltaBlock }
|
|
23
|
-
|
|
24
|
-
# References an image URL in the content of a message.
|
|
25
|
-
variant :image_url, -> { OpenAI::Beta::Threads::ImageURLDeltaBlock }
|
|
26
|
-
|
|
27
|
-
# @!method self.variants
|
|
28
|
-
# @return [Array(OpenAI::Models::Beta::Threads::ImageFileDeltaBlock, OpenAI::Models::Beta::Threads::TextDeltaBlock, OpenAI::Models::Beta::Threads::RefusalDeltaBlock, OpenAI::Models::Beta::Threads::ImageURLDeltaBlock)]
|
|
29
|
-
end
|
|
30
|
-
end
|
|
31
|
-
end
|
|
32
|
-
end
|
|
33
|
-
end
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
# frozen_string_literal: true
|
|
2
|
-
|
|
3
|
-
module OpenAI
|
|
4
|
-
module Models
|
|
5
|
-
module Beta
|
|
6
|
-
module Threads
|
|
7
|
-
# References an image
|
|
8
|
-
# [File](https://developers.openai.com/api/reference/resources/files) in the
|
|
9
|
-
# content of a message.
|
|
10
|
-
module MessageContentPartParam
|
|
11
|
-
extend OpenAI::Internal::Type::Union
|
|
12
|
-
|
|
13
|
-
discriminator :type
|
|
14
|
-
|
|
15
|
-
# References an image [File](https://developers.openai.com/api/reference/resources/files) in the content of a message.
|
|
16
|
-
variant :image_file, -> { OpenAI::Beta::Threads::ImageFileContentBlock }
|
|
17
|
-
|
|
18
|
-
# References an image URL in the content of a message.
|
|
19
|
-
variant :image_url, -> { OpenAI::Beta::Threads::ImageURLContentBlock }
|
|
20
|
-
|
|
21
|
-
# The text content that is part of a message.
|
|
22
|
-
variant :text, -> { OpenAI::Beta::Threads::TextContentBlockParam }
|
|
23
|
-
|
|
24
|
-
# @!method self.variants
|
|
25
|
-
# @return [Array(OpenAI::Models::Beta::Threads::ImageFileContentBlock, OpenAI::Models::Beta::Threads::ImageURLContentBlock, OpenAI::Models::Beta::Threads::TextContentBlockParam)]
|
|
26
|
-
end
|
|
27
|
-
end
|
|
28
|
-
end
|
|
29
|
-
end
|
|
30
|
-
end
|
|
@@ -1,172 +0,0 @@
|
|
|
1
|
-
# frozen_string_literal: true
|
|
2
|
-
|
|
3
|
-
module OpenAI
|
|
4
|
-
module Models
|
|
5
|
-
module Beta
|
|
6
|
-
module Threads
|
|
7
|
-
# @see OpenAI::Resources::Beta::Threads::Messages#create
|
|
8
|
-
class MessageCreateParams < OpenAI::Internal::Type::BaseModel
|
|
9
|
-
extend OpenAI::Internal::Type::RequestParameters::Converter
|
|
10
|
-
include OpenAI::Internal::Type::RequestParameters
|
|
11
|
-
|
|
12
|
-
# @!attribute thread_id
|
|
13
|
-
#
|
|
14
|
-
# @return [String]
|
|
15
|
-
required :thread_id, String
|
|
16
|
-
|
|
17
|
-
# @!attribute content
|
|
18
|
-
# The text contents of the message.
|
|
19
|
-
#
|
|
20
|
-
# @return [String, Array<OpenAI::Models::Beta::Threads::ImageFileContentBlock, OpenAI::Models::Beta::Threads::ImageURLContentBlock, OpenAI::Models::Beta::Threads::TextContentBlockParam>]
|
|
21
|
-
required :content, union: -> { OpenAI::Beta::Threads::MessageCreateParams::Content }
|
|
22
|
-
|
|
23
|
-
# @!attribute role
|
|
24
|
-
# The role of the entity that is creating the message. Allowed values include:
|
|
25
|
-
#
|
|
26
|
-
# - `user`: Indicates the message is sent by an actual user and should be used in
|
|
27
|
-
# most cases to represent user-generated messages.
|
|
28
|
-
# - `assistant`: Indicates the message is generated by the assistant. Use this
|
|
29
|
-
# value to insert messages from the assistant into the conversation.
|
|
30
|
-
#
|
|
31
|
-
# @return [Symbol, OpenAI::Models::Beta::Threads::MessageCreateParams::Role]
|
|
32
|
-
required :role, enum: -> { OpenAI::Beta::Threads::MessageCreateParams::Role }
|
|
33
|
-
|
|
34
|
-
# @!attribute attachments
|
|
35
|
-
# A list of files attached to the message, and the tools they should be added to.
|
|
36
|
-
#
|
|
37
|
-
# @return [Array<OpenAI::Models::Beta::Threads::MessageCreateParams::Attachment>, nil]
|
|
38
|
-
optional(
|
|
39
|
-
:attachments,
|
|
40
|
-
-> {
|
|
41
|
-
OpenAI::Internal::Type::ArrayOf[OpenAI::Beta::Threads::MessageCreateParams::Attachment]
|
|
42
|
-
},
|
|
43
|
-
nil?: true
|
|
44
|
-
)
|
|
45
|
-
|
|
46
|
-
# @!attribute metadata
|
|
47
|
-
# Set of 16 key-value pairs that can be attached to an object. This can be useful
|
|
48
|
-
# for storing additional information about the object in a structured format, and
|
|
49
|
-
# querying for objects via API or the dashboard.
|
|
50
|
-
#
|
|
51
|
-
# Keys are strings with a maximum length of 64 characters. Values are strings with
|
|
52
|
-
# a maximum length of 512 characters.
|
|
53
|
-
#
|
|
54
|
-
# @return [Hash{Symbol=>String}, nil]
|
|
55
|
-
optional :metadata, OpenAI::Internal::Type::HashOf[String], nil?: true
|
|
56
|
-
|
|
57
|
-
# @!method initialize(thread_id:, content:, role:, attachments: nil, metadata: nil, request_options: {})
|
|
58
|
-
# @param thread_id [String]
|
|
59
|
-
#
|
|
60
|
-
# @param content [String, Array<OpenAI::Models::Beta::Threads::ImageFileContentBlock, OpenAI::Models::Beta::Threads::ImageURLContentBlock, OpenAI::Models::Beta::Threads::TextContentBlockParam>]
|
|
61
|
-
# The text contents of the message.
|
|
62
|
-
#
|
|
63
|
-
# @param role [Symbol, OpenAI::Models::Beta::Threads::MessageCreateParams::Role]
|
|
64
|
-
# The role of the entity that is creating the message. Allowed values include:
|
|
65
|
-
#
|
|
66
|
-
# - `user`: Indicates the message is sent by an actual user and should be used in
|
|
67
|
-
# most cases to represent user-generated messages.
|
|
68
|
-
# - `assistant`: Indicates the message is generated by the assistant. Use this
|
|
69
|
-
# value to insert messages from the assistant into the conversation.
|
|
70
|
-
#
|
|
71
|
-
# @param attachments [Array<OpenAI::Models::Beta::Threads::MessageCreateParams::Attachment>, nil]
|
|
72
|
-
# A list of files attached to the message, and the tools they should be added to.
|
|
73
|
-
#
|
|
74
|
-
# @param metadata [Hash{Symbol=>String}, nil]
|
|
75
|
-
# Set of 16 key-value pairs that can be attached to an object. This can be useful
|
|
76
|
-
# for storing additional information about the object in a structured format, and
|
|
77
|
-
# querying for objects via API or the dashboard.
|
|
78
|
-
#
|
|
79
|
-
# Keys are strings with a maximum length of 64 characters. Values are strings with
|
|
80
|
-
# a maximum length of 512 characters.
|
|
81
|
-
#
|
|
82
|
-
# @param request_options [OpenAI::RequestOptions, Hash{Symbol=>Object}]
|
|
83
|
-
|
|
84
|
-
# The text contents of the message.
|
|
85
|
-
module Content
|
|
86
|
-
extend OpenAI::Internal::Type::Union
|
|
87
|
-
|
|
88
|
-
# The text contents of the message.
|
|
89
|
-
variant String
|
|
90
|
-
|
|
91
|
-
# An array of content parts with a defined type, each can be of type `text` or images can be passed with `image_url` or `image_file`. Image types are only supported on [Vision-compatible models](https://developers.openai.com/api/docs/models).
|
|
92
|
-
variant -> { OpenAI::Models::Beta::Threads::MessageCreateParams::Content::MessageContentPartParamArray }
|
|
93
|
-
|
|
94
|
-
# @!method self.variants
|
|
95
|
-
# @return [Array(String, Array<OpenAI::Models::Beta::Threads::ImageFileContentBlock, OpenAI::Models::Beta::Threads::ImageURLContentBlock, OpenAI::Models::Beta::Threads::TextContentBlockParam>)]
|
|
96
|
-
|
|
97
|
-
# @type [OpenAI::Internal::Type::Converter]
|
|
98
|
-
MessageContentPartParamArray = OpenAI::Internal::Type::ArrayOf[
|
|
99
|
-
union: -> { OpenAI::Beta::Threads::MessageContentPartParam }
|
|
100
|
-
]
|
|
101
|
-
end
|
|
102
|
-
|
|
103
|
-
# The role of the entity that is creating the message. Allowed values include:
|
|
104
|
-
#
|
|
105
|
-
# - `user`: Indicates the message is sent by an actual user and should be used in
|
|
106
|
-
# most cases to represent user-generated messages.
|
|
107
|
-
# - `assistant`: Indicates the message is generated by the assistant. Use this
|
|
108
|
-
# value to insert messages from the assistant into the conversation.
|
|
109
|
-
module Role
|
|
110
|
-
extend OpenAI::Internal::Type::Enum
|
|
111
|
-
|
|
112
|
-
USER = :user
|
|
113
|
-
ASSISTANT = :assistant
|
|
114
|
-
|
|
115
|
-
# @!method self.values
|
|
116
|
-
# @return [Array<Symbol>]
|
|
117
|
-
end
|
|
118
|
-
|
|
119
|
-
class Attachment < OpenAI::Internal::Type::BaseModel
|
|
120
|
-
# @!attribute file_id
|
|
121
|
-
# The ID of the file to attach to the message.
|
|
122
|
-
#
|
|
123
|
-
# @return [String, nil]
|
|
124
|
-
optional :file_id, String
|
|
125
|
-
|
|
126
|
-
# @!attribute tools
|
|
127
|
-
# The tools to add this file to.
|
|
128
|
-
#
|
|
129
|
-
# @return [Array<OpenAI::Models::Beta::CodeInterpreterTool, OpenAI::Models::Beta::Threads::MessageCreateParams::Attachment::Tool::FileSearch>, nil]
|
|
130
|
-
optional(
|
|
131
|
-
:tools,
|
|
132
|
-
-> {
|
|
133
|
-
OpenAI::Internal::Type::ArrayOf[union: OpenAI::Beta::Threads::MessageCreateParams::Attachment::Tool]
|
|
134
|
-
}
|
|
135
|
-
)
|
|
136
|
-
|
|
137
|
-
# @!method initialize(file_id: nil, tools: nil)
|
|
138
|
-
# @param file_id [String]
|
|
139
|
-
# The ID of the file to attach to the message.
|
|
140
|
-
#
|
|
141
|
-
# @param tools [Array<OpenAI::Models::Beta::CodeInterpreterTool, OpenAI::Models::Beta::Threads::MessageCreateParams::Attachment::Tool::FileSearch>]
|
|
142
|
-
# The tools to add this file to.
|
|
143
|
-
module Tool
|
|
144
|
-
extend OpenAI::Internal::Type::Union
|
|
145
|
-
|
|
146
|
-
discriminator :type
|
|
147
|
-
|
|
148
|
-
variant :code_interpreter, -> { OpenAI::Beta::CodeInterpreterTool }
|
|
149
|
-
|
|
150
|
-
variant :file_search, -> { OpenAI::Beta::Threads::MessageCreateParams::Attachment::Tool::FileSearch }
|
|
151
|
-
|
|
152
|
-
class FileSearch < OpenAI::Internal::Type::BaseModel
|
|
153
|
-
# @!attribute type
|
|
154
|
-
# The type of tool being defined: `file_search`
|
|
155
|
-
#
|
|
156
|
-
# @return [Symbol, :file_search]
|
|
157
|
-
required :type, const: :file_search
|
|
158
|
-
|
|
159
|
-
# @!method initialize(type: :file_search)
|
|
160
|
-
# @param type [Symbol, :file_search]
|
|
161
|
-
# The type of tool being defined: `file_search`
|
|
162
|
-
end
|
|
163
|
-
|
|
164
|
-
# @!method self.variants
|
|
165
|
-
# @return [Array(OpenAI::Models::Beta::CodeInterpreterTool, OpenAI::Models::Beta::Threads::MessageCreateParams::Attachment::Tool::FileSearch)]
|
|
166
|
-
end
|
|
167
|
-
end
|
|
168
|
-
end
|
|
169
|
-
end
|
|
170
|
-
end
|
|
171
|
-
end
|
|
172
|
-
end
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
# frozen_string_literal: true
|
|
2
|
-
|
|
3
|
-
module OpenAI
|
|
4
|
-
module Models
|
|
5
|
-
module Beta
|
|
6
|
-
module Threads
|
|
7
|
-
# @see OpenAI::Resources::Beta::Threads::Messages#delete
|
|
8
|
-
class MessageDeleteParams < OpenAI::Internal::Type::BaseModel
|
|
9
|
-
extend OpenAI::Internal::Type::RequestParameters::Converter
|
|
10
|
-
include OpenAI::Internal::Type::RequestParameters
|
|
11
|
-
|
|
12
|
-
# @!attribute thread_id
|
|
13
|
-
#
|
|
14
|
-
# @return [String]
|
|
15
|
-
required :thread_id, String
|
|
16
|
-
|
|
17
|
-
# @!attribute message_id
|
|
18
|
-
#
|
|
19
|
-
# @return [String]
|
|
20
|
-
required :message_id, String
|
|
21
|
-
|
|
22
|
-
# @!method initialize(thread_id:, message_id:, request_options: {})
|
|
23
|
-
# @param thread_id [String]
|
|
24
|
-
# @param message_id [String]
|
|
25
|
-
# @param request_options [OpenAI::RequestOptions, Hash{Symbol=>Object}]
|
|
26
|
-
end
|
|
27
|
-
end
|
|
28
|
-
end
|
|
29
|
-
end
|
|
30
|
-
end
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
# frozen_string_literal: true
|
|
2
|
-
|
|
3
|
-
module OpenAI
|
|
4
|
-
module Models
|
|
5
|
-
module Beta
|
|
6
|
-
module Threads
|
|
7
|
-
# @see OpenAI::Resources::Beta::Threads::Messages#delete
|
|
8
|
-
class MessageDeleted < OpenAI::Internal::Type::BaseModel
|
|
9
|
-
# @!attribute id
|
|
10
|
-
#
|
|
11
|
-
# @return [String]
|
|
12
|
-
required :id, String
|
|
13
|
-
|
|
14
|
-
# @!attribute deleted
|
|
15
|
-
#
|
|
16
|
-
# @return [Boolean]
|
|
17
|
-
required :deleted, OpenAI::Internal::Type::Boolean
|
|
18
|
-
|
|
19
|
-
# @!attribute object
|
|
20
|
-
#
|
|
21
|
-
# @return [Symbol, :"thread.message.deleted"]
|
|
22
|
-
required :object, const: :"thread.message.deleted"
|
|
23
|
-
|
|
24
|
-
# @!method initialize(id:, deleted:, object: :"thread.message.deleted")
|
|
25
|
-
# @param id [String]
|
|
26
|
-
# @param deleted [Boolean]
|
|
27
|
-
# @param object [Symbol, :"thread.message.deleted"]
|
|
28
|
-
end
|
|
29
|
-
end
|
|
30
|
-
end
|
|
31
|
-
end
|
|
32
|
-
end
|