Skip to content

MCPVOT/mcpvotsagi

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

37 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MCPVotsAGI SDK

MCP integration SDK with agent orchestration, persistent memory, AI reasoning, and Darwin Gödel Machine evolution.

Install

pip install mcpvotsagi

With optional features:

pip install mcpvotsagi[trading]   # Solana trading support
pip install mcpvotsagi[ai]        # OpenAI integration
pip install mcpvotsagi[all]       # Everything

Quick Start

import asyncio
from mcpvotsagi import MCPVotsAGI, MCPVotsAGIConfig

async def main():
    config = MCPVotsAGIConfig(
        redis_host="localhost",
        redis_password="your-password",
    )

    async with MCPVotsAGI(config) as agi:
        # Store and retrieve memories
        await agi.memory.store("trade_1", {"action": "buy", "asset": "SOL", "price": 185.50})
        memory = await agi.memory.retrieve("trade_1")
        print(memory)

        # Search memories by category
        trades = await agi.memory.search_memories(category="trading")

        # AI reasoning
        result = await agi.reason("Should I buy SOL at current price?", task_type="trading")
        print(result)

        # System status
        status = await agi.status()
        print(status)

asyncio.run(main())

Configuration

All settings can be passed via MCPVotsAGIConfig or environment variables:

Env Variable Default Description
REDIS_HOST localhost Redis host
REDIS_PORT 6379 Redis port
REDIS_PASSWORD (empty) Redis password
A2A_PORT 8001 A2A gateway port
DEEPSEEK_PORT 3003 DeepSeek MCP server port
OLLAMA_HOST http://localhost:11434 Ollama API host
LOG_LEVEL INFO Logging level

API Reference

MCPVotsAGI

Main SDK client. Use as async context manager.

async with MCPVotsAGI() as agi:
    agi.memory    # EnhancedMCPMemoryServer
    agi.a2a       # A2AProtocolGateway
    agi.dgm       # UnifiedDGMServer

Methods:

  • await agi.start() — Initialize all services
  • await agi.stop() — Shut down all services
  • await agi.reason(prompt, task_type="general") — AI reasoning
  • await agi.status() — System health check

EnhancedMCPMemoryServer

Persistent key-value memory with Redis backend.

# Store
memory_id = await agi.memory.store("key", {"data": "value"}, category="trades")

# Retrieve
entry = await agi.memory.retrieve("key")

# Search by category
results = await agi.memory.search_memories(category="trades", limit=50)

# Delete
await agi.memory.delete("key")

# Stats
stats = await agi.memory.get_stats()

A2AProtocolGateway

Agent-to-agent communication via WebSocket.

gateway = agi.a2a
await gateway.start()

# Register an agent
await gateway.agent_registry.register_agent(AgentInfo(...))

# Discover agents
agents = await gateway.agent_registry.discover_agents(capability="trading")

UnifiedDGMServer

Darwin Gödel Machine evolution engine for self-improving programs.

dgm = agi.dgm
result = await dgm.evolve_program(program_id="strategy_1")

Architecture

┌──────────────────────────────────┐
│         MCPVotsAGI Client        │
├──────────┬──────────┬────────────┤
│  Memory  │   A2A    │    DGM     │
│ (Redis)  │ (WS:8001)│ (Evolution)│
├──────────┴──────────┴────────────┤
│          MCP Servers              │
│  ┌──────────┐  ┌───────────────┐ │
│  │ DeepSeek │  │   OpenCTI     │ │
│  │ (Ollama) │  │ (Threat Intel)│ │
│  └──────────┘  └───────────────┘ │
└──────────────────────────────────┘

Development

git clone https://github.com/MCPVOT/mcpvotsagi.git
cd mcpvotsagi
pip install -e ".[dev]"

# Lint
ruff check src/mcpvotsagi/

# Test
pytest

# Type check
mypy src/mcpvotsagi/

License

MIT

About

Model Context Protocol integration suite with voting mechanisms and agent orchestration.

Topics

Resources

License

Contributing

Stars

Watchers

Forks

Packages

 
 
 

Contributors