Purposeful Agent Orchestration System
"He who has a why to live can bear almost any how." - Friedrich Nietzsche
TELOSCRIPT is a sophisticated agent orchestration platform that coordinates MCP (Model Context Protocol) servers toward any goal you can think of. Unlike chat-based MCP implementations, TELOSCRIPT empowers fully autonomous goal resolution by seamlessly orchestrating your provided MCP servers into a purposeful, coordinated system.
- Python 3.12+
- Docker & Docker Compose
- Node.js 18+ (for MCP servers)
- Clone the repository
git clone https://github.com/calumjs/teloscript
cd teloscript
- Install dependencies
pip install -r requirements.txt
- Start the system
# Development mode
python main.py
# Production with Docker
docker-compose up -d
- Access the orchestration interface
- Primary Interface: http://localhost:8000/dashboard/test
- API Documentation: http://localhost:8000/docs
- Health Check: http://localhost:8000/health
The web interface provides real-time agent monitoring, configuration management, and an intuitive way to launch agents with visual feedback.
TELOSCRIPT can also run as an MCP (Model Context Protocol) server, allowing other MCP clients (like Claude Desktop, Continue, or other AI tools) to access TELOSCRIPT's agent orchestration capabilities.
Pros:
- β Instant setup - No local installation required
- β Isolated environment - No conflicts with system packages
- β Always latest - Pulls from GitHub automatically
- β Zero maintenance - uvx handles dependencies
Cons:
- β Default configs only - Can't access custom
config/mcp_configs.json
- β Limited customization - Uses built-in MCP server configurations
- β Network required - Downloads package each time
# Run directly with uvx (no installation needed)
uvx --from git+https://github.com/calumjs/teloscript.git teloscript-mcp
Pros:
- β
Full customization - Access to your
config/mcp_configs.json
andconfig/purpose_endpoints.json
- β Custom MCP servers - Use your configured Brave Search keys, GitHub tokens, etc.
- β Development workflow - Make changes and test immediately
- β Offline capable - Works without internet after installation
Cons:
- β Setup required - Need to install dependencies locally
- β Environment management - Need to maintain Python environment
# Clone and install locally
git clone https://github.com/calumjs/teloscript.git
cd teloscript
git checkout feature/mcp-server
pip install -e .
# Run the MCP server
teloscript-mcp
Once the MCP server is running, configure your MCP client:
Add to your claude_desktop_config.json
:
{
"mcpServers": {
"teloscript-mcp": {
"command": "teloscript-mcp",
"env": {
"OPENAI_API_KEY": "your-openai-api-key-here"
}
}
}
}
{
"mcpServers": {
"teloscript-mcp": {
"command": "uvx",
"args": [
"--from",
"git+https://github.com/calumjs/teloscript.git@feature/mcp-server",
"teloscript-mcp"
],
"env": {
"OPENAI_API_KEY": "your-openai-api-key-here"
}
}
}
}
When running as an MCP server, TELOSCRIPT provides these tools to MCP clients:
Tool | Description |
---|---|
launch_agent |
Launch an agent with a specific goal |
get_agent_status |
Check the status of a running agent |
get_agent_result |
Get the final result from a completed agent |
cancel_agent |
Cancel a running agent |
list_agents |
List all active agents |
get_available_servers |
List available MCP server configurations |
# Ask Claude (or other MCP client):
"Use the teloscript MCP server to launch an agent that researches the latest AI news and saves it to a file"
# The client will automatically:
# 1. Call launch_agent with your goal
# 2. Monitor progress with get_agent_status
# 3. Retrieve results with get_agent_result
# 4. Present the final outcome to you
Aspect | uvx Method | Local Method |
---|---|---|
MCP Servers | Built-in defaults only | Your custom config/mcp_configs.json |
API Keys | Must be provided via MCP client env | Can use your local config files |
Purpose Endpoints | Default examples only | Your custom config/purpose_endpoints.json |
File Access | Limited to uvx cache directory | Full access to your local filesystem |
Performance | Slightly slower (downloads each time) | Faster (local installation) |
Updates | Automatic (always latest from GitHub) | Manual (git pull required) |
MCP Server Won't Start:
# Check if ports are available
netstat -an | find "8000"
# Test with no auto-start (uvx method)
uvx --from git+https://github.com/calumjs/teloscript.git@feature/mcp-server teloscript-mcp --no-auto-start
# Check logs (local method)
teloscript-mcp --log-level DEBUG
MCP Client Can't Connect:
- Ensure your MCP client configuration is correct
- Check that the OPENAI_API_KEY environment variable is set
- Verify the teloscript-mcp command is in your PATH (local method)
Limited Functionality (uvx method):
- This is expected - uvx uses default configurations only
- Switch to local method for full customization
curl -X POST http://localhost:8000/agents \
-H "Content-Type: text/plain" \
-d "Write a Nietzschean aphorism about automating the achievement of goals"
curl -X POST http://localhost:8000/agents \
-H "Content-Type: application/json" \
-d '{
"goal": "Research Python async patterns and save findings to a report",
"servers": [
{
"name": "brave-search",
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-brave-search"],
"env": {"BRAVE_API_KEY": "your-api-key"},
"transport": "stdio"
},
{
"name": "filesystem",
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-filesystem", "."],
"transport": "stdio"
}
],
"max_iterations": 15,
"timeout": 300
}'
TELOSCRIPT implements a distributed coordination model where agents maintain autonomy while working toward shared objectives:
βββββββββββββββββββ βββββββββββββββββββ βββββββββββββββββββ
β MCP Agent A β β MCP Agent B β β MCP Agent C β
β (Filesystem) β β (Web Search) β β (GitHub) β
βββββββββββ¬ββββββββ βββββββββββ¬ββββββββ βββββββββββ¬ββββββββ
β β β
ββββββββββββββββ¬βββββββββββββββββββββββββββββββ
β
βββββββββββΌββββββββ
β TELOSCRIPT β
β Orchestrator β
β (Coordination β
β Engine) β
βββββββββββββββββββ
- Orchestrator: Central coordination engine that manages agent interactions
- MCP Agents: Specialized agents handling specific domains (files, web, APIs, etc.)
- Orchestration Interface: Real-time monitoring and control interface
- API Gateway: RESTful interface for external integrations
- Configuration Manager: Dynamic agent and system configuration
teloscript/
βββ src/
β βββ api.py # FastAPI application & orchestration endpoints
β βββ orchestrator.py # Agent coordination and goal management
β βββ mcp_agent.py # Individual agent implementation
β βββ models.py # Data models & API schemas
β βββ utils/ # Utility functions and helpers
βββ config/
β βββ mcp_configs.json # MCP server configurations
β βββ system_config.yaml # System-wide settings
βββ scripts/
β βββ startup.sh # System initialization
β βββ preload-mcps.sh # MCP server preloading
βββ docker-compose.yml # Container orchestration
βββ Dockerfile # Container definition
βββ nginx.conf # Reverse proxy configuration
βββ requirements.txt # Python dependencies
βββ main.py # Application entry point
TELOSCRIPT uses a flexible configuration system for MCP servers:
{
"filesystem": {
"name": "Filesystem Server",
"description": "Access and manipulate files in the project directory",
"config": {
"name": "filesystem",
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-filesystem", "."],
"transport": "stdio"
},
"capabilities": ["read", "write", "search", "monitor"]
},
"brave-search": {
"name": "Brave Search",
"description": "Web search capabilities using Brave Search API",
"config": {
"name": "brave-search",
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-brave-search"],
"transport": "stdio"
},
"capabilities": ["search", "summarize"],
"requires_api_key": true
}
}
You only need to specify your OpenAI API key to use Teloscript orchestrator - obviously individual MCP servers may require their own configuration.
OPENAI_API_KEY=your-open-ai-api-key
Method | Endpoint | Description |
---|---|---|
POST |
/agents |
Launch agent with goal (text or JSON) |
POST |
/agents/launch |
Launch agent with UI-selected MCP configs |
GET |
/agents/{id}/status |
Get agent execution status |
GET |
/agents/{id}/stream |
Stream real-time agent updates |
DELETE |
/agents/{id} |
Cancel running agent |
DELETE |
/agents |
Cancel all running agents |
GET |
/agents |
List all active agents |
Method | Endpoint | Description |
---|---|---|
GET |
/mcp-configs |
List all MCP configurations |
GET |
/mcp-configs/{id} |
Get specific MCP configuration |
GET |
/mcp-configs/info |
Get configuration file information |
POST |
/mcp-configs |
Create new MCP configuration |
PUT |
/mcp-configs/{id} |
Update existing configuration |
DELETE |
/mcp-configs/{id} |
Remove configuration |
POST |
/mcp-configs/reload |
Reload configurations from file |
Method | Endpoint | Description |
---|---|---|
GET |
/dashboard |
Get orchestration state |
GET |
/dashboard/stream |
Stream real-time orchestration updates |
GET |
/dashboard/test |
Web orchestration interface |
GET |
/health |
System health check |
GET |
/ |
API information |
Method | Endpoint | Description |
---|---|---|
GET |
/examples/mcp-config |
Example MCP configurations |
GET |
/examples/request |
Example agent request format |
# Start all services
docker-compose up
# Watch logs
docker-compose logs -f teloscript
# Production deployment with scaling
docker-compose --profile production up -d
# Scale specific services
docker-compose up -d --scale teloscript=3
The production profile includes:
- Nginx reverse proxy with SSL termination
- Optimized container configurations
- Health checks and automatic restart policies
- Persistent logging and configuration storage
- Resource limits and monitoring
- Container Security: Runs as non-privileged user with minimal permissions
- Network Isolation: Services communicate through isolated Docker networks
- Input Validation: All API inputs are validated and sanitized
- API Rate Limiting: Built-in rate limiting to prevent abuse
- Secret Management: Environment variables for sensitive configuration
- Audit Logging: Comprehensive logging of all agent activities
We welcome contributions that align with TELOSCRIPT's philosophy of purposeful technology:
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature
) - Commit changes with clear, purposeful messages
- Test your changes thoroughly
- Push to your branch (
git push origin feature/amazing-feature
) - Open a Pull Request with detailed description
- Follow PEP 8 style guidelines
- Write comprehensive tests for new features
- Document new functionality clearly
- Ensure Docker compatibility
Agents Not Starting
- Check MCP server configurations in
config/mcp_configs.json
- Verify Node.js and npm are installed
- Check system logs:
docker-compose logs teloscript
Orchestration Interface Not Loading
- Ensure port 8000 is available
- Check nginx configuration
- Verify WebSocket connections are allowed
- Manus: For the original idea - see Manus.im
- Model Context Protocol (MCP): Foundation for agent communication standards
- FastAPI: Modern, fast Python web framework powering our API
- Docker: Containerization platform enabling seamless deployment
TELOSCRIPT - Where purpose meets autonomous coordination