Chunporo/anna-speaking-coach

Anna is a web app for Vietnamese learners to practice IELTS speaking with AI-powered feedback and progress tracking

4

stars

27

commits

Python

primary language

Dec 27, 2025

updated

ai-education
english-learning
english-speaking
fastapi
ielts
python
speech-api
typescirpt
whisper-turbo

README

IELTS Speaking Practice Platform Banner

🎀 IELTS Speaking Practice Platform

A comprehensive full-stack web application for IELTS speaking practice with AI-powered feedback

license FastAPI Next.js PostgreSQL TypeScript Tailwind CSS Whisper TTS
features quick-start tech-stack issues stars

πŸ“– Overview

A full-stack web application for IELTS speaking practice, built with FastAPI (backend) and Next.js with Tailwind CSS (frontend). Features AI-powered speech transcription using Whisper and text-to-speech for question audio playback.

✨ Features

  • 🏠 Homepage Dashboard - Progress tracking, streaks, and GitHub-style activity calendar
  • πŸ“ Practice by Question - Practice questions from Part 1, 2, and 3 with instant feedback
  • 🎯 Mock Tests - Take full or partial mock tests simulating real IELTS exam conditions
  • πŸ“Š Progress Tracking - Daily progress, streaks, and part-wise progress analytics
  • πŸ‘€ User Management - Secure authentication with Google OAuth support
  • πŸ“ˆ Activity Calendar - Visual GitHub-style contribution graph showing practice history
  • 🎀 AI-Powered Transcription - Automatic speech-to-text using Whisper AI
  • πŸ”Š Text-to-Speech - Question audio playback using Puter.js TTS
  • πŸ“± Responsive Design - Beautiful UI built with Tailwind CSS
  • πŸ”„ Real-time Updates - Live progress tracking and streak management

πŸ“‹ Table of Contents

πŸ“ Project Structure

english_speaking_test/
β”œβ”€β”€ backend/          # FastAPI backend
β”‚   β”œβ”€β”€ app/
β”‚   β”‚   β”œβ”€β”€ routers/  # API routes
β”‚   β”‚   β”œβ”€β”€ models.py # Database models
β”‚   β”‚   β”œβ”€β”€ schemas.py # Pydantic schemas
β”‚   β”‚   └── main.py   # FastAPI app
β”‚   β”œβ”€β”€ database/
β”‚   β”‚   └── schema.sql # Database schema
β”‚   └── requirements.txt
β”œβ”€β”€ frontend/         # Next.js frontend
β”‚   β”œβ”€β”€ app/          # Next.js app directory
β”‚   β”œβ”€β”€ components/   # React components
β”‚   β”œβ”€β”€ lib/          # Utilities and API client
β”‚   └── package.json
└── README.md

πŸš€ Quick Start

For detailed setup instructions, see Quick Start Guide.

Backend Setup

  1. Navigate to backend directory:
cd backend
  1. Create virtual environment and install dependencies:
python -m venv venv
source venv/bin/activate  # On Windows: venv\Scripts\activate
pip install -r requirements.txt
  1. Set up PostgreSQL database:
# Create database
createdb ielts_speaking

# Run schema
psql ielts_speaking < database/schema.sql
  1. Create .env file:
cp .env.example .env
# Edit .env with your database credentials:
# DATABASE_URL=postgresql://user:password@localhost:5432/ielts_speaking
# SECRET_KEY=your-secret-key-change-in-production
# GOOGLE_CLIENT_ID=your-google-client-id  # For Google OAuth
  1. Run the server:
uvicorn app.main:app --reload --port 8000

Backend will be available at http://localhost:8000 API docs at http://localhost:8000/docs

Frontend Setup

  1. Navigate to frontend directory:
cd frontend
  1. Install dependencies:
npm install
# or
yarn install
  1. Create .env.local file:
NEXT_PUBLIC_API_URL=http://localhost:8000
NEXT_PUBLIC_GOOGLE_CLIENT_ID=your-google-client-id  # For Google OAuth
  1. Run the development server:
npm run dev
# or
yarn dev

Frontend will be available at http://localhost:3000

πŸ—„οΈ Database Schema

