Skip to content

Releases: ForLegalAI/mcp-ms-office-documents

v3.15 - Word (DOCX) lists: <br> breaks & numbering continuation

24 Jun 06:55
bf6a37a

Choose a tag to compare

Word (DOCX) — lists after <br> and numbering continuation

Fixed

  • A numbered/bulleted list (or heading) that follows a <br> is now recognised as a real block instead of rendering as literal text. Previously <br> was only an inline soft break, so Výrok soudu:<br>1. První<br>2. Druhý produced one paragraph with the 1./2. as plain text; it now produces an intro paragraph plus a proper numbered list. This applies to both create_word_from_markdown and DOCX template placeholders.
  • Ordered-list numbering now continues across an intervening heading or blank line. Procedural filings whose numbered paragraphs run 1., 2. under one heading and 3., 4. under the next now render as a single 1–4 sequence (the continuation resumes the count via startOverride) instead of 3./4. falling back to plain text.

Changed

  • <br> becomes a block break (new paragraph / list item) when it directly borders block content — a list item or a heading. A <br> between prose still produces a soft break (line break within a paragraph), and <br> inside a table cell is unchanged. This refines the v3.14 rule “<br> → soft break”: prose and table behaviour are identical, only block-bordering <br> is promoted.

Behaviour preserved

  • A standalone date (23. června 2026) and a blank-separated number pair with no preceding list (5. / 6.) still render as prose — the date-vs-list disambiguation is unchanged. Numbering continuation requires the markdown’s explicit numbers to match the running count, so a non-matching number under a later heading stays prose.
  • A list that restarts at 1. still restarts.

Tests

  • New tests/test_docx_list_continuation_and_br.py (17 tests: <br> block promotion, continuation across headings, single-item continuation, restart, plus regressions for prose <br>, table-cell <br>, and date disambiguation). Full DOCX suite: 337 passing.

Full changelog: v3.14...v3.15

v3.14 - Word (DOCX) line breaks: fix & unify

23 Jun 21:30
25711fa

Choose a tag to compare

Word (DOCX) — newline handling fixed and unified

Fixed

  • A literal \n (the two characters backslash + n, e.g. from a double-escaped tool argument) is no longer corrupted into a stray n with the paragraph break lost. The backslash-escape handler now follows CommonMark — it only un-escapes ASCII punctuation — so \t, \d, and Windows paths like C:\new are preserved too.
  • Literal \n / \r\n / \r sequences are now converted to real line breaks, so a value the model wrote with escaped newlines renders correctly.

Changed — unified newline semantics

Newline handling is now identical between create_word_from_markdown and DOCX templates:

  • blank line → new paragraph
  • single line break → new paragraph
  • <br> or two trailing spaces → soft break (line break within a paragraph)

Multi-line whole-paragraph placeholders render through the same markdown pipeline as the base tool. The placeholder paragraph's layout (alignment/indent/spacing) and the placeholder run's character format are carried onto produced prose, while headings, lists and quotes keep their own styles. (Side benefit: justified body text no longer stretches the line before each break.)

Docs

  • The create_word_from_markdown description and the example config/docx_templates.yaml no longer demonstrate a literal \n (which taught models to emit it), and now document the three line-break cases plus the YAML | vs > block-scalar pitfall.

Tests

  • New tests/test_docx_escaped_newlines.py (literal-\n regression, punctuation escaping, base↔template parity, style/format propagation vs. heading/list style retention).

Full changelog: v3.13...v3.14

v3.13 - Multi-arch Docker (amd64 + arm64)

22 Jun 14:10
7cadc78

Choose a tag to compare

CD / Docker

  • Fixes the Docker publish that failed for v3.12 (empty image tag — invalid reference format). The image tag is now sourced from the release payload (github.event.release.tag_name) and guarded against empty values.
  • Multi-arch images: the published image now supports both linux/amd64 and linux/arm64.

This release supersedes v3.12, which never published a Docker image.

🤖 Generated with Claude Code

v3.12 - Word (DOCX) Bug Fixes

21 Jun 18:16
b688d6a

Choose a tag to compare

What's Changed

  • Word DOCX: disambiguate numbered-list dates and preserve placeholder formatting by @dvejsada in #72

