MathCAT icon indicating copy to clipboard operation
MathCAT copied to clipboard

Add a UEB contractions exceptions list

Open NSoiffer opened this issue 2 years ago • 1 comments

There are other issues that suggest language-specific braille definitions.yaml file. This issue is about adding a ContractionsOverride entry. This would be used to override what happens given the limited rules used by MathCAT. For example, "arccos" has rules for contracting "ar" and "cc". However, the "cc" shouldn't be used because "arccos" is a non-hyphenated compound word (RUEB 10.11.1). So "arccos" would be in the table.

ContractionsOverride: [
   "arccos" : ">ccos",
   "arccosine" : ">ccos9e",
 ]

Probably want to accept both Unicode braille and ASCII braille (as above).

The code would first check this list for standing alone words (hashmap in Rust), and then apply rules if not in the table.

In addition to "arccos", all the words in RUEB 10.1 and 10.2 should be in the list. Faster runtime and more flexible (can add "can't" etc., and not make the rule more complicated by checking for '.

NSoiffer avatar Nov 14 '23 19:11 NSoiffer

Perhaps the "Default Operator Names" list provided by Desmos's Abraham Braille Library could help in making MathCAT's exception list. It is also a great project otherwise:

Abraham is a library for converting between LaTeX and the Braille math codes Nemeth and UEB. If you are interested in using this library, please contact us at [email protected].

NV-Codes avatar Feb 04 '25 22:02 NV-Codes