Skip to content

Guide · Agent skill

How to use the Book SFT Pipeline agent skill

Updated · written with AI from the project's own documentation and checked against our catalogue data

The Book SFT Pipeline skill teaches an AI agent how to turn a book, ideally an ePub file, into a labeled training dataset and then train a small style-transfer model on a platform such as Tinker. It is written for developers and researchers who already understand fine-tuning. This guide explains what the skill does, how to install it, how to ask for it in natural language, and what you need before you start.

Book SFT Pipelinemuratcankoylan/Agent-Skills-for-Context-Engineering · MIT

Quick start

  1. 1Download and unzip. Download the ZIP from this page and unzip it so you have a book-sft-pipeline folder containing SKILL.md.
  2. 2Place the folder. Move the folder into ~/.claude/skills/ for personal use or into a project's .claude/skills/ folder. Alternatively, upload it under Settings → Capabilities → Skills in the Claude apps.
  3. 3Install the Python libraries. Install epub2 and beautifulsoup4 in the Python environment you will use for extraction.
  4. 4Prepare your ePub. Choose a book you have the right to process. Remove front and back matter before chunking.
  5. 5Ask for the pipeline. Describe your goal in plain language, naming the ePub, the target model, and the platform, so the agent activates the skill.
  6. 6Review chunks and data. Check that chunks are 150 to 400 words, break at natural boundaries, and that the JSONL follows the messages format.
  7. 7Train and evaluate. Run LoRA training on your Tinker or similar platform and evaluate the model's outputs before using it.

What is an agent skill, and what does this one do?

An agent skill is a folder containing a SKILL.md file with instructions that an AI agent loads when a task matches the skill's description. This one is named book-sft-pipeline and is described as covering ePub extraction, literary segmentation, author-voice dataset construction, style-transfer training, LoRA workflows, and model evaluation for voice replication.

Once installed, the agent follows a defined sequence: extract paragraphs from the ePub, split the text into chunks of roughly 150 to 400 words at natural boundaries, generate varied prompts, and format the output as chat-style JSONL. The skill then covers LoRA training on Tinker and a validation phase.

  • Extraction: reads the ePub and pulls text from paragraph tags, removing front and back matter.
  • Segmentation: builds chunks of 150 to 400 words, keeping the last paragraph as overlap.
  • Instructions: asks a cheap LLM to describe each excerpt without quoting it, then wraps it in varied prompt templates and system prompts.
  • Dataset: writes messages-format examples (system, user, assistant) for training.

Install the skill from the ZIP download

Download the ZIP for this skill from this page and unzip it. You can install it in one of two places. For a single user across all projects, place the book-sft-pipeline folder inside ~/.claude/skills/. For one project only, place it inside that project's .claude/skills/ folder. The folder must contain SKILL.md at its top level.

If you use the Claude apps instead of the file system, open Settings, go to Capabilities, and upload the skill under Skills.

  • Personal install: ~/.claude/skills/book-sft-pipeline/
  • Project install: .claude/skills/book-sft-pipeline/ inside your project
  • Claude apps: Settings → Capabilities → Skills

Install from the repository (alternative)

The repository README says agent skill hosts expect a directory containing SKILL.md, not a loose markdown file. From the repository root, you can copy the whole example directory into a project-scoped skills folder. The README gives these commands for Claude Code:

  • The README also lists equivalent project paths for Cursor (.cursor/skills) and Codex (.agents/skills).
  • The README notes a manual option: reference examples/book-sft-pipeline/SKILL.md directly.
mkdir -p .claude/skills cp -R examples/book-sft-pipeline .claude/skills/book-sft-pipeline

Trigger the skill with natural requests

You do not need a special command. The agent looks at the skill's description and uses it when your request matches. The description covers book-to-SFT pipelines, ePub extraction, literary segmentation, and voice-replication training, so phrase your request around those tasks. The skill's own activation list includes building fine-tuning datasets from literary works, creating author-voice or style-transfer models, and preparing training data for Tinker or similar platforms.

Specific requests work better than vague ones. Name the file, the goal, and the platform.

  • "Use the book-sft-pipeline skill to turn my ePub into a chunked JSONL training set."
  • "Segment this ePub into 150 to 400 word chunks at paragraph boundaries."
  • "Help me prepare Tinker training data in messages format for a style-transfer LoRA."
  • "Set up a LoRA training loop on Qwen3-8B-Base using this book."

