Skip to content

nydiokar/ai-chat

Repository files navigation

Discord bot with MCP capabilities

A comprehensive system that combines AI capabilities, cryptocurrency token tracking, and advanced task management. Built with a modular architecture using the Model Context Protocol (MCP) for extensible tool integration.

Core Features

πŸ€– AI Integration

  • Multiple AI model support (OpenAI, Ollama)
  • Context-aware interactions
  • Memory management system
  • Dynamic prompt generation

πŸ’Ž Token Tracking

  • Real-time cryptocurrency monitoring
  • Market cap and price tracking
  • Trend detection and alerts
  • Category-based organization

⚑ Task Management

  • Advanced task scheduling
  • Dependency management
  • Progress visualization
  • Automated notifications

πŸ”Œ Tool Integration

  • Dynamic MCP server integration
  • Extensible tool system
  • GitHub-based tool discovery
  • Resource management

System Architecture

Core Services

  • AI Service: Model integration and context management
  • Memory System: Long-term conversation memory
  • Cache System: Performance optimization
  • Performance Monitoring: System health and metrics

Features

  • Hot Tokens: Cryptocurrency tracking and analysis
  • Pulse MCP: Tool and server management
  • Task System: Scheduling and dependency handling

Integration

  • Discord Bot: User interface and notifications
  • Database: Prisma-based data persistence
  • GitHub: Tool discovery and integration

Technical Stack

  • Runtime: Node.js (v16+)
  • Language: TypeScript
  • Database: Prisma with SQL
  • Testing: Mocha
  • Process Management: PM2

Prerequisites

  • Node.js (v16 or higher)
  • Discord Bot Token
  • Database (supported by Prisma)
  • API Keys for AI services

Environment Setup

Create a .env.development or .env.production file:

# Core Configuration
INSTANCE_ID=development
NODE_ENV=development

# AI Services
OPENAI_API_KEY=your_openai_key
OLLAMA_HOST=http://127.0.0.1:11434

# Discord Integration
DISCORD_TOKEN=your_discord_bot_token

# Database
DATABASE_URL=your_database_url

# Optional Settings
DEBUG=true

Getting Started

  1. Installation

    git clone [repository-url]
    cd them
    npm install
  2. Database Setup

    npx prisma generate
    npx prisma migrate dev
  3. Running the System

    Development:

    ./start-dev.bat

    Production:

    ./start-prod.bat

    Using PM2:

    pm2 start ecosystem.config.cjs

Development

Testing

npm test

Linting

npm run lint

Project Structure

src/
β”œβ”€β”€ features/          # Core feature implementations
β”œβ”€β”€ services/         # Shared services
β”œβ”€β”€ tasks/           # Task management system
β”œβ”€β”€ tools/           # Tool integration
β”œβ”€β”€ types/           # Type definitions
└── utils/           # Utility functions

Documentation

For detailed documentation, please refer to the /docs directory:

Core Documentation

Feature Documentation

Service Documentation

Contributing

  1. Fork the repository
  2. Create a feature branch
  3. Commit your changes
  4. Push to your branch
  5. Create a Pull Request

License

About

LLM engine with MCP capabilities and Discord interface

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •