-
Notifications
You must be signed in to change notification settings - Fork 111
Parse from latex #38
Comments
The string parsing in algebra.js is split into 2 steps:
The parser is independent of the used input format, as it operates on the generated token stream. In general, I don't think LaTeX is the best input format as it's purpose is to encode how the input is displayed and not what it represents. To write a lexer that accepts basic LaTeX as input is not too difficult. You could give it a try with the existing lexer as a template or I could write one if others also see a use for it ;) TL;DR: I think LaTeX is not an appropriate input format but a lexer for it would be not too hard to write. |
Thanks for that elaborate reply. I agree that latex probably isn't the best input format, but I'm getting latex formatted formulas returned from some handwriting recognition service I'm using. If you could make an example file I could look and and expand, that would be nice. |
I made a package that can parse latex to algebra.js link. |
Woah awesome @viktorstrate !!! Will get this added to the docs. |
Cool 🎉 Thank you ^^ |
that would be amazing and thank you @viktorstrate |
I am really impressed with this project.
I'm in need of a way of parsing latex, to the string format used here. It's already possible to parse to latex, so I'm not sure if the other way is possible too. I looked at Jison and stuff, but I'm in way over my head here.
The text was updated successfully, but these errors were encountered: