fixing lint issues

This commit is contained in:
Dmitry Pimenov 2025-03-25 16:34:00 -07:00
parent 788b4faba6
commit 3587502c69
1 changed files with 4 additions and 4 deletions

View File

@ -1,10 +1,10 @@
import asyncio import asyncio
import os
import shutil import shutil
from agents import Agent, Runner, trace from agents import Agent, Runner, trace
from agents.mcp import MCPServer, MCPServerStdio from agents.mcp import MCPServer, MCPServerStdio
async def run(mcp_server: MCPServer, directory_path: str): async def run(mcp_server: MCPServer, directory_path: str):
agent = Agent( agent = Agent(
name="Assistant", name="Assistant",
@ -12,13 +12,13 @@ async def run(mcp_server: MCPServer, directory_path: str):
mcp_servers=[mcp_server], mcp_servers=[mcp_server],
) )
message = f"Who's the most frequent contributor?" message = "Who's the most frequent contributor?"
print("\n" + "-" * 40) print("\n" + "-" * 40)
print(f"Running: {message}") print(f"Running: {message}")
result = await Runner.run(starting_agent=agent, input=message) result = await Runner.run(starting_agent=agent, input=message)
print(result.final_output) print(result.final_output)
message = f"Summarize the last change in the repository." message = "Summarize the last change in the repository."
print("\n" + "-" * 40) print("\n" + "-" * 40)
print(f"Running: {message}") print(f"Running: {message}")
result = await Runner.run(starting_agent=agent, input=message) result = await Runner.run(starting_agent=agent, input=message)
@ -45,4 +45,4 @@ if __name__ == "__main__":
if not shutil.which("uvx"): if not shutil.which("uvx"):
raise RuntimeError("uvx is not installed. Please install it with `pip install uvx`.") raise RuntimeError("uvx is not installed. Please install it with `pip install uvx`.")
asyncio.run(main()) asyncio.run(main())