diff --git a/docs/AGENT_CREATION.md b/docs/AGENT_CREATION.md index 49b5184..b3ff4ac 100644 --- a/docs/AGENT_CREATION.md +++ b/docs/AGENT_CREATION.md @@ -1,80 +1,55 @@ # Agent Creation Guide -This guide provides comprehensive instructions for adding new agents to the Quantum Tasks AI platform. +Modern guide for adding new agents to the Quantum Tasks AI platform using the streamlined file-based system. ## Overview -Quantum Tasks AI supports **TWO DISTINCT AGENT SYSTEMS**: +Quantum Tasks AI uses a **simple file-based agent system**: +1. Create JSON configuration file +2. Commit to git +3. Agent appears in marketplace automatically -- **Webhook Agents** - N8N integrations for complex processing with dynamic forms -- **Direct Access Agents** - External form services (JotForm, Google Forms) with embedded interfaces +**Two Agent Types:** +- **Webhook Agents** - N8N integrations with dynamic forms +- **Direct Access Agents** - External forms (JotForm, etc.) with payment processing -**⚡ RECOMMENDED APPROACH:** Use JSON configuration + `populate_agents` command for error-free, Railway-ready agent creation. +## Current Agents (8 Total) ---- +### Webhook Agents (4) +- **Social Ads Generator** - 6.00 AED - Social media ad creation +- **Job Posting Generator** - 10.00 AED - Professional job postings +- **PDF Summarizer** - 8.00 AED - Document analysis and summarization +- **5 Whys Analyzer** - 15.00 AED - Interactive root cause analysis -## Current Agent Status +### Direct Access Agents (4) +- **CyberSec Career Navigator** - FREE - Career guidance +- **AI Brand Strategist** - FREE - Brand strategy consultation +- **Lean Six Sigma Expert** - FREE - Process improvement +- **SWOT Analysis Expert** - FREE - Strategic analysis -**Total Agents: 8** (4 webhook + 4 direct access) -**Total Categories: 6** +## Categories (6 Available) +Use existing categories first to avoid proliferation: -### Webhook Agents (N8N Integration) -1. **Social Ads Generator** - 6.00 AED - Creates social media advertisements -2. **Job Posting Generator** - 10.00 AED - Creates professional job postings -3. **PDF Summarizer** - 8.00 AED - Analyzes and summarizes PDF documents -4. **5 Whys Analyzer** - 15.00 AED - Interactive chat-based root cause analysis +- **`analysis`** 🧠 - Problem-solving, strategic analysis +- **`career-education`** 🎓 - Career guidance, professional development +- **`document-processing`** 📄 - PDF analysis, file processing +- **`human-resources`** 💼 - Job postings, HR automation +- **`marketing`** 📢 - Social ads, content marketing +- **`consulting`** 💼 - Business consultation, expert advice -### Direct Access Agents (External Forms) -1. **CyberSec Career Navigator** - FREE - Career guidance consultation -2. **AI Brand Strategist** - FREE - Brand strategy consultation -3. **Lean Six Sigma Expert** - FREE - Process improvement consultation -4. **SWOT Analysis Expert** - FREE - Strategic business analysis - ---- - -## 🏷️ Choose Existing Category First - -**IMPORTANT:** Always use existing categories before creating new ones to avoid category proliferation. - -### Available Categories: -- 🧠 **`analysis`** - Problem-solving, SWOT analysis, strategic analysis tools -- 🎓 **`career-education`** - Career guidance, educational resources, professional development -- 📄 **`document-processing`** - PDF analysis, file processing, document tools -- 💼 **`human-resources`** - Job postings, HR automation, talent management -- 📢 **`marketing`** - Social ads, branding, content marketing, advertising -- 💼 **`consulting`** - Business consultation, strategy services, expert advice - -**Only create new categories when absolutely necessary and logically distinct.** - ---- - -## 🚀 Agent Creation Workflow - -### System 1: Webhook Agents (N8N Integration) -- **Use for:** Dynamic forms, server-side processing, file uploads, complex workflows -- **Examples:** Social Ads Generator, PDF Summarizer, Job Posting Generator -- **Flow:** Marketplace → Agent detail page → Dynamic form → N8N webhook → Results - -### System 2: Direct Access Agents (External Forms) -- **Use for:** External form services (JotForm, Google Forms), consultation interfaces -- **Examples:** SWOT Analysis Expert, CyberSec Career Navigator, AI Brand Strategist -- **Flow:** Marketplace → Payment processing → Quantum Tasks header + embedded external form - ---- - -## 📝 Implementation Steps +## Creating New Agents ### Step 1: Create JSON Configuration -Create a new file in `agents/configs/agents/your-agent-name.json`: +Add new file in `agents/configs/agents/your-agent-name.json`: #### Webhook Agent Example: ```json { "slug": "content-optimizer", - "name": "Content Optimizer", + "name": "Content Optimizer", "short_description": "AI-powered content optimization and enhancement", - "description": "Enhance your content for better engagement with AI-powered optimization suggestions, tone analysis, and improvement recommendations.", + "description": "Enhance your content with AI-powered optimization suggestions, tone analysis, and improvement recommendations.", "category": "marketing", "price": 5.0, "agent_type": "form", @@ -88,7 +63,7 @@ Create a new file in `agents/configs/agents/your-agent-name.json`: "required": true }, { - "name": "content_type", + "name": "content_type", "type": "select", "label": "Content Type", "required": true, @@ -109,194 +84,105 @@ Create a new file in `agents/configs/agents/your-agent-name.json`: #### Direct Access Agent Example: ```json { - "slug": "business-strategist", - "name": "Business Strategist", - "short_description": "Expert business strategy consultation", - "description": "Get professional business strategy insights and recommendations from experienced consultants to grow your business effectively.", + "slug": "business-coach", + "name": "Business Coach", + "short_description": "Expert business coaching consultation", + "description": "Get professional business coaching insights and strategic guidance from experienced consultants.", "category": "consulting", "price": 0.0, - "agent_type": "form", + "agent_type": "form", "system_type": "direct_access", - "form_schema": { - "fields": [] - }, - "webhook_url": "https://agent.jotform.com/your-form-id", + "form_schema": {"fields": []}, + "webhook_url": "https://form.jotform.com/your-form-id", "access_url_name": "agents:direct_access_handler", "display_url_name": "agents:direct_access_display" } ``` -### Step 2: Run populate_agents Command - +### Step 2: Commit to Git ```bash -# Development -source venv/bin/activate -python manage.py populate_agents - -# Production (Railway) -python manage.py populate_agents # Runs automatically on deployment +git add agents/configs/agents/your-agent-name.json +git commit -m "Add new agent: Your Agent Name" +git push ``` -### Step 3: Additional Setup (Direct Access Agents Only) +### Step 3: Done! +- **Development:** Restart server to see new agent +- **Production:** Railway auto-deploys and agent appears in marketplace -For direct access agents that need custom templates or marketplace integration: +## JSON Configuration Reference -#### 3a. Create Custom Template (optional): -```html - -{% extends 'base.html' %} -{% load static %} - -{% block title %}Your Agent Name - Quantum Tasks AI{% endblock %} - -{% block extra_css %} - -{% endblock %} - -{% block content %} -