agentleFS
GoRenkuGoRenku/studio-skills/skills/screenplay-pdf-to-fdx/SKILL.md

screenplay-pdf-to-fdx

Skill2 starsChanged 7 months agoMITView on GitHub

Reconstruct a conventionally formatted screenplay PDF as a faithful, editor-ready Final Draft XML (.fdx) file. Use when PDF import loses screenplay structure or produces garbled character, dialogue, action, parenthetical, transition, or scene-heading elements; do not use for adapting prose into a screenplay.

The file

Show its rules and text

We split this skill into the rules it gives an agent

23 rules. About 0 are common, 7 are distinctive, and 16 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈7

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 16

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    When this skill comes from renku-cloud and the Renku tools are missing, the person has not signed in to Renku Cloud yet.

    line 18
  2. Distinctive:

    Read the PDF and run this skill's scripts on your computer, from the installed plugin, with Poppler and any OCR you need.

    line 28
  3. Very specific:

    Keep the manifest, rendered pages and downloads in a working folder on your computer, laid out like the tmp/ tree below.

    line 30
  4. Very specific:

    Write the .fdx on your computer where the person asked, or beside the source.

    line 34
  5. Very specific:

    Keep every agent-created working file inside the current Project's categorized tmp/ tree.

    line 59
  6. Very specific:

    Use tmp/operations/ for CLI authoring documents and the reviewed conversion manifest.

    line 63
  7. Very specific:

    Use tmp/operations/media-generation/ for any later Media Producer review or provenance documents.

    line 65
  8. Very specific:

    Use tmp/media/ for temporary generated or transformed media, tmp/qa/ for rendered PDF pages and review evidence, and tmp/scratch/ for …

    line 67
  9. Distinctive:

    Create category folders lazily.

    line 70
  10. Very specific:

    Keep an external user source outside the Project when possible.

    line 71
  11. Very specific:

    Write the final .fdx to the user's requested location.

    line 73
  12. Very specific:

    Run scripts/extract_pdf_layout.py to produce page PNGs and line geometry.

    line 82
  13. Very specific:

    Run scripts/reconcile_text.py against the layout evidence and manifest.

    line 91
  14. Very specific:

    Run scripts/build_fdx.py with the reviewed manifest.

    line 97
  15. Very specific:

    Run scripts/validate_fdx.py --manifest ...

    line 100
  16. Very specific:

    Import the .fdx in Beat, Final Draft, or another FDX-capable editor when one is available.

    line 102
  17. Very specific:

    When the user also wants a Renku import, invoke the screenplay-drafter workflow after the standalone FDX is complete.

    line 111
  18. Very specific:

    Use Transition, Shot, General, Lyrics, New Act, End of Act, or Sequence only when the source actually authors that element.

    line 127
  19. Distinctive:

    If simultaneous dialogue is unmistakable, read the dual-dialogue section of the manifest reference.

    line 129
  20. Distinctive:

    Before delivery, require all of the following:

    line 134
  21. Distinctive:

    every source page was rendered and inspected.

    line 136
  22. Distinctive:

    every scene number in the PDF is represented exactly once.

    line 140
  23. Distinctive:

    no page header or page number appears in screenplay content.

    line 141

≈ “Common” is an estimate: at least 1 in 5 of the 408,460 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Screenplay PDF to FDX

Renku Cloud

Renku runs in Renku Cloud when this skill comes from the renku-cloud plugin (its folder is inside that plugin; Claude Code lists it as renku-cloud:<skill>), or when the Renku tools renku_command, renku_upload, renku_download, renku_view and renku_guide are present. An app may show them with a prefix, such as mcp__plugin_renku-cloud_renku__renku_command. In Renku Cloud, never run a renku command on the computer, even when one is installed there.

When this skill comes from renku-cloud and the Renku tools are missing, the person has not signed in to Renku Cloud yet. Tell them how, and stop until they have: in Claude Code, type /mcp and sign in to plugin:renku-cloud:renku; in the Claude app, open Renku Cloud's Connectors tab in Customize → Plugins and select Add, then Connect; in the ChatGPT app, select Connect on Renku Cloud; in the Codex CLI, run codex mcp login renku.

In Renku Cloud the conversion still runs entirely on your computer, because Renku reads no PDFs.

  • Read the PDF and run this skill's scripts on your computer, from the installed plugin, with Poppler and any OCR you need.
  • Keep the manifest, rendered pages and downloads in a working folder on your computer, laid out like the tmp/ tree below.
  • A PDF already in the Project, such as supporting material, comes down with one renku_download call.
  • Write the .fdx on your computer where the person asked, or beside the source.
  • For a Renku import, upload the finished .fdx with one renku_upload call and hand screenplay-drafter the path the upload reports. It imports the file with screenplay import-fdx.

