Thanks to visit codestin.com
Credit goes to GitHub.com

Skip to content

shyjutech/devroad-ai

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

2 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

DevRoad AI - AI-Powered Developer Roadmap Generator

🎯 Your Personalized Learning Roadmap, Powered by Gemini

Generate detailed, actionable developer roadmaps with curated resources based on your goals and experience level.

🌟 Features

  • AI-Powered Roadmaps: Uses Google Gemini 2.5 Pro to generate personalized learning paths
  • Multiple Categories: DevOps, Flutter, React, Backend, AI/ML, Data Science
  • Experience-Based: Tailored for Beginner, Intermediate, or Advanced learners
  • Structured Output: Step-by-step learning path with resources, tools, projects, and timelines
  • Beautiful UI: Modern, responsive design with dark mode support
  • Export Options: Copy roadmap as text or export as JSON
  • Production-Ready: Deployed on Firebase Hosting with Cloud Functions

πŸ—οΈ Tech Stack

  • Frontend: React 18 + Vite + TailwindCSS
  • Backend: Firebase Cloud Functions (Node.js 20)
  • AI: Google Gemini 2.5 Pro / 1.5 Pro
  • Hosting: Firebase Hosting
  • Security: Firebase Secrets for API keys

πŸ“ Project Structure

devroad/
β”œβ”€β”€ functions/           # Firebase Cloud Functions
β”‚   β”œβ”€β”€ index.js        # Gemini API integration
β”‚   └── package.json
β”œβ”€β”€ web/                # React frontend
β”‚   β”œβ”€β”€ src/
β”‚   β”‚   β”œβ”€β”€ App.jsx
β”‚   β”‚   β”œβ”€β”€ components/
β”‚   β”‚   β”‚   β”œβ”€β”€ Logo.jsx
β”‚   β”‚   β”‚   β”œβ”€β”€ RoadmapForm.jsx
β”‚   β”‚   β”‚   β”œβ”€β”€ RoadmapView.jsx
β”‚   β”‚   β”‚   β”œβ”€β”€ AccordionSection.jsx
β”‚   β”‚   β”‚   β”œβ”€β”€ ThemeToggle.jsx
β”‚   β”‚   β”‚   └── actions/
β”‚   β”‚   β”‚       └── CopyExport.jsx
β”‚   β”‚   β”œβ”€β”€ index.css
β”‚   β”‚   └── main.jsx
β”‚   β”œβ”€β”€ package.json
β”‚   └── vite.config.js
β”œβ”€β”€ firebase.json       # Firebase configuration
└── .firebaserc        # Firebase project ID

πŸš€ Quick Start

Prerequisites

  • Node.js 20+ installed
  • Firebase CLI: npm i -g firebase-tools
  • Firebase account with a project created
  • Google Gemini API key (Get one here)

Installation

  1. Clone the repository

    git clone <your-repo-url>
    cd devroad
  2. Install dependencies

    # Frontend
    cd web
    npm install
    npm install -D @vitejs/plugin-react
    
    # Backend
    cd ../functions
    npm install
  3. Configure Firebase

    • Update .firebaserc with your Firebase project ID:
      {
        "projects": {
          "default": "YOUR_PROJECT_ID"
        }
      }
    • Initialize Firebase (if not already done):
      firebase init hosting
      firebase init functions
  4. Set Gemini API Key

    cd functions
    firebase functions:secrets:set GEMINI_API_KEY
    # Paste your Gemini API key when prompted
  5. Build and Deploy

    # Build frontend
    cd ../web
    npm run build
    
    # Deploy everything
    cd ..
    firebase deploy

πŸ§ͺ Local Development

Option 1: With Firebase Emulators (Recommended)

  1. Start emulators

    cd functions
    export GEMINI_API_KEY=YOUR_API_KEY  # Only needed for local dev
    firebase emulators:start --only functions,hosting
  2. Access the app

Option 2: Vite Dev Server (Mock Mode)

For frontend-only development without backend:

cd web
VITE_DISABLE_BACKEND=true npm run dev

Access: http://localhost:5173

πŸ” Security Notes

βœ… Safe to Push to Public Repo

  • All secrets are stored in Firebase Secrets (not in code)
  • .firebaserc only contains project ID (safe to share)
  • No API keys or credentials in the repository
  • .gitignore excludes sensitive files

Important: Never commit:

  • .env files
  • API keys in code
  • node_modules/
  • Build artifacts

πŸ“‘ API Endpoint

Generate Roadmap

Endpoint: POST /api/generateRoadmap

Request Body:

{
  "category": "Flutter",
  "experience": "Beginner",
  "known_languages": "Dart, JavaScript",
  "goal": "Become a Flutter mobile app developer"
}

Response:

{
  "overview": "...",
  "steps": [
    {
      "title": "Foundations",
      "details": "...",
      "resources": ["..."]
    }
  ],
  "tools": ["VS Code", "Flutter SDK"],
  "projects": ["Build a todo app", "Create a weather app"],
  "duration_weeks": 12,
  "bonus_tips": ["Join Flutter community", "..."]
}

🎨 Customization

Update Categories

Edit web/src/components/RoadmapForm.jsx:

const CATEGORIES = ['DevOps', 'Flutter', 'React', 'Backend', 'AI/ML', 'Data Science'];

Update Experience Levels

Edit web/src/components/RoadmapForm.jsx:

const LEVELS = ['Beginner', 'Intermediate', 'Advanced'];

Change Gemini Model

Edit functions/index.js:

const modelNames = ["gemini-2.5-pro", "gemini-1.5-pro", "gemini-1.5-flash", "gemini-pro"];

πŸ“ Roadmap Schema

The AI generates roadmaps matching this JSON schema:

{
  overview: string;
  steps: Array<{
    title: string;
    details: string;
    resources: string[];
  }>;
  tools: string[];
  projects: string[];
  duration_weeks: number;
  bonus_tips: string[];
}

🚨 Troubleshooting

401 Unauthorized Error

  • Ensure Gemini API key is set: firebase functions:secrets:set GEMINI_API_KEY
  • Verify API key has Generative Language API enabled in Google Cloud Console
  • Check billing is enabled for your Firebase/GCP project

404 Model Not Found

  • The function automatically tries fallback models: gemini-2.5-pro β†’ gemini-1.5-pro β†’ gemini-1.5-flash β†’ gemini-pro
  • Ensure your API key has access to at least one of these models

Function Deployment Issues

  • Ensure Firebase CLI is logged in: firebase login
  • Check project ID in .firebaserc matches your Firebase project
  • Verify Node.js version: Functions require Node.js 20

πŸ“„ License

MIT License - feel free to use this project for your own purposes.

🀝 Contributing

Contributions welcome! Please open an issue or submit a pull request.

πŸ“§ Support

For issues or questions, open an issue on GitHub.


Built with ❀️ using React, TailwindCSS, Firebase, and Google Gemini AI

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •