openai-agents 0.0.2__py3-none-any.whl → 0.0.3__py3-none-any.whl

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.

Potentially problematic release.


This version of openai-agents might be problematic. Click here for more details.

agents/_run_impl.py CHANGED
@@ -23,7 +23,7 @@ from openai.types.responses.response_computer_tool_call import (
23
23
  ActionWait,
24
24
  )
25
25
  from openai.types.responses.response_input_param import ComputerCallOutput
26
- from openai.types.responses.response_output_item import Reasoning
26
+ from openai.types.responses.response_reasoning_item import ResponseReasoningItem
27
27
 
28
28
  from . import _utils
29
29
  from .agent import Agent
@@ -288,7 +288,7 @@ class RunImpl:
288
288
  items.append(ToolCallItem(raw_item=output, agent=agent))
289
289
  elif isinstance(output, ResponseFunctionWebSearch):
290
290
  items.append(ToolCallItem(raw_item=output, agent=agent))
291
- elif isinstance(output, Reasoning):
291
+ elif isinstance(output, ResponseReasoningItem):
292
292
  items.append(ReasoningItem(raw_item=output, agent=agent))
293
293
  elif isinstance(output, ResponseComputerToolCall):
294
294
  items.append(ToolCallItem(raw_item=output, agent=agent))
agents/agent_output.py CHANGED
@@ -138,7 +138,7 @@ def _type_to_str(t: type[Any]) -> str:
138
138
  # It's a simple type like `str`, `int`, etc.
139
139
  return t.__name__
140
140
  elif args:
141
- args_str = ', '.join(_type_to_str(arg) for arg in args)
141
+ args_str = ", ".join(_type_to_str(arg) for arg in args)
142
142
  return f"{origin.__name__}[{args_str}]"
143
143
  else:
144
144
  return str(t)
agents/items.py CHANGED
@@ -19,7 +19,7 @@ from openai.types.responses import (
19
19
  ResponseStreamEvent,
20
20
  )
21
21
  from openai.types.responses.response_input_item_param import ComputerCallOutput, FunctionCallOutput
22
- from openai.types.responses.response_output_item import Reasoning
22
+ from openai.types.responses.response_reasoning_item import ResponseReasoningItem
23
23
  from pydantic import BaseModel
24
24
  from typing_extensions import TypeAlias
25
25
 
