feat: add manual video tagging

This commit is contained in:
2026-04-29 21:20:21 +08:00
parent 02d37f3953
commit eac6ad2343
17 changed files with 1066 additions and 418 deletions
@@ -0,0 +1,5 @@
ALTER TABLE "Video"
ADD COLUMN "manual_content_tags" TEXT[] NOT NULL DEFAULT ARRAY[]::TEXT[];
CREATE INDEX "video_manual_content_tags_idx"
ON "Video" USING GIN ("manual_content_tags");
+25 -23
View File
@@ -24,32 +24,34 @@ model Author {
}
model Video {
aweme_id String @id
desc String
preview_title String?
duration_ms Int
created_at DateTime
share_url String
digg_count BigInt @default(0)
comment_count BigInt @default(0)
share_count BigInt @default(0)
collect_count BigInt @default(0)
authorId String
createdAt DateTime @default(now())
updatedAt DateTime @updatedAt
tags String[]
video_url String
height Int?
width Int?
cover_url String?
fps Int?
raw_json Json?
comments Comment[]
author Author @relation(fields: [authorId], references: [sec_uid], onDelete: Cascade)
transcript VideoTranscript?
aweme_id String @id
desc String
preview_title String?
duration_ms Int
created_at DateTime
share_url String
digg_count BigInt @default(0)
comment_count BigInt @default(0)
share_count BigInt @default(0)
collect_count BigInt @default(0)
authorId String
createdAt DateTime @default(now())
updatedAt DateTime @updatedAt
tags String[]
manual_content_tags String[] @default([])
video_url String
height Int?
width Int?
cover_url String?
fps Int?
raw_json Json?
comments Comment[]
author Author @relation(fields: [authorId], references: [sec_uid], onDelete: Cascade)
transcript VideoTranscript?
@@index([authorId])
@@index([created_at])
@@index([manual_content_tags], map: "video_manual_content_tags_idx", type: Gin)
}
model CommentUser {