{
  "messages": [
    {
      "role": "system",
      "content": "You are a screenwriting agent. The program already created a script skeleton and shot plan. Do not change scene_id or shot_id ordering. Keep the number of shots stable. Chronology is program-owned. Use it to keep flashback, dream, rumor, and parallel-line language consistent, but do not rewrite chronology fields. Adaptation is also program-owned. Use the adaptation brief to decide what to fully dramatize, what to compress, and what to turn into bridge narration. Refine language, dialogue, narration, and shot descriptions while preserving the program structure. Prefer the existing entity display names from the entity context. Do not invent unnecessary new speaker variants when the candidate already provides a stable character name. Return JSON only."
    },
    {
      "role": "user",
      "content": "Given the scene payload, chronology context, adaptation context, entity context, and the program-generated script candidate, refine it into a concise screenplay. Output STRICT JSON with keys: scene_id, shots (list), scene_notes, audio_notes, narrator_profile_id. Shot schema: {shot_id,description,camera,actions,dialogue,narration,on_screen_text,narrator_profile_id,narration_delivery_hint}. dialogue is a list of {speaker,speaker_entity_uid,delivery_hint,line}. speaker_entity_uid and narrator_profile_id are program-owned identity fields: preserve the candidate values when unsure, and do not fabricate random IDs. Keep the same shot count as the candidate unless the candidate is malformed. Keep the narrative presentation order, but make the script language consistent with chronology time_mode, anchor, ordering hints, and adaptation decision/presentation_mode. Prefer existing characters and locations. Return a single JSON object and nothing else (no markdown, no code fences). If unsure, return {\"scene_id\":\"\",\"shots\":[]}.\n\nSCENE:\n{\"candidate_id\": \"C0002-SC02\", \"title\": \"系统确认\", \"summary\": \"李凡看着饼发愣，系统确认选择‘镇静一点’气运，心情下降1点。\", \"type\": [\"系统/设定\", \"对话\"], \"tone\": [\"庄严\"], \"importance\": \"主线\", \"presentation\": [\"文字卡片\", \"旁白+画面\", \"对白驱动\"], \"key_beats\": [\"李凡瞅饼发愣\", \"系统确认气运\", \"心情下降1点\"], \"characters\": [\"李凡\", \"老道\"], \"locations\": [], \"continuation_of_prev\": false, \"source_chunk_id\": \"C0002\", \"source_start_para\": 35, \"source_end_para\": 38, \"text\": \"“……”李凡瞅瞅老道，又瞅瞅怀里的饼，还没等他反应过来，系统又开始搞他心态了。\\n\\n‘确认宿主选择先天气运，镇静一点’\\n\\n哦迈噶德……\\n\\n‘李凡的心情下降了1点’\", \"text_preview\": \"“……”李凡瞅瞅老道，又瞅瞅怀里的饼，还没等他反应过来，系统又开始搞他心态了。 ‘确认宿主选择先天气运，镇静一点’ 哦迈噶德…… ‘李凡的心情下降了1点’\", \"candidate_meta\": {\"candidate_id\": \"C0002-SC02\", \"record_count\": 4, \"char_len\": 80, \"structure_counts\": {\"dialogue\": 3, \"short_line\": 1}, \"boundary_reasons_after\": [\"system_switch\"], \"matched_entities\": [{\"entity_id\": \"E000002\", \"name\": \"李凡\", \"type\": \"人物\", \"subtype\": \"\", \"matched_terms\": [\"李凡\"], \"score\": 5.3}, {\"entity_id\": \"E000001\", \"name\": \"老道\", \"type\": \"人物\", \"subtype\": \"\", \"matched_terms\": [\"老道\"], \"score\": 5.3}], \"heuristic_types\": [\"系统/设定\", \"对话\"], \"heuristic_tones\": [\"庄严\"], \"heuristic_presentation\": [\"文字卡片\", \"旁白+画面\", \"对白驱动\"], \"heuristic_importance\": \"主线\"}, \"scene_id\": \"S0006\"}\n\nCHRONOLOGY:\n{\"scene_id\": \"S0006\", \"narrative_order\": 6, \"story_chronology_order\": 6, \"story_chronology_group\": \"CG0006\", \"time_mode\": \"mainline\", \"confidence\": 0.86, \"order_delta\": 0, \"temporal_anchor\": {\"label\": \"\", \"normalized_label\": \"unknown\", \"anchor_type\": \"unknown\", \"relative_direction\": \"unknown\", \"amount\": null, \"unit\": \"\", \"time_of_day\": \"\", \"explicit\": false, \"anchor_scene_id\": \"S0005\"}, \"constraints\": [{\"relation\": \"after\", \"target_scene_id\": \"S0005\", \"confidence\": 0.58, \"reason\": \"narrative_forward\"}], \"evidence\": []}\n\nADAPTATION:\n{\"scene_id\": \"S0006\", \"source_chunk_id\": \"C0002\", \"scene_summary\": \"李凡看着饼发愣，系统确认选择‘镇静一点’气运，心情下降1点。\", \"chronology\": {\"scene_id\": \"S0006\", \"narrative_order\": 6, \"story_chronology_order\": 6, \"story_chronology_group\": \"CG0006\", \"time_mode\": \"mainline\", \"confidence\": 0.86, \"order_delta\": 0, \"temporal_anchor\": {\"label\": \"\", \"normalized_label\": \"unknown\", \"anchor_type\": \"unknown\", \"relative_direction\": \"unknown\", \"amount\": null, \"unit\": \"\", \"time_of_day\": \"\", \"explicit\": false, \"anchor_scene_id\": \"S0005\"}, \"constraints\": [{\"relation\": \"after\", \"target_scene_id\": \"S0005\", \"confidence\": 0.58, \"reason\": \"narrative_forward\"}], \"evidence\": []}, \"decision\": \"retain\", \"presentation_mode\": \"dialogue\", \"story_function\": [\"信息揭示\", \"角色反应\", \"系统引入\"], \"adaptation_focus\": \"通过李凡对饼的愣神反应，引出系统对气运选择的冰冷确认及其带来的负面情绪影响，强化系统与主角的互动关系。\", \"must_keep\": [\"李凡对饼发愣的瞬间\", \"系统语音/文字确认选择‘镇静一点’气运\", \"李凡心情下降1点的明确反馈\"], \"may_compress\": [\"李凡与老道之间的眼神切换细节\", \"系统提示的冗长说明\"], \"visual_focus\": [\"李凡盯着饼的特写\", \"李凡面部表情从困惑到无奈的变化\", \"系统UI（如文字卡片或光效）的视觉呈现\"], \"audio_focus\": [\"环境音（可能的风声或远处人声）\", \"系统提示音或旁白（庄严、非人声）\", \"李凡可能的内心吐槽或叹息\"], \"continuity_requirements\": [\"李凡的情绪状态需承接前序场景\", \"老道在场但可能处于背景或焦点外\", \"系统UI风格需与前后场景一致\"], \"script_objective\": \"在保持轻松基调的同时，清晰传达系统机制（气运选择与心情值关联），并通过李凡的反应建立观众对系统的认知与共情。\", \"conflict\": \"李凡的内心期望（获得好处）与系统实际效果（带来负面心情）之间的微小冲突。\", \"turning_point\": \"系统宣布‘心情下降1点’，标志着李凡意识到这个“金手指”并非全然有益，初次体验其代价。\", \"reason\": \"该场景是系统功能的关键展示节点，通过具体事件（气运确认与心情变化）而非纯说明来建立世界观规则。对话（系统提示）驱动情节，且‘心情下降’是后续角色状态变化的基础，必须保留。\", \"candidate_meta\": {\"scene_id\": \"S0006\", \"decision_reasons\": [\"main_conflict_or_dialogue_dense\"], \"presentation_reasons\": [\"dialogue_priority\"], \"metrics\": {\"text_length\": 215, \"quote_count\": 2, \"action_score\": 0, \"exposition_score\": 5, \"inner_score\": 0, \"transition_score\": 0, \"reveal_score\": 0, \"tension_score\": 0, \"environment_score\": 0, \"character_count\": 2, \"location_count\": 0, \"beat_count\": 3, \"continuation_of_prev\": false, \"time_mode\": \"mainline\", \"order_delta\": 0}, \"characters\": [\"李凡\", \"老道\"], \"locations\": [], \"key_beats\": [\"李凡瞅饼发愣\", \"系统确认气运\", \"心情下降1点\"]}}\n\nENTITY CONTEXT:\n{\"registry_entities\": [{\"entity_uid\": \"E000002\", \"canonical_name\": \"李凡\", \"aliases\": [\"穿越者\"], \"type\": \"人物\", \"subtype\": \"\", \"voice_card_id\": \"VO000002\"}, {\"entity_uid\": \"E000001\", \"canonical_name\": \"老道\", \"aliases\": [\"老道士\"], \"type\": \"人物\", \"subtype\": \"\", \"voice_card_id\": \"VO000001\"}], \"kg_entities\": [{\"entity_id\": \"E000001\", \"name\": \"老道\", \"type\": \"人物\", \"subtype\": \"\", \"aliases\": [\"老道士\"], \"attributes\": {}, \"descriptions\": [\"墨竹山法坛前的老道\", \"负责挑选童子\", \"墨竹山法坛前老道\"], \"evidence\": [\"法坛前只有个墨帻法褐的老道\", \"老道鼻子里哼了一声\", \"老道士已经阴沉着脸走过来\", \"老道士突然爆发出一声怪笑\"], \"mentions\": [{\"chunk_id\": \"C0001\", \"summary\": \"法坛前打盹老道\", \"evidence\": [\"老道撅撅嘴，用叼着的竹叶指指那些童子\"], \"attributes\": {}}, {\"chunk_id\": \"C0002\", \"summary\": \"给李凡芝麻饼\", \"evidence\": [\"老道士也瞪了李凡一会儿\"], \"attributes\": {}}, {\"chunk_id\": \"C0002\", \"summary\": \"警告李凡不要抬头\", \"evidence\": [\"老道士突然爆发出一声怪笑\"], \"attributes\": {}}], \"mention_count\": 3, \"observation_count\": 3, \"first_seen\": \"C0001\", \"last_seen\": \"C0002\"}, {\"entity_id\": \"E000002\", \"name\": \"李凡\", \"type\": \"人物\", \"subtype\": \"\", \"aliases\": [\"穿越者\"], \"attributes\": {}, \"descriptions\": [\"二十一童子之一\", \"现代穿越者\", \"拥有心理健康系统\"], \"evidence\": [\"二十一人中有一个穿越者\", \"李凡，普普通通的打工人\", \"李凡实在是忍不住了\", \"李凡流着冷汗\"], \"mentions\": [{\"chunk_id\": \"C0001\", \"summary\": \"穿越者童子\", \"evidence\": [\"李凡只记得一睁眼，上来还没摸清楚现在是什么朝代\"], \"attributes\": {}}, {\"chunk_id\": \"C0002\", \"summary\": \"吐槽系统选择气运\", \"evidence\": [\"李凡实在是忍不住了\"], \"attributes\": {}}, {\"chunk_id\": \"C0002\", \"summary\": \"研究系统功能\", \"evidence\": [\"李凡正愁眉苦脸得研究\"], \"attributes\": {}}], \"mention_count\": 3, \"observation_count\": 3, \"first_seen\": \"C0001\", \"last_seen\": \"C0002\"}]}\n\nSCRIPT CANDIDATE:\n{\"scene_id\": \"S0006\", \"scene_notes\": \"李凡看着饼发愣，系统确认选择‘镇静一点’气运，心情下降1点。；重要性：主线；呈现：文字卡片 / 旁白+画面 / 对白驱动；改编策略：retain；呈现策略：dialogue；剧本目标：在保持轻松基调的同时，清晰传达系统机制（气运选择与心情值关联），并通过李凡的反应建立观众对系统的认知与共情。\", \"audio_notes\": \"保留对白节奏；环境音（可能的风声或远处人声）；系统提示音或旁白（庄严、非人声）；李凡可能的内心吐槽或叹息\", \"narrator_profile_id\": \"narrator_main_cn\", \"chronology\": {\"scene_id\": \"S0006\", \"narrative_order\": 6, \"story_chronology_order\": 6, \"story_chronology_group\": \"CG0006\", \"time_mode\": \"mainline\", \"confidence\": 0.86, \"order_delta\": 0, \"temporal_anchor\": {\"label\": \"\", \"normalized_label\": \"unknown\", \"anchor_type\": \"unknown\", \"relative_direction\": \"unknown\", \"amount\": null, \"unit\": \"\", \"time_of_day\": \"\", \"explicit\": false, \"anchor_scene_id\": \"S0005\"}, \"constraints\": [{\"relation\": \"after\", \"target_scene_id\": \"S0005\", \"confidence\": 0.58, \"reason\": \"narrative_forward\"}], \"evidence\": []}, \"adaptation\": {\"scene_id\": \"S0006\", \"decision\": \"retain\", \"presentation_mode\": \"dialogue\", \"story_function\": [\"信息揭示\", \"角色反应\", \"系统引入\"], \"adaptation_focus\": \"通过李凡对饼的愣神反应，引出系统对气运选择的冰冷确认及其带来的负面情绪影响，强化系统与主角的互动关系。\", \"must_keep\": [\"李凡对饼发愣的瞬间\", \"系统语音/文字确认选择‘镇静一点’气运\", \"李凡心情下降1点的明确反馈\"], \"may_compress\": [\"李凡与老道之间的眼神切换细节\", \"系统提示的冗长说明\"], \"visual_focus\": [\"李凡盯着饼的特写\", \"李凡面部表情从困惑到无奈的变化\", \"系统UI（如文字卡片或光效）的视觉呈现\"], \"audio_focus\": [\"环境音（可能的风声或远处人声）\", \"系统提示音或旁白（庄严、非人声）\", \"李凡可能的内心吐槽或叹息\"], \"continuity_requirements\": [\"李凡的情绪状态需承接前序场景\", \"老道在场但可能处于背景或焦点外\", \"系统UI风格需与前后场景一致\"], \"script_objective\": \"在保持轻松基调的同时，清晰传达系统机制（气运选择与心情值关联），并通过李凡的反应建立观众对系统的认知与共情。\", \"conflict\": \"李凡的内心期望（获得好处）与系统实际效果（带来负面心情）之间的微小冲突。\", \"turning_point\": \"系统宣布‘心情下降1点’，标志着李凡意识到这个“金手指”并非全然有益，初次体验其代价。\", \"reason\": \"该场景是系统功能的关键展示节点，通过具体事件（气运确认与心情变化）而非纯说明来建立世界观规则。对话（系统提示）驱动情节，且‘心情下降’是后续角色状态变化的基础，必须保留。\", \"chronology\": {\"scene_id\": \"S0006\", \"narrative_order\": 6, \"story_chronology_order\": 6, \"story_chronology_group\": \"CG0006\", \"time_mode\": \"mainline\", \"confidence\": 0.86, \"order_delta\": 0, \"temporal_anchor\": {\"label\": \"\", \"normalized_label\": \"unknown\", \"anchor_type\": \"unknown\", \"relative_direction\": \"unknown\", \"amount\": null, \"unit\": \"\", \"time_of_day\": \"\", \"explicit\": false, \"anchor_scene_id\": \"S0005\"}, \"constraints\": [{\"relation\": \"after\", \"target_scene_id\": \"S0005\", \"confidence\": 0.58, \"reason\": \"narrative_forward\"}], \"evidence\": []}}, \"shots\": [{\"shot_id\": \"S0006_SH01\", \"camera\": \"对白建立镜头\", \"description\": \"场景建立镜头，带出李凡瞅饼发愣\", \"actions\": [\"李凡瞅饼发愣\"], \"dialogue\": [], \"narration\": \"\", \"on_screen_text\": \"\", \"focus_characters\": [\"李凡\", \"老道\"], \"focus_locations\": [], \"candidate_meta\": {\"shot_role\": \"opening\", \"description_hint\": \"场景建立镜头，带出李凡瞅饼发愣\", \"camera_hint\": \"中景\", \"adaptation_summary\": {\"decision\": \"retain\", \"presentation_mode\": \"dialogue\", \"story_function\": [\"信息揭示\", \"角色反应\", \"系统引入\"], \"must_keep_count\": 3, \"audio_focus_count\": 3}, \"shot_index\": 1, \"chronology_summary\": {\"narrative_order\": 6, \"story_chronology_order\": 6, \"story_chronology_group\": \"CG0006\", \"time_mode\": \"mainline\", \"confidence\": 0.86, \"order_delta\": 0, \"anchor_label\": \"\", \"anchor_type\": \"unknown\", \"constraint_count\": 1, \"evidence_count\": 0}}, \"narrator_profile_id\": \"narrator_main_cn\"}, {\"shot_id\": \"S0006_SH02\", \"camera\": \"双人中景\", \"description\": \"李凡的反应镜头，推进系统确认气运\", \"actions\": [\"系统确认气运\"], \"dialogue\": [], \"narration\": \"\", \"on_screen_text\": \"\", \"focus_characters\": [\"李凡\", \"老道\"], \"focus_locations\": [], \"candidate_meta\": {\"shot_role\": \"character\", \"description_hint\": \"李凡的反应镜头，推进系统确认气运\", \"camera_hint\": \"双人中景\", \"adaptation_summary\": {\"decision\": \"retain\", \"presentation_mode\": \"dialogue\", \"story_function\": [\"信息揭示\", \"角色反应\", \"系统引入\"], \"must_keep_count\": 3, \"audio_focus_count\": 3}, \"shot_index\": 2, \"chronology_summary\": {\"narrative_order\": 6, \"story_chronology_order\": 6, \"story_chronology_group\": \"CG0006\", \"time_mode\": \"mainline\", \"confidence\": 0.86, \"order_delta\": 0, \"anchor_label\": \"\", \"anchor_type\": \"unknown\", \"constraint_count\": 1, \"evidence_count\": 0}}, \"narrator_profile_id\": \"narrator_main_cn\"}, {\"shot_id\": \"S0006_SH03\", \"camera\": \"正反打\", \"description\": \"对白推进核心信息\", \"actions\": [\"系统确认气运\", \"心情下降1点\"], \"dialogue\": [{\"speaker\": \"李凡\", \"speaker_entity_uid\": \"\", \"delivery_hint\": \"带停顿\", \"line\": \"……\"}], \"narration\": \"\", \"on_screen_text\": \"李凡看着饼发愣，系统确认选择‘镇静一点’气运，心情下降1点。\", \"focus_characters\": [\"李凡\", \"老道\"], \"focus_locations\": [], \"candidate_meta\": {\"shot_role\": \"dialogue_or_action\", \"description_hint\": \"对白推进核心信息\", \"camera_hint\": \"正反打\", \"adaptation_summary\": {\"decision\": \"retain\", \"presentation_mode\": \"dialogue\", \"story_function\": [\"信息揭示\", \"角色反应\", \"系统引入\"], \"must_keep_count\": 3, \"audio_focus_count\": 3}, \"shot_index\": 3, \"chronology_summary\": {\"narrative_order\": 6, \"story_chronology_order\": 6, \"story_chronology_group\": \"CG0006\", \"time_mode\": \"mainline\", \"confidence\": 0.86, \"order_delta\": 0, \"anchor_label\": \"\", \"anchor_type\": \"unknown\", \"constraint_count\": 1, \"evidence_count\": 0}}, \"narrator_profile_id\": \"narrator_main_cn\"}, {\"shot_id\": \"S0006_SH04\", \"camera\": \"特写\", \"description\": \"李凡收束镜头，停在心情下降1点\", \"actions\": [\"心情下降1点\"], \"dialogue\": [], \"narration\": \"\", \"on_screen_text\": \"\", \"focus_characters\": [\"李凡\"], \"focus_locations\": [], \"candidate_meta\": {\"shot_role\": \"closing\", \"description_hint\": \"李凡收束镜头，停在心情下降1点\", \"camera_hint\": \"特写\", \"adaptation_summary\": {\"decision\": \"retain\", \"presentation_mode\": \"dialogue\", \"story_function\": [\"信息揭示\", \"角色反应\", \"系统引入\"], \"must_keep_count\": 3, \"audio_focus_count\": 3}, \"shot_index\": 4, \"chronology_summary\": {\"narrative_order\": 6, \"story_chronology_order\": 6, \"story_chronology_group\": \"CG0006\", \"time_mode\": \"mainline\", \"confidence\": 0.86, \"order_delta\": 0, \"anchor_label\": \"\", \"anchor_type\": \"unknown\", \"constraint_count\": 1, \"evidence_count\": 0}}, \"narrator_profile_id\": \"narrator_main_cn\"}], \"candidate_meta\": {\"scene_id\": \"S0006\", \"source_chunk_id\": \"C0002\", \"source_start_para\": 35, \"source_end_para\": 38, \"characters\": [\"李凡\", \"老道\"], \"locations\": [], \"key_beats\": [\"李凡瞅饼发愣\", \"系统确认气运\", \"心情下降1点\"], \"shot_count_hint\": 4, \"scene_summary\": \"李凡看着饼发愣，系统确认选择‘镇静一点’气运，心情下降1点。\", \"scene_text_preview\": \"“……”李凡瞅瞅老道，又瞅瞅怀里的饼，还没等他反应过来，系统又开始搞他心态了。 ‘确认宿主选择先天气运，镇静一点’ 哦迈噶德…… ‘李凡的心情下降了1点’\", \"chronology_summary\": {\"narrative_order\": 6, \"story_chronology_order\": 6, \"story_chronology_group\": \"CG0006\", \"time_mode\": \"mainline\", \"confidence\": 0.86, \"order_delta\": 0, \"anchor_label\": \"\", \"anchor_type\": \"unknown\", \"constraint_count\": 1, \"evidence_count\": 0}, \"adaptation_summary\": {\"decision\": \"retain\", \"presentation_mode\": \"dialogue\", \"story_function\": [\"信息揭示\", \"角色反应\", \"系统引入\"], \"must_keep_count\": 3, \"audio_focus_count\": 3}}}"
    }
  ]
}