Follow this guide to set up Devr.AI's development environment on your local machine. For Setup guide video tutorial go to Devr Setup Guide
- Python 3.9+ (version 3.10 is recommended)
- Node.js (latest LTS version)
- Git (any recent version)
- Docker and Docker Compose (for Weaviate database)
- Clone the repository
git clone https://github.com/AOSSIE-Org/Devr.AI.git
cd Devr.AI- Install Poetry (Python package manager)
# Linux / MacOS / WSL
curl -sSL https://install.python-poetry.org | python3 -
# Windows (PowerShell)
(Invoke-WebRequest -Uri https://install.python-poetry.org -UseBasicParsing).Content | py -
# Verify installation
poetry --version # Should show v2.0.0 or above- Install Python dependencies
poetry env use python3.10
poetry lock
poetry install --with dev- Activate the virtual environment
# Linux / Mac / WSL
eval $(poetry env activate)
# Windows (PowerShell)
Invoke-Expression (poetry env activate)- Set up environment variables
# Copy the example environment file
cp env.example .env
# Edit .env with your API keys and configuration
nano .env # or use your preferred editor- Set up Docker container
cd backend
docker-compose up -d # Start weaviate, falkordb, rabbitmq- Start Docker containers
Go to docker dekstop and start the containers- Start the backend server
cd backend
poetry run python main.py # Terminal 1
poetry run python start_github_mcp_server.py # Terminal 2 (Start MCP server)
flask --app api/index.py run --debug --port 5000 # Terminal 3 (Start graphDB)- Start the frontend (in a new terminal)
cd frontend
npm install
npm run devCreate a .env file in the project root with the following variables:
# AI Services
GEMINI_API_KEY=your_gemini_api_key_here
TAVILY_API_KEY=your_tavily_api_key_here
# Platform Integrations
DISCORD_BOT_TOKEN=your_discord_bot_token_here
GITHUB_TOKEN=your_github_token_here
# Database
SUPABASE_URL=your_supabase_url_here
SUPABASE_KEY=your_supabase_anon_key_here
# Backend Configuration
BACKEND_URL=http://localhost:8000# LangSmith Tracing (for development)
LANGSMITH_TRACING=false
LANGSMITH_API_KEY=your_langsmith_api_key_here
LANGSMITH_PROJECT=DevR_AI
# RabbitMQ (uses default if not set)
RABBITMQ_URL=amqp://localhost:5672/
# Agent Configuration
DEVREL_AGENT_MODEL=gemini-2.5-flash
GITHUB_AGENT_MODEL=gemini-2.5-flash
CLASSIFICATION_AGENT_MODEL=gemini-2.0-flash
AGENT_TIMEOUT=30
MAX_RETRIES=3- Go to Google AI Studio
- Create a new API key
- Add it to your
.envfile asGEMINI_API_KEY
- Go to Tavily
- Sign up and get your API key
- Add it to your
.envfile asTAVILY_API_KEY
- Go to Discord Developer Portal
- Create a new application
- Go to "Bot" section and create a bot
- Copy the token and add it to your
.envfile asDISCORD_BOT_TOKEN - Enable required intents: Message Content Intent, Server Members Intent
- Go to GitHub Settings > Developer settings > Personal access tokens
- Generate a new token with
repoanduserscopes - Add it to your
.envfile asGITHUB_TOKEN
- Go to Supabase and create a new project
- Go to Settings > API
- Copy the URL and anon key
- Add them to your
.envfile asSUPABASE_URLandSUPABASE_KEY
Weaviate is used for semantic search and embeddings storage. It runs in Docker:
cd backend
docker-compose up -d weaviateThe database will be available at http://localhost:8080
Supabase provides the PostgreSQL database for user data and authentication. The connection is configured via environment variables.
- Intelligent Message Processing: AI-powered responses to community questions
- GitHub Account Verification: Link Discord accounts to GitHub profiles
- Conversation Memory: Persistent context across sessions
- Commands:
!verify_github- Link your GitHub account!verification_status- Check account linking status!reset- Clear conversation memory!help_devrel- Show available commands
- DevRel Agent: Primary conversational agent for community support
- ReAct Workflow: Think → Act → Observe pattern for intelligent responses
- Tool Integration: Web search, FAQ lookup, GitHub operations
- Conversation Summarization: Automatic memory management
- Google Gemini: Primary LLM for reasoning and response generation
- Tavily Search: Real-time web search for current information
- Text Embeddings: Semantic search capabilities
- Supabase: User profiles, authentication, conversation metadata
- Weaviate: Vector embeddings and semantic search
- Agent Memory: Persistent conversation context
poetry run pytestpoetry run black .
poetry run isort .poetry run flake8cd frontend
npm run dev # Start development server
npm run build # Build for production
npm run lint # Run ESLint-
Poetry environment not activated
poetry shell
-
Weaviate connection failed
# Check if Docker is running docker ps # Restart Weaviate docker-compose down docker-compose up -d weaviate
-
Missing environment variables
- Ensure all required variables are set in
.env - Check that the file is in the project root
- Ensure all required variables are set in
-
Port conflicts
- Backend runs on port 8000
- Frontend runs on port 5173 (Vite default)
- Weaviate runs on port 8080
- Backend logs are displayed in the terminal where you run
python main.py - Check Docker logs for Weaviate:
docker-compose logs weaviate
Devr.AI/
├── backend/ # FastAPI backend
│ ├── app/
│ │ ├── agents/ # LangGraph agents
│ │ ├── api/ # API routes
│ │ ├── core/ # Configuration and core logic
│ │ ├── database/ # Database connections
│ │ ├── models/ # Data models
│ │ └── services/ # Business logic
│ ├── integrations/ # Platform integrations
│ │ ├── discord/ # Discord bot
│ │ ├── github/ # GitHub integration
│ │ └── slack/ # Slack integration (planned)
│ └── main.py # Application entry point
├── frontend/ # React frontend
├── docs/ # Documentation
└── tests/ # Test files
- Set up your Discord server and invite the bot
- Configure GitHub OAuth for user verification
- Test the bot with basic commands
- Explore the codebase to understand the architecture
- Contribute by implementing new features or fixing bugs
For more information, refer to the main README.md file.