A modern, terminal-inspired portfolio website built with Next.js 15, featuring an AI-powered chatbot with RAG (Retrieval-Augmented Generation) capabilities and a responsive bento grid layout.
- AI-powered Chatbot: Interactive portfolio exploration using LangChain and OpenAI, with vector search capabilities through Supabase pgvector for context-aware responses
- Bento Grid Layout: Modern, responsive grid design that adapts seamlessly between desktop and mobile views
- Terminal Aesthetic: Developer-focused design with terminal-inspired UI elements, typing animations, and command-style interactions
- Global Theming: Centralized CSS variable system with full dark/light mode support across all components
- Blog System: Markdown-based blog with reading time estimation, syntax highlighting, and table of contents
- Configurable Content: All portfolio data (projects, skills, experience, education) managed through TypeScript config files
- Framework: Next.js 15 with App Router
- Language: TypeScript
- Styling: Tailwind CSS with CSS variables for theming
- Animations: Framer Motion
- Database: Supabase with pgvector for vector embeddings
- AI/ML:
- LangChain for RAG-based chat functionality
- OpenAI for embeddings and completions
- Vercel AI SDK for streaming responses
- UI Components:
- Radix UI primitives (Dialog, Label, Slot)
- Lucide React icons
- Custom terminal-style components
- Content:
- React Markdown with GFM support
- Gray Matter for frontmatter parsing
- React Syntax Highlighter for code blocks
- Hero: Personal introduction with animated role typing, availability status, and social links
- Products/Projects: Showcase of featured projects with images, tech stack, and status badges
- Skills: Categorized skill display with progress indicators (Frontend, Backend, Database, AI/ML)
- AI Capabilities: Highlights of AI/ML expertise and interests
- Experience: Professional timeline with role details and technologies
- Blog: Latest blog posts with category filtering
- CTA: Contact section with email and LinkedIn links
- AI Chat Widget: Floating chatbot for interactive portfolio exploration
- Node.js 18.17 or later
- npm or yarn package manager
- Git
- Supabase account (free tier works)
- OpenAI API key
-
Clone the Repository
git clone https://github.com/medevs/smart-portfolio.git cd smart-portfolio -
Install Dependencies
npm install
-
Set Up Environment Variables
cp .env.example .env.local
Then edit
.env.localwith your credentials:Variable Description Where to Get SUPABASE_URLYour Supabase project URL Supabase Dashboard → Settings → API SUPABASE_ANON_KEYPublic anonymous key Supabase Dashboard → Settings → API OPENAI_API_KEYOpenAI API key OpenAI Platform -
Set Up Supabase Database
Option A: Using Supabase Dashboard (Recommended for beginners)
- Create a new project at supabase.com
- Go to the SQL Editor in your project dashboard
- Run each migration file in order from
supabase/migrations/:20240101000000_enable_pgvector.sql20240101000001_create_documents_table.sql20240101000002_create_match_function.sql
Option B: Using Supabase CLI
# Install Supabase CLI if you haven't npm install -g supabase # Link to your remote project supabase link --project-ref your-project-ref # Push migrations supabase db push
-
Generate Embeddings
npm run generate
This populates the database with document embeddings for the AI chat.
-
Start Development Server
npm run dev
Open http://localhost:3000 to view the site.
All portfolio content is managed through TypeScript config files in src/config/:
personal.ts- Name, email, location, availability statusprojects.ts- Featured projects with descriptions and tech stackexperience.ts- Work history and timelineeducation.ts- Educational backgroundskills.ts- Skill categories and proficiency levelssocial.ts- Social media linksai.ts- AI capabilities displayseo.ts- SEO metadata
The project uses Supabase with pgvector for AI-powered semantic search:
documentstable: Stores content chunks with vector embeddingsmatch_documentsfunction: Performs cosine similarity search for RAG
Migration files are located in supabase/migrations/ for version control.
| Variable | Required | Description |
|---|---|---|
SUPABASE_URL |
Yes | Your Supabase project URL |
SUPABASE_ANON_KEY |
Yes | Supabase anonymous (public) key |
OPENAI_API_KEY |
Yes | OpenAI API key for embeddings & chat |
SUPABASE_SERVICE_ROLE_KEY |
No | Only for local CLI migrations |
Note: These are server-side variables. Do NOT prefix with
NEXT_PUBLIC_as they contain sensitive keys.
npm run build
npm run startnpm run dev- Start development servernpm run build- Generate embeddings and build for productionnpm run generate- Generate vector embeddings for RAGnpm run start- Start production servernpm run lint- Run ESLint
src/
├── app/ # Next.js App Router pages
│ ├── api/chat/ # AI chat API endpoint
│ ├── blog/ # Blog pages
│ └── page.tsx # Home page with bento grid
├── components/
│ ├── chat/ # AI chatbot components
│ ├── sections/ # Page sections (Hero, Skills, etc.)
│ ├── terminal/ # Terminal-style UI components
│ └── ui/ # Reusable UI primitives
├── config/ # Portfolio configuration files
└── lib/ # Utility functions
This project is licensed under the MIT License - see the LICENSE file for details.