Recognizers-Text icon indicating copy to clipboard operation
Recognizers-Text copied to clipboard

[EN Dimension] Add ' to Foot symbols (#1820)

Open aitelint opened this issue 5 years ago • 4 comments

Fix for issue #1820, 5' to be recognized as type=dimension, unit=Foot, value=5. Test case added to DimensionModel

aitelint avatar Aug 21 '20 08:08 aitelint

This would also require extra processing to avoid matching as surrounding single-quote. Like in '5'.

yes I thought so, but the same kind of processing should be required also for " (inch) which is currently included in the unit list ("5" returns 5 inches).

aitelint avatar Aug 21 '20 10:08 aitelint

Do you have an estimate to handle the mentioned "quote" issue?

I have not looked into the "quote" issue yet, I was trying to tackle the python failure first. The problem there is that list elements in the yaml file are converted to raw strings, but while " is correctly converted to r'"', ' becomes r'\''. Do you have any suggestion on how to solve it?

aitelint avatar Sep 02 '20 11:09 aitelint

Do you have an estimate to handle the mentioned "quote" issue?

I have not looked into the "quote" issue yet, I was trying to tackle the python failure first. The problem there is that list elements in the yaml file are converted to raw strings, but while " is correctly converted to r'"', ' becomes r'''. Do you have any suggestion on how to solve it?

This would also require a change in the Python code generator. We can add it once the .NET version is finalized.

tellarin avatar Sep 08 '20 03:09 tellarin

@tellarin, added regex to handle the quote issue (merged with the existing NonUnitRegex)

aitelint avatar Sep 14 '20 06:09 aitelint