- Repository analyses are now saved to the database
- Chat sessions and messages are preserved
- Full conversation history available
- Pagination support for large histories
- View all previous analysis sessions
- Quick access to past conversations
- Session titles and repository info
- Date-based sorting
POST /api/repositories— Save repository analysisPOST /api/chat— Create chat sessionPOST /api/chat/[sessionId]— Add messages to sessionGET /api/history— Retrieve analysis history with pagination
useRepositoryAnalysis()— Save analysis datauseChatSession()— Create and manage chat sessionsuseChatMessages()— Add and retrieve messagesuseHistory()— Fetch conversation history
- ConfigStatus — Visual indicator for API key configuration
- ErrorBoundary — Graceful error handling
- HistorySidebar — Session navigation
- Toast — User notifications
- Skeleton — Loading placeholders
- Exponential backoff retry logic for database timeouts
- Windows SQLite optimization (10-second timeout)
- Graceful fallback to offline mode
- Detailed error messages with setup instructions
- On-the-fly API key detection
- User-friendly error messages
- Setup wizard display when key missing
- Clear configuration instructions
- RESTful API design with proper status codes
- Zod schema validation on all inputs
- Type-safe Prisma ORM integration
- Comprehensive error handling
- Client-side retry logic for failed requests
- Offline-first UI design
- Database initialization on component mount
- Proper error propagation to user
- SQLite for local development
- Proper indexing for performance
- Referential integrity (foreign keys)
- Migration system in place
Stores GitHub repository metadata and analysis results
Represents a conversation about a specific repository
Individual messages within a conversation
AI-generated analysis of repository structure and technologies
-
Configure API Key
# See API_SETUP.md for detailed instructions -
Start Dev Server
npm run dev
-
Analyze a Repository
- Enter GitHub URL (e.g.,
facebook/react) - AI generates analysis
- Data saved to database
- Enter GitHub URL (e.g.,
-
Chat About Repository
- Ask questions about code
- Conversation history saved
- Access from History sidebar
If you were using the previous version:
.env.localfile structure unchanged- Add
NEXT_PUBLIC_GEMINI_API_KEY(if not present) - Database schema auto-migrates on first run
- No data loss from existing features
- File locking requires 10-second timeout
- Not suitable for high-concurrency scenarios
- Upgrade to PostgreSQL for production
- Google Gemini: Subject to quota limits
- GitHub API: Check rate limits in documentation
.env.local— Environment variablesprisma/schema.prisma— Database schemasrc/lib/prisma.ts— ORM configurationAPI_SETUP.md— API configuration guideDATABASE.md— Database documentation
- Export analysis as PDF
- Collaborative chat sessions
- Code snippet suggestions
- Repository comparison
- Advanced search/filtering
- User authentication
- Cloud deployment examples