You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
# This project provides a Python SDK for building multi-agent workflows.
74
+
#Output: "This project provides a Python SDK for building multi-agent workflows."
79
75
```
80
76
81
77
(_If running this, ensure you set the `OPENAI_API_KEY` environment variable_)
82
78
79
+
## Run an agent without a sandbox
80
+
81
+
You can still use a regular `Agent` when your workflow does not need a filesystem workspace or sandbox lifecycle.
82
+
83
+
```python
84
+
from agents import Agent, Runner
85
+
86
+
agent = Agent(name="Assistant", instructions="You are a helpful assistant")
87
+
88
+
result = Runner.run_sync(agent, "Write a haiku about recursion in programming.")
89
+
print(result.final_output)
90
+
91
+
# Code within the code,
92
+
# Functions calling themselves,
93
+
# Infinite loop's dance.
94
+
```
95
+
83
96
(_For Jupyter notebook users, see [hello_world_jupyter.ipynb](https://github.com/openai/openai-agents-python/blob/main/examples/basic/hello_world_jupyter.ipynb)_)
84
97
85
98
Explore the [examples](https://github.com/openai/openai-agents-python/tree/main/examples) directory to see the SDK in action, and read our [documentation](https://openai.github.io/openai-agents-python/) for more details.
0 commit comments