screenwriting-refactor

screenwriting-refactor is a skill for Claude Code from e06084/claude-screenwriting. It costs 67 tokens per session (923 once invoked), scanned A, original, MIT.

A guided process for restructuring an existing story in an Obsidian wiki while applying screenwriting rules. It creates a proposed change list, shows before-and-after edits, explains the reasoning, and waits for confirmation before writing changes.

In plain words
What is it for?
Use it to change genre, strengthen structure, reshape characters, adjust pacing, or clarify themes across related story pages.
Why use it?
It makes large story edits traceable and helps prevent changes from breaking important plot or character foundations.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the claude-screenwriting plugin — 8 skills, 2 agents shipped together

Good fit Use it to change genre, strengthen structure, reshape characters, adjust pacing, or clarify themes across related story pages.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/e06084/claude-screenwriting/screenwriting-refactor
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add e06084/claude-screenwriting --skill screenwriting-refactor
Clone the repo
git clone --depth 1 https://github.com/e06084/claude-screenwriting

Made for: Claude Code.

Or install claude-screenwriting, the plugin that ships this one along with the rest of its 8 skills, 2 agents.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for screenwriting-refactor

README.md
[![agentmods](https://agentmods.dev/badge/skills/e06084/claude-screenwriting/screenwriting-refactor.svg)](https://agentmods.dev/skills/e06084/claude-screenwriting/screenwriting-refactor)
Your own site
<a href="https://agentmods.dev/skills/e06084/claude-screenwriting/screenwriting-refactor"><img src="https://agentmods.dev/badge/skills/e06084/claude-screenwriting/screenwriting-refactor.svg" alt="Measured on agentmods" height="20"></a>
Per session 67 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 923 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00067 $0.00923
Opus 5 $0.00034 $0.00462
Sonnet 5 $0.00013 $0.00185
Haiku 4.5 $0.00007 $0.00092

Measured 7d ago against content hash 019677184949, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-07, from the pricing page.

Security

Grade A, and why

screenwriting-refactor scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 7d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/screenwriting-refactor/SKILL.md · 86 lines

What it actually says

Screenwriting Refactor

在编剧理论约束下重构故事结构,确保变更不破坏核心戏剧原则。

流程

Step 1: 读取当前状态

  1. 读取 wiki/meta/logline.md — 理解核心前提
  2. 读取 wiki/beats/ — 获取当前 15-beat 结构
  3. 读取 wiki/characters/ — 获取角色设定
  4. 读取 wiki/meta/genre.md — 理解类型约束

Step 2: 分析重构方向

根据用户指令判断重构类型:

类型 示例指令 影响范围
类型转换 "调整为心理惊悚" beats + 部分角色
结构强化 "加强 B Story" 特定 beats
角色重塑 "让反派更有深度" 角色卡 + 关联 beats
节奏调整 "中段太拖" beats 7-12
主题聚焦 "主题不够清晰" meta + theme-related beats

Step 3: 生成重构提案

references/refactor-rules.md 中的约束规则,生成:

  1. 变更清单: 哪些文件会被修改
  2. Diff 展示: 每个文件的旧→新对比
  3. 理论依据: 为什么这样改(引用具体理论原则)
  4. 风险评估: 这个改动可能引入什么新问题

Step 4: 确认与执行

  1. 展示完整提案给用户
  2. 等待用户确认(可以选择"全部接受"/"逐项确认"/"取消")
  3. 确认后批量写入修改
  4. wiki/log.md 追加重构记录(含 diff 摘要)

重构约束

完整规则见 references/refactor-rules.md。核心不可违反原则:

  1. 15-beat 框架不可删减 — 可以调整内容,不能跳过 beat
  2. 主角 Wants/Needs 张力必须保持 — 重构后两者仍需冲突
  3. Catalyst 外力性不可破坏 — 催化事件必须是外力而非主角自发
  4. 弧光方向不可无理由逆转 — 除非明确是类型转换
  5. 来源追溯不可断裂 — 新内容标注来源为"refactor"

输出示例

🔄 重构提案: "调整为心理惊悚"

影响范围: 9 个 beat + 2 个角色

--- wiki/beats/beat-01-开场画面.md ---
- 内容: 阳光明媚的小镇广场
+ 内容: 表面平静的小镇,但画面构图暗示不安(过于对称的房屋、过于整齐的草坪)

--- wiki/beats/beat-04-催化剂.md ---
- 内容: 收到一封工作邀请
+ 内容: 深夜目睹邻居在花园秘密掩埋什么东西

--- wiki/characters/小明.md ---
- opinions: 小镇生活很平静
+ opinions: 表面上觉得平静,但总有一种说不清的不安感

📝 理论依据:
- 心理惊悚的 Opening Image 需要"表面正常 + 微妙不安"的视觉暗示
- Catalyst 在惊悚类型中应是"发现了不应该发现的事"

⚠️ 风险: B Story 可能需要相应调整以承载"信任vs怀疑"主题

确认应用?(y/全部接受 | n/取消 | p/逐项确认)
Files

What ships with it

1 file beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 7d ago First seen · 86 lines · 67 tokens per session scan A 019677184949

Subscribe to this mod's changes

screenwriting-refactor is a skill published in the GitHub repository e06084/claude-screenwriting (6 stars, last pushed 2mo ago), licensed MIT. It adds 67 tokens to every session and 923 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories

novel-original-writing

A Chinese-language workflow for turning an original story idea directly into a filmable script, without adapting a novel or other existing source. It develops the idea through seven stages, from concept and world-building to characters, structure, performance, and aftermath.

juemin4-source/writing-pro-max · 122 tokens

novel-to-screen-adaptation

A process for turning a novel into a screenplay by breaking it down into its main idea, story engine, objects, scenes, episodes, and script in that order. It is an adaptation workflow, not a general script-writing tool.

juemin4-source/writing-pro-max · 133 tokens

video-prompt-adapter

A Chinese-language system for creating performance-focused prompts for video generation, combining acting direction, platform details, and production handoffs.

juemin4-source/writing-pro-max · 143 tokens

canvas

Create, inspect, and update Obsidian JSON Canvas boards with text, file, link, group, and edge nodes. Use for canvas status, canvas lists, visual maps, zones, spatial layouts, adding vault notes or media to a .canvas file, and requests such as create canvas, add to canvas, or put this on the canvas.

AgriciDaniel/claude-obsidian · 72 tokens

plannotator-visual-explainer

Generate self-contained HTML visualizations with Plannotator theming. Use for implementation plans, PR explainers, architecture diagrams, data tables, slide decks, and any visual explanation of technical concepts. Plans and PR explainers follow Plannotator's prescriptive approach; all other visual content delegates to…

backnotprop/plannotator · 78 tokens

json-canvas

Create and edit JSON Canvas files (.canvas) with nodes, edges, groups, and connections. Use when working with .canvas files, creating visual canvases, mind maps, flowcharts, or when the user mentions Canvas files in Obsidian.

kepano/obsidian-skills · 54 tokens