From 4f4c3c7a6e5696ecb206e7b6618bb334fabda3ef Mon Sep 17 00:00:00 2001 From: Claude Date: Sat, 15 Nov 2025 20:17:19 +0000 Subject: [PATCH 1/3] docs: add comprehensive features documentation Add detailed documentation of all ProgChain features including: - Topic Explorer: Hierarchical learning paths with difficulty levels - Interview Preparation: AI-generated technical interview questions - Explore Mode: Conversational learning assistant with chat history - Learning Threads: Structured multi-part content generation - Project Management: File-based knowledge system with vector search - Infinity Mode: Extensible learning modes registry - LeetCode Scraper: Utility for problem collection Documentation includes: - Feature descriptions and capabilities - API endpoints and database models - Frontend components and routes - Technical architecture details - Use cases and workflows - Comparison with other platforms - Future enhancement possibilities This provides a complete overview of the platform's capabilities and helps users understand how to leverage all available features. --- FEATURES.md | 546 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 546 insertions(+) create mode 100644 FEATURES.md diff --git a/FEATURES.md b/FEATURES.md new file mode 100644 index 0000000..a6e3e1f --- /dev/null +++ b/FEATURES.md @@ -0,0 +1,546 @@ +# ProgChain Features Documentation + +## Overview +ProgChain is an AI-powered learning platform that helps developers learn programming concepts, prepare for technical interviews, and manage coding projects. It combines multiple learning modes with AI assistance to create personalized learning experiences. + +--- + +## 🎯 Core Features + +### 1. **Topic Explorer** - Interactive Learning Paths + +**What it does**: Generates hierarchical learning paths for any programming topic with difficulty-based progression. + +**Key Features**: +- **Hierarchical Topic Trees**: Topics are organized in chains (e.g., Python → Async Programming → Asyncio) +- **Difficulty Levels**: Each subtopic is categorized as Easy, Medium, or Hard +- **AI-Generated Content**: Uses OpenAI to generate relevant subtopics and descriptions +- **Visual Learning Path**: Frontend displays topics in an interactive flowchart/tree structure +- **Topic Chains**: Persistent learning paths that can be saved and resumed + +**API Endpoints**: +- `POST /topics/generate` - Generate subtopics for a given topic path +- `POST /topics/create-topic-chain` - Create a new topic learning chain + +**Database Models**: +- `TopicChain`: Represents a complete learning journey +- `BaseTopic`: Main topic in the chain +- `SubTopic`: Specific concepts with difficulty ratings + +**Example Use Case**: +``` +User asks: "Python" +→ System generates: Beginner (Variables, Functions), Intermediate (Classes, Decorators), Advanced (Metaclasses, Async) +→ User selects: "Async Programming" +→ System generates deeper subtopics for async programming +``` + +**Frontend Component**: `client/src/components/topics/TopicChain.tsx` + +--- + +### 2. **Interview Preparation** - Technical Interview Questions + +**What it does**: Generates AI-powered interview questions for specific technologies and topics. + +**Key Features**: +- **Topic-Based Questions**: Generate questions for any tech stack +- **Contextual Understanding**: Provide additional context for more targeted questions +- **Streaming Responses**: Real-time question generation +- **Question Quality**: AI ensures questions are relevant and appropriately challenging + +**API Endpoints**: +- `POST /interview/questions` - Generate interview questions with streaming + +**Request Example**: +```json +{ + "topic": "React Hooks", + "context": "Senior frontend developer position" +} +``` + +**Response Format**: +```json +{ + "topic": "React Hooks", + "questions": [ + { + "question": "Explain the difference between useEffect and useLayoutEffect", + "difficulty": "intermediate" + } + ] +} +``` + +**Frontend Component**: `client/src/components/interview/Interview.tsx` + +--- + +### 3. **Explore Mode** - Conversational Learning Assistant + +**What it does**: Interactive Q&A system where users can explore any programming topic through conversation. + +**Key Features**: +- **Research Assistant**: AI acts as a programming tutor +- **Chat History**: Maintains conversation context across sessions +- **Follow-up Questions**: Ask clarifying questions on any topic +- **Multi-Model Support**: Choose between different OpenAI models (GPT-4, GPT-3.5) +- **Vector Store Integration**: Uses FAISS for semantic search and context retrieval +- **Conversation Management**: Save, list, and delete exploration sessions + +**API Endpoints**: +- `POST /explore/topic` - Start exploring a new topic +- `POST /explore/question` - Ask a follow-up question in an existing chat +- `POST /explore/chats/list` - Get all saved exploration chats +- `GET /explore/chat/{chat_id}` - Retrieve a specific chat session +- `DELETE /explore/chat/{chat_id}` - Delete a chat session + +**Database Models**: +- Chat sessions with full conversation history +- Message storage with timestamps + +**Frontend Component**: `client/src/components/explore/Explore.tsx` + +**Example Flow**: +``` +User: "Explain how Python decorators work" +→ AI provides detailed explanation +User: "Can you show me a practical example?" +→ AI provides code examples +User: "How do I create a decorator with arguments?" +→ AI provides advanced examples +``` + +--- + +### 4. **Learning Threads** - Structured Content Generation + +**What it does**: Creates multi-part learning content organized as threads with individual content pieces. + +**Key Features**: +- **Thread Creation**: Generate complete learning paths on any topic +- **Content Organization**: Each thread contains multiple content pieces +- **Progressive Learning**: Content is organized sequentially +- **Interactive Chat**: Ask questions about specific content pieces +- **Content Expansion**: Generate additional content for existing threads + +**API Endpoints**: +- `POST /threads/create` - Create a new thread and generate initial content +- `POST /threads/generate` - Generate more content for an existing thread +- `GET /threads/` - List all threads +- `GET /threads/{thread_id}` - Get all content for a specific thread +- `POST /threads/chat` - Chat about specific thread content +- `GET /threads/chat/{thread_content_id}` - Get chat history for content +- `POST /threads/chat/stop` - Stop ongoing chat generation + +**Database Models**: +- `Thread`: Main learning topic container +- `ThreadContent`: Individual learning content pieces +- `ThreadContentChat`: Q&A sessions about specific content + +**Frontend Component**: `client/src/components/thread/Thread.tsx` + +**Example Use Case**: +``` +User creates thread: "Advanced React Patterns" +→ System generates content: + 1. Render Props Pattern + 2. Higher-Order Components + 3. Custom Hooks Pattern + 4. Compound Components +→ User clicks on "Custom Hooks Pattern" +→ User asks: "When should I use custom hooks vs regular functions?" +→ AI provides contextual explanation +``` + +--- + +### 5. **Project Management** - File-Based Knowledge System + +**What it does**: Manage coding projects with file uploads and AI-powered project understanding. + +**Key Features**: +- **Project Creation**: Create and organize multiple projects +- **File Upload**: Upload project files (code, docs, etc.) +- **Vector Database**: Each project has its own vector store for semantic search +- **Project Chat**: Ask questions about your project files +- **File Context**: AI answers are grounded in your actual project files +- **Chat History**: Maintains conversation history per project + +**API Endpoints**: +- `POST /projects/create` - Create a new project +- `POST /projects/upload-file` - Upload files to a project + +**Database Models**: +- `Project`: Project metadata (title, description, vector DB path) +- `ProjectFiles`: Uploaded files with paths +- `ProjectChats`: Chat sessions for each project +- `ProjectChatMessages`: Individual messages with file context + +**Frontend Component**: `client/src/components/projects/Projects.tsx` + +**Example Workflow**: +``` +1. Create project: "E-commerce API" +2. Upload files: server.js, routes.js, models.js +3. System indexes files in vector database +4. User asks: "How is authentication handled?" +5. AI searches through files and provides answer based on actual code +``` + +--- + +### 6. **Infinity Mode** - Extensible Learning Modes (Beta) + +**What it does**: Provides a registry system for different learning modes and content generation. + +**Key Features**: +- **Mode Registry**: Pluggable system for different learning experiences +- **Topic Generation**: Mass generate learning topics +- **Categorization**: Organize topics by categories +- **Extensible Architecture**: Easy to add new learning modes + +**API Endpoints**: +- `POST /infinity/topics/generate` - Generate multiple topic titles + +**Frontend Integration**: Can be extended for new learning modes + +--- + +### 7. **LeetCode Problem Scraper** (Utility) + +**What it does**: Scrapes LeetCode problems for offline practice and learning. + +**Key Features**: +- **Selenium-Based Scraping**: Automated browser scraping +- **Problem Details**: Extracts descriptions, tags, examples +- **Multi-Processing**: Parallel scraping for efficiency +- **JSON Export**: Saves problems in structured format +- **Retry Logic**: Handles failures gracefully + +**Files**: `server/src/scrape/problem_scrape.py` + +**Use Case**: Build a local database of coding problems for practice + +--- + +## 🎨 Frontend Features + +### UI Components + +**Modern Design System**: +- Dark mode by default +- Radix UI components (accessible, customizable) +- Tailwind CSS for styling +- Framer Motion for animations +- Responsive layouts + +**Key UI Features**: +1. **Sidebar Navigation**: Quick access to all features +2. **Streaming Responses**: Real-time AI response display +3. **Markdown Rendering**: Rich text formatting with code highlighting +4. **Math Rendering**: LaTeX support via KaTeX +5. **Code Syntax Highlighting**: Beautiful code blocks +6. **Interactive Flows**: Visual node-based topic exploration +7. **Loading Animations**: Custom AI thinking animations +8. **Toast Notifications**: User feedback system + +### Frontend Routes + +``` +/ → Explore Mode (default) +/explore → Conversational Learning +/topics → Topic Explorer +/interview → Interview Prep +/threads → Learning Threads +/projects → Project Management +/history → Chat History +``` + +--- + +## 🔧 Technical Architecture + +### Backend Stack + +**Framework**: FastAPI (Python 3.11+) +- Async/await throughout +- Type hints with Pydantic +- Automatic API documentation (Swagger/OpenAPI) +- Server-Sent Events (SSE) for streaming + +**AI Integration**: +- **OpenAI API**: GPT-4, GPT-3.5 for content generation +- **LangChain**: Orchestration framework +- **LangGraph**: Advanced AI workflows +- **FAISS**: Vector similarity search + +**Database**: +- **SQLite** with async support (aiosqlite) +- SQLAlchemy ORM (async) +- Database models with mixins (timestamps, public IDs) + +**File Processing**: +- **PyMuPDF**: PDF reading +- **python-docx**: Word document processing +- Multiple PDF libraries (pypdf, PyPDF2, pdfminer) + +### Frontend Stack + +**Framework**: React 18 + TypeScript +- Vite for build tooling +- React Router for navigation +- Redux Toolkit for state management + +**UI Libraries**: +- Radix UI primitives +- Tailwind CSS +- shadcn/ui components +- Framer Motion animations +- Lucide React icons + +**Rendering**: +- React Markdown for content +- Syntax highlighting +- Math rendering (KaTeX) +- PDF viewing + +--- + +## 🌟 Unique Selling Points + +### 1. **Multi-Modal Learning** +Unlike single-purpose learning platforms, ProgChain offers: +- Topic exploration (structured) +- Conversational learning (flexible) +- Interview prep (practical) +- Project-based learning (contextual) +- Thread-based learning (sequential) + +### 2. **AI-Powered Personalization** +- Content adapts to user's learning path +- Difficulty levels automatically adjusted +- Context-aware responses +- Follow-up question support + +### 3. **Real-Time Streaming** +- No waiting for complete responses +- Progressive content loading +- Better user experience +- Efficient resource usage + +### 4. **Project Context Awareness** +- Upload your actual code +- Get answers based on YOUR project +- No generic responses +- Learn from your own codebase + +### 5. **Comprehensive Coverage** +- Any programming language +- Any framework or technology +- Interview preparation +- Practical coding problems +- Theoretical concepts + +--- + +## 📊 Feature Comparison + +| Feature | ProgChain | Stack Overflow | LeetCode | Coursera | +|---------|-----------|----------------|----------|----------| +| AI-Powered Q&A | ✅ | ❌ | ❌ | ❌ | +| Topic Exploration | ✅ | ❌ | ❌ | ✅ | +| Interview Prep | ✅ | ❌ | ✅ | ❌ | +| Project Context | ✅ | ❌ | ❌ | ❌ | +| Streaming Responses | ✅ | ❌ | ❌ | ❌ | +| Personalized Paths | ✅ | ❌ | ❌ | ✅ | +| Free to Use | ✅* | ✅ | Partial | Partial | + +*Requires OpenAI API key + +--- + +## 🎓 Learning Workflows + +### Beginner Workflow +``` +1. Start with Explore Mode + → Ask: "What is Python?" + → Get foundational explanation + +2. Use Topic Explorer + → Generate learning path for Python + → Follow beginner → intermediate → advanced + +3. Practice with Interview Questions + → Test understanding + → Get immediate feedback +``` + +### Intermediate Workflow +``` +1. Create Learning Thread + → Topic: "Advanced JavaScript Patterns" + → Get structured multi-part content + +2. Deep Dive with Projects + → Upload your code + → Ask specific questions + → Get contextual answers + +3. Interview Preparation + → Generate questions for target role + → Practice explanations +``` + +### Advanced Workflow +``` +1. Project-Based Learning + → Upload entire codebase + → Ask architecture questions + → Get refactoring suggestions + +2. Specialized Topics + → Explore cutting-edge concepts + → Generate custom learning paths + → Deep technical discussions +``` + +--- + +## 🔮 Future Feature Possibilities + +Based on the current architecture, here are potential features: + +### Planned/In Development +1. **Infinity Mode Expansion** - More learning modes +2. **User Authentication** - Personal accounts +3. **Progress Tracking** - Learning analytics +4. **Code Execution** - Run code in browser +5. **Collaborative Learning** - Share with others + +### Technical Enhancements +1. **PostgreSQL Migration** - Better scalability +2. **Redis Caching** - Faster responses +3. **Rate Limiting** - Fair usage +4. **Multi-Language Support** - i18n +5. **Mobile App** - React Native + +### Learning Features +1. **Quiz Generation** - Test knowledge +2. **Code Challenges** - Practice problems +3. **Video Integration** - Multimedia learning +4. **Spaced Repetition** - Memory retention +5. **Peer Review** - Community feedback + +--- + +## 💡 Use Cases + +### 1. **Self-Taught Developers** +- Learn new languages systematically +- Get instant answers to questions +- Build structured knowledge + +### 2. **Interview Preparation** +- Practice technical questions +- Understand concepts deeply +- Build confidence + +### 3. **Professional Development** +- Learn new frameworks quickly +- Understand existing codebases +- Stay current with technology + +### 4. **Students** +- Supplement coursework +- Get additional explanations +- Practice for exams + +### 5. **Code Reviewers** +- Understand unfamiliar code +- Learn best practices +- Improve code quality + +--- + +## 🎯 Getting Started + +### Quick Start +1. **Explore Mode**: Ask any programming question +2. **Topic Explorer**: Enter a technology you want to learn +3. **Interview Prep**: Select your target role/technology +4. **Projects**: Upload code for contextual help +5. **Threads**: Generate structured learning content + +### Best Practices +- Start broad, then go deep +- Use multiple learning modes +- Upload real projects for better context +- Save important conversations +- Follow difficulty progressions + +--- + +## 📈 Feature Metrics + +### Current Capabilities +- **5 Main Learning Modes** +- **15+ API Endpoints** +- **50+ Frontend Components** +- **Multiple AI Models Supported** +- **Unlimited Topics Coverage** +- **Real-time Streaming** +- **Vector Search Enabled** +- **Multi-Format File Support** + +--- + +## 🔗 Feature Dependencies + +``` +Core Infrastructure: +├── FastAPI (Backend) +├── React (Frontend) +├── OpenAI API (AI) +└── SQLite (Database) + +Learning Features: +├── Topic Explorer +│ ├── AI Generation +│ ├── Difficulty Rating +│ └── Visual Display +│ +├── Explore Mode +│ ├── Conversation AI +│ ├── Vector Search +│ └── Chat History +│ +├── Interview Prep +│ ├── Question Generation +│ └── Streaming Responses +│ +├── Threads +│ ├── Content Generation +│ ├── Thread Management +│ └── Interactive Chat +│ +└── Projects + ├── File Upload + ├── Vector Indexing + └── Context-Aware AI +``` + +--- + +## 📝 Summary + +ProgChain is a comprehensive AI-powered learning platform that combines: +- **Structured learning** (Topic Explorer, Threads) +- **Conversational learning** (Explore Mode) +- **Practical application** (Interview Prep, Projects) +- **Modern technology** (Real-time streaming, Vector search) +- **Flexible architecture** (Extensible, modular) + +It's designed to help developers at all levels learn more effectively by providing multiple learning modes, AI assistance, and personalized experiences. From feae63e434faa16eece3c735a3e47703561171c6 Mon Sep 17 00:00:00 2001 From: Claude Date: Sat, 15 Nov 2025 21:32:49 +0000 Subject: [PATCH 2/3] refactor: remove infinity and projects features Remove infinity mode and project management features from both frontend and backend to streamline the application focus. Backend changes: - Delete server/src/features/infinity/ directory and all submodules - Delete server/src/features/projects/ directory and all submodules - Remove infinity_router from server.py - Remove infinity_router from features/__init__.py Frontend changes: - Delete client/src/components/projects/ directory - Remove Projects import and route from App.tsx - Remove /infinity and /projects menu items from menuItems.tsx - Clean up unused icon imports (Infinity, Code) Documentation updates: - Update FEATURES.md to reflect 4 core learning modes - Update README.md core features section - Remove all references to infinity and project management The application now focuses on 4 core learning modes: 1. Topic Explorer - Hierarchical learning paths 2. Interview Preparation - Technical interview questions 3. Explore Mode - Conversational learning assistant 4. Learning Threads - Structured content generation --- FEATURES.md | 153 +---- README.md | 3 +- client/src/App.tsx | 2 - client/src/components/layout/menuItems.tsx | 16 - client/src/components/projects/Projects.tsx | 13 - .../projects/home/ProjectCreate.tsx | 140 ---- .../projects/home/ProjectCreateForm.tsx | 192 ------ .../components/projects/home/ProjectList.tsx | 129 ---- .../projects/project/ChatHistory.tsx | 202 ------ .../components/projects/project/Project.tsx | 80 --- .../projects/project/ProjectFiles.tsx | 344 ---------- .../projects/project/ProjectHeader.tsx | 90 --- .../projects/project/ProjectKnowledge.tsx | 154 ----- server/src/features/__init__.py | 4 +- server/src/features/infinity/__init__.py | 3 - server/src/features/infinity/base.py | 59 -- server/src/features/infinity/handlers.py | 19 - .../features/infinity/handlers/__init__.py | 7 - .../src/features/infinity/handlers/topic.py | 40 -- server/src/features/infinity/impls.py | 644 ------------------ server/src/features/infinity/models.py | 29 - server/src/features/infinity/registry.py | 71 -- .../features/infinity/services/__init__.py | 0 server/src/features/projects/__init__.py | 6 - server/src/features/projects/file_manager.py | 129 ---- server/src/features/projects/handler.py | 33 - server/src/features/projects/models.py | 77 --- server/src/features/projects/service.py | 47 -- server/src/server.py | 4 +- 29 files changed, 32 insertions(+), 2658 deletions(-) delete mode 100644 client/src/components/projects/Projects.tsx delete mode 100644 client/src/components/projects/home/ProjectCreate.tsx delete mode 100644 client/src/components/projects/home/ProjectCreateForm.tsx delete mode 100644 client/src/components/projects/home/ProjectList.tsx delete mode 100644 client/src/components/projects/project/ChatHistory.tsx delete mode 100644 client/src/components/projects/project/Project.tsx delete mode 100644 client/src/components/projects/project/ProjectFiles.tsx delete mode 100644 client/src/components/projects/project/ProjectHeader.tsx delete mode 100644 client/src/components/projects/project/ProjectKnowledge.tsx delete mode 100644 server/src/features/infinity/__init__.py delete mode 100644 server/src/features/infinity/base.py delete mode 100644 server/src/features/infinity/handlers.py delete mode 100644 server/src/features/infinity/handlers/__init__.py delete mode 100644 server/src/features/infinity/handlers/topic.py delete mode 100644 server/src/features/infinity/impls.py delete mode 100644 server/src/features/infinity/models.py delete mode 100644 server/src/features/infinity/registry.py delete mode 100644 server/src/features/infinity/services/__init__.py delete mode 100644 server/src/features/projects/__init__.py delete mode 100644 server/src/features/projects/file_manager.py delete mode 100644 server/src/features/projects/handler.py delete mode 100644 server/src/features/projects/models.py delete mode 100644 server/src/features/projects/service.py diff --git a/FEATURES.md b/FEATURES.md index a6e3e1f..4d74b2c 100644 --- a/FEATURES.md +++ b/FEATURES.md @@ -1,7 +1,7 @@ # ProgChain Features Documentation ## Overview -ProgChain is an AI-powered learning platform that helps developers learn programming concepts, prepare for technical interviews, and manage coding projects. It combines multiple learning modes with AI assistance to create personalized learning experiences. +ProgChain is an AI-powered learning platform that helps developers learn programming concepts, prepare for technical interviews, and create structured learning paths. It provides personalized learning experiences through multiple learning modes powered by AI. --- @@ -156,75 +156,6 @@ User creates thread: "Advanced React Patterns" --- -### 5. **Project Management** - File-Based Knowledge System - -**What it does**: Manage coding projects with file uploads and AI-powered project understanding. - -**Key Features**: -- **Project Creation**: Create and organize multiple projects -- **File Upload**: Upload project files (code, docs, etc.) -- **Vector Database**: Each project has its own vector store for semantic search -- **Project Chat**: Ask questions about your project files -- **File Context**: AI answers are grounded in your actual project files -- **Chat History**: Maintains conversation history per project - -**API Endpoints**: -- `POST /projects/create` - Create a new project -- `POST /projects/upload-file` - Upload files to a project - -**Database Models**: -- `Project`: Project metadata (title, description, vector DB path) -- `ProjectFiles`: Uploaded files with paths -- `ProjectChats`: Chat sessions for each project -- `ProjectChatMessages`: Individual messages with file context - -**Frontend Component**: `client/src/components/projects/Projects.tsx` - -**Example Workflow**: -``` -1. Create project: "E-commerce API" -2. Upload files: server.js, routes.js, models.js -3. System indexes files in vector database -4. User asks: "How is authentication handled?" -5. AI searches through files and provides answer based on actual code -``` - ---- - -### 6. **Infinity Mode** - Extensible Learning Modes (Beta) - -**What it does**: Provides a registry system for different learning modes and content generation. - -**Key Features**: -- **Mode Registry**: Pluggable system for different learning experiences -- **Topic Generation**: Mass generate learning topics -- **Categorization**: Organize topics by categories -- **Extensible Architecture**: Easy to add new learning modes - -**API Endpoints**: -- `POST /infinity/topics/generate` - Generate multiple topic titles - -**Frontend Integration**: Can be extended for new learning modes - ---- - -### 7. **LeetCode Problem Scraper** (Utility) - -**What it does**: Scrapes LeetCode problems for offline practice and learning. - -**Key Features**: -- **Selenium-Based Scraping**: Automated browser scraping -- **Problem Details**: Extracts descriptions, tags, examples -- **Multi-Processing**: Parallel scraping for efficiency -- **JSON Export**: Saves problems in structured format -- **Retry Logic**: Handles failures gracefully - -**Files**: `server/src/scrape/problem_scrape.py` - -**Use Case**: Build a local database of coding problems for practice - ---- - ## 🎨 Frontend Features ### UI Components @@ -254,7 +185,6 @@ User creates thread: "Advanced React Patterns" /topics → Topic Explorer /interview → Interview Prep /threads → Learning Threads -/projects → Project Management /history → Chat History ``` @@ -281,11 +211,6 @@ User creates thread: "Advanced React Patterns" - SQLAlchemy ORM (async) - Database models with mixins (timestamps, public IDs) -**File Processing**: -- **PyMuPDF**: PDF reading -- **python-docx**: Word document processing -- Multiple PDF libraries (pypdf, PyPDF2, pdfminer) - ### Frontend Stack **Framework**: React 18 + TypeScript @@ -304,18 +229,16 @@ User creates thread: "Advanced React Patterns" - React Markdown for content - Syntax highlighting - Math rendering (KaTeX) -- PDF viewing --- ## 🌟 Unique Selling Points ### 1. **Multi-Modal Learning** -Unlike single-purpose learning platforms, ProgChain offers: +ProgChain offers different learning approaches: - Topic exploration (structured) - Conversational learning (flexible) - Interview prep (practical) -- Project-based learning (contextual) - Thread-based learning (sequential) ### 2. **AI-Powered Personalization** @@ -330,17 +253,10 @@ Unlike single-purpose learning platforms, ProgChain offers: - Better user experience - Efficient resource usage -### 4. **Project Context Awareness** -- Upload your actual code -- Get answers based on YOUR project -- No generic responses -- Learn from your own codebase - -### 5. **Comprehensive Coverage** +### 4. **Comprehensive Coverage** - Any programming language - Any framework or technology - Interview preparation -- Practical coding problems - Theoretical concepts --- @@ -352,7 +268,6 @@ Unlike single-purpose learning platforms, ProgChain offers: | AI-Powered Q&A | ✅ | ❌ | ❌ | ❌ | | Topic Exploration | ✅ | ❌ | ❌ | ✅ | | Interview Prep | ✅ | ❌ | ✅ | ❌ | -| Project Context | ✅ | ❌ | ❌ | ❌ | | Streaming Responses | ✅ | ❌ | ❌ | ❌ | | Personalized Paths | ✅ | ❌ | ❌ | ✅ | | Free to Use | ✅* | ✅ | Partial | Partial | @@ -384,10 +299,9 @@ Unlike single-purpose learning platforms, ProgChain offers: → Topic: "Advanced JavaScript Patterns" → Get structured multi-part content -2. Deep Dive with Projects - → Upload your code +2. Deep Dive with Explore Mode → Ask specific questions - → Get contextual answers + → Get detailed explanations 3. Interview Preparation → Generate questions for target role @@ -396,10 +310,9 @@ Unlike single-purpose learning platforms, ProgChain offers: ### Advanced Workflow ``` -1. Project-Based Learning - → Upload entire codebase - → Ask architecture questions - → Get refactoring suggestions +1. Thread-Based Learning + → Create comprehensive topic threads + → Study each section systematically 2. Specialized Topics → Explore cutting-edge concepts @@ -414,11 +327,11 @@ Unlike single-purpose learning platforms, ProgChain offers: Based on the current architecture, here are potential features: ### Planned/In Development -1. **Infinity Mode Expansion** - More learning modes -2. **User Authentication** - Personal accounts -3. **Progress Tracking** - Learning analytics -4. **Code Execution** - Run code in browser -5. **Collaborative Learning** - Share with others +1. **User Authentication** - Personal accounts +2. **Progress Tracking** - Learning analytics +3. **Code Execution** - Run code in browser +4. **Collaborative Learning** - Share with others +5. **Spaced Repetition** - Memory retention ### Technical Enhancements 1. **PostgreSQL Migration** - Better scalability @@ -431,8 +344,8 @@ Based on the current architecture, here are potential features: 1. **Quiz Generation** - Test knowledge 2. **Code Challenges** - Practice problems 3. **Video Integration** - Multimedia learning -4. **Spaced Repetition** - Memory retention -5. **Peer Review** - Community feedback +4. **Peer Review** - Community feedback +5. **Flashcards** - Quick review --- @@ -450,18 +363,18 @@ Based on the current architecture, here are potential features: ### 3. **Professional Development** - Learn new frameworks quickly -- Understand existing codebases - Stay current with technology +- Deep dive into specific topics ### 4. **Students** - Supplement coursework - Get additional explanations - Practice for exams -### 5. **Code Reviewers** -- Understand unfamiliar code -- Learn best practices -- Improve code quality +### 5. **Technical Writers** +- Research topics thoroughly +- Generate structured content +- Understand complex concepts --- @@ -471,13 +384,11 @@ Based on the current architecture, here are potential features: 1. **Explore Mode**: Ask any programming question 2. **Topic Explorer**: Enter a technology you want to learn 3. **Interview Prep**: Select your target role/technology -4. **Projects**: Upload code for contextual help -5. **Threads**: Generate structured learning content +4. **Threads**: Generate structured learning content ### Best Practices - Start broad, then go deep - Use multiple learning modes -- Upload real projects for better context - Save important conversations - Follow difficulty progressions @@ -486,14 +397,13 @@ Based on the current architecture, here are potential features: ## 📈 Feature Metrics ### Current Capabilities -- **5 Main Learning Modes** -- **15+ API Endpoints** -- **50+ Frontend Components** +- **4 Main Learning Modes** +- **12+ API Endpoints** +- **40+ Frontend Components** - **Multiple AI Models Supported** - **Unlimited Topics Coverage** - **Real-time Streaming** - **Vector Search Enabled** -- **Multi-Format File Support** --- @@ -521,15 +431,10 @@ Learning Features: │ ├── Question Generation │ └── Streaming Responses │ -├── Threads -│ ├── Content Generation -│ ├── Thread Management -│ └── Interactive Chat -│ -└── Projects - ├── File Upload - ├── Vector Indexing - └── Context-Aware AI +└── Threads + ├── Content Generation + ├── Thread Management + └── Interactive Chat ``` --- @@ -539,7 +444,7 @@ Learning Features: ProgChain is a comprehensive AI-powered learning platform that combines: - **Structured learning** (Topic Explorer, Threads) - **Conversational learning** (Explore Mode) -- **Practical application** (Interview Prep, Projects) +- **Practical application** (Interview Prep) - **Modern technology** (Real-time streaming, Vector search) - **Flexible architecture** (Extensible, modular) diff --git a/README.md b/README.md index 1d01418..3558f7a 100644 --- a/README.md +++ b/README.md @@ -8,8 +8,7 @@ This project is a comprehensive full-stack learning platform I've built to help - **Interactive Concept Exploration**: Users can ask questions about programming topics and follow a guided learning path that branches based on their interests. - **Topic Learning Journeys**: The platform generates personalized learning paths for any programming concept, organized by difficulty level. - **Technical Interview Preparation**: Practice with AI-generated interview questions tailored to specific technologies and difficulty levels. -- **LeetCode-style Problem Practice**: A collection of coding challenges with AI-generated solutions and explanations. -- **Project Management**: Users can create and manage projects, upload relevant files, and maintain project-specific knowledge bases. +- **Learning Threads**: Create structured multi-part learning content organized as sequential threads with interactive Q&A. ## 🏗️ Architecture Overview diff --git a/client/src/App.tsx b/client/src/App.tsx index 5846ea9..474a8c7 100644 --- a/client/src/App.tsx +++ b/client/src/App.tsx @@ -5,7 +5,6 @@ import Explore from "@/components/explore/Explore"; import Interview from "@/components/interview/Interview"; import TopicChain from "@/components/topics/TopicChain"; -import Projects from "@/components/projects/Projects"; import { Toaster } from "@/components/ui/toaster"; import Thread from "@/components/thread/Thread"; import History from "./components/history/History"; @@ -26,7 +25,6 @@ function App() { } /> } /> } /> - } /> } /> } /> } /> diff --git a/client/src/components/layout/menuItems.tsx b/client/src/components/layout/menuItems.tsx index 10bb9a0..d3f1b8a 100644 --- a/client/src/components/layout/menuItems.tsx +++ b/client/src/components/layout/menuItems.tsx @@ -1,21 +1,12 @@ import { - Infinity, Book, Users, Compass, - Code, Dna, History, } from "lucide-react"; export const menuItems = [ - { - key: "/infinity", - icon: , - title: "Infinity", - description: "Explore programming topics", - gradient: "from-violet-500 to-indigo-500", - }, { key: "/topics", icon: , @@ -37,13 +28,6 @@ export const menuItems = [ description: "Discover new concepts", gradient: "from-orange-500 to-amber-500", }, - { - key: "/projects", - icon: , - title: "Projects", - description: "Showcase your projects", - gradient: "from-red-500 to-pink-500", - }, { key: "/threads", icon: , diff --git a/client/src/components/projects/Projects.tsx b/client/src/components/projects/Projects.tsx deleted file mode 100644 index 5d1b705..0000000 --- a/client/src/components/projects/Projects.tsx +++ /dev/null @@ -1,13 +0,0 @@ -import React from "react"; -import ProjectCreate from "./home/ProjectCreate"; -import Project from "./project/Project"; - -const Projects: React.FC = () => { - return ( -
- -
- ); -}; - -export default Projects; diff --git a/client/src/components/projects/home/ProjectCreate.tsx b/client/src/components/projects/home/ProjectCreate.tsx deleted file mode 100644 index 40d8041..0000000 --- a/client/src/components/projects/home/ProjectCreate.tsx +++ /dev/null @@ -1,140 +0,0 @@ -import React, { useState } from "react"; -import { motion, AnimatePresence } from "framer-motion"; -import { FolderPlus, FileCode, Files, Plus } from "lucide-react"; -import { Tabs, TabsContent, TabsList, TabsTrigger } from "@/components/ui/tabs"; -import { Button } from "@/components/ui/button"; -import PageHeader from "@/components/utils/PageHeader"; -import ProjectCreateForm from "./ProjectCreateForm"; -import ProjectList from "./ProjectList"; - -const ProjectCreate: React.FC = () => { - const [activeTab, setActiveTab] = useState("projects"); - - return ( - - -
- - -
- -
- - , - , - , - ]} - /> - - -
- - - All Projects - - - Create New - - - - -
- - - - - - - - - - -
-
-
-
-
- ); -}; - -const containerVariants = { - hidden: { opacity: 0 }, - visible: { - opacity: 1, - transition: { - staggerChildren: 0.15, - delayChildren: 0.2, - }, - }, -}; - -const itemVariants = { - hidden: { opacity: 0, y: 20 }, - visible: { opacity: 1, y: 0 }, -}; - -export default ProjectCreate; diff --git a/client/src/components/projects/home/ProjectCreateForm.tsx b/client/src/components/projects/home/ProjectCreateForm.tsx deleted file mode 100644 index a23fffc..0000000 --- a/client/src/components/projects/home/ProjectCreateForm.tsx +++ /dev/null @@ -1,192 +0,0 @@ -import React, { useState } from "react"; -import { Card, CardContent } from "@/components/ui/card"; -import { Input } from "@/components/ui/input"; -import { Textarea } from "@/components/ui/textarea"; -import { Button } from "@/components/ui/button"; -import { Upload } from "lucide-react"; -import { cn } from "@/lib/utils"; -import { motion } from "framer-motion"; -import { Alert, AlertDescription } from "../../ui/alert"; - -const ProjectCreateForm: React.FC = () => { - const [description, setDescription] = useState(""); - const [files, setFiles] = useState([]); - const [isTyping, setIsTyping] = useState(false); - const [projectName, setProjectName] = useState(""); - const [error, setError] = useState(""); - - const removeFile = (indexToRemove: number) => { - setFiles((prev) => prev.filter((_, index) => index !== indexToRemove)); - }; - - const handleFileChange = (e: React.ChangeEvent) => { - const selectedFiles = Array.from(e.target.files || []); - setFiles((prev) => [...prev, ...selectedFiles]); - }; - - const handleSubmit = async (e: React.FormEvent) => { - e.preventDefault(); - if (!projectName.trim()) { - setError("Project name is required"); - return; - } - - const formData = new FormData(); - formData.append("projectName", projectName); - formData.append("description", description); - files.forEach((file) => { - formData.append("files", file); - }); - - try { - const response = await fetch("/api/projects", { - method: "POST", - body: formData, - }); - - if (!response.ok) throw new Error("Failed to create project"); - } catch (err) { - setError((err as Error).message); - } - }; - - return ( - - -
-
-
-
-
- { - setProjectName(e.target.value); - setIsTyping(true); - }} - onBlur={() => setIsTyping(false)} - className={cn( - "w-full p-6 text-lg bg-transparent border-0", - "focus:ring-0 placeholder:text-zinc-500", - "transition-all duration-300" - )} - /> -
-
-
- -
-