Class: OpenAI::Models::Responses::ComputerUsePreviewTool

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/openai/models/responses/computer_use_preview_tool.rb

Defined Under Namespace

Modules: Environment

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Internal::Type::BaseModel

==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml

Methods included from Internal::Type::Converter

#coerce, coerce, #dump, dump, inspect, #inspect, meta_info, new_coerce_state, type_info

Methods included from Internal::Util::SorbetRuntimeSupport

#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type

Constructor Details

#initialize(display_height:, display_width:, environment:, type: :computer_use_preview) ⇒ Object

A tool that controls a virtual computer. Learn more about the [computer tool](platform.openai.com/docs/guides/tools-computer-use).

Parameters:

  • The height of the computer display.

  • The width of the computer display.

  • The type of computer environment to control.

  • (defaults to: :computer_use_preview)

    The type of the computer use tool. Always computer_use_preview.



# File 'lib/openai/models/responses/computer_use_preview_tool.rb', line 31


Instance Attribute Details

#display_heightInteger

The height of the computer display.

Returns:



11
# File 'lib/openai/models/responses/computer_use_preview_tool.rb', line 11

required :display_height, Integer

#display_widthInteger

The width of the computer display.

Returns:



17
# File 'lib/openai/models/responses/computer_use_preview_tool.rb', line 17

required :display_width, Integer

#environmentSymbol, OpenAI::Models::Responses::ComputerUsePreviewTool::Environment

The type of computer environment to control.

Returns:



23
# File 'lib/openai/models/responses/computer_use_preview_tool.rb', line 23

required :environment, enum: -> { OpenAI::Responses::ComputerUsePreviewTool::Environment }

#typeSymbol, :computer_use_preview

The type of the computer use tool. Always computer_use_preview.

Returns:



29
# File 'lib/openai/models/responses/computer_use_preview_tool.rb', line 29

required :type, const: :computer_use_preview