@lingjingai/scriptctl 0.63.6 → 0.63.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,4 @@
1
+ # 0.63.7
2
+
3
+ - 豆包文本、结构化与视频请求不再传递输出 token 上限。
4
+ - 豆包返回 `incomplete/length` 时正确识别为输出截断,避免误报为内容审核拦截。
@@ -0,0 +1,5 @@
1
+ # 0.63.8
2
+
3
+ - 视频 ingest 整合保留逐集提取的 Action 正文,修复人物别名「头」「妈」「洛」「哥」及地点、道具别名误替换普通词的问题。
4
+ - 名称归一化仅作用于完整的结构化资产引用;人物跨集更名、历史 aliases、稳定 ID 和道具去重继续生效。
5
+ - 沿用视频 pipeline 19 和原分集 checkpoint,修复无需重新调用模型;已经人工审核或修改的成稿应单独核对恢复。
package/dist/bin.js CHANGED
@@ -7032,7 +7032,6 @@ var DoubaoModel = class {
7032
7032
  async generateOnce(fileId, request2) {
7033
7033
  const params = {
7034
7034
  model: this.model,
7035
- max_output_tokens: request2.maxOutputTokens,
7036
7035
  input: [{ role: "user", content: [
7037
7036
  { type: "input_video", file_id: fileId },
7038
7037
  { type: "input_text", text: request2.user }
@@ -7069,7 +7068,6 @@ var DoubaoModel = class {
7069
7068
  textParams(request2) {
7070
7069
  return {
7071
7070
  model: this.model,
7072
- max_output_tokens: request2.maxOutputTokens,
7073
7071
  instructions: request2.system,
7074
7072
  input: [{ role: "user", content: [{ type: "input_text", text: request2.user }] }]
7075
7073
  };
@@ -7086,7 +7084,7 @@ var DoubaoModel = class {
7086
7084
  const usage3 = arkUsage(res.usage);
7087
7085
  if (status === "incomplete") {
7088
7086
  const reason = res.incomplete_details?.reason ?? "unknown";
7089
- if (reason === "max_output_tokens") throw new LlmTransportError("truncated", "Doubao output was truncated.", { usage: usage3 });
7087
+ if (reason === "max_output_tokens" || reason === "length") throw new LlmTransportError("truncated", "Doubao output was truncated.", { usage: usage3 });
7090
7088
  throw new LlmTransportError("content_filtered", `Doubao response incomplete (reason=${reason}).`, { usage: usage3 });
7091
7089
  }
7092
7090
  const text2 = extractText(res);
@@ -16489,29 +16487,8 @@ function checkLifecycle2(store, previous, episodes, force) {
16489
16487
  }
16490
16488
  }
16491
16489
  function renameDocs(docs, alias) {
16492
- const terms = /* @__PURE__ */ new Map();
16493
- for (const [surface, canonical] of alias) {
16494
- terms.set(canonical, canonical);
16495
- terms.set(surface, canonical);
16496
- }
16497
- const orderedTerms = [...terms].sort(([left], [right]) => right.length - left.length);
16498
- const renameActionContent = (content) => {
16499
- let result = "";
16500
- let offset = 0;
16501
- while (offset < content.length) {
16502
- const match = orderedTerms.find(([surface]) => content.startsWith(surface, offset));
16503
- if (match) {
16504
- result += match[1];
16505
- offset += match[0].length;
16506
- } else {
16507
- result += content[offset];
16508
- offset += 1;
16509
- }
16510
- }
16511
- return result;
16512
- };
16513
16490
  return docs.map((d) => {
16514
- const c = JSON.parse(JSON.stringify(d));
16491
+ const c = structuredClone(d);
16515
16492
  for (const a of c.actors) a.name = applyRename(a.name, alias) ?? a.name;
16516
16493
  for (const sc of c.scenes) {
16517
16494
  for (const ch of sc.characters) ch.name = applyRename(ch.name, alias) ?? ch.name;
@@ -16529,7 +16506,6 @@ function renameDocs(docs, alias) {
16529
16506
  sc.props = renamedProps;
16530
16507
  for (const an of sc.anchors) {
16531
16508
  an.speaker = applyRename(an.speaker, alias);
16532
- if (an.kind === "act") an.content = renameActionContent(an.content);
16533
16509
  }
16534
16510
  }
16535
16511
  return c;