CoolFace
Apppublic

Hamza4100/ai-workflow-agent

sourceHugging Faceupdated 7mo agoView on Hugging Face
0likes
App README

AI Workflow Agent - M1 (Milestone 1)

๐Ÿค– Core AI Decision Making System - Analyzes automation needs and generates intelligent workflows.

Features

  • โ€”๐Ÿง  AI Analysis: Uses Gemini 2.5 Flash to understand your automation requirements
  • โ€”โš™๏ธ Workflow Generation: Creates n8n and ComfyUI workflows from natural language
  • โ€”๐Ÿ” Smart Search: GitHub repository search and web search (DuckDuckGo)
  • โ€”๐Ÿ’ฌ AI Chat: Conversational assistant for workflow planning
  • โ€”โšก Dual Mode: Fast keyword matching or intelligent LLM analysis
  • โ€”๐ŸŒ Bilingual: Full English + Spanish support

How to Use

  1. 1.Enable AI Mode: Toggle "๐Ÿง  Intelligent AI Mode" in sidebar for Gemini analysis
  2. 2.Choose Language: Select English or Spanish
  3. 3.Navigate Tabs:
  4. 4.๐Ÿ  Home: Overview and getting started
  5. 5.๐Ÿง  AI Analysis: Analyze automation needs
  6. 6.โš™๏ธ Build Workflow: Generate n8n/ComfyUI JSON
  7. 7.๐Ÿ” GitHub Search: Find open source projects
  8. 8.๐ŸŒ Web Search: Search with DuckDuckGo
  9. 9.๐Ÿ’ฌ Chat: Conversational AI assistant
  10. 10.Try Examples: Each tab has pre-filled examples

Technology Stack

  • โ€”LLM: Google Gemini 2.5 Flash (REST API)
  • โ€”Workflow Tools: n8n (automation) + ComfyUI (AI image generation)
  • โ€”Search: DuckDuckGo (no API key) + GitHub API
  • โ€”Framework: Streamlit 1.31.0
  • โ€”Python: 3.11

Configuration

Required for AI Mode:

Optional:

  • โ€”GITHUB_TOKEN: For higher GitHub API rate limits

Setting Secrets in HuggingFace Spaces:

  1. 1.Go to Space Settings โ†’ Variables and secrets
  2. 2.Add secret: GEMINI_API_KEY = yourkeyhere
  3. 3.Restart the Space

Fast vs Intelligent Mode

  • โ€”โšก Fast Mode (AI disabled): <100ms, uses keyword pattern matching, perfect for testing
  • โ€”๐Ÿง  Intelligent Mode (AI enabled): 2-3s, uses Gemini for deep analysis and complex workflow generation

Example Workflows

Customer Support Automation: Generate workflows that receive tickets, classify urgency, check knowledge base, create Jira tickets, and send notifications.

Image Generation: Create ComfyUI workflows for txt2img, img2img, upscaling, inpainting, and ControlNet.

Notes

  • โ€”No Docker Required: Runs entirely on HuggingFace infrastructure
  • โ€”No Training: Uses pre-trained Gemini model (no GPU needed)
  • โ€”Minimal Dependencies: Only 8 packages for fast startup
  • โ€”Free Tier: Works with free Gemini API (15 requests/minute)

Built for Milestone 1 of the AI Workflow Agent project.