Word Tool

Two DOCX rendering fixes that make generated documents truer to the source — especially for date-heavy templates (legal documents, contracts) and richly-formatted placeholders.

Bug Fixes

🔢 Standalone dates no longer become numbered lists

A line that merely starts with a number followed by a dot — most commonly a dates in some languages like 23. června 2026 — was being misread as the 23rd item of a numbered list. Numbered-list detection is now continuation-aware:

A numbered line starts a list only when it begins at 1. or is followed by another item (a sibling or a nested item).

Input Before After
23. června 2026 (on its own) ❌ list item #23 ✅ plain paragraph
5. Fifth / 6. Sixth numbered list (start 5) ✅ unchanged
1. Only item (on its own) numbered list ✅ unchanged
1. First / 2. Second numbered list ✅ unchanged

Highlights

  • No false positives for dates — days 2–31 are handled automatically; a standalone numbered line is treated as prose.
  • Real lists are untouched — single-item lists and lists that intentionally start at a number other than 1 (e.g. 5., 6.) still render correctly.
  • Consistent in templates — the same rule applies to Markdown injected through {{placeholder}} values, so a date in a placeholder stays inline text.
  • Day-1 escape hatch — a day-1 date (1. června 2026) is byte-for-byte identical to a one-item list, so escape the dot to force prose: 1\. června 2026.

🎨 Placeholder replacement keeps its formatting

Filling a {{placeholder}} used to flatten the surrounding text to plain runs and drop most of the placeholder's own styling. Now formatting is preserved on both sides of the replacement:

  • The placeholder's own formatting carries over — font, size, colour, and now bold, italic, underline, and highlight are captured from the placeholder and applied to the replacement text.
  • Surrounding text is preserved — formatting of the text before and after the placeholder in the same paragraph (bold, italic, colour, highlight, character styles…) is kept instead of being reset to plain.
  • Markdown still wins — formatting the value asks for (e.g. **bold**) is never overridden; the placeholder's style only fills what the value left unset. An explicit "not bold" on the placeholder is honoured too.

Notes & Limitations

  • Two adjacent date-like lines (e.g. 23. června 2026 immediately followed by 24. července 2026) look exactly like a two-item list and will still render as one — escape them if they must stay prose.
  • Formatting preservation applies to the inline replacement path. Block content (a list/heading value) is still inserted as separate paragraphs styled by the template's style map.

Full Changelog: v3.11...v3.12

v3.11 - Conditional Template Blocks

21 Jun 15:00
0cdfab1

Choose a tag to compare

What's Changed

  • Word DOCX: conditional template blocks via {{#if}} / {{/if}} markers by @dvejsada in #71

Word Tool — Release Notes

New Feature

🔀 Conditional Template Blocks

Dynamic DOCX templates can now include or omit a whole range of content depending on a boolean tool argument. Wrap the optional part of your template between marker paragraphs and it appears only when the flag says so — perfect for optional clauses, alternative wording, and "either/or" sections.

Include when true:

{{#if include_arbitration}}
Any dispute shall be resolved by binding arbitration...
(any paragraphs, lists, page breaks — even whole tables — may go here)
{{/if}}

Include when false (negated):

{{^if include_arbitration}}
Disputes are resolved in the courts of competent jurisdiction.
{{/if}}

Pairing {{#if}} with {{^if}} on the same flag gives a clean mutually-exclusive "either/or" clause.

Drive it from a bool argument in config/docx_templates.yaml:

args:
  - name: include_arbitration
    type: bool
    description: Include the binding-arbitration clause.
    required: false
    default: false

Highlights

  • Block-level granularity — everything between the markers is kept or dropped together: paragraphs, lists, page breaks, and whole tables.
  • Nesting — blocks can be nested; an inner block only renders when all enclosing conditions are satisfied.
  • Robust marker detection — markers are matched even when Word splits them across runs, and stray spacing inside the braces (e.g. {{ #if flag }}) is tolerated.
  • Forgiving by design — an unknown condition name keeps its content (a typo never silently deletes a clause), and unbalanced markers don't fail the document: a warning is logged, all content is preserved, and the marker paragraphs are stripped.

Notes & Limitations

  • A marker must be the paragraph's only text, and a {{/if}} pairs with the most recently opened block (nesting order), not by name.
  • Conditions resolve before placeholder substitution, so {{name}} placeholders inside a kept block are filled normally; those in a dropped block disappear with it.
  • Conditionals currently apply to the document body — inside table cells, headers, and footers they aren't processed yet. Inline (mid-paragraph) conditions and boolean expressions are planned follow-ups; today's marker syntax is forward-compatible with both.

Full Changelog: v3.10...v3.11

v3.10 - Base image patch

20 Jun 08:25
19da7df

Choose a tag to compare

What's Changed

  • fix(docker): patch base-image OS CVEs (openssl/musl/xz/sqlite) by @dvejsada in #70

Full Changelog: v3.9...v3.10

v3.9 - Word (DOCX) Improvements

19 Jun 16:03
b98dd23

Choose a tag to compare

What's Changed

  • Word DOCX: list restart, custom styles, code blocks, parser fixes by @dvejsada in #68

Word Tool — Release Notes

New Features

🔢 Numbered List Restart

Each ordered list that begins again at 1. now restarts numbering instead of continuing the previous count. A list that starts at N is honored too.

1. First
2. Second

1. Restarts at one   ← was 3 before
2. Two

🎨 Custom Style Mapping

Map the renderer's built-in style names to your template's own styles — no need to rename styles in Word. Set a global style_mapping (and/or a per-template one that overrides it) in config/docx_templates.yaml:

style_mapping:
  heading_1: "Brand Title"
  list_number: "Brand Numbers"
  quote: "Brand Quote"
  table: "Brand Table"
  code: "Code Block"

Keys: heading_1heading_6, list_number/_2/_3, list_bullet/_2/_3, quote, table, normal, code. Unknown names fall back to the document default with a warning — generation never fails.

🏷️ Per-Block Style Tag

Apply any template style to a single block inline, without a mapping. Put the directive directly above the block:

<!-- style: Callout -->
This paragraph uses the "Callout" style.

Applies to the next block only (every item of a list, or the table).

🧩 Fenced Code Blocks

Triple-backtick / tilde fences render verbatim in a monospace font — markdown inside (headings, lists, backticks) is no longer mis-parsed.

```python
def greet(name):
    return f"Hello, {name}!"   # indentation & comments preserved
```

Map the paragraph style with the code key (e.g. to set Consolas / JetBrains Mono); otherwise Courier New is used.


Improvements

  • Flexible list indentation — nested lists now work with 2, 3, or 4 spaces, or a tab (previously only a 3-space step nested correctly).
  • Composable table directives<!-- borderless -->, <!-- widths: … -->, and <!-- style: … --> are collected by one mechanism and can be stacked above the same table.
  • Example broadcast-email template — a documented dynamic email template (bu_broadcast_email_style_1) ships in config/email_templates.yaml + default_templates/ as a starting point.

Fixes

  • Nested emphasis at a *** boundary**bold *italic*** and *italic **bold*** no longer leak a literal * or mis-format the rest of the line.
  • Code blocks stay monospace even when a mapped code style is missing from the template.
  • Clearer fallback when a mapped or tagged style doesn't exist in the template.

Full Changelog: v3.8...v3.9

v3.8 - XLSX Improvements

26 May 04:07
f4fe993

Choose a tag to compare

What's Changed

Excel Tool — Release Notes

New Features

🔽 Auto-Filter

Add filter dropdowns to table headers for sorting and filtering in Excel. Set auto_filter: true when calling the tool. Supports multiple tables per sheet.

❄️ Freeze Panes

Keep headers visible while scrolling. Place <!-- freeze --> directly above a table.

🏷️ Column Type Directives

Force data types per column with <!-- types: ... --> directly above a table:

<!-- types: text, currency:€, number, date, percent, bool -->
| ID    | Price  | Qty | Date       | Margin | Active |
|-------|--------|-----|------------|--------|--------|
| 00123 | €1.250 | 50  | 25.05.2026 | 15%    | yes    |

Types: text (preserves leading zeros), currency:<symbol> ($, €, £, ¥, Kč, zł, kr, CHF, R$, ₹), number, date, percent, bool. Leave blank for auto-detection.

↔️ Column Alignment

Standard markdown alignment syntax in the separator row:

  • :--- left | :---: center | ---: right

📅 Automatic Date Detection

Dates are auto-recognized and stored as Excel date values. Supports ISO, European, US, and many other formats via dateutil.


Improvements

  • Formulas must start with = — no implicit detection
  • Inline cell formatting: **bold**, *italic*, `code`
  • Better column width auto-sizing
  • Directives can be stacked above the same table
  • Improved error handling and input validation

Full Changelog: v3.7...v3.8

v3.7 - PPTX Improvements

25 May 08:10
5910e18

Choose a tag to compare

What's Changed

  • feat: enhance PowerPoint presentation creation by @dvejsada in #61

PowerPoint Tool — New Features

Inline Text Formatting

Bullet points and quote text now support markdown-style inline formatting. Simply use standard markdown syntax in your text fields — no extra configuration needed.

Syntax Result
**bold** bold
*italic* italic
***bold italic*** bold italic
~~strikethrough~~ strikethrough
__underline__ underlined text
`code` monospace (Courier New) font

Formatting works in: content slide bullets, two-column slide bullets, and quote text. Escape with backslash (\*literal asterisks\*) to prevent formatting.


Subtitle on Title Slides

Title slides now use a subtitle field for the text below the main title. Use it for taglines, dates, author names, event names, or any secondary text.

{
  "slide_type": "title",
  "slide_title": "Q4 Business Review",
  "subtitle": "Confidential — December 2025"
}

Author (Document Metadata)

Set the presentation author in file properties — visible in PowerPoint's Info panel and when sharing files. This is a presentation-level parameter, not per-slide.

{
  "author": "Jane Smith"
}

Footer Text

Display a consistent footer on every slide — ideal for company names, confidentiality notices, or document identifiers.

{
  "footer_text": "Acme Corp — Internal Use Only"
}

The footer appears in the standard PowerPoint footer area (bottom of each slide) and supports special characters.


Slide Numbers

Enable automatic slide numbering across all slides with a single flag.

{
  "show_slide_numbers": true
}

Slide numbers appear in the standard PowerPoint position (typically bottom-right) and update automatically when slides are reordered.


Table Column Alignment

Tables now support column alignment via the standard markdown separator row. Include it as the second row of your table data:

{
  "slide_type": "table",
  "slide_title": "Financial Summary",
  "table_data": [
    ["Item", "Q1", "Q2", "Total"],
    [":---", ":---:", "---:", "---:"],
    ["Revenue", "$1.2M", "$1.5M", "$2.7M"],
    ["Costs", "$800K", "$900K", "$1.7M"]
  ]
}
Separator Alignment
:--- Left (default)
:---: Center
---: Right

The separator row is automatically removed from the rendered table — only the alignment is applied.

Full Changelog: v3.6...v3.7

v3.6 - Async Runner and Docx improvements

22 May 04:57
8e6099d

Choose a tag to compare

What's Changed

  • a configurable async_runner of mcp tool functions are added as wrapper so that event loop doesn't get stuck on long processing work by @zahangirbu in #54
  • Docx improvements by @dvejsada in #60

DOCX Tool Improvements

New Inline Formatting

Syntax Result Example
^text^ Superscript E = mc^2^ → E = mc²
~text~ Subscript H~2~O → H₂O
==text== Yellow highlight ==important==

Table Enhancements

  • Column alignment:---|:---:|---: in separator row for left/center/right
  • Borderless tables<!-- borderless --> before the table removes all borders
  • Column widths<!-- widths: 30 70 --> before the table sets proportional column widths (works with any number of columns)
  • Multi-paragraph cells<br> inside a cell creates a new paragraph

Directives can be combined on consecutive lines before the table.

Text Processing

  • HTML entities&nbsp;, &mdash;, &hellip;, &copy;, smart quotes, etc. are decoded to proper characters
  • <br> soft breaks<br> tags produce line breaks in regular text
  • HTML comments<!-- ... --> lines are silently skipped (used for table directives)

Refactoring

  • Unified markdown parsing into a single process_markdown_content() function (was duplicated in 3 places)
  • Split monolithic helpers.py (871 lines) into 5 focused modules

Full Changelog: v3.5...v3.6