Skip to content

Building AI agents, atomically

updating example imports

jon fox941caf98d0c1
diff --git a/atomic-examples/mcp-agent/example-client/example_client/main.py b/atomic-examples/mcp-agent/example-client/example_client/main.py
index 07b7e73..985ff6e 100644
--- a/atomic-examples/mcp-agent/example-client/example_client/main.py
+++ b/atomic-examples/mcp-agent/example-client/example_client/main.py
@@ -6,7 +6,7 @@ This file serves as a launcher that can run either the STDIO or SSE transport ve
import argparse
import sys
-from atomic_agents.lib.factories.tool_definition_service import MCPTransportType
+from atomic_agents.lib.factories import MCPTransportType
def main():
diff --git a/atomic-examples/mcp-agent/example-client/example_client/main_fastapi.py b/atomic-examples/mcp-agent/example-client/example_client/main_fastapi.py
index 7757d3e..d4d0a26 100644
--- a/atomic-examples/mcp-agent/example-client/example_client/main_fastapi.py
+++ b/atomic-examples/mcp-agent/example-client/example_client/main_fastapi.py
@@ -8,10 +8,8 @@ from dataclasses import dataclass
from fastapi import FastAPI, HTTPException
from pydantic import BaseModel, Field
-from atomic_agents.lib.factories.mcp_tool_factory import fetch_mcp_tools_async, MCPTransportType
-from atomic_agents.agents.base_agent import BaseIOSchema, BaseAgent, BaseAgentConfig
-from atomic_agents.lib.components.system_prompt_generator import SystemPromptGenerator
-from atomic_agents.lib.components.chat_history import ChatHistory
+from atomic_agents.lib.factories import fetch_mcp_tools_async, MCPTransportType
+from atomic_agents import BaseIOSchema, BaseAgent, BaseAgentConfig, ChatHistory, SystemPromptGenerator
import openai
import instructor
diff --git a/atomic-examples/mcp-agent/example-client/example_client/main_http.py b/atomic-examples/mcp-agent/example-client/example_client/main_http.py
index 473f732..07d22d5 100644
--- a/atomic-examples/mcp-agent/example-client/example_client/main_http.py
+++ b/atomic-examples/mcp-agent/example-client/example_client/main_http.py
@@ -2,17 +2,13 @@
HTTP Stream transport client for MCP Agent example.
Communicates with the server_http.py `/mcp` endpoint using HTTP GET/POST/DELETE for JSON-RPC streams.
"""
-
+from atomic_agents.lib.factories import fetch_mcp_tools, MCPTransportType
+from atomic_agents import BaseIOSchema, BaseAgent, BaseAgentConfig, ChatHistory, SystemPromptGenerator
import sys
-from atomic_agents.lib.factories.mcp_tool_factory import fetch_mcp_tools
-from atomic_agents.lib.factories.tool_definition_service import MCPTransportType
from rich.console import Console
from rich.table import Table
from rich.markdown import Markdown
from pydantic import Field
-from atomic_agents.agents.base_agent import BaseIOSchema, BaseAgent, BaseAgentConfig
-from atomic_agents.lib.components.system_prompt_generator import SystemPromptGenerator
-from atomic_agents.lib.components.chat_history import ChatHistory
import openai
import os
import instructor
diff --git a/atomic-examples/mcp-agent/example-client/example_client/main_sse.py b/atomic-examples/mcp-agent/example-client/example_client/main_sse.py
index 47fd444..b25e1f9 100644
--- a/atomic-examples/mcp-agent/example-client/example_client/main_sse.py
+++ b/atomic-examples/mcp-agent/example-client/example_client/main_sse.py
@@ -1,6 +1,6 @@
# pyright: reportInvalidTypeForm=false
-from atomic_agents.lib.factories.mcp_tool_factory import fetch_mcp_tools
-from atomic_agents.lib.factories.tool_definition_service import MCPTransportType
+from atomic_agents.lib.factories import fetch_mcp_tools, MCPTransportType
+from atomic_agents import BaseIOSchema, BaseAgent, BaseAgentConfig, ChatHistory, SystemPromptGenerator
from rich.console import Console
from rich.table import Table
from rich.markdown import Markdown
@@ -8,9 +8,6 @@ import openai
import os
import instructor
from pydantic import Field
-from atomic_agents.agents.base_agent import BaseIOSchema, BaseAgent, BaseAgentConfig
-from atomic_agents.lib.components.system_prompt_generator import SystemPromptGenerator
-from atomic_agents.lib.components.chat_history import ChatHistory
from typing import Union, Type, Dict
from dataclasses import dataclass
import re
diff --git a/atomic-examples/mcp-agent/example-client/example_client/main_stdio.py b/atomic-examples/mcp-agent/example-client/example_client/main_stdio.py
index e46f686..9294bc9 100644
--- a/atomic-examples/mcp-agent/example-client/example_client/main_stdio.py
+++ b/atomic-examples/mcp-agent/example-client/example_client/main_stdio.py
@@ -1,4 +1,6 @@
# pyright: reportInvalidTypeForm=false
+from atomic_agents.lib.factories import fetch_mcp_tools, MCPTransportType
+from atomic_agents import BaseIOSchema, BaseAgent, BaseAgentConfig, ChatHistory, SystemPromptGenerator
from rich.console import Console
from rich.table import Table
import openai
@@ -8,8 +10,6 @@ import asyncio
import shlex
from contextlib import AsyncExitStack
from pydantic import Field
-from atomic_agents.lib.factories import fetch_mcp_tools, MCPTransportType
-from atomic_agents import BaseIOSchema, BaseAgent, BaseAgentConfig, ChatHistory, SystemPromptGenerator
from typing import Union, Type, Dict, Optional
from dataclasses import dataclass
from mcp import ClientSession, StdioServerParameters
diff --git a/atomic-examples/mcp-agent/example-client/example_client/main_stdio_async.py b/atomic-examples/mcp-agent/example-client/example_client/main_stdio_async.py
index ab18c24..8bc1a8a 100644
--- a/atomic-examples/mcp-agent/example-client/example_client/main_stdio_async.py
+++ b/atomic-examples/mcp-agent/example-client/example_client/main_stdio_async.py
@@ -1,6 +1,6 @@
# pyright: reportInvalidTypeForm=false
-from atomic_agents.lib.factories.mcp_tool_factory import fetch_mcp_tools_async, MCPToolOutputSchema
-from atomic_agents.lib.factories.tool_definition_service import MCPTransportType
+from atomic_agents.lib.factories import fetch_mcp_tools_async, MCPToolOutputSchema, MCPTransportType
+from atomic_agents import BaseAgent, BaseAgentConfig, BaseIOSchema, SystemPromptGenerator, ChatHistory
from rich.console import Console
from rich.table import Table
import openai
@@ -10,9 +10,6 @@ import asyncio
import shlex
from contextlib import AsyncExitStack
from pydantic import Field
-from atomic_agents.agents.base_agent import BaseIOSchema, BaseAgent, BaseAgentConfig
-from atomic_agents.lib.components.system_prompt_generator import SystemPromptGenerator
-from atomic_agents.lib.components.chat_history import ChatHistory
from typing import Union, Type, Dict
from dataclasses import dataclass
from mcp import ClientSession, StdioServerParameters