A personal AI assistant that acts as your junior developer and documentation librarian. DevAI helps you quickly reference your own documentation, configurations, and past solutions without needing an internet connection. Instead of digging through folders or searching online for things you've already solved, DevAI instantly surfaces the exact information you need from your own knowledge base, saving you time and keeping you focused on building.
Stop reinventing the wheel. Start referencing your own solutions.
DevAI transforms your scattered documentation into an intelligent assistant that remembers everything you've built. No more hunting through old projects or Googling solutions you've already implemented.
Perfect for developers who:
- Save Time: Instantly find your own configurations, scripts, and solutions
- Stay Focused: No context switching between projects and documentation
- Work Offline: Access your knowledge base without internet dependency
- Maintain Privacy: Your code and documentation never leave your machine
- Avoid Repetition: Quickly reference past implementations for new projects
- Scale Knowledge: Build on your own expertise across multiple projects
Ideal Use Cases:
- Quick Reference: "How did I set up that Docker config last time?"
- Project Setup: "What was that database migration pattern I used?"
- Troubleshooting: "I've seen this error before - what was the solution?"
- Knowledge Transfer: "Show me the API patterns from my previous project"
- Learning: "Explain this complex setup I documented months ago"
- 100% Offline & Private: Runs entirely on your local machine with Ollama LLMs
- Documentation-Focused AI: Restricted to only use your provided documentation sources
- Context-Aware Assistance: Leverages your project docs, APIs, and codebase for accurate help
- Real-Time Chat: WebSocket-based communication with streaming responses
- Modern UI: React with TypeScript and Tailwind CSS
- Dark Mode: Complete dark theme with toggle functionality
- Production Ready: Docker containerization and deployment scripts
- Responsive Design: Mobile-first, accessible interface
- Performance Optimized: Fast response times and efficient resource usage
- Conversation Persistence: Environment-based storage (IndexedDB/SQLite/PostgreSQL)
- Message Search: Full-text search across all conversations with highlighting
- Admin Dashboard: Real-time system monitoring and health checks
- Export/Import: Export conversations in multiple formats (JSON/ZIP/TXT/MD)
- User Preferences: Customizable settings with production-safe restrictions
- Keyboard Shortcuts: Alt-key combinations for improved productivity
- Caching System: In-memory caching with TTL and LRU eviction
- Environment Management: Backend-controlled configuration with automatic storage switching
┌─────────────────┐ ┌─────────────────┐ ┌─────────────────┐
│ React Frontend│ │ FastAPI Backend│ │ Ollama LLM │
│ │ │ │ │ │
│ ┌─────────────┐ │ │ ┌─────────────┐ │ │ ┌─────────────┐ │
│ │ Chat UI │◄┼────┼►│ API Server │ │ │ │ Local LLM │ │
│ │ Components │ │ │ │ WebSockets │ │ │ │ Models │ │
│ └─────────────┘ │ │ └─────────────┘ │ │ └─────────────┘ │
│ │ │ ┌─────────────┐ │ │ │
│ │ │ │ AI Service │◄┼────┼►│ phi3:mini │ │
│ │ │ │ │ │ │ │ tinyllama │ │
│ │ │ └─────────────┘ │ │ │ llama2 │ │
└─────────────────┘ └─────────────────┘ └─────────────────┘
- FastAPI - Modern Python web framework
- Ollama - Local LLM integration
- WebSockets - Real-time communication
- Pydantic - Data validation
- Python 3.8+ - Runtime environment
- React 18 - UI framework
- TypeScript - Type safety
- Tailwind CSS - Styling
- Vite - Build tool
- Axios - HTTP client
- Docker - Containerization
- Nginx - Reverse proxy
- Raspberry Pi - Production hosting
- Unified port management - single script for checking and syncing ports
- Focused updates - only updates port-related variables
- Preserves all other settings - your custom configuration stays intact
- Smart detection - identifies port mismatches and suggests fixes
- Detailed startup logging showing documentation loading status
- File-by-file processing information
- Clear error messages when documentation path is missing
- Statistics endpoint to check documentation status
- Visual indicators (emojis) for better log readability
- Python 3.8+
- Node.js 18+
- Docker (optional)
- Ollama installed and running
-
Clone the repository
git clone <repository-url> cd dev-ai
-
Start Ollama and pull a model
ollama serve ollama pull phi3:mini # Recommended for speed -
Backend Setup
cd backend pip install -r requirements.txt # Environment file is created from .env.example if it doesn't exist uvicorn app.main:app --reload --host 0.0.0.0 --port 8000
-
Frontend Setup
cd frontend npm install # Environment file is created with default settings if it doesn't exist npm run dev
-
Port Management
# Check port synchronization status node scripts/ports.js # Sync only port-related variables (preserves all other settings) node scripts/ports.js --sync
-
Access the application
- Frontend: http://localhost:3000
- Backend API: http://localhost:8000
- API Docs: http://localhost:8000/docs
dev-ai/
├── backend/ # FastAPI backend
│ ├── app/
│ │ ├── main.py # Application entry point
│ │ ├── services/ # Business logic services
│ │ ├── models/ # Pydantic models
│ │ └── api/ # API endpoints
│ ├── tests/ # Backend tests
│ ├── requirements.txt # Python dependencies
│ └── .env.example # Environment template
├── frontend/ # React frontend
│ ├── src/
│ │ ├── components/ # React components
│ │ ├── services/ # API services
│ │ ├── types/ # TypeScript types
│ │ └── utils/ # Utility functions
│ ├── public/ # Static assets
│ └── package.json # Node dependencies
├── docker/ # Docker configurations
├── docs/ # Documentation
└── scripts/ # Deployment scripts
# Ollama Configuration
OLLAMA_BASE_URL=http://localhost:11434
OLLAMA_MODEL=phi3:mini
# Performance Settings
MAX_TOKENS=500
TEMPERATURE=0.5
ENABLE_STREAMING=true
# Security
SECRET_KEY=your-secret-key-change-in-production
ALLOWED_ORIGINS=http://localhost:3000export const config = {
apiUrl: "http://localhost:8000",
wsUrl: "ws://localhost:8000/ws",
maxMessageLength: 1000,
reconnectInterval: 5000
};# Build and run with Docker Compose
docker-compose up --build
# Production deployment
docker-compose -f docker-compose.prod.yml up -dSee deployment guide for detailed Pi server setup instructions.
# Backend tests
cd backend
pytest tests/
# Frontend tests
cd frontend
npm test
# E2E tests
npm run test:e2e- Response Time: < 2 seconds average
- Streaming: Real-time response chunks
- Memory Usage: Optimized for Pi deployment
- Concurrent Users: Supports multiple simultaneous chats
- Fork the repository
- Create a feature branch
- Make your changes
- Add tests if applicable
- Submit a pull request
This project is open source and available under the MIT License.
This project demonstrates:
- Full-stack development with modern technologies
- AI/ML integration with local LLMs
- Real-time applications using WebSockets
- Production deployment on Raspberry Pi
- Clean architecture and best practices
- Responsive design and accessibility
- Performance analysis and engineering judgment
Comprehensive documentation available in the docs/ directory:
- Deployment Guide - Complete Raspberry Pi deployment
- Performance Analysis - Hardware limitation analysis
- Portfolio Case Study - Technical achievements showcase
- Cleanup Guide - Resource management procedures
Key Achievement: Successfully deployed full-stack AI application on Raspberry Pi 4B, identified performance bottlenecks (42-second response times), and documented the complete technical analysis - demonstrating both deployment expertise and realistic engineering judgment.
Perfect for showcasing technical skills to potential employers!
Version: 1.0.0
Last Updated: October 2025