The application uses PostgreSQL with the following main tables:

  • users - User accounts
  • questions - Practice questions
  • user_questions - Custom questions added by users
  • practice_sessions - Practice session records
  • mock_tests - Mock test records
  • daily_progress - Daily practice progress
  • streaks - User streak tracking
  • activity_calendar - Activity calendar data
  • part_progress - Progress by IELTS part (1, 2, 3)

See backend/database/schema.sql for the complete schema.

πŸ”Œ API Endpoints

Authentication

  • POST /api/auth/register - Register new user
  • POST /api/auth/login - Login
  • POST /api/auth/google - Login/Register with Google OAuth
  • GET /api/auth/me - Get current user

Questions

  • GET /api/questions/ - Get questions (with optional part and topic filters)
  • GET /api/questions/topics - Get all topics
  • GET /api/questions/user-questions - Get user's custom questions
  • POST /api/questions/user-questions - Create custom question
  • DELETE /api/questions/user-questions/{id} - Delete custom question

Practice

  • POST /api/practice/ - Create practice session
  • GET /api/practice/ - Get practice sessions

Mock Tests

  • POST /api/mock-test/ - Create mock test
  • GET /api/mock-test/ - Get mock tests
  • GET /api/mock-test/{id} - Get specific mock test

Progress

  • GET /api/progress/daily - Get daily progress
  • GET /api/progress/streak - Get streak info
  • GET /api/progress/activity-calendar - Get activity calendar
  • GET /api/progress/part-progress - Get part-wise progress

πŸ› οΈ Tech Stack

Backend

  • FastAPI - Modern Python web framework
  • SQLAlchemy - ORM
  • PostgreSQL - Database
  • Pydantic - Data validation
  • JWT - Authentication

Frontend

  • Next.js 14 - React framework
  • TypeScript - Type safety
  • Tailwind CSS - Styling
  • Axios - HTTP client
  • Zustand - State management

πŸ’» Development

Adding Questions

You can add questions to the database by inserting into the questions table:

INSERT INTO questions (part, topic, question_text) VALUES
(1, 'Doing something well', 'Do you have an experience when you did something well?'),
(1, 'Rules', 'Are there any rules for students at your school?');

Environment Variables

For detailed environment variable setup, see Environment Setup Guide.

Backend (.env):

  • DATABASE_URL - PostgreSQL connection string
  • SECRET_KEY - Secret key for JWT tokens
  • GOOGLE_CLIENT_ID - Google OAuth Client ID (get from Google Cloud Console)

Frontend (.env.local):

  • NEXT_PUBLIC_API_URL - Backend API URL
  • NEXT_PUBLIC_GOOGLE_CLIENT_ID - Google OAuth Client ID (same as backend)

πŸš€ Deployment

To deploy your application to production, see the comprehensive deployment guides:

  • Quick Start Deployment - Fast deployment options (Vercel + Railway)
  • Full Deployment Guide - Detailed instructions for multiple platforms:
    • Vercel + Railway/Render (Recommended)
    • Docker Compose
    • Traditional VPS (Ubuntu/Debian)
    • AWS/GCP/Azure

Quick Deploy

Easiest option: Deploy frontend to Vercel and backend to Railway. See DEPLOY_QUICKSTART.md for step-by-step instructions.

πŸ” Google OAuth Setup

  1. Go to Google Cloud Console
  2. Create a new project or select an existing one
  3. Enable Google+ API
  4. Go to "Credentials" β†’ "Create Credentials" β†’ "OAuth client ID"
  5. Configure OAuth consent screen
  6. Create OAuth 2.0 Client ID for Web application
  7. Add authorized JavaScript origins: http://localhost:3000 (for development)
  8. Add authorized redirect URIs: http://localhost:3000 (for development)
  9. Copy the Client ID and add it to both backend .env and frontend .env.local files

Note: For production, update the authorized origins and redirect URIs to your production domain.

πŸ“„ License

This project is licensed under the MIT License - see the LICENSE file for details.


Made with ❀️ for IELTS learners

⭐ Star this repo if you find it helpful!

Contributors

Chunporo

27 commits

Chunporo/anna-speaking-coach

Anna is a web app for Vietnamese learners to practice IELTS speaking with AI-powered feedback and progress tracking

4

stars

27

commits

Python

primary language

Dec 27, 2025

updated

ai-education
english-learning
english-speaking
fastapi
ielts
python
speech-api
typescirpt
whisper-turbo

README

IELTS Speaking Practice Platform Banner

🎀 IELTS Speaking Practice Platform

A comprehensive full-stack web application for IELTS speaking practice with AI-powered feedback

license FastAPI Next.js PostgreSQL TypeScript Tailwind CSS Whisper TTS
features quick-start tech-stack issues stars

πŸ“– Overview

A full-stack web application for IELTS speaking practice, built with FastAPI (backend) and Next.js with Tailwind CSS (frontend). Features AI-powered speech transcription using Whisper and text-to-speech for question audio playback.

✨ Features

  • 🏠 Homepage Dashboard - Progress tracking, streaks, and GitHub-style activity calendar
  • πŸ“ Practice by Question - Practice questions from Part 1, 2, and 3 with instant feedback
  • 🎯 Mock Tests - Take full or partial mock tests simulating real IELTS exam conditions
  • πŸ“Š Progress Tracking - Daily progress, streaks, and part-wise progress analytics
  • πŸ‘€ User Management - Secure authentication with Google OAuth support
  • πŸ“ˆ Activity Calendar - Visual GitHub-style contribution graph showing practice history
  • 🎀 AI-Powered Transcription - Automatic speech-to-text using Whisper AI
  • πŸ”Š Text-to-Speech - Question audio playback using Puter.js TTS
  • πŸ“± Responsive Design - Beautiful UI built with Tailwind CSS
  • πŸ”„ Real-time Updates - Live progress tracking and streak management

πŸ“‹ Table of Contents

πŸ“ Project Structure

english_speaking_test/
β”œβ”€β”€ backend/          # FastAPI backend
β”‚   β”œβ”€β”€ app/
β”‚   β”‚   β”œβ”€β”€ routers/  # API routes
β”‚   β”‚   β”œβ”€β”€ models.py # Database models
β”‚   β”‚   β”œβ”€β”€ schemas.py # Pydantic schemas
β”‚   β”‚   └── main.py   # FastAPI app
β”‚   β”œβ”€β”€ database/
β”‚   β”‚   └── schema.sql # Database schema
β”‚   └── requirements.txt
β”œβ”€β”€ frontend/         # Next.js frontend
β”‚   β”œβ”€β”€ app/          # Next.js app directory
β”‚   β”œβ”€β”€ components/   # React components
β”‚   β”œβ”€β”€ lib/          # Utilities and API client
β”‚   └── package.json
└── README.md

πŸš€ Quick Start

For detailed setup instructions, see Quick Start Guide.

Backend Setup

  1. Navigate to backend directory:
cd backend
  1. Create virtual environment and install dependencies:
python -m venv venv
source venv/bin/activate  # On Windows: venv\Scripts\activate
pip install -r requirements.txt
  1. Set up PostgreSQL database:
# Create database
createdb ielts_speaking

# Run schema
psql ielts_speaking < database/schema.sql
  1. Create .env file:
cp .env.example .env
# Edit .env with your database credentials:
# DATABASE_URL=postgresql://user:password@localhost:5432/ielts_speaking
# SECRET_KEY=your-secret-key-change-in-production
# GOOGLE_CLIENT_ID=your-google-client-id  # For Google OAuth
  1. Run the server:
uvicorn app.main:app --reload --port 8000

Backend will be available at http://localhost:8000 API docs at http://localhost:8000/docs

Frontend Setup

  1. Navigate to frontend directory:
cd frontend
  1. Install dependencies:
npm install
# or
yarn install
  1. Create .env.local file:
NEXT_PUBLIC_API_URL=http://localhost:8000
NEXT_PUBLIC_GOOGLE_CLIENT_ID=your-google-client-id  # For Google OAuth
  1. Run the development server:
npm run dev
# or
yarn dev

Frontend will be available at http://localhost:3000

πŸ—„οΈ Database Schema

The application uses PostgreSQL with the following main tables:

  • users - User accounts
  • questions - Practice questions
  • user_questions - Custom questions added by users
  • practice_sessions - Practice session records
  • mock_tests - Mock test records
  • daily_progress - Daily practice progress
  • streaks - User streak tracking
  • activity_calendar - Activity calendar data
  • part_progress - Progress by IELTS part (1, 2, 3)

See backend/database/schema.sql for the complete schema.

πŸ”Œ API Endpoints

Authentication

  • POST /api/auth/register - Register new user
  • POST /api/auth/login - Login
  • POST /api/auth/google - Login/Register with Google OAuth
  • GET /api/auth/me - Get current user

Questions

  • GET /api/questions/ - Get questions (with optional part and topic filters)
  • GET /api/questions/topics - Get all topics
  • GET /api/questions/user-questions - Get user's custom questions
  • POST /api/questions/user-questions - Create custom question
  • DELETE /api/questions/user-questions/{id} - Delete custom question

Practice

  • POST /api/practice/ - Create practice session
  • GET /api/practice/ - Get practice sessions

Mock Tests

  • POST /api/mock-test/ - Create mock test
  • GET /api/mock-test/ - Get mock tests
  • GET /api/mock-test/{id} - Get specific mock test

Progress

  • GET /api/progress/daily - Get daily progress
  • GET /api/progress/streak - Get streak info
  • GET /api/progress/activity-calendar - Get activity calendar
  • GET /api/progress/part-progress - Get part-wise progress

πŸ› οΈ Tech Stack

Backend

  • FastAPI - Modern Python web framework
  • SQLAlchemy - ORM
  • PostgreSQL - Database
  • Pydantic - Data validation
  • JWT - Authentication

Frontend

  • Next.js 14 - React framework
  • TypeScript - Type safety
  • Tailwind CSS - Styling
  • Axios - HTTP client
  • Zustand - State management

πŸ’» Development

Adding Questions

You can add questions to the database by inserting into the questions table:

INSERT INTO questions (part, topic, question_text) VALUES
(1, 'Doing something well', 'Do you have an experience when you did something well?'),
(1, 'Rules', 'Are there any rules for students at your school?');

Environment Variables

For detailed environment variable setup, see Environment Setup Guide.

Backend (.env):

  • DATABASE_URL - PostgreSQL connection string
  • SECRET_KEY - Secret key for JWT tokens
  • GOOGLE_CLIENT_ID - Google OAuth Client ID (get from Google Cloud Console)

Frontend (.env.local):

  • NEXT_PUBLIC_API_URL - Backend API URL
  • NEXT_PUBLIC_GOOGLE_CLIENT_ID - Google OAuth Client ID (same as backend)

πŸš€ Deployment

To deploy your application to production, see the comprehensive deployment guides:

  • Quick Start Deployment - Fast deployment options (Vercel + Railway)
  • Full Deployment Guide - Detailed instructions for multiple platforms:
    • Vercel + Railway/Render (Recommended)
    • Docker Compose
    • Traditional VPS (Ubuntu/Debian)
    • AWS/GCP/Azure

Quick Deploy

Easiest option: Deploy frontend to Vercel and backend to Railway. See DEPLOY_QUICKSTART.md for step-by-step instructions.

πŸ” Google OAuth Setup

  1. Go to Google Cloud Console
  2. Create a new project or select an existing one
  3. Enable Google+ API
  4. Go to "Credentials" β†’ "Create Credentials" β†’ "OAuth client ID"
  5. Configure OAuth consent screen
  6. Create OAuth 2.0 Client ID for Web application
  7. Add authorized JavaScript origins: http://localhost:3000 (for development)
  8. Add authorized redirect URIs: http://localhost:3000 (for development)
  9. Copy the Client ID and add it to both backend .env and frontend .env.local files

Note: For production, update the authorized origins and redirect URIs to your production domain.

πŸ“„ License

This project is licensed under the MIT License - see the LICENSE file for details.


Made with ❀️ for IELTS learners

⭐ Star this repo if you find it helpful!

Contributors

Chunporo

27 commits

Languages

Python

46.6%

TypeScript

42.6%

JavaScript

5.8%

Shell

3.2%