@@ -136,10 +136,10 @@ class ToolCallOutputItem(RunItemBase[Union[FunctionCallOutput, ComputerCallOutpu
136
136
 
137
137
 
138
138
  @dataclass
139
- class ReasoningItem(RunItemBase[Reasoning]):
139
+ class ReasoningItem(RunItemBase[ResponseReasoningItem]):
140
140
  """Represents a reasoning item."""
141
141
 
142
- raw_item: Reasoning
142
+ raw_item: ResponseReasoningItem
143
143
  """The raw reasoning item."""
144
144
 
145
145
  type: Literal["reasoning_item"] = "reasoning_item"
agents/model_settings.py CHANGED
@@ -11,6 +11,7 @@ class ModelSettings:
11
11
  This class holds optional model configuration parameters (e.g. temperature,
12
12
  top_p, penalties, truncation, etc.).
13
13
  """
14
+
14
15
  temperature: float | None = None
15
16
  top_p: float | None = None
16
17
  frequency_penalty: float | None = None
@@ -361,7 +361,7 @@ class Converter:
361
361
  includes = "file_search_call.results" if tool.include_search_results else None
362
362
  elif isinstance(tool, ComputerTool):
363
363
  converted_tool = {
364
- "type": "computer-preview",
364
+ "type": "computer_use_preview",
365
365
  "environment": tool.computer.environment,
366
366
  "display_width": tool.computer.dimensions[0],
367
367
  "display_height": tool.computer.dimensions[1],
agents/tool.py CHANGED
@@ -284,3 +284,5 @@ def function_tool(
284
284
  return _create_function_tool(real_func)
285
285
 
286
286
  return decorator
287
+ return decorator
288
+ return decorator
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: openai-agents
3
- Version: 0.0.2
3
+ Version: 0.0.3
4
4
  Summary: OpenAI Agents SDK
5
5
  Project-URL: Homepage, https://github.com/openai/openai-agents-python
6
6
  Project-URL: Repository, https://github.com/openai/openai-agents-python
@@ -19,7 +19,7 @@ Classifier: Topic :: Software Development :: Libraries :: Python Modules
19
19
  Classifier: Typing :: Typed
20
20
  Requires-Python: >=3.9
21
21
  Requires-Dist: griffe<2,>=1.5.6
22
- Requires-Dist: openai>=1.66.0
22
+ Requires-Dist: openai>=1.66.2
23
23
  Requires-Dist: pydantic<3,>=2.10
24
24
  Requires-Dist: requests<3,>=2.0
25
25
  Requires-Dist: types-requests<3,>=2.0
@@ -30,16 +30,18 @@ Description-Content-Type: text/markdown
30
30
 
31
31
  The OpenAI Agents SDK is a lightweight yet powerful framework for building multi-agent workflows.
32
32
 
33
- <img src="docs/assets/images/orchestration.png" alt="Image of the Agents Tracing UI" style="max-height: 803px;">
33
+ <img src="https://cdn.openai.com/API/docs/images/orchestration.png" alt="Image of the Agents Tracing UI" style="max-height: 803px;">
34
34
 
35
35
  ### Core concepts:
36
36
 
37
- 1. [**Agents**](docs/agents.md): LLMs configured with instructions, tools, guardrails, and handoffs
38
- 2. [**Handoffs**](docs/handoffs.md): Allow agents to transfer control to other agents for specific tasks
39
- 3. [**Guardrails**](docs/guardrails.md): Configurable safety checks for input and output validation
40
- 4. [**Tracing**](docs/tracing.md): Built-in tracking of agent runs, allowing you to view, debug and optimize your workflows
37
+ 1. [**Agents**](https://openai.github.io/openai-agents-python/agents): LLMs configured with instructions, tools, guardrails, and handoffs
38
+ 2. [**Handoffs**](https://openai.github.io/openai-agents-python/handoffs/): Allow agents to transfer control to other agents for specific tasks
39
+ 3. [**Guardrails**](https://openai.github.io/openai-agents-python/guardrails/): Configurable safety checks for input and output validation
40
+ 4. [**Tracing**](https://openai.github.io/openai-agents-python/tracing/): Built-in tracking of agent runs, allowing you to view, debug and optimize your workflows
41
41
 
42
- Explore the [examples](examples) directory to see the SDK in action.
42
+ Explore the [examples](examples) directory to see the SDK in action, and read our [documentation](https://openai.github.io/openai-agents-python/) for more details.
43
+
44
+ Notably, our SDK [is compatible](https://openai.github.io/openai-agents-python/models/) with any model providers that support the OpenAI Chat Completions API format.
43
45
 
44
46
  ## Get started
45
47
 
@@ -166,7 +168,7 @@ The Agents SDK is designed to be highly flexible, allowing you to model a wide r
166
168
 
167
169
  ## Tracing
168
170
 
169
- The Agents SDK includes built-in tracing, making it easy to track and debug the behavior of your agents. Tracing is extensible by design, supporting custom spans and a wide variety of external destinations, including [Logfire](https://logfire.pydantic.dev/docs/integrations/llms/openai/#openai-agents), [AgentOps](https://docs.agentops.ai/v1/integrations/agentssdk), and [Braintrust](https://braintrust.dev/docs/guides/traces/integrations#openai-agents-sdk). See [Tracing](http://openai.github.io/openai-agents-python/tracing.md) for more details.
171
+ The Agents SDK automatically traces your agent runs, making it easy to track and debug the behavior of your agents. Tracing is extensible by design, supporting custom spans and a wide variety of external destinations, including [Logfire](https://logfire.pydantic.dev/docs/integrations/llms/openai/#openai-agents), [AgentOps](https://docs.agentops.ai/v1/integrations/agentssdk), and [Braintrust](https://braintrust.dev/docs/guides/traces/integrations#openai-agents-sdk). For more details about how to customize or disable tracing, see [Tracing](http://openai.github.io/openai-agents-python/tracing).
170
172
 
171
173
  ## Development (only needed if you need to edit the SDK/examples)
172
174
 
@@ -1,25 +1,25 @@
1
1
  agents/__init__.py,sha256=Qd1eatUlALblGTqHV4o5jL-h65furZ-s0IK8RFNRGWY,5879
2
2
  agents/_config.py,sha256=5qrDSZuguiL0gCTd_6f9J6ulpsRySueZ3re4lyd4PU0,743
3
3
  agents/_debug.py,sha256=7OKys2lDjeCtGggTkM53m_8vw0WIr3yt-_JPBDAnsw0,608
4
- agents/_run_impl.py,sha256=v9mMCT_v0pwGnPW-fydzHpdu1gI9pROC7Wvhe50IVrw,28522
4
+ agents/_run_impl.py,sha256=QzHStnsTZymjTFy8fKTpkfvMijyW7zWoKg1a2VUzC7U,28549
5
5
  agents/_utils.py,sha256=L21Hdl20U66Asp-W61yTnahmo8b6X58jsgdUBWb9_Rk,1685
6
6
  agents/agent.py,sha256=Y0lnIva9qL_WJVUVxDQtSrMa0KuM5IXLWK0q6CzIxas,6297
7
- agents/agent_output.py,sha256=xk17hMtFQSviQNydzt70ENvsPDTWgZazv1NhswC16e4,5345
7
+ agents/agent_output.py,sha256=k271F9MgMaoS1nPtsSwsURP8mNxv8VrEOWrv7PJSQT4,5345
8
8
  agents/computer.py,sha256=XD44UgiUWSfniv-xKwwDP6wFKVwBiZkpaL1hO-0-7ZA,2516
9
9
  agents/exceptions.py,sha256=F3AltRt27PGdhbFqKBhRJL9eHqoN4SQx7oxBn0GWmhs,1856
10
10
  agents/function_schema.py,sha256=OgeuiDhLowhYt6T9CU-7Fk05uKIxPaDPgL2hdnMFjpQ,12666
11
11
  agents/guardrail.py,sha256=3A355heAUkaGBmyKArq-3XVFunydlAZKkFRo8mHuH5w,9290
12
12
  agents/handoffs.py,sha256=onlvwSCTNJKof2Ftk-qZ5-zxTNT9AimjvyOcxj4Rp38,8999
13
- agents/items.py,sha256=kvhgsyKyIxkycUw33fKKX17SAQyIo4jGwyFLqgroB7I,8030
13
+ agents/items.py,sha256=DQPAJQkAVRR9Js-RVDtp4eizxiVaL30bbB0W-8U7GuQ,8069
14
14
  agents/lifecycle.py,sha256=wYFG6PLSKQ7bICKVbB8oGtdoJNINGq9obh2RSKlAkDE,2938
15
15
  agents/logger.py,sha256=p_ef7vWKpBev5FFybPJjhrCCQizK08Yy1A2EDO1SNNg,60
16
- agents/model_settings.py,sha256=lKYXNS6M6R7Ybku7o3sAfeyasXOctwHVRk3joYGe7Nk,1425
16
+ agents/model_settings.py,sha256=UqMgm_wuSjY7Mu6fsal9a8nbOUKJDYx957DxWfmYvB8,1426
17
17
  agents/result.py,sha256=vBLf6wUMIeCVcLKoaXLtxXZzmqK2QYRoba76uRCjAcs,8276
18
18
  agents/run.py,sha256=GLPPfHH7MswO_5oW27y7RsZVY5rbkvyCBxG4kbN5y-Q,37064
19
19
  agents/run_context.py,sha256=vuSUQM8O4CLensQY27-22fOqECnw7yvwL9U3WO8b_bk,851
20
20
  agents/stream_events.py,sha256=ULgBEcL_H4vklZoxhpY2yomeoxVF0UiXvswsFsjFv4s,1547
21
21
  agents/strict_schema.py,sha256=FEyEvF3ZjxIHRLmraBGZyjJjuFiPCZGaCFV22LlwaTQ,5783
22
- agents/tool.py,sha256=I6MD3H3wB9ka9FUOg6hlx9Swe9fceSnbH2BPMmNYXl0,10629
22
+ agents/tool.py,sha256=0WU0moxdIBnpbxM-iXpPZXZOd1tMX2f3X5E8qntVJ6U,10671
23
23
  agents/usage.py,sha256=-MZOmSDVdWxA2V_yVVnmUcwVcLdvYFccv0HXZ7Ow3_A,733
24
24
  agents/version.py,sha256=bkeg2DaYBS8OnV7R7J6OuF5pNA__0mJ4QZsJjC1DTI0,223
25
25
  agents/extensions/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
@@ -31,7 +31,7 @@ agents/models/fake_id.py,sha256=lbXjUUSMeAQ8eFx4V5QLUnBClHE6adJlYYav55RlG5w,268
31
31
  agents/models/interface.py,sha256=dgIlKyPaCbNRTHXxd6x7OQwJuAelG3F-C19P-aacHWQ,3129
32
32
  agents/models/openai_chatcompletions.py,sha256=pVAS0WnXhCUR1XK90KCDf985TaiWEkfkjgvdiOHamxU,37880
33
33
  agents/models/openai_provider.py,sha256=0F_tiftdpTx3mDj0fWzthjw8ZC91HAs1kHQs5oEYnDE,2295
34
- agents/models/openai_responses.py,sha256=PuUSByOvq7eeNLC3OWH8JUcvy8icy9ROxxv2O2-rGBQ,13167
34
+ agents/models/openai_responses.py,sha256=i8kZJyFcy-JvK8lIuS94-wRCNgp8niyQ-xiX6ygamrg,13171
35
35
  agents/tracing/__init__.py,sha256=pp2_mBCQGL9oN6_czCWHQsV4ZTEOcy1AVxdjQ41PNr0,2424
36
36
  agents/tracing/create.py,sha256=PAhfJKAeJ8jbZvxylTiikU_LqAhezYHphR4jG5EdaAE,12110
37
37
  agents/tracing/logger.py,sha256=J4KUDRSGa7x5UVfUwWe-gbKwoaq8AeETRqkPt3QvtGg,68
@@ -43,7 +43,7 @@ agents/tracing/span_data.py,sha256=UQUPpMQ7Z1XOqKFJNHUxAJUVPwa6JMfGa7dm_NovuhQ,4
43
43
  agents/tracing/spans.py,sha256=KWCqcRwUlt85NCZPQp98UIF5vAQAVWuVWQh3tgPK0WE,6605
44
44
  agents/tracing/traces.py,sha256=GL9EoEQKVk7eo0BcfRfQ6C7tdzlmPhkneQn4fdsCdqA,4774
45
45
  agents/tracing/util.py,sha256=BsDvn2rjE4SRQvfm55utljT8agdA0Z36KWXd1vdx4hs,392
46
- openai_agents-0.0.2.dist-info/METADATA,sha256=4usCZcGhHblA5qcC2MwN4ybHHdvfuC2wzqqos5xFBVo,6797
47
- openai_agents-0.0.2.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
48
- openai_agents-0.0.2.dist-info/licenses/LICENSE,sha256=E994EspT7Krhy0qGiES7WYNzBHrh1YDk3r--8d1baRU,1063
49
- openai_agents-0.0.2.dist-info/RECORD,,
46
+ openai_agents-0.0.3.dist-info/METADATA,sha256=opoAevRMlODIV-a359F0WHOV6CJI2vNzfazw4zYrF7A,7285
47
+ openai_agents-0.0.3.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
48
+ openai_agents-0.0.3.dist-info/licenses/LICENSE,sha256=E994EspT7Krhy0qGiES7WYNzBHrh1YDk3r--8d1baRU,1063
49
+ openai_agents-0.0.3.dist-info/RECORD,,