generator client {
  provider = "prisma-client-js"
  output   = "./client"
}

datasource db {
  provider = "mysql"
  url      = env("DATABASE_URL")
}

model AWS_Policy_Role {
  id                     String    @id @db.VarChar(36)
  assistant_id           String?   @db.VarChar(36)
  agent_bedrock_policy   String?   @db.LongText
  agent_kb_schema_policy String?   @db.LongText
  kb_bedrock_policy      String?   @db.LongText
  kb_aoss_policy         String?   @db.LongText
  kb_s3_policy           String?   @db.LongText
  agent_role_name        String?   @db.Text
  kb_role_name           String?   @db.Text
  createtime             DateTime? @db.DateTime(0)
}

model Ai_Agent_Assistants {
  id               String    @id @db.VarChar(36)
  userId           String?   @db.VarChar(255)
  username         String?   @db.VarChar(255)
  agent_sort       String?   @db.VarChar(255)
  agent_tag        String?   @db.VarChar(255)
  assistantName    String?   @db.VarChar(255)
  description      String?   @db.LongText
  prologue         String?   @db.LongText
  headUrl          String?   @db.LongText
  instructions     String?   @db.LongText
  isRetrieval      Boolean?
  isCode           Boolean?
  isGoogle         Boolean?
  isDalleImage     Boolean?
  functionNames    String?   @db.LongText
  functionContents String?   @db.LongText
  assistant_id     String?   @db.Text
  thread_id        String?   @db.Text
  file_ids         String?   @db.LongText
  file_names       String?   @db.LongText
  isPublish        Boolean?
  organize_id      String?   @db.LongText
  vector_store_id  String?   @db.Text
  modelType        String?   @db.VarChar(255)
  createtime       DateTime? @db.DateTime(0)
  updatetime       DateTime? @db.DateTime(0)
  a                String?   @db.Text
}

model Ai_Agent_Threads {
  id           String    @id @db.VarChar(36)
  userId       String?   @db.VarChar(255)
  assistant_id String?   @db.Text
  thread_id    String?   @db.Text
  createtime   DateTime? @db.DateTime(0)
  session_name String    @default("") @db.VarChar(255)
}

model Assistant {
  id              String    @id @db.VarChar(36)
  uid             String?   @db.VarChar(36)
  assistant_id    String?   @db.Text
  thread_id       String?   @db.Text
  file_ids        String?   @db.Text
  vector_store_id String?   @db.Text
  createtime      DateTime? @db.DateTime(0)
}

model Chat {
  id           String    @id @default("") @db.VarChar(36)
  groupid      String?   @db.VarChar(36)
  userid       String?   @db.VarChar(36)
  username     String?   @db.VarChar(255)
  answer       String?   @db.Text
  problem      String?   @db.LongText
  createtime   DateTime? @db.DateTime(0)
  fileid       String?   @db.VarChar(36)
  isMindMap    Int?
  filename     String?   @db.VarChar(255)
  session_name String    @default("") @db.VarChar(255)
  scene        String?   @db.VarChar(255)

  @@index([createtime], map: "createtime")
  @@index([fileid], map: "fileid")
  @@index([groupid], map: "groupid")
  @@index([userid], map: "userid")
}

model Disposition {
  id                String    @id @db.VarChar(36)
  module            String?   @db.VarChar(255)
  disposition_class String?   @db.VarChar(255)
  disposition_type  String?   @db.VarChar(255)
  disposition_style String?   @db.VarChar(255)
  disposition_theme String?   @db.VarChar(255)
  user_id           String?   @db.VarChar(36)
  create_time       DateTime? @db.DateTime(0)
}

model Group {
  id         String    @id @db.VarChar(36)
  name       String?   @db.VarChar(255)
  userid     String?   @db.VarChar(36)
  createtime DateTime? @db.DateTime(0)
}

model GroupFile {
  id              String    @id @db.VarChar(36)
  userid          String?   @db.VarChar(36)
  fileurl         String?   @db.Text
  filename        String?   @db.Text
  groupid         String?   @db.VarChar(36)
  abstract        String?   @db.Text
  assistantFileId String?   @db.VarChar(36)
  modelType       String?   @db.VarChar(36)
  createtime      DateTime? @db.DateTime(0)

  @@index([createtime], map: "createtime")
  @@index([groupid], map: "groupid")
}

