SPB Git forge

spb/uqo-chat

Public
14commits 1branches 0releases
1.4 MBsize
maindefault branch
17 days agolast push
Python 64.6% TypeScript 33.7% CSS 0.8%
2.2 KB · 105 lines typescript
Raw Blame History
1export type Role = 'student' | 'professor' | 'admin';23export interface User {4  id: string;5  email: string;6  role: Role;7  display_name: string | null;8  preferences: { tutoiement?: boolean; course?: string; deep?: boolean; locale?: string; font_scale?: number };9  consent_at: string | null;10  has_password?: boolean;11}1213export interface Course {14  code: string;15  title: string;16  term: string;17  modules: string[];18  suggestions: string[];19  site: string;20  deadlines: { label: string; date: string }[];21  announcement: string;22}2324export interface Conversation {25  id: string;26  title: string;27  course: string;28  pinned: boolean;29  archived: boolean;30  created_at: string;31  updated_at: string;32}3334export interface Artifact {35  type: string;36  file_id: string | null;37  filename: string | null;38  preview?: unknown;39  url?: string | null;40}4142export interface ToolCallView {43  id: string;44  name: string;45  arguments: Record<string, unknown>;46  args_preview?: string;47  summary: string;48  payload: Record<string, unknown>;49  artifacts?: Artifact[];50  status: 'running' | 'ok' | 'error';51  progress?: string;52  duration_ms: number;53}5455export interface Message {56  id: string;57  role: 'user' | 'assistant' | 'system';58  content: string;59  model?: string | null;60  created_at: string;61  feedback?: string | null;62  attachments?: string[];63  tool_calls?: ToolCallView[];64  cost_usd?: number;65  streaming?: boolean;66  error?: string;67  latency_ms?: number;68}6970export interface UploadedFile {71  file_id: string;72  filename: string;73  type: string;74  size: number;75  url: string;76  kind?: string;77  pinned?: boolean;78  created_at?: string;79}8081export interface QuizQuestion {82  id: string;83  type: 'mcq' | 'true_false' | 'numeric';84  prompt: string;85  choices?: string[];86  unit?: string;87}8889export interface QuizPayload {90  quiz_id: string;91  title: string;92  course: string;93  topic: string;94  difficulty: string;95  questions: QuizQuestion[];96  sources?: { module: string; section: string; url: string }[];97}9899export interface QuizResult {100  score: number;101  correct: number;102  total: number;103  results: { id: string; correct: boolean; given: unknown; answer: unknown; explanation: string; unit?: string }[];104}105