Skip to content

jjacobo-00/Primary-5-Math-Problem

Repository files navigation

Math Problem Generator

Overview

This is a starter kit for building an AI-powered math problem generator application. The goal is to create a standalone prototype that uses AI to generate math word problems suitable for Primary 5 students, saves the problems and user submissions to a database, and provides personalized feedback.

Tech Stack

  • Frontend Framework: Next.js 14 (App Router)
  • Language: TypeScript
  • Styling: Tailwind CSS
  • Database: Supabase
  • AI Integration: Google Generative AI (Gemini)

Setup Instructions

1. Clone the Repository

git clone <your-repo-url>
cd math-problem-generator

2. Create a Supabase Project

  1. Go to https://supabase.com and create a free account
  2. Create a new project
  3. Go to Settings → API to find your:
    • Project URL (starts with https://)
    • Anon/Public Key

3. Set Up Database Tables

  1. In your Supabase dashboard, go to SQL Editor
  2. Copy and paste the contents of database.sql
  3. Click "Run" to create the tables and policies

4. Get Google API Key

  1. Go to Google AI Studio
  2. Create a new API key for Gemini

5. Configure Environment Variables

  1. Copy .env.local.example to .env.local:
    cp .env.local.example .env.local
  2. Edit .env.local and add your actual keys:
    NEXT_PUBLIC_SUPABASE_URL=your_actual_supabase_url
    NEXT_PUBLIC_SUPABASE_ANON_KEY=your_actual_supabase_anon_key
    GOOGLE_API_KEY=your_actual_google_api_key
    

6. Install Dependencies

npm install

7. Run the Development Server

npm run dev

Open http://localhost:3000 in your browser.

About

A full-stack prototype application designed for a developer assessment. This project leverages the Google Gemini API to generate personalized math word problems and feedback for Primary 5 (age 10-11) students. Supabase handles authentication and data persistence for sessions and submissions.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors