manuscript-import
Skill1 starsChanged 13 days agoMITView on GitHub
Use when the user wants to import, upload, or bring in a manuscript file (.docx or Markdown) so its chapters and scenes land in a StorytellerOS title. Triggers on "import my manuscript", "upload this draft to [title]", "bring my book into StorytellerOS", "parse this file into chapters", "add these chapters from my Word file". Always asks whether to only store the manuscript or also build the story bible before uploading.
In this repository29 other files it gives its agents.
- ads-studioSkill
- blog-post-and-newsletterSkill
- calendarSkill
- chapter-draftingSkill
- character-mergeSkill
- financeSkill
- getting-startedSkill
- manuscript-revisionsSkill
- markersSkill
- marketing-studioSkill
- mentionsSkill
- pen-namesSkill
- quick-task-captureSkill
- sales-studioSkill
- social-handoffSkill
- story-bibleSkill
- stos-setupSkill
- tasksSkill
- timelineSkill
- time-trackingSkill
- wordpress-connectSkill
- wordpress-llm-optimizationSkill
- wordpress-mediaSkill
- wordpress-pagesSkill
- wordpress-postsSkill
- wordpress-productsSkill
- wordpress-seoSkill
- worldbuilding-mergeSkill
- worldbuildingSkill
The file
We split this skill into the rules it gives an agent
11 rules. About 0 are common, 4 are distinctive, and 7 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈4
Distinctive · estimate
This author's own choices. Worth a look.
7
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 22
No title yet? Create one first: stos_titles_create({ fields: { title: '...' }, penNameId }).
- Very specific: line 35
If you are preparing a Markdown file for the author (for example from text they pasted), give every chapter a # Chapter N: Title heading …
- Very specific: line 37
Existing chapters decide the mode: If stos_chapters_list returned chapters, explain the two choices in plain words and let the author pick:
- Distinctive: line 44
Before calling the upload tool, ask the author this, in these words or close to them:
- Distinctive: line 48
Wait for the answer. Don't upload until you have it, and don't start building the story bible unless the author says yes to it.
- Distinctive: line 52
Read the file's bytes, base64-encode them, and call:
- Distinctive: line 63
Call it once per file. Never paste the manuscript into the chat to retype it.
- Very specific: line 95
Wrong file type or too large: use the conversion steps in Step 2, or suggest splitting the book into two files and importing the second …
- Very specific: line 104
Call stos_chapters_delete({ id }) without confirm.
- Very specific: line 105
Only if the author says yes, call stos_chapters_delete({ id, confirm: true }).
- Very specific: line 114
Re-uploading a whole file after a partial failure: Read committed_chapter_ids first.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 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.
Files
Manuscript Import
What this does
stos_titles_upload_manuscript is the same import the app runs from Upload Manuscript. It splits the file into chapters, saves every chapter's full text with a first scene for each, keeps a copy of the file in the title's Manuscripts list, and adds any front or back matter (dedication, acknowledgements, about the author and so on) to the title.
The author's words are the point. Nothing in this flow rewrites, trims, or reorders them.
Step 1: Find the title
stos_pen_names_list() // match the pen name
stos_titles_list({ penNameId }) // match the title
stos_chapters_list({ bookId: titleId }) // does it already have chapters?No title yet? Create one first: stos_titles_create({ fields: { title: '...' }, penNameId }). Confirm the pen name and title with the author before going on.
Step 2: Check the file
- Accepted: Word (
.docx) and Markdown (.mdor.markdown), up to 50 MB. - Not accepted: older Word (
.doc), Apple Pages (.pages) and.rtf. Tell the author how to convert in plain words: in Word, Save As → Word Document (.docx); in Pages, File → Export To → Word. - How chapters are found:
- Word: chapter titles set in the Heading 1 or Heading 2 style.
- Markdown: a heading line per chapter, written
# Chapter 1: Title. When the file has these, only those headings start chapters, and every other line stays in the chapter text, including numbered lines, dates and lines that begin with "Chapter". - Headings named Dedication, Epigraph, Foreword, Preface, Acknowledgements or About the Author fill those parts of the title. If the title already has one, the new text is added after it, never over it.
- Prologue and Epilogue become their own chapters.
- A file with no headings at all becomes one chapter.
If you are preparing a Markdown file for the author (for example from text they pasted), give every chapter a # Chapter N: Title heading and copy their text exactly.
- Existing chapters decide the mode. If
stos_chapters_listreturned chapters, explain the two choices in plain words and let the author pick:append(the default): adds the file's chapters after the ones already there.merge: adds only the chapter numbers the title doesn't have yet, so a file of chapters 1 to 20 on a title that has 1 to 12 adds 13 to 20.- Replacing the existing chapters is not available here. If the author wants that, they do it in the app.
Step 3: Ask before uploading (required)
Before calling the upload tool, ask the author this, in these words or close to them:
"Do you want me to just import and store the manuscript, or also build the story bible (characters, places, events and lore) from it?"
Wait for the answer. Don't upload until you have it, and don't start building the story bible unless the author says yes to it. "Just import" is a complete, good answer.
Step 4: Upload
Read the file's bytes, base64-encode them, and call:
stos_titles_upload_manuscript({
id: titleId,
filename: 'my-book.docx', // must end in .docx, .md or .markdown
content_base64: '<file bytes, base64>',
conflict_resolution: 'append', // or 'merge'; omit for append
})Call it once per file. Never paste the manuscript into the chat to retype it.
Step 5: Report what happened
A successful response carries:
| Field | Tell the author |
chapters_created | How many chapters were added. With merge this can be lower than the number of chapters in the file; say which numbers were skipped because the title already had them. |
total_word_count | How many words the file held. |
warnings | Every warning, in full and in plain words. They explain things like no headings found, chapter numbers out of order, numbered titles such as "1. The Arrival" that weren't treated as chapters, or front matter added after existing text. Suggest the fix the warning names. |
source_file_saved | If false, the chapters are in, but the copy of the file wasn't saved to the Manuscripts list. Say so. |
chapter_ids | Keep these for the next steps; don't show raw ids. |
A good report: "Imported 24 chapters, about 86,000 words, into Curses and Currents." Then the warnings, if any.
Older-version guard. If the response has no warnings field, the import ran on an older version of StorytellerOS that can replace a title's existing front and back matter instead of adding to it. Don't treat the missing field as a sign that everything went fine. Report chapters and words, then tell the author, for example: "This import ran on an older version of StorytellerOS. Please open the title in the app and check your front and back matter, such as the dedication and acknowledgements, because the import may have replaced what was there."
Step 6: Follow the author's answer from Step 3
- Just import and store: you're done. Mention that the story bible can be built any time later.
- Also build the story bible: only after a successful import, follow the
story-bibleskill. It defaults to the chat loop, which reads the imported chapters and lets the author steer as it goes. It uses the server extractor only for unattended runs or very large books; that extractor reads the chapters you just imported. Don't repeat its steps here; switch to that skill.
When something goes wrong
- Partial import (an error after some chapters were saved). The error text ends with
(details: {"committed_chapter_ids": [...], "warnings": [...]}), and the message names the chapter where it stopped.- Read
committed_chapter_ids, thenstos_chapters_list({ bookId: titleId })to confirm what actually landed. The chapter list is what counts; if the error has no details block (older server), it is the only record. Every chapter incommitted_chapter_idsis already in the book, including one the message says "was added but its scenes may not have been saved". Ask the author to check that chapter in the app rather than importing it again. - Tell the author which chapters are in and where it stopped. Their existing chapters were not touched.
- Never re-upload the whole file. That adds the saved chapters a second time, and front and back matter that were already saved get added again too.
- The safe retry is a file holding only the chapters after the last one that landed, without the front or back matter headings, uploaded with
append. Ask the author before retrying.
- Read
- "The manuscript has no text to import" (422): the file has headings but no chapter text, or is empty. Ask the author to check they picked the right file.
- Paused (409
STRUCTURE_OPS_PAUSED): nothing was written. Tell the author this kind of change is paused for now and their text is safe. Don't retry. - Wrong file type or too large: use the conversion steps in Step 2, or suggest splitting the book into two files and importing the second with
append.
Removing a chapter after an import
Sometimes an import leaves a chapter the author doesn't want, such as a duplicate. Chapter delete is two steps, and a copy of the chapter is saved first so it can be brought back.
Check first: only use chapter delete if stos_chapters_restore_deleted is among your tools. If it isn't, the server has the older delete, which has no question step and keeps no copy. Don't call stos_chapters_delete at all; tell the author chapter delete isn't available from here yet and nothing was changed.
- Confirm with the author which chapter you mean (number and title).
- Call
stos_chapters_delete({ id })withoutconfirm. Nothing is deleted. The result is{ confirmation_required: true, question }: put that question to the author. - Only if the author says yes, call
stos_chapters_delete({ id, confirm: true }). The response includes arevisionId. - To bring it back:
stos_chapters_restore_deleted({ titleId, revisionId }). If its old chapter number is now taken, that call also returns a question; ask it, and call again withconfirm: trueonly on a yes. Deleted chapters are also listed on the title's Revisions page in the app, with a Restore button.
A 409 TRY_AGAIN means nothing was deleted; call again. If the server answers that chapter delete is paused (409 STRUCTURE_OPS_PAUSED), nothing changed: tell the author it isn't available right now, and don't look for another way to remove the chapter.
Anti-patterns
- Uploading before asking the Step 3 question.
- Starting a story bible build without a yes. Importing and building the bible are separate choices.
- Re-uploading a whole file after a partial failure. Read
committed_chapter_idsfirst; it duplicates chapters and front matter. - Hiding warnings. They tell the author what to fix in their file.
- Calling
stos_chapters_deletewithconfirm: trueon the first call, or deleting chapters to "clean up" without the author choosing each one. - Rewriting the author's text while preparing a Markdown file. Add headings only.
Related skills
story-bible: build characters, places, events and lore from the imported book.manuscript-revisions: the saved manuscript files for a title, and which one is active.chapter-drafting: read and revise the imported chapters.
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
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.

