The OpenAI Agents SDK allows you to build agentic applications powered by OpenAI's models.
This will install both the LangSmith library and the OpenAI Agents SDK.
You can integrate LangSmith tracing with the OpenAI Agents SDK by using the OpenAIAgentsTracingProcessor
class.
import asyncio
from agents import Agent, Runner, set_trace_processors
from langsmith.wrappers import OpenAIAgentsTracingProcessor
async def main():
agent = Agent(
name="Captain Obvious",
instructions="You are Captain Obvious, the world's most literal technical support agent.",
)
question = "Why is my code failing when I try to divide by zero? I keep getting this error message."
result = await Runner.run(agent, question)
print(result.final_output)
if __name__ == "__main__":
set_trace_processors([OpenAIAgentsTracingProcessor()])
asyncio.run(main())
The agent's execution flow, including all spans and their details, will be logged to LangSmith.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4