rivescript-js icon indicating copy to clipboard operation
rivescript-js copied to clipboard

Make lowerCase conversion optional

Open josephrexme opened this issue 8 years ago • 4 comments
trafficstars

This forces every input to be converted to lower case but I need the correct letter casing from the input. Can we take this out completely or make it optional like unicodePunctuation https://github.com/aichaos/rivescript-js/blob/e734896f781904a54c9f4002b18e1bd9e221ea70/src/brain.coffee#L588

josephrexme avatar Sep 12 '17 16:09 josephrexme

Is there any risk posed by upper case letters? Why can't there be case sensitive inputs?

josephrexme avatar Sep 12 '17 17:09 josephrexme

I think we discussed this originally and @kirsle felt it would be too demanding on users to have case sensitive required. we had problems around having to artificially type things like i am here with I in lowercase.

https://github.com/aichaos/rivescript-js/issues/143

dcsan avatar Sep 13 '17 06:09 dcsan

@dcsan with the changes on my PR referenced here #246 , we wouldn't be forcing case sensitive inputs on users. It only gets added when the author wants it. I.e new Rivescript({caseSensitive: true}) without that, everything converts to lower case. I just can't tell why the tests are failing on that. I'd write a test for it but it is quite hard to understand how the tests are arranged per feature and the test errors are so long with no detail or proper trace

josephrexme avatar Sep 13 '17 06:09 josephrexme

@kirsle I got the tests passing on the PR for this. Is it something that will be considered?

josephrexme avatar Sep 13 '17 07:09 josephrexme