YAML-to-Word document generator for automated pipelines and LLM-driven content creation
Project description
docsmith
YAML-in, Word-out. Define document content in a simple YAML schema and docsmith forges it into a professionally formatted Word (.docx) file.
Why docsmith?
docsmith is built for automated pipelines and LLM-driven content generation. The YAML input format is deliberately simple -- flat, predictable, and easy for any language model or script to produce. No template engine, no programming required. Hand it a YAML file, get a Word document back.
Use cases:
- LLM document generation -- have an AI produce structured YAML, then render to Word
- CI/CD pipelines -- generate reports, proposals, or compliance documents as build artifacts
- Batch processing -- convert a directory of YAML files to Word in one pass
- Content-first authoring -- focus on content in YAML, let docsmith handle formatting
Installation
pipx install docsmith
Or with pip:
pip install docsmith
Usage
# Generate a Word document from a YAML source
docsmith input.yaml
# Specify output directory
docsmith input.yaml -o output/
Also works as a Python module:
python -m docsmith input.yaml
YAML Document Format
title: "Document Title"
subtitle: "Subtitle text"
status: "Draft"
content:
- heading: "Section Heading"
level: 1
- text: "Paragraph with **bold** and *italic* support."
- bullets:
- "First bullet point"
- "Second bullet with **bold**"
- numbered:
- "Step one"
- "Step two"
- table:
headers: ["Column A", "Column B"]
rows:
- ["Cell 1", "Cell 2"]
- ["Cell 3", "Cell 4"]
- decision: "A decision callout that needs stakeholder input"
Supported Block Types
| Block | Purpose |
|---|---|
heading |
Section heading (level 1-4) |
text |
Paragraph with inline bold/italic |
bullets |
Unordered list |
numbered |
Ordered list |
table |
Table with headers and rows |
decision |
Red decision callout |
Document Metadata
docsmith sets SharePoint/OneDrive-compatible document properties:
dc:creatorandcp:lastModifiedByset to "docsmith"dcterms:createdanddcterms:modifiedset to generation timestampdc:titleanddc:subjectpopulated from YAML metadata
Future Output Formats
Word is the first format. The YAML source schema is designed to be renderable to multiple output formats (PDF, HTML, Markdown) in future versions.
License
GPL-3.0-or-later. See LICENSE for details.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file docsmith-0.1.1.tar.gz.
File metadata
- Download URL: docsmith-0.1.1.tar.gz
- Upload date:
- Size: 17.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.10.9 {"installer":{"name":"uv","version":"0.10.9","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
259378cc5b3d996853c158f8a1c4f45175b3e8dfd1a2a285b264a45819dffb74
|
|
| MD5 |
09a0e0404545f28b26dbd18754fdb7ab
|
|
| BLAKE2b-256 |
225662b510b261f4d42f45f977f55d442f9abcc2711951d2a6292d98509d5a51
|
File details
Details for the file docsmith-0.1.1-py3-none-any.whl.
File metadata
- Download URL: docsmith-0.1.1-py3-none-any.whl
- Upload date:
- Size: 18.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.10.9 {"installer":{"name":"uv","version":"0.10.9","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7c11a55234a580a150d06973acf31ac0e893509865100c629c752af8cdf12f40
|
|
| MD5 |
8df5f93efe11e4d811badc7df557131c
|
|
| BLAKE2b-256 |
76b3b40475edb66987572e3532fedcac48f9af2d170c3f04f8b355b993e60ffc
|