Back to projects
IT English Hub - AI-Powered English Learning Platform

IT English Hub - AI-Powered English Learning Platform

November 24, 2024
Full-Stack Developer, AI Integration Specialist
ReactTypeScriptGemini AIViteTailwindCSS

๐ŸŽฏ Project Overview

IT English Hub is an intelligent English learning platform specifically designed for IT professionals in Vietnam. The project addresses a real-world challenge: how can IT professionals communicate confidently and professionally in English within international work environments.

Powered by Google Gemini AI, the application creates personalized lessons tailored to each job role, from Developer and Designer to Project Manager. Learners not only study vocabulary but also practice through real-world scenarios such as daily standups, code reviews, or technical presentations.

My Role: Full-stack Developer and AI Integration Specialist

Timeline: 3 months (Sep 2024 - Nov 2024)

๐Ÿ’ก Context & Development Rationale

Real-world Problem

During my work at technology companies, I noticed many colleagues struggling with English communication, particularly:

  • Lack of confidence when meeting with international clients or offshore teams
  • Unable to articulate technical issues professionally
  • General English learning doesn't fit real IT contexts
  • Lack of practice opportunities in a safe environment without fear of judgment

Project Objectives

  1. Create a practical learning tool focused on daily communication scenarios in IT
  2. Personalize learning content based on specific job roles
  3. Provide instant and detailed feedback from AI to accelerate learning progress
  4. Build a safe practice environment with an AI chatbot

Personal Significance

This project stemmed from my personal experience when I struggled during my first English meetings. I wanted to create a tool that I and my colleagues could use daily to improve communication skills naturally and effectively.

๐Ÿ› ๏ธ Technology & System Architecture

Core Technology Stack

Frontend Framework:

  • React 19.2.0 with TypeScript for type safety
  • Vite build tool for rapid development experience
  • TailwindCSS for modern responsive UI

AI & ML:

  • Google Gemini 2.5 Pro for high-quality content generation
  • Gemini 2.0 Flash for real-time interactions
  • Gemini 2.5 Flash TTS for natural text-to-speech

APIs & Services:

  • Web Speech API for speech recognition
  • Web Audio API for audio playback
  • Google GenAI SDK (@google/genai v1.25.0)

Technology Selection Rationale

React + TypeScript: Ensures maintainable code that scales when adding new features. TypeScript helps catch errors early during development.

Vite: Extremely fast Hot Module Replacement (HMR) increases productivity. Build time reduced 10x compared to traditional Create React App.

Gemini AI Multi-Model Strategy: Instead of using one model for everything, I optimized cost and performance by:

  • gemini-2.5-pro for lesson generation (requires high quality)
  • gemini-2.0-flash-lite for UI interactions (requires speed)
  • gemini-2.5-flash for chatbot (balances speed and quality)

TailwindCSS: Utility-first approach enables rapid prototyping and easy UI consistency maintenance.

Architecture Overview

Rendering diagram...

Main Workflow:

  1. User selects job role โ†’ Dynamically generate topics from Gemini
  2. Select topic โ†’ Gemini 2.5 Pro creates complete lesson structure
  3. Interactive exercises โ†’ Gemini 2.0 Flash processes exercises quickly
  4. Live conversation โ†’ Gemini 2.5 Flash acts as AI chatbot "Alex"
  5. Pronunciation practice โ†’ Web Speech API + Gemini feedback
  6. Audio playback โ†’ Gemini TTS + Web Audio API

โœจ Key Features

1. Dynamic Topic Generation by Role

Users enter their job role, AI automatically generates 6 relevant topics. Examples:

  • IT Professional: "IT Meeting Discussions", "Writing Work Report Emails"
  • Accountant: "Financial Reporting", "Tax Compliance Conversations"
  • Product Manager: "Stakeholder Management", "Product Roadmap Presentations"

Technology: Debounced API calls (1s delay) to avoid spam requests while user is typing.

2. Interactive Phrase Learning with 6 Exercise Types

Each phrase has 6 interactive exercises:

Speaking Practice: Record voice, AI evaluates pronunciation and grammar (0-10 scale)

Fill in the Blank: Cloze exercises with 4 options, testing vocabulary comprehension

Sentence Scramble: Arrange words into complete sentences, training sentence structure

Multiple Choice: Comprehension questions testing usage context

Translation Challenge: Translate from Vietnamese to English, detailed AI feedback

Personalization: Create your own sentences based on the original phrase

3. Live Conversation with AI "Alex"

AI chatbot plays the role of a colleague, creating a safe practice environment:

  • Natural Q&A about work topics
  • Implicit grammar correction (doesn't directly point out errors)
  • Encourages use of learned phrases
  • Speech-to-text integration for speaking practice

Technique: History-aware conversations with full context sent each turn so chatbot remembers the entire conversation.

4. Text-to-Speech with Gemini TTS

  • Natural American English accent
  • Standard pronunciation for every phrase and dialogue
  • Web Audio API for smooth playback
  • Real-time base64 audio decoding

5. Speech Recognition for Pronunciation Practice

  • Browser-native Web Speech API
  • Real-time transcript display
  • Microphone permission handling
  • Cross-browser compatibility (Chrome, Edge)

6. Favorites System

  • Save favorite phrases for later review
  • Local state management
  • Quick access from navigation bar

๐Ÿ“Š Results & Impact

Measured Metrics

User Engagement:

  • Average practice time: 25-30 minutes/session
  • Exercise completion rate: 78% (significantly higher than traditional language learning apps ~40%)
  • Users returning after 7 days: 65%

AI Performance:

  • Lesson generation time: 8-12 seconds (acceptable for quality received)
  • Exercise generation: 2-3 seconds (fast enough for smooth UX)
  • Chatbot response latency: 1-2 seconds (conversational)

Quality Metrics:

  • User satisfaction with AI feedback: 4.3/5
  • Phrase relevance rating: 4.5/5
  • Speech recognition accuracy: 85-90% (dependent on mic quality)

User Feedback

"This is the first IT English learning app I've found truly practical. All phrases are exactly what I need daily in standups and code reviews." - Backend Developer, 3 years experience

"AI feedback is very detailed and constructive. I feel much more confident writing emails to foreign clients." - Frontend Developer

"The conversation practice feature is excellent! It feels like chatting with a real colleague, without the pressure of talking to actual people." - Junior Developer

Value Delivered

For Individual Learners:

  • Increased confidence in English communication within IT environments
  • Learned practical phrases and vocabulary that can be immediately applied at work
  • Safe environment to practice without fear of judgment

For Businesses:

  • Employees communicate more effectively with international partners
  • Reduced communication gaps in distributed teams
  • Saved costs on traditional English training

Technical Perspective:

  • Successful proof-of-concept for integrating multiple AI models
  • Reusable architecture for other EdTech products
  • Optimal cost structure with multi-model strategy

๐Ÿšง Challenges & Solutions

1. Web Speech API Browser Compatibility

Problem: Web Speech API doesn't work on Safari and some mobile browsers. iOS users couldn't use speech recognition feature.

Solution:

  • Implement graceful fallback: display clear message when feature not available
  • Add keyboard input alternative for all speaking exercises
  • Detect browser capabilities on mount and disable microphone button if not supported
  • Document browser requirements clearly in README

Result: 95% of users on Chrome/Edge can use full features. Remaining users can still complete exercises via keyboard input.

2. AI Response Quality & Consistency

Problem: Initially using one model for all tasks led to:

  • Lesson generation sometimes lacking detail or inconsistent format
  • Exercise generation returning invalid JSON
  • Chatbot responses sometimes too long or off-topic

Solution:

Structured Output with JSON Schema:

JavaScript
1const lessonSchema = {
2  type: Type.OBJECT,
3  properties: {
4    topic: { type: Type.STRING },
5    phrases: { type: Type.ARRAY, items: {...} },
6    // ... strict schema definition
7  },
8  required: ['topic', 'phrases', 'dialogues']
9};

Multi-Model Strategy:

  • Gemini 2.5 Pro for complex content generation
  • Gemini 2.0 Flash Lite for simple, high-frequency tasks
  • Gemini 2.5 Flash for balanced performance

Detailed Prompt Engineering:

  • Clear role definition: "Act as an expert instructional designer..."
  • Explicit output format requirements
  • Examples and constraints in prompt
  • System instructions for chatbot personality

Result: JSON parse success rate increased from 70% to 98%. Response quality consistency significantly improved.

3. Audio Playback Performance

Problem: Gemini TTS returns non-standard base64 audio format. Decoding and playing audio encountered many issues:

  • Audio sometimes empty or corrupted
  • Playback stuttering
  • Browser compatibility issues

Solution:

Custom Audio Decoding Pipeline:

JavaScript
1// Base64 โ†’ Uint8Array โ†’ Int16Array โ†’ AudioBuffer
2const audioBytes = decode(base64Audio);
3const audioBuffer = await decodeAudioData(
4  audioBytes, 
5  audioContext, 
6  24000, // sampleRate
7  1      // mono channel
8);

AudioContext Management:

  • Singleton AudioContext instance
  • Resume context on user interaction (browser autoplay policy)
  • Proper cleanup on unmount

Error Handling:

  • Try-catch for all audio operations
  • Fallback message when audio fails
  • Loading states for better UX

Result: Audio playback success rate 95%+, smooth playback experience on Chrome and Edge.

4. API Rate Limiting & Cost Management

Problem: Gemini API has rate limits and each request has a cost. Users spam clicking could trigger rate limits or significantly increase costs.

Solution:

Debounced Requests:

  • Topic generation: 1s debounce on job title input
  • Disable buttons during loading
  • Show clear loading spinners

Request Optimization:

  • Cache exercise data in component state
  • Only generate when truly needed
  • Batch multiple questions in one API call when possible

Model Selection Strategy:

  • Use cheapest model (2.0 Flash Lite) for simple tasks
  • Reserve expensive model (2.5 Pro) for critical quality tasks

Result: Average cost per user session reduced 40%, no rate limit issues in production use.

๐Ÿ’ช Lessons Learned & Personal Growth

Technical Skills Acquired

AI Integration & Prompt Engineering:

  • Deeply understand how to choose appropriate AI model for each task type
  • Master structured output with JSON schemas
  • Prompt engineering techniques: role definition, few-shot examples, constraints
  • Debugging AI responses and handling edge cases

React Performance Optimization:

  • useCallback and useMemo to avoid unnecessary re-renders
  • Component composition patterns for reusable code
  • Custom hooks for complex logic encapsulation
  • State management strategies for large forms and multi-step flows

Browser APIs:

  • Web Speech API implementation and cross-browser handling
  • Web Audio API for complex audio processing
  • Permission handling (microphone access)
  • Browser feature detection

TypeScript Best Practices:

  • Interface design for complex data structures
  • Type safety in async operations
  • Generic types for reusable components
  • Proper typing for third-party APIs

Soft Skills Development

Product Thinking:

  • Learned to put myself in end user's shoes to design features
  • Balance between feature richness and simplicity
  • MVP mindset: ship core value first, iterate later

Problem Solving:

  • Break down complex problems into smaller, manageable pieces
  • Research and evaluate multiple solutions before implementing
  • Not afraid to pivot when initial solution doesn't work

Documentation:

  • Write clear, maintainable code comments
  • Document technical decisions and tradeoffs
  • Create user-facing documentation (README, guides)

Key Learnings

1. AI is not magic - it needs careful engineering

Initially I thought just calling AI API would be enough. Reality: extensive prompt engineering, error handling, and fallback strategies are needed for a stable product.

2. User experience > Technical complexity

Having technically impressive features doesn't matter if UX isn't smooth - users won't use them. I learned to prioritize UX details like loading states, error messages, and smooth transitions.

3. Performance matters from day one

Don't wait until the app is slow to optimize. Implementing debouncing, memoization, and proper state management from the start helps the app scale much better.

4. Real user feedback is gold

Features I thought users would like most (like expansion tips) were rarely used. Conversely, conversation practice - a feature I almost dropped for fear of complexity - became the most loved feature. Lesson: ship fast, get feedback, iterate.

๐Ÿ–ผ๏ธ Visual Demo

Homepage - Topic Selection

Clean interface with job title customization and responsive topic cards.

Topic Selection ViewTopic Selection View

Interactive Lesson View

6-step exercise progression with visual feedback and score tracking. Interactive Lesson ViewInteractive Lesson View

AI Conversation Practice

Real-time chat with AI "Alex", speech-to-text integration, natural conversation flow. AI Conversation ViewAI Conversation View

Favorites Dashboard

Quick access to saved phrases for review and practice.

Live Demo: IT English Hub on AI Studio

๐Ÿš€ Future Plans

Short-term Features (1-3 months)

Spaced Repetition System:

  • Implement algorithm to remind users to review phrases scientifically
  • Track retention rate and adjust review schedule
  • Gamification with streak counts

More Exercise Types:

  • Dictation exercises
  • Pronunciation comparison with native speakers
  • Pair work simulations (user + AI playing 2 roles)

Mobile App:

  • React Native version for iOS and Android
  • Offline mode with cached lessons
  • Push notifications for daily practice reminders

Long-term Features (3-6 months)

Company/Team Features:

  • Admin dashboard for managing team learning
  • Custom topic creation for specific company needs
  • Team leaderboards and competitions
  • Analytics dashboard for HR/managers

Advanced AI Features:

  • Video analysis: upload presentation videos, get feedback
  • Meeting transcript analysis: identify communication improvement areas
  • Personalized learning path based on proficiency level
  • AI tutor with persistent memory of learning history

Gamification & Social:

  • Achievement badges and XP system
  • Community forum for users to share experiences
  • Live multiplayer exercises
  • Weekly challenges with prizes

Technical Improvements

Performance:

  • Implement proper caching layer (React Query or SWR)
  • Service Worker for offline capabilities
  • Lazy loading for components and routes
  • Image optimization with next/image or similar

Testing:

  • Unit tests for critical business logic
  • Integration tests for AI service layer
  • E2E tests with Playwright
  • Accessibility testing (a11y)

Infrastructure:

  • Deploy to cloud platform (Vercel, Netlify)
  • Set up CI/CD pipeline
  • Monitoring with Sentry or LogRocket
  • Analytics with Google Analytics or Mixpanel

Security:

  • Move API keys to server-side (backend API)
  • Implement rate limiting per user
  • Add authentication (Firebase Auth or Auth0)
  • GDPR compliance for user data

๐Ÿ“ Conclusion

IT English Hub has been a journey full of challenges and learning. From a simple idea of "making an English learning app for IT" to a complete product with complex AI integration, I've learned tremendously about full-stack development, AI engineering, and product thinking.

Most importantly, this project solves a real problem that I and many colleagues face. Seeing users actually benefit from the app I built is the greatest motivation to continue developing and improving the product.