# Devil Agent Ai Platform

> 🔥 Devil Agent — Autonomous AI Engineering Platform · 40-word zero-knowledge auth · OpenAI-compatible agent · NEXUS engineering OS · MCP server · self-hostable · MIT

- **Type:** MCP server
- **Install:** `agentstack add mcp-vikrant-project-devil-agent-ai-platform`
- **Verified:** Yes — security-reviewed for prompt injection and unsafe behavior
- **Seller:** [vikrant-project](https://agentstack.voostack.com/s/vikrant-project)
- **Installs:** 0
- **Category:** [Databases](https://agentstack.voostack.com/c/databases)
- **Latest version:** 0.1.0
- **License:** MIT
- **Upstream author:** [vikrant-project](https://github.com/vikrant-project)
- **Source:** https://github.com/vikrant-project/devil-agent-ai-platform

## Install

```sh
agentstack add mcp-vikrant-project-devil-agent-ai-platform
```

Requires the [AgentStack CLI](https://agentstack.voostack.com/docs/cli). Works with Claude Code, Cursor, and any MCP-compatible agent.

## About

# ⚡ Devil Agent — Autonomous AI Engineering Operating System

**🔥 The World's Most Advanced Autonomous AI Agent Platform**

Built with NEXUS OS Framework | Agent Core | MCP Server Architecture

[Features](#-revolutionary-features) • [Quick Start](#-quick-start) • [Architecture](#-architecture) • [Deployment](#-deployment) • [Contributing](#-contributing)

---

## 🌟 Why Choose Devil Agent?

Devil Agent isn't just another AI assistant — it's a **fully autonomous engineering operating system** that combines cutting-edge AI capabilities with production-grade reliability. Here's what makes it truly unique:

### 🚀 **Unmatched Capabilities**

- **100% Autonomous Operation** — Self-directed planning, execution, and verification
- **Multi-Layer Reasoning** — Strategic, Tactical, Execution, and Sentinel layers running in parallel
- **Zero Regression Guarantee** — Automated snapshots and rollbacks for every change
- **Enterprise-Grade Security** — OWASP compliance, CVE scanning, and zero-trust architecture
- **Real-Time Learning** — Continuous self-improvement through failure pattern analysis

### 💎 **Rare Features No One Else Has**

1. **NEXUS Autonomous Engineering System**
   - 4-layer cognitive architecture (Strategic → Tactical → Execution → Sentinel)
   - Self-healing infrastructure with automatic remediation
   - Quantum-ready cryptographic assessment
   - Probabilistic release readiness scoring

2. **Agent Core Skill Library**
   - 100+ pre-built specialized skills (Finance, Research, Web Dev, Data Analysis)
   - Anthropic-authored professional skills (PowerPoint, Excel, Financial Modeling)
   - Dynamic skill injection and hot-swapping
   - Custom skill development framework

3. **MCP (Model Context Protocol) Server**
   - Universal AI model integration layer
   - Support for Claude, GPT-4, Gemini, and custom models
   - Context-aware model switching
   - Built-in rate limiting and cost optimization

4. **Production-Ready Full-Stack Platform**
   - React 19 + TypeScript frontend with shadcn/ui
   - FastAPI backend with async/await patterns
   - MongoDB for persistent storage
   - WebSocket real-time communication
   - Key-based authentication (40-word secret keys)

5. **Advanced Security Features**
   - No username/password — only cryptographic secret keys
   - Zero-knowledge architecture
   - Automatic secret detection and rotation
   - Supply chain security (SBOM + provenance)
   - Compliance automation (SOC2, GDPR, HIPAA ready)

6. **Self-Improving AI**
   - Failure pattern library that learns from mistakes
   - Performance regression detection
   - Knowledge staleness tracking
   - Capability gap logging for future improvements

---

## 📚 Table of Contents

- [Revolutionary Features](#-revolutionary-features)
- [Quick Start](#-quick-start)
- [Architecture](#-architecture)
- [Installation](#-installation)
- [Configuration](#-configuration)
- [Usage](#-usage)
- [MCP Server](#-mcp-server)
- [Agent Core Skills](#-agent-core-skills)
- [NEXUS OS](#-nexus-os-framework)
- [Security](#-security)
- [Deployment](#-deployment)
- [API Documentation](#-api-documentation)
- [Contributing](#-contributing)
- [Troubleshooting](#-troubleshooting)
- [License](#-license)
- [Tags](#-tags)

---

## 🎯 Revolutionary Features

### Core Platform Features

| Feature | Description | Status |
|---------|-------------|--------|
| **Autonomous Planning** | Multi-step task decomposition with dependency graphs | ✅ Production |
| **Self-Healing** | Automatic error detection and recovery | ✅ Production |
| **Zero Downtime Deploys** | Blue-green + canary deployment strategies | ✅ Production |
| **Real-Time Monitoring** | Live metrics, logs, and performance tracking | ✅ Production |
| **Cost Optimization** | Automatic rightsizing and resource optimization | ✅ Production |
| **Security Scanning** | Continuous CVE monitoring and patching | ✅ Production |
| **Chaos Engineering** | Automated resilience testing | 🚧 Beta |
| **Quantum Readiness** | Post-quantum cryptography migration | 📋 Planned |

### AI/ML Capabilities

- **Multi-Model Support**: Claude Opus 4.5, GPT-5.2, Gemini 3 Pro
- **Function Calling**: Advanced tool use and API integration
- **RAG (Retrieval Augmented Generation)**: Semantic codebase search
- **Code Generation**: Context-aware code synthesis
- **Test Generation**: Automatic unit + integration test creation
- **Documentation Generation**: Auto-generated API docs and guides

### Developer Experience

- **Hot Reload**: Frontend and backend auto-reload on changes
- **Type Safety**: Full TypeScript support with strict mode
- **Linting**: ESLint + Prettier with auto-fix
- **Testing**: Jest + React Testing Library + Playwright
- **CI/CD**: GitHub Actions workflows included
- **Docker Support**: Multi-stage builds with optimization

---

## 🚀 Quick Start

### Prerequisites

- **Node.js** 18+ and **npm/yarn**
- **Python** 3.9+ and **pip**
- **MongoDB** 5.0+
- **Redis** 6.0+ (optional, for caching)
- **Git**

### One-Command Installation

```bash
# Clone the repository
git clone https://github.com/vikrant-project/devil-agent-ai-platform.git
cd devil-agent-ai-platform

# Run the automated setup script
chmod +x setup.sh
./setup.sh
```

### Manual Installation

#### 1. Backend Setup

```bash
cd backend

# Create virtual environment
python3 -m venv venv
source venv/bin/activate  # On Windows: venv\Scripts\activate

# Install dependencies
pip install -r requirements.txt

# Copy environment variables
cp .env.example .env

# Edit .env and add your configuration
nano .env
```

#### 2. Frontend Setup

```bash
cd frontend

# Install dependencies
npm install
# or
yarn install

# Copy environment variables
cp .env.example .env

# Edit .env and add your configuration
nano .env
```

#### 3. Database Setup

```bash
# Start MongoDB
sudo systemctl start mongod

# Or use Docker
docker run -d -p 27017:27017 --name mongodb mongo:latest
```

#### 4. Start the Application

```bash
# Terminal 1 - Backend
cd backend
source venv/bin/activate
python server.py

# Terminal 2 - Frontend
cd frontend
npm start
```

Visit `http://localhost:3000` 🎉

---

## 🏗️ Architecture

### System Overview

```
┌─────────────────────────────────────────────────────────────┐
│                        Devil Agent Platform                  │
├─────────────────────────────────────────────────────────────┤
│                                                               │
│  ┌──────────────┐     ┌──────────────┐     ┌──────────────┐│
│  │   Frontend   │────▶│   Backend    │────▶│   MongoDB    ││
│  │  React + TS  │     │   FastAPI    │     │              ││
│  └──────────────┘     └──────────────┘     └──────────────┘│
│         │                     │                              │
│         │                     ▼                              │
│         │              ┌──────────────┐                      │
│         │              │  MCP Server  │                      │
│         │              └──────────────┘                      │
│         │                     │                              │
│         │                     ▼                              │
│         │              ┌──────────────┐                      │
│         └─────────────▶│  Agent Core  │                      │
│                        │  (Skills)    │                      │
│                        └──────────────┘                      │
│                                                               │
│                        ┌──────────────┐                      │
│                        │  NEXUS OS    │                      │
│                        │  Framework   │                      │
│                        └──────────────┘                      │
└─────────────────────────────────────────────────────────────┘
```

### Technology Stack

**Frontend:**
- React 19 with TypeScript
- Tailwind CSS + shadcn/ui components
- React Router v7 for routing
- Axios for API communication
- Lucide React for icons
- Recharts for data visualization

**Backend:**
- FastAPI (Python 3.9+)
- Motor (Async MongoDB driver)
- Pydantic for validation
- JWT authentication
- bcrypt for password hashing
- emergentintegrations for AI models

**Infrastructure:**
- MongoDB 5.0+
- Redis (optional caching)
- Nginx (reverse proxy)
- PM2 (process management)
- Docker & Docker Compose

---

## 🔧 Installation

### Development Environment

```bash
# Install all dependencies
npm run install:all

# Start development servers
npm run dev

# Run tests
npm run test

# Build for production
npm run build
```

### Production Deployment

```bash
# Build optimized bundles
npm run build:prod

# Start with PM2
pm2 start ecosystem.config.js
```

---

## ⚙️ Configuration

### Environment Variables

#### Backend (.env)

```env
# Server Configuration
PORT=8000
HOST=0.0.0.0
ENV=production

# Database
MONGO_URL=mongodb://localhost:27017
DB_NAME=devil_agent_db

# Security
SECRET_KEY=your-super-secret-key-change-this-in-production
JWT_ALGORITHM=HS256
ACCESS_TOKEN_EXPIRE_MINUTES=60

# AI Models (Optional)
OPENAI_API_KEY=sk-...
ANTHROPIC_API_KEY=sk-ant-...
GOOGLE_API_KEY=...

# Redis (Optional)
REDIS_URL=redis://localhost:6379

# CORS
CORS_ORIGINS=http://localhost:3000,https://YOUR_DOMAIN_HERE
```

#### Frontend (.env)

```env
# API Configuration
REACT_APP_API_URL=https://YOUR_DOMAIN_HERE
REACT_APP_WS_URL=wss://YOUR_DOMAIN_HERE/ws

# Feature Flags
REACT_APP_ENABLE_MCP=true
REACT_APP_ENABLE_NEXUS=true
REACT_APP_DEBUG_MODE=false
```

### Agent Core Configuration

Edit `agent_core/DEVIL_AGENT_CONFIG.md` to customize:
- Available skills
- Model preferences
- Tool permissions
- Safety constraints

---

## 📖 Usage

### Basic Usage

```python
from agent_core import DevilAgent

# Initialize agent
agent = DevilAgent(
    model="claude-opus-4.5",
    skills=["research", "coding", "finance"]
)

# Run autonomous task
result = agent.execute(
    task="Build a full-stack web app with user authentication",
    constraints={
        "timeline": "2 hours",
        "budget": "$0",
        "security": "high"
    }
)

print(result.summary)
print(result.artifacts)
```

### Advanced Usage

```python
# Multi-agent orchestration
orchestrator = AgentOrchestrator()

orchestrator.spawn_agents([
    ("architect", ArchitectAgent()),
    ("builder", BuilderAgent()),
    ("tester", TesterAgent()),
    ("security", SecurityAgent())
])

result = orchestrator.execute_workflow(
    task_graph=build_task_graph(),
    parallel_execution=True,
    max_retries=3
)
```

---

## 🔌 MCP Server

The Model Context Protocol (MCP) server provides a universal interface for AI model integration.

### Starting MCP Server

```bash
cd agent_core
./start-gateway.sh
```

### MCP Endpoints

- `POST /v1/chat/completions` - Chat completion
- `POST /v1/embeddings` - Generate embeddings
- `GET /v1/models` - List available models
- `POST /v1/tools/execute` - Execute a tool/function

### Supported Models

| Provider | Models | Status |
|----------|--------|--------|
| Anthropic | Claude Opus 4.5, Sonnet 4.5, Haiku 4.5 | ✅ |
| OpenAI | GPT-5.2, GPT-4o, GPT-4 Turbo | ✅ |
| Google | Gemini 3 Pro, Gemini 3 Flash | ✅ |
| Custom | Your fine-tuned models | ✅ |

---

## 🎓 Agent Core Skills

Agent Core includes 100+ specialized skills across multiple domains:

### Finance Skills
- **3-Statement Financial Model** - Build integrated P&L, Balance Sheet, Cash Flow
- **DCF Valuation** - Discounted Cash Flow analysis with sensitivity tables
- **LBO Model** - Leveraged Buyout modeling
- **Comps Analysis** - Comparable company analysis
- **Merger Model** - M&A accretion/dilution analysis
- **Excel Author** - Generate complex Excel spreadsheets
- **PowerPoint Author** - Create professional presentations

### Research Skills
- **Parallel CLI** - Run multiple research queries in parallel
- **Darwinian Evolver** - Evolve solutions through genetic algorithms
- **Web Scraper** - Extract structured data from websites
- **Literature Search** - Search academic papers and publications

### Web Development Skills
- **Page Agent** - Build full web pages from descriptions
- **Component Generator** - Create React/Vue/Angular components
- **API Designer** - Design RESTful APIs with OpenAPI specs

### Productivity Skills
- **Document Converter** - Convert between formats (PDF, DOCX, MD)
- **Data Analyzer** - Analyze CSV/Excel data
- **Image Processor** - Resize, crop, optimize images

### Adding Custom Skills

```python
# Create a new skill
from agent_core.skills import BaseSkill

class MyCustomSkill(BaseSkill):
    name = "my-custom-skill"
    description = "Does something amazing"
    
    def execute(self, params):
        # Your logic here
        return result

# Register the skill
agent_core.register_skill(MyCustomSkill())
```

---

## 🧠 NEXUS OS Framework

NEXUS is the autonomous operating system that powers Devil Agent's decision-making.

### Four Cognitive Layers

1. **Strategic Mind** - Long-term planning and architecture
2. **Tactical Mind** - Task decomposition and sequencing
3. **Execution Engine** - Direct action and implementation
4. **Sentinel** - Continuous verification and security

### Core Principles

- **Autonomy First** - Default to autonomous execution
- **Evidence-Based Completion** - Tasks are "done" only with proof
- **Zero Regression** - Automated rollback on degradation
- **Minimum Footprint** - Only install what's needed
- **Security by Default** - OWASP Top 10 compliance

### NEXUS Features

- Autonomous code refactoring
- Self-healing deployments
- Predictive technical debt tracking
- Continuous threat modeling
- Real-time cost optimization

See [NEXUS_QUICK_START.md](NEXUS_QUICK_START.md) for detailed documentation.

---

## 🔐 Security

### Key-Based Authentication

Devil Agent uses a unique 40-word secret key system instead of traditional username/password:

**Benefits:**
- 🔒 **Unhackable** - 256-bit entropy, impossible to brute force
- 🚫 **No Phishing** - Keys can't be phished like passwords
- 🔑 **One Key** - Single key for all services
- 💾 **Offline Storage** - Store in password manager or encrypted file

**Creating an Account:**
1. Visit `/signup`
2. Click "Generate My Secret Key"
3. **CRITICAL**: Save the 40-word key immediately (it's shown only once!)
4. Store in password manager (1Password, LastPass, Bitwarden)
5. Use key to login at `/login`

### Security Features

- **Automatic Secret Scanning** - Detects secrets in code/logs
- **CVE Monitoring** - Real-time vulnerability detection
- **Zero-Trust Architecture** - Every service-to-service call is authenticated
- **Audit Logging** - Tamper-proof logs with cryptographic signatures
- **Compliance** - SOC2, GDPR, HIPAA ready out of the box

### Responsible Disclosure

Found a security issue? Please email: security@YOUR_DOMAIN_HERE

**Do NOT** open a public GitHub issue for security vulnerabilities.

---

## 🚀 Deployment

### VPS Deployment (Ubuntu 22.04)

```bash
# 1. SSH into your VPS
ssh -i YOUR_PEM_KEY_HERE ubuntu@YOUR_VPS_IP_HERE

# 2. Clone repository
git clone https://github.com/vikrant-project/devil-agent-ai-platform.git
cd devil-agent-ai-platform

# 3. Run deployment script
chmod +x deploy.sh
./deploy.sh production

# 4. Configure Nginx
sudo cp nginx.conf /etc/nginx/sites-available/devil-agent
sudo ln -s /etc/nginx/sites-available/devil-agent /etc/nginx/sites-enabled/
sudo nginx -t && sudo systemctl reload nginx

# 5. Setup SSL with Let's Encrypt
sudo certbot --nginx -d YOUR_DOMAIN_HERE
```

### Docker Deployment

```bash
# Build and run with Docker Compose
docker-compose up -d

# View logs
docker-compose logs -f

# Stop services
docker-compose down
```

### Cloud Platforms

**AWS**:
- EC2 + RDS + S3
- Elastic Beanstalk
- ECS + Fargate

**Google Cloud**:
- Compute Engine + Cloud SQL
- App Engine
- Cloud Run

**Azure**:
- Virtual Machines + Cosmos DB
- App Service
- Container Instances

See [docs/DEPLOYMENT_SUMMARY.md](docs/DEPLOYMENT_SUMMARY.md) for platform-specific guides.

---

## 📡 API Documentation

### Authenti

…

## Source & license

This open-source MCP server is cataloged on AgentStack and links to its original source — we do not rehost the code.

- **Author:** [vikrant-project](https://github.com/vikrant-project)
- **Source:** [vikrant-project/devil-agent-ai-platform](https://github.com/vikrant-project/devil-agent-ai-platform)
- **License:** MIT

Install and usage instructions live in the source repository linked above.

## Pricing

- **Free** — Free

## Security capabilities

Automated source analysis of v0.1.0 — what this tool can access:

- **Network access:** yes
- **Filesystem access:** no
- **Shell / process execution:** no
- **Environment & secrets:** yes
- **Dynamic code execution:** no

*"Yes" means the capability is present in the source — more access means more to trust, not that it is unsafe.*


## Versions

- **0.1.0** — security scan: passed — Imported from the upstream source.

## Links

- Listing page: https://agentstack.voostack.com/l/mcp-vikrant-project-devil-agent-ai-platform
- Seller: https://agentstack.voostack.com/s/vikrant-project
- Browse the marketplace: https://agentstack.voostack.com/browse

---
Listed on AgentStack — the marketplace for AI agent skills and MCP servers. Every listing is security-reviewed. Creators keep 70%.
