Skip to content

Conversation

@GerjanDorgelo
Copy link
Contributor

Description

Do this one first

add new features for latex to word

Fixes #880

Type of change

Please delete options that are not relevant.

  • New feature (non-breaking change which adds functionality)
  • This change requires a documentation update

Checklist:

  • I have added tests that prove my fix is effective or that my feature works
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • New and existing unit tests pass locally with my changes

…ns, subsections, and tables; improve parsing logic for text formatting.
…er and add ReportToWordConverter with enhanced features and tests
…t, enhancing report representation with structured properties.
… enumerated lists in LaTeX to Word conversion
…port-for-checks' into 880-feature-request-add-new-features-for-latex-to-word
…port-for-checks' into 880-feature-request-add-new-features-for-latex-to-word
…x document generation

- Replaced hardcoded complex LaTeX string with dynamic report generation using LatexReport class.
- Added various sections, subsections, text formatting, equations, enumerations, itemizations, and a table to the test.
- Included an image in the report to enhance testing of document conversion.
…ation

- Introduced _replace_section_commands method to handle \section, \subsection, \subsubsection, and \title commands.
- Updated _check_decimal_separator to account for figure blocks.
- Enhanced _translate_latex to translate section commands and integrate with existing text translations.
- Modified to_document and to_word methods in LatexReport to accept language parameter for localization.
- Adjusted tests to validate new language features and document conversion.
…or figure, title, section, and table translations
@GerjanDorgelo GerjanDorgelo self-assigned this Jan 3, 2026
Copilot AI review requested due to automatic review settings January 3, 2026 18:32
@GerjanDorgelo GerjanDorgelo linked an issue Jan 3, 2026 that may be closed by this pull request
2 tasks
@github-actions
Copy link

github-actions bot commented Jan 3, 2026

Thank you so much for contributing to Blueprints!
Your contributions help thousands of engineers work more efficiently and accurately.

Now that you've created your pull request, please don't go away; take a look at the bottom of this page for the automated checks that should already be running. If they pass, great! If not, please click on 'Details' and see if you can fix the problem they've identified. A maintainer should be along shortly to review your pull request and help get it added!

@coderabbitai
Copy link

coderabbitai bot commented Jan 3, 2026

Important

Review skipped

Draft detected.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Note

Other AI code review bot(s) detected

CodeRabbit has detected other AI code review bot(s) in this pull request and will avoid duplicating their findings in the review comments. This may lead to a less comprehensive review.


Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds comprehensive Word document conversion capabilities to the LaTeX reporting system, enabling reports to be exported directly to Word format with proper formatting, translation support, and handling of complex document structures.

  • Introduces ReportToWordConverter class with full support for LaTeX document elements (sections, equations, tables, figures, lists)
  • Extends translation functionality to support sections, captions, list items, and table cells
  • Adds to_word() method to LatexReport for direct Word document export with language localization

Reviewed changes

Copilot reviewed 8 out of 9 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
blueprints/utils/report_to_word.py New converter implementing comprehensive LaTeX-to-Word conversion with support for equations, tables, figures, and nested lists
blueprints/utils/report.py Added to_word() method and language parameter to to_document() for translation support
blueprints/language/translate.py Enhanced translation to handle sections, captions, list items, and table cells; improved decimal separator logic for equation contexts
tests/utils/test_report_to_word.py New comprehensive test suite covering document conversion scenarios
tests/language/test_translate.py Extended translation tests for new LaTeX element types
docs/guides/concepts/formulas.md Updated documentation describing formula representation modes
tests/test_latex_to_word_document.py Removed legacy converter tests
blueprints/latex_to_word_document.py Removed legacy converter implementation

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

…removing redundant information about check generation and method outputs.
@GerjanDorgelo GerjanDorgelo marked this pull request as draft January 3, 2026 18:34
@codecov
Copy link

codecov bot commented Jan 3, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 100.00%. Comparing base (06afbbc) to head (5350b0f).
⚠️ Report is 5 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##              main      #891    +/-   ##
==========================================
  Coverage   100.00%   100.00%            
==========================================
  Files          403       403            
  Lines        12763     13219   +456     
==========================================
+ Hits         12763     13219   +456     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[✨ Feature request]: Add new features for LaTeX to word

2 participants