Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

telegramify: Add support for latex image rendering #41

Open
sudoskys opened this issue Dec 11, 2024 · 7 comments
Open

telegramify: Add support for latex image rendering #41

sudoskys opened this issue Dec 11, 2024 · 7 comments
Labels
enhancement New feature or request good first issue Good for newcomers help wanted Extra attention is needed

Comments

@sudoskys
Copy link
Owner

No description provided.

@sudoskys sudoskys added enhancement New feature or request good first issue Good for newcomers labels Dec 11, 2024
@neutron-nerve neutron-nerve bot added the help wanted Extra attention is needed label Dec 11, 2024
@sudoskys sudoskys removed the help wanted Extra attention is needed label Dec 11, 2024
@sudoskys
Copy link
Owner Author

@sudoskys sudoskys added the help wanted Extra attention is needed label Dec 13, 2024
@sudoskys
Copy link
Owner Author

Local rendering may introduce potential RCE, so we decided to build in some latex on http

@sudoskys
Copy link
Owner Author

Dense math tex may disrupt the continuity of reading.
And we can't convert them to png...
This will make copying inconvenient

@sudoskys
Copy link
Owner Author

Extending the parser for non-native grammars may cause undesired conversions to occur.

Publishing to an online service would also break the responsibilities of the dependent library.

So I decided to render the entire text paragraph in Latex and attach the original message.
Display it in the form of a caption. It ensures readability while being easy to understand.

@sudoskys
Copy link
Owner Author

sudoskys commented Jan 3, 2025

I ran into problems with the implementation that the Python ecology couldn't solve:

The option that balances reproducibility and comprehensibility is to render additional images of paragraphs with latex and attach the original content. But the Python ecosystem makes this hard to do, and many latex tools require us to install the tex-live suite (which is huge) and render poorly. Maybe it's time to turn to the front-end tech stack

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

1 participant