model InvitationCode {
  id             String    @id @db.VarChar(36)
  cid            String?   @db.VarChar(36)
  themeId        String?   @db.VarChar(36)
  type           Int?
  invitationCode String?   @db.VarChar(36)
  createtime     DateTime? @db.DateTime(0)
}

model ai_agent_park_session {
  id             String    @id @db.VarChar(36)
  session_name   String?   @db.VarChar(255)
  user_id        String?   @db.VarChar(255)
  isCocoNote     Int?      @db.TinyInt
  createtime     DateTime? @db.DateTime(0)
  work_area_text String?   @db.LongText
  scene          String?   @db.VarChar(255)
}

model classroom_ob_comment {
  id             String    @id @db.VarChar(255)
  module_id      String    @db.VarChar(255)
  module_name    String?   @db.VarChar(255)
  nickname       String?   @db.VarChar(255)
  commentContent String?   @db.LongText
  audit_status   Int       @default(0)
  t_id           String?   @db.VarChar(36)
  create_time    DateTime? @db.DateTime(0)

  @@index([audit_status, t_id], map: "tid_status")
}

model classroom_observation {
  id         String    @id @db.VarChar(36)
  jsonData   String?   @db.LongText
  Type       Int?
  tIndex     Int?
  tId        String?   @db.VarChar(36)
  createtime DateTime? @db.DateTime(0)
  like_num   Int       @default(0)
  like_data  String?   @db.LongText
  userid     String?   @db.VarChar(255)
  isdel      Int?      @default(0)
  limitData  String?   @db.LongText

  @@index([Type], map: "Type")
  @@index([createtime], map: "createtime")
  @@index([tIndex], map: "tIndex")
  @@index([Type, tId], map: "type_tid")
}

model course_resource {
  id             String  @id @db.VarChar(36)
  subject        String? @db.VarChar(255)
  grade          String? @db.VarChar(255)
  textbook       String? @db.VarChar(255)
  book_type      String? @db.VarChar(255)
  unit           String? @db.VarChar(255)
  period         String? @db.VarChar(255)
  unit_content   String? @db.LongText
  course_content String? @db.LongText
}

model knowledge_construction_doc {
  id          String    @id @db.VarChar(255)
  muti_id     String?   @db.VarChar(255)
  user_id     String?   @db.VarChar(255)
  session_id  String?   @db.VarChar(255)
  content     String?   @db.LongText
  create_time DateTime? @db.DateTime(0)
}

model meeting_trick {
  id               String    @id @db.VarChar(36)
  createtime       DateTime? @db.DateTime(0)
  userid           String?   @db.VarChar(255)
  meeting_name     String?   @db.VarChar(255)
  meeting_original String?   @db.LongText
  meeting_minutes  String?   @db.LongText
  audio_url        String?   @db.VarChar(255)
  duration         String?   @db.VarChar(255)
  ab               String?   @db.LongText

  @@index([userid], map: "get_meeting_trick")
}

model meeting_trick_chat {
  id           String    @id @db.VarChar(36)
  meeting_id   String?   @db.VarChar(36)
  createtime   DateTime? @db.DateTime(0)
  user_content String?   @db.Text
  ai_content   String?   @db.Text

  @@index([meeting_id], map: "get_meeting_trick_chat")
}

model muti_agent_list {
  id                     String    @id @db.VarChar(255)
  userid                 String?   @db.VarChar(255)
  username               String?   @db.VarChar(255)
  muti_name              String?   @db.VarChar(255)
  description            String?   @db.LongText
  isPublish              Boolean?
  organizeid             String?   @db.LongText
  content                String?   @db.LongText
  create_time            DateTime? @db.DateTime(0)
  knowledge_construction Int?

  @@index([id], map: "index_id")
}

model park_chat_file_list {
  id          String    @id @db.VarChar(255)
  user_id     String?   @db.VarChar(255)
  file_names  String    @db.LongText
  file_ids    String    @db.LongText
  create_time DateTime? @db.DateTime(0)
  file_urls   String?   @db.LongText
}

model token {
  id             String    @id @db.VarChar(255)
  schoolId       String?   @db.VarChar(255)
  key            String?   @db.VarChar(255)
  createUsername String?   @db.VarChar(255)
  createtime     DateTime? @db.DateTime(0)
}
