Class: OpenAI::Models::Beta::Environment::OpenAIHosted

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/openai/models/beta/environment.rb,
sig/openai/models/beta/environment.rbs

Defined Under Namespace

Modules: ContainerSize Classes: Desktop, Network, Packages

Instance Attribute Summary collapse

Attributes inherited from Internal::Type::BaseModel

#last_response

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Internal::Type::BaseModel

==, #==, #[], #_request_id, #_set_last_response, coerce, #deconstruct_keys, #deep_to_h, dump, #encode_with, 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, coerce_cached, coerce_with_error, #dump, dump, #inspect, inspect, meta_info, new_coerce_state, resolve_type, 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(npm:, python:, system_:) ⇒ OpenAIHosted

Returns a new instance of OpenAIHosted.

Parameters:

  • id —

    The public ID of the environment.

  • capability_directories —

    Directories that contain capabilities exposed to the agent.

  • files —

    Files available in the environment, excluding their contents.

  • network —

    The effective network access policy for the environment.

  • packages —

    Packages installed in the environment.

  • plugins —

    Plugins installed in the environment, excluding their archive contents.

  • skills —

    Skills installed in the environment, excluding their archive contents.

  • container_size —

    The effective CPU and memory tier, or null when unknown or outside the public tiers.

  • desktop —

    The effective desktop configuration.

  • type —

    The type of the object. Always openai_hosted.

  • id: (String)
  • capability_directories: (::Array[String])
  • files: (::Array[OpenAI::Models::Beta::hosted_environment_file])
  • network: (OpenAI::Beta::Environment::OpenAIHosted::Network)
  • packages: (OpenAI::Beta::Environment::OpenAIHosted::Packages)
  • plugins: (::Array[OpenAI::Beta::HostedPlugin])
  • skills: (::Array[OpenAI::Models::Beta::hosted_skill])
  • container_size: (OpenAI::Models::Beta::Environment::OpenAIHosted::container_size, nil)
  • desktop: (OpenAI::Beta::Environment::OpenAIHosted::Desktop)
  • type: (:openai_hosted)


# File 'lib/openai/models/beta/environment.rb', line 104

Instance Attribute Details

#capability_directories ⇒ ::Array[String]

Directories that contain capabilities exposed to the agent.

Returns:

  • (::Array[String])


47
# File 'lib/openai/models/beta/environment.rb', line 47

required :capability_directories, OpenAI::Internal::Type::ArrayOf[String]

#container_size ⇒ OpenAI::Models::Beta::Environment::OpenAIHosted::container_size?

The effective CPU and memory tier, or null when unknown or outside the public tiers.

Returns:

  • (OpenAI::Models::Beta::Environment::OpenAIHosted::container_size, nil)


90
91
92
93
94
95
96
# File 'lib/openai/models/beta/environment.rb', line 90

optional(
  :container_size,
  enum: -> {
    OpenAI::Beta::Environment::OpenAIHosted::ContainerSize
  },
  nil?: true
)

#desktop ⇒ OpenAI::Beta::Environment::OpenAIHosted::Desktop?

The effective desktop configuration.

Returns:

  • (OpenAI::Beta::Environment::OpenAIHosted::Desktop, nil)


102
# File 'lib/openai/models/beta/environment.rb', line 102

optional :desktop, -> { OpenAI::Beta::Environment::OpenAIHosted::Desktop }

#files ⇒ ::Array[OpenAI::Models::Beta::hosted_environment_file]

Files available in the environment, excluding their contents.

Returns:

  • (::Array[OpenAI::Models::Beta::hosted_environment_file])


53
# File 'lib/openai/models/beta/environment.rb', line 53

required :files, -> { OpenAI::Internal::Type::ArrayOf[union: OpenAI::Beta::HostedEnvironmentFile] }

#id ⇒ String

The public ID of the environment.

Returns:

  • (String)


41
# File 'lib/openai/models/beta/environment.rb', line 41

required :id, String

#network ⇒ OpenAI::Beta::Environment::OpenAIHosted::Network

The effective network access policy for the environment.

Returns:

  • (OpenAI::Beta::Environment::OpenAIHosted::Network)


59
# File 'lib/openai/models/beta/environment.rb', line 59

required :network, -> { OpenAI::Beta::Environment::OpenAIHosted::Network }

#packages ⇒ OpenAI::Beta::Environment::OpenAIHosted::Packages

Packages installed in the environment.

Returns:

  • (OpenAI::Beta::Environment::OpenAIHosted::Packages)


65
# File 'lib/openai/models/beta/environment.rb', line 65

required :packages, -> { OpenAI::Beta::Environment::OpenAIHosted::Packages }

#plugins ⇒ ::Array[OpenAI::Beta::HostedPlugin]

Plugins installed in the environment, excluding their archive contents.

Returns:

  • (::Array[OpenAI::Beta::HostedPlugin])


71
# File 'lib/openai/models/beta/environment.rb', line 71

required :plugins, -> { OpenAI::Internal::Type::ArrayOf[OpenAI::Beta::HostedPlugin] }

#skills ⇒ ::Array[OpenAI::Models::Beta::hosted_skill]

Skills installed in the environment, excluding their archive contents.

Returns:

  • (::Array[OpenAI::Models::Beta::hosted_skill])


77
# File 'lib/openai/models/beta/environment.rb', line 77

required :skills, -> { OpenAI::Internal::Type::ArrayOf[union: OpenAI::Beta::HostedSkill] }

#type ⇒ :openai_hosted

The type of the object. Always openai_hosted.

Returns:

  • (:openai_hosted)


83
# File 'lib/openai/models/beta/environment.rb', line 83

required :type, const: :openai_hosted

Class Method Details

.values ⇒ Array<Symbol>

Returns:

  • (Array<Symbol>)


# File 'lib/openai/models/beta/environment.rb', line 176

Instance Method Details

#to_hash ⇒ { id: String, capability_directories: ::Array[String], files: ::Array[OpenAI::Models::Beta::hosted_environment_file], network: OpenAI::Beta::Environment::OpenAIHosted::Network, packages: OpenAI::Beta::Environment::OpenAIHosted::Packages, plugins: ::Array[OpenAI::Beta::HostedPlugin], skills: ::Array[OpenAI::Models::Beta::hosted_skill], ?type: :openai_hosted, ?container_size: OpenAI::Models::Beta::Environment::OpenAIHosted::container_size?, ?desktop: OpenAI::Beta::Environment::OpenAIHosted::Desktop }

Returns:

  • ({ id: String, capability_directories: ::Array[String], files: ::Array[OpenAI::Models::Beta::hosted_environment_file], network: OpenAI::Beta::Environment::OpenAIHosted::Network, packages: OpenAI::Beta::Environment::OpenAIHosted::Packages, plugins: ::Array[OpenAI::Beta::HostedPlugin], skills: ::Array[OpenAI::Models::Beta::hosted_skill], ?type: :openai_hosted, ?container_size: OpenAI::Models::Beta::Environment::OpenAIHosted::container_size?, ?desktop: OpenAI::Beta::Environment::OpenAIHosted::Desktop })


110
111
112
113
114
115
116
117
118
119
120
121
# File 'sig/openai/models/beta/environment.rbs', line 110

def to_hash: -> {
  id: String,
  capability_directories: ::Array[String],
  files: ::Array[OpenAI::Models::Beta::hosted_environment_file],
  network: OpenAI::Beta::Environment::OpenAIHosted::Network,
  packages: OpenAI::Beta::Environment::OpenAIHosted::Packages,
  plugins: ::Array[OpenAI::Beta::HostedPlugin],
  skills: ::Array[OpenAI::Models::Beta::hosted_skill],
  ?type: :openai_hosted,
  ?container_size: OpenAI::Models::Beta::Environment::OpenAIHosted::container_size?,
  ?desktop: OpenAI::Beta::Environment::OpenAIHosted::Desktop
}