File size: 2,017 Bytes
6d6eaef
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
// Domain vocabulary for auto-lms. Single source of truth for the string unions
// used across the DB schema, pipeline, and UI. Kept dependency-free so both the
// Next app and the standalone worker can import it.

export const DEPTHS = ['overview', 'standard', 'deep'] as const;
export type Depth = (typeof DEPTHS)[number];

export const DIFFICULTIES = ['beginner', 'intermediate', 'advanced'] as const;
export type Difficulty = (typeof DIFFICULTIES)[number];

export const SOURCE_TYPES = ['file', 'video', 'link', 'text'] as const;
export type SourceType = (typeof SOURCE_TYPES)[number];

export const SOURCE_STATUSES = ['pending', 'processing', 'ready', 'failed'] as const;
export type SourceStatus = (typeof SOURCE_STATUSES)[number];

export const COURSE_STATUSES = [
  'draft',
  'ingesting',
  'structuring',
  'awaiting_review',
  'generating',
  'ready',
  'failed',
] as const;
export type CourseStatus = (typeof COURSE_STATUSES)[number];

export const SEGMENT_STATUSES = ['pending', 'scripted', 'narrated', 'rendered', 'failed'] as const;
export type SegmentStatus = (typeof SEGMENT_STATUSES)[number];

export const JOB_STATUSES = ['queued', 'running', 'awaiting_review', 'completed', 'failed'] as const;
export type JobStatus = (typeof JOB_STATUSES)[number];

// Ordered pipeline stages. The orchestrator walks these in sequence.
export const STAGES = [
  'ingest',
  'structure',
  'script',
  'narrate',
  'render',
  'assess',
  'assemble',
] as const;
export type Stage = (typeof STAGES)[number];

// On-screen content for a single ~1-minute video segment.
export interface VisualCue {
  heading?: string;
  bullets: string[];
  note?: string;
}

export type QuestionType = 'mcq' | 'short_answer';

export interface QuestionOption {
  id: string;
  text: string;
}

export interface Question {
  id: string;
  type: QuestionType;
  prompt: string;
  options?: QuestionOption[]; // mcq only
  correctOptionId?: string; // mcq only
  sampleAnswer?: string; // short_answer only
  explanation?: string;
}