Skip to content

v1.2.0 - Company letterhead

Latest

Choose a tag to compare

@ianustec ianustec released this 19 Jul 05:44

What's new

  • Company letterhead: set letterhead: "Filename.docx" in frontmatter (aliases: sample, base_docx)
  • Accepts .docx and .dotx (templates are converted in memory for python-docx)
  • Resolves the file from chat attachments first, then from /mnt/uploads and the Open WebUI upload dir
  • Matches uuid-prefixed upload names (<uuid>_Filename.dotx)
  • Optional valve letterhead_dirs to override the scan paths
  • Keeps header, footer and page margins; rewrites only the body
  • Example + smoke tests in examples/letterhead.md and examples/test_letterhead.py

Notes

  • Do not set a programmatic cover together with a letterhead
  • Prefer calling generate_document with letterhead set instead of reading the template via execute_code
  • Open WebUI RAG may dump .dotx as binary text in context; putting the file under /mnt/uploads is a reliable path

Install

Paste generate_documents.py into Workspace → Tools, or replace your existing copy with this release.