逐日AI

面试题库

共 328 题,当前筛选 1 题。

14 天用 Agent 搭一条 AI 短剧生产线

D10 审片室:能预览、能改词、能重生成单镜的人机协作后台

  • 版本回滚要存什么?只存最终产物够不够?What must a version record hold for rollback? Are the final artifacts enough?
    国内高频海外高频进阶#versioning#rollback#data-modeling

    分析过程 · 先想清楚再作答

    1. 题眼在「够不够」三个字,它在提示答案是否定的。先把问题重述成一句判断:**版本不是备份**,这句话说出来这题就答对了一半。
    2. 两者的语义不一样。备份是「出事了拿回来」,只需要保留最近一份好状态;版本是「两个都在」,要能并排对比、来回切换,最终选哪个由人定。审核场景要的是后者。
    3. 所以每个版本要存三类东西:产物本身(按版本分目录,一个文件都不删)、产生它的输入(那一版的台词与画面描述,否则三天后没人说得清两版差在哪)、以及这一版重跑了哪些节点与原因。
    4. 当前版本要设计成一个指针,不是一份拷贝。回滚就是把指针挪回去,不搬文件,因此是瞬时且可逆的;这也让「再切回新版本」变成理所当然的操作。
    5. 有一个连带影响必须提到,提了就说明你真做过:**回滚一镜会改变整集的时间轴**。新版配音比旧版长一秒,切回去之后后面所有镜头的起止时间都要重排。所以回滚之后要重算一次时间轴,好在这是纯本地计算,很便宜。
    6. 可预期的追问是「版本存多久」。按产物体积和业务价值定:小文本无限存,视频这种大件设一个保留期,过期只留元数据和输入,需要时可以按同样的输入重跑出来。

    How to reason about it · think before answering

    1. The hinge is are they enough, which signals the answer is no. Restate it as a claim: a version is not a backup. Saying that sentence gets you half the credit.
    2. The semantics differ. A backup means restore after an incident and only needs the latest good state. A version means both exist, side by side, switchable, with a human choosing. Review workflows need the latter.
    3. So each version stores three things: the artifacts themselves, kept in per-version directories with nothing deleted; the inputs that produced them, the line and the visual description, or nobody can explain the difference three days later; and which nodes reran plus why.
    4. The current version should be a pointer, not a copy. Rollback moves the pointer without touching files, which makes it instant and reversible, and makes switching forward again equally natural.
    5. Mention the knock-on effect, because it shows you have actually shipped this: rolling back one shot changes the whole episode timeline. If the new take of the voice is a second longer, every later shot shifts, so rollback must recompute the timeline. That part is cheap local computation.
    6. Expected follow-up: how long to keep versions. Scale it by artifact size and business value: keep small text forever, put a retention window on video, and after expiry keep only metadata and inputs so the artifact can be regenerated on demand.

    答题要点

    • 版本不是备份:备份只要最近一份好状态,版本要求新旧同时存在、能并排对比。
    • 每版要存三类:产物(按版本分目录、不删)、产生它的输入、重跑的节点与原因。
    • 当前版本是指针不是拷贝,回滚只挪指针,瞬时且可逆。
    • 回滚一镜会改变整集时间轴,回滚后要重算一次——这是纯本地计算,很便宜。
    • 保留策略按体积分级:文本长期留,大视频设保留期,过期只留元数据与输入以便按需重跑。

    Key points

    • A version is not a backup: backups keep the latest good state, versions keep old and new side by side.
    • Store three things per version: artifacts in per-version directories, the inputs that produced them, and which nodes reran and why.
    • Make the current version a pointer, not a copy, so rollback is instant and reversible.
    • Rolling back one shot shifts the episode timeline, so recompute it after rollback; it is cheap local work.
    • Set retention by size: keep text forever, expire large video and retain metadata plus inputs for regeneration.