What you need before you start

The skill assumes Python with the epub2 and beautifulsoup4 libraries, which the extraction example uses. It also needs an LLM API to write the instructions; the example uses a cheap model such as Gemini Flash. Training requires a Tinker or similar SFT platform account. The skill runs scripts and uses the network, so plan for both.

The skill is written for people with machine learning experience. It assumes you understand LoRA, SFT, JSONL, and model evaluation.

  • Python with epub2 and beautifulsoup4
  • An LLM API key for instruction generation (example: Gemini Flash)
  • A Tinker or similar SFT platform account
pip install epub2 beautifulsoup4

This skill runs scripts and makes network calls. The bundled scripts/pipeline_example.py is described as conceptual rather than production-ready, so read it before running it and test on a small excerpt first. Calls to an LLM API and to a training platform send your text outside your machine.

Copyright is a real concern. The skill builds training data from full book text. Whether that is allowed depends on the source and your jurisdiction. Use books you have the right to process, and do not redistribute the resulting text.

  • Read scripts/pipeline_example.py before running it.
  • Expect network traffic to your LLM provider and training platform.
  • Check the copyright status of any book before you process it.

Tips for better results

The skill's own guidance is specific. Prefer ePub over PDF, because OCR errors become learned patterns. Remove copyright pages and tables of contents so they do not pollute the dataset. Use base rather than instruct models, since the skill argues style is captured better by base models.

The example project reports a training run on Qwen/Qwen3-8B-Base with LoRA rank 32 and about 592 training examples, with a test set of 50. Treat these as one case study, not a benchmark for your book.

  • Use ePub, not scanned PDF.
  • Strip front and back matter before chunking.
  • Vary prompt templates and system prompts to reduce memorization.
  • Check outputs with the skill's evaluation steps before trusting the model.

What people use it for

  • Building a style-transfer dataset from a public-domain novel for a small base model.
  • Preparing chat-style JSONL training files from an ePub for a fine-tuning platform.
  • Experimenting with how chunk size affects style transfer on a small model.
  • Documenting a case study of a model trained to write in an author's voice, as in the Gertrude Stein example.

Frequently asked questions

Is the book-sft-pipeline skill free?

The skill is published under the MIT licence, as stated on this page. Your own costs come from the LLM API used for instruction generation and from any Tinker or similar training platform account you use. The source does not list prices, so check those providers directly.

What do I need to run the book-sft-pipeline skill?

You need Python with the epub2 and beautifulsoup4 libraries, an LLM API for generating instructions (the example uses Gemini Flash), and a Tinker or similar SFT platform account for training. The skill also runs scripts and uses the network.

Where do I install an agent skill?

Unzip the downloaded folder into ~/.claude/skills/ for personal use or into a project's .claude/skills/ folder. In the Claude apps, you can upload it under Settings → Capabilities → Skills.

Do I need ML experience to use this skill?

Yes, the skill assumes familiarity with LoRA, SFT, JSONL, and model evaluation. The bundled script is described as conceptual rather than production-ready, so it is not a turnkey tool for beginners.

Can I use this skill to copy copyrighted books?

The skill is not intended for copying or redistributing copyrighted books. It builds training data from full book text, which may raise copyright and licensing issues depending on the source and jurisdiction. Check the rules that apply to your book and your location.

How does this compare with other fine-tuning approaches?

This skill focuses specifically on book-to-SFT pipelines for author voice, with a defined chunking and prompt-variation method. It is not a general fine-tuning framework. If you need a general-purpose training workflow or do not work with literary text, a different tool or guide may suit you better.

New agent skills, repos and AI tools — every week

The best new skills and open-source projects, the fastest-growing repos, and one free prompt. Five minutes to read. Unsubscribe anytime.

Our verdict

Use this skill if you are a developer or researcher with fine-tuning experience who already has a Tinker or similar platform account and wants a documented method for turning literary text into style-transfer training data. Pick something else if you want a turnkey tool, need to avoid copyright questions, or do not yet understand LoRA and SFT.

Download the skill