Course Factory

Last updated: 2026-07-06

What is Course Factory?

Course Factory is the AI-powered automated course generation system on HaMi Code Việt. The system uses AI to research topics, create outlines, write lesson content, generate quizzes, and perform safety checks — all within a 5-stage pipeline that can resume if interrupted.

5-Stage Pipeline

StageDescriptionAI Model
1. ResearchAI researches the topic, identifies key conceptsLlama
2. OutlineCreates course structure: lessons, order, objectivesClaude Haiku / Llama
3. ContentWrites bilingual Vietnamese-English lesson contentClaude Haiku / Llama
4. QuizGenerates quiz questions and exercisesLlama
5. Safety checkChild safety filter, content reviewSafety classifier

Key Features

Course Factory Admin Interface

Admins can access the Course Factory interface at /admin/factory. Here, admins can:

API Endpoints

# Create a new Course Factory request
POST /factory/generate
{
  "topic": "Python basics for beginners",
  "level": "beginner",
  "ageRange": "8-13",
  "lessonCount": 10
}

# Check status
GET /factory/generations/:id

# Approve course
POST /factory/generations/:id/approve
Access control

Course Factory is restricted to admins and content_admins. See roles & permissions for details.

Creators and Course Factory

Creators can use Creator Studio to create content with AI assistance, but this process differs from Course Factory. Creator Studio is for Creators building content manually with AI help, while Course Factory generates complete courses automatically.