Convert the screenplay by reconstructing its semantic paragraphs. Treat PDF text extraction as transcription evidence, not as an authoritative parse.

Required outcome

Deliver an .fdx that:

  • preserves the source wording and authored scene numbers;
  • represents every screenplay paragraph with the correct Final Draft element;
  • excludes page headers, page numbers, and extraction artifacts;
  • opens cleanly in an FDX-capable editor; and
  • passes the supplied structural validator.

This is a format conversion. Do not rewrite, modernize, summarize, repair story logic, invent act headings, or silently correct the author's wording. Record uncertain readings for review instead of guessing.

Project Workspace

Keep every agent-created working file inside the current Project's categorized tmp/ tree. Never create operation JSON, Generation Specs, import manifests, QA images, downloads, crops, or scratch files at the Project root.

  • Use tmp/operations/ for CLI authoring documents and the reviewed conversion manifest.
  • Use tmp/operations/media-generation/ for any later Media Producer review or provenance documents; this conversion skill does not create them itself.
  • Use tmp/media/ for temporary generated or transformed media, tmp/qa/ for rendered PDF pages and review evidence, and tmp/scratch/ for downloads and other temporary inputs.
  • Create category folders lazily. Keep the downloaded source unchanged.
  • Keep an external user source outside the Project when possible. If a temporary in-Project copy is necessary, place it under tmp/scratch/.
  • Write the final .fdx to the user's requested location. Otherwise use <source-name>-converted.fdx beside the source. Never overwrite an existing output unless the user explicitly requested it.

Workflow

  1. Confirm that the input is a screenplay PDF and establish the requested output path. If it is scans rather than embedded text, OCR may be used, but every page still requires visual reconciliation.
  2. Run scripts/extract_pdf_layout.py to produce page PNGs and line geometry. It requires Poppler's pdftotext and pdftoppm commands.
  3. Inspect every rendered page. Use coordinates, indentation, capitalization, surrounding elements, and screenplay conventions to identify paragraph boundaries and types. Never classify from capitalization alone.
  4. Author the reviewed conversion manifest described in references/conversion-manifest.md. Join visual line wraps within one paragraph, but preserve separate authored paragraphs. Remove only verified headers, footers, and page numbers.
  5. Run scripts/reconcile_text.py against the layout evidence and manifest. Resolve every textual mismatch against the rendered pages. This comparison starts at the first screenplay paragraph and ignores detected page numbers; it does not replace visual review. Dual-dialogue columns cannot be reduced to one trustworthy reading order, so the script stops when they are present; reconcile those passages visually and disclose that exception.
  6. Run scripts/build_fdx.py with the reviewed manifest. The builder owns XML escaping and FDX envelope construction; do not hand-escape or concatenate XML in shell commands.
  7. Run scripts/validate_fdx.py --manifest ... and resolve every error. Review every warning against the rendered pages.
  8. Import the .fdx in Beat, Final Draft, or another FDX-capable editor when one is available. In Beat, use File > Import Final Draft...; Beat does not register .fdx as a directly openable document. Compare the imported screenplay page by page with the PDF and correct the manifest, not the generated XML. Rebuild and revalidate after every correction.
  9. Report the output path, scene and paragraph counts, character cues, warnings reviewed, and any unresolved source ambiguity. Do not call a conversion complete while ambiguity remains unreported.

When the user also wants a Renku import, invoke the screenplay-drafter workflow after the standalone FDX is complete. Do not create a Renku Project merely to satisfy this skill's own validation.

Classification rules

  • A Scene Heading is an authored slugline or other explicit scene boundary. Preserve its printed scene number separately in number.
  • Character identifies a dialogue cue, including an authored extension such as (V.O.) or (O.S.).
  • Parenthetical contains the complete parentheses.
  • Consecutive visual dialogue lines belong to one Dialogue paragraph until spacing or another element establishes a new paragraph.
  • Action contains visible or audible action and description. Preserve meaningful all-caps emphasis as text; semantic type is not inferred from capitalization.
  • Use Transition, Shot, General, Lyrics, New Act, End of Act, or Sequence only when the source actually authors that element.
  • If simultaneous dialogue is unmistakable, read the dual-dialogue section of the manifest reference. Otherwise do not manufacture dual dialogue.

Quality gate

Before delivery, require all of the following:

  • every source page was rendered and inspected;
  • screenplay text reconciles exactly from the first converted paragraph onward, except for any disclosed dual-dialogue passage reconciled visually;
  • the manifest-to-FDX comparison has zero errors;
  • every scene number in the PDF is represented exactly once;
  • no page header or page number appears in screenplay content;
  • character cues are followed by their parenthetical/dialogue material;
  • XML is well formed and contains no empty screenplay paragraphs; and
  • an editor-open test or a clearly disclosed reason it could not be performed.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.