{"id":28130175,"url":"https://github.com/nbsp1221/ai-agents","last_synced_at":"2025-07-10T07:34:10.531Z","repository":{"id":291611781,"uuid":"937089722","full_name":"nbsp1221/agentforge","owner":"nbsp1221","description":"🤖 A comprehensive framework for building and deploying AI agents","archived":false,"fork":false,"pushed_at":"2025-05-27T08:49:53.000Z","size":24,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-06-26T17:52:24.734Z","etag":null,"topics":["ai-agents","litellm","n8n","ollama","open-webui"],"latest_commit_sha":null,"homepage":"","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nbsp1221.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-02-22T10:04:22.000Z","updated_at":"2025-05-27T08:49:56.000Z","dependencies_parsed_at":"2025-05-05T16:54:39.715Z","dependency_job_id":"7356db51-b56c-4dc0-bd1a-fb3cc14a90b7","html_url":"https://github.com/nbsp1221/agentforge","commit_stats":null,"previous_names":["nbsp1221/ai-agents","nbsp1221/agentforge"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/nbsp1221/agentforge","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nbsp1221%2Fagentforge","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nbsp1221%2Fagentforge/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nbsp1221%2Fagentforge/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nbsp1221%2Fagentforge/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nbsp1221","download_url":"https://codeload.github.com/nbsp1221/agentforge/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nbsp1221%2Fagentforge/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":264545174,"owners_count":23625405,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ai-agents","litellm","n8n","ollama","open-webui"],"created_at":"2025-05-14T12:24:37.222Z","updated_at":"2025-07-10T07:34:10.517Z","avatar_url":"https://github.com/nbsp1221.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# AgentForge\n\n🤖 **A comprehensive framework for building and deploying AI agents**\n\nAgentForge combines powerful workflow automation with standardized LLM access to create a complete environment for developing intelligent agents that can process data, make decisions, and interact with various services and APIs.\n\n## 🚀 What is AgentForge?\n\nAgentForge is an all-in-one platform that brings together the best tools for AI agent development:\n\n## 🏗️ Architecture Overview\n\nThis platform integrates five powerful components:\n\n- **🔄 n8n**: Powerful workflow automation platform for building complex agent logic and decision trees\n- **🌐 LiteLLM**: Proxy server providing standardized access to 100+ LLM providers (OpenAI, Anthropic, Cohere, etc.)\n- **🗄️ PostgreSQL**: Robust database backend for persistent data storage across all services\n- **🧠 Ollama**: Local LLM server for running open-source models on your own infrastructure\n- **💬 Open WebUI**: Modern, intuitive web interface for interacting with your AI models\n\n**Perfect for:** Creating sophisticated AI agents that can automate workflows, process complex data, integrate with APIs, and provide intelligent responses through multiple interfaces.\n\n## 📋 Prerequisites\n\n- Docker\n- Docker Compose\n\n## 🚀 Quick Start\n\n### 1. 📁 Prepare Your Environment\n\nCreate a directory for files that will be accessible by n8n:\n\n```bash\nmkdir -p files\n```\n\n### 2. ⚙️ Configure Environment Variables\n\nCopy the example environment file and configure it:\n\n```bash\ncp .env.example .env\n```\n\nEdit the `.env` file to set your database credentials, LiteLLM keys, and other configuration options.\n\n💡 **Pro Tip:** Generate secure passwords and keys:\n```bash\n# For database passwords\nopenssl rand -base64 32\n\n# For LiteLLM API keys (more appropriate for API key format)\nopenssl rand -hex 32\n```\n\n### 3. 🌐 Setup Network\n\nCreate an external network for Caddy (if you plan to use reverse proxy):\n\n```bash\ndocker network create caddy-network\n```\n\n### 4. 🚀 Launch AgentForge\n\nStart all services:\n\n```bash\ndocker compose up -d\n```\n\n### 5. 🎯 Access Your Services\n\nOnce everything is running, access your AgentForge platform:\n\n- **🔄 n8n Workflow Builder**: `http://localhost:5678`\n- **🌐 LiteLLM API Dashboard**: `http://localhost:4000`\n- **🧠 Ollama API**: `http://localhost:11434`\n- **💬 Open WebUI Chat Interface**: `http://localhost:8080`\n\n## 🧠 Using Ollama\n\n### Installing Models\n\nOnce the Ollama service is running, you can install and run models using the Ollama API. To install a model, run:\n\n```bash\n# Install a model (e.g., llama3)\ncurl -X POST http://localhost:11434/api/pull -d '{\"name\": \"llama3\"}'\n```\n\nOr using docker exec:\n\n```bash\ndocker exec -it ollama ollama pull llama3\n```\n\n### Running Models\n\nTo run a model in interactive mode:\n\n```bash\ndocker exec -it ollama ollama run llama3\n```\n\n### Connecting Ollama to LiteLLM\n\nYou can connect Ollama to LiteLLM through the LiteLLM UI:\n\n1. Access the LiteLLM UI at `http://localhost:4000/ui`\n2. Log in with your credentials\n3. Navigate to Models/Providers section\n4. Add Ollama as a provider using the internal URL: `http://ollama:11434`\n5. Set up model routing configurations as needed\n\nThis allows you to access Ollama models through the standardized LiteLLM API interface.\n\n## 💬 Using Open WebUI\n\nOpen WebUI provides a user-friendly interface for interacting with your Ollama models through a modern chat interface.\n\n### Getting Started with Open WebUI\n\n1. Make sure Ollama is running and has at least one model installed\n2. Access Open WebUI at `http://localhost:8080`\n3. Create an account or log in\n4. Start chatting with your local Ollama models\n\n### Key Features\n\n- **Chat Interface**: Intuitive chat interface similar to popular AI assistants\n- **Model Selection**: Switch between different Ollama models\n- **Secure Authentication**: User accounts with authentication\n- **Chat History**: Persistent chat history stored in the open-webui-data volume\n- **File Uploads**: Upload files for the AI to analyze (depending on model capabilities)\n- **Customization**: Adjust various settings to tailor your experience\n\n### Authentication\n\n- The first user to register will automatically become an admin\n- Admin users can manage user accounts and system settings\n- The `WEBUI_SECRET_KEY` environment variable is used for securing authentication\n- For production use, ensure you set a strong random key for `WEBUI_SECRET_KEY`\n\n### API Access\n\nOpen WebUI provides API access for integration with other applications:\n\n1. Navigate to your account settings in the Open WebUI interface\n2. Generate an API key and/or JWT token\n3. Use these credentials to authenticate with the Open WebUI API\n\n### Security Considerations\n\nWhen deploying Open WebUI in a production environment, consider these security practices:\n\n- **Generate a Strong Secret Key**: Use a cryptographically secure random generator to create a `WEBUI_SECRET_KEY` with at least 64 characters\n- **Enable HTTPS**: For production deployments, configure your reverse proxy (e.g., Caddy) to use HTTPS\n- **Cookie Security**: When using HTTPS, make sure `WEBUI_SESSION_COOKIE_SECURE` and `WEBUI_AUTH_COOKIE_SECURE` are set to `True`\n- **User Management**: Review and approve new user registrations, especially when setting `DEFAULT_USER_ROLE=pending`\n- **API Access Control**: Be cautious when sharing API keys and always use the shortest viable token expiration time\n- **Regular Updates**: Keep your Open WebUI instance updated to the latest version to benefit from security patches\n\n## 🛠️ Management Commands\n\n### Stopping the Service\n\nTo stop the containers:\n\n```bash\ndocker compose down\n```\n\n### Upgrading Services\n\nTo upgrade to the latest versions:\n\n```bash\n# Pull latest versions\ndocker compose pull\n\n# Stop and remove older versions\ndocker compose down\n\n# Start the containers\ndocker compose up -d\n```\n\n## ⚙️ Environment Variables\n\nThe following important environment variables can be configured in your `.env` file:\n\n### PostgreSQL Configuration\n- `POSTGRES_USER`: PostgreSQL root username\n- `POSTGRES_PASSWORD`: PostgreSQL root password\n\n### n8n Configuration\n- `N8N_POSTGRES_DB`: Database name for n8n\n- `N8N_POSTGRES_USER`: Database user for n8n\n- `N8N_POSTGRES_PASSWORD`: Database password for n8n\n- `N8N_PROTOCOL`: Protocol to use (http or https)\n- `N8N_HOST`: Hostname for n8n\n- `WEBHOOK_URL`: URL for webhooks\n- `GENERIC_TIMEZONE`: Timezone for n8n to use (UTC, Europe/Berlin, etc.)\n\n### LiteLLM Configuration\n- `LITELLM_POSTGRES_DB`: Database name for LiteLLM\n- `LITELLM_POSTGRES_USER`: Database user for LiteLLM\n- `LITELLM_POSTGRES_PASSWORD`: Database password for LiteLLM\n- `LITELLM_MASTER_KEY`: Master key for LiteLLM admin access\n- `LITELLM_SALT_KEY`: Salt key for credential encryption\n- `LITELLM_UI_USERNAME`: Username for LiteLLM admin UI access\n- `LITELLM_UI_PASSWORD`: Password for LiteLLM admin UI access\n\n### Open WebUI Configuration\n- `WEBUI_SECRET_KEY`: Secret key for JWT token generation and authentication (at least 64 characters recommended for security)\n\n## 📝 Important Notes\n\n- The `init-db.sh` script automatically creates databases for n8n and LiteLLM based on the environment variables\n- The databases are populated using the values from `N8N_POSTGRES_DB` and `LITELLM_POSTGRES_DB` environment variables\n- All data is stored in Docker volumes for persistence\n- You can place files you want to access from n8n in the `./files` directory, which is mounted to `/files` in the n8n container\n- LiteLLM configuration is stored in `litellm-config.yaml`\n- LiteLLM admin UI is accessible at `http://localhost:4000/ui` using the credentials set in the environment variables\n- Open WebUI provides a user-friendly interface for interacting with your Ollama models through a modern chat interface\n- This setup uses an external `caddy-network` which should be created before running the containers\n- For security in production environments, be sure to set strong passwords and keys\n- Ollama models are stored in the `ollama-data` volume for persistence\n- Open WebUI data (chats, settings) is stored in the `open-webui-data` volume for persistence\n\n## 🔗 Resources\n\n- **GitHub Repository**: [https://github.com/nbsp1221/agentforge](https://github.com/nbsp1221/agentforge)\n- **n8n Documentation**: [https://docs.n8n.io/](https://docs.n8n.io/)\n- **LiteLLM Documentation**: [https://docs.litellm.ai/](https://docs.litellm.ai/)\n- **Ollama Documentation**: [https://ollama.ai/](https://ollama.ai/)\n- **Open WebUI Documentation**: [https://docs.openwebui.com/](https://docs.openwebui.com/)\n\n## 📄 License\n\nThis project is open source and available under the [MIT License](LICENSE).\n\n---\n\n**AgentForge** - 🤖 *Forge your AI agents with confidence*","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnbsp1221%2Fai-agents","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnbsp1221%2Fai-agents","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnbsp1221%2Fai-agents/lists"}