contractions icon indicating copy to clipboard operation
contractions copied to clipboard

Words that shouldn't be fixed

Open Animenosekai opened this issue 4 years ago • 5 comments

I think that you should check if the word is inside of a quotation before fixing it.

For example:

>>> import contractions
>>> contractions.fix("you're happy now")
'you are happy now' # works fine
>>> contractions.fix('I like the letter "u"')
'I like the letter "you"' # "u" should stay "u"

Animenosekai avatar Jun 14 '21 13:06 Animenosekai

I like it.. what would be other examples? This might be the only one?

kootenpv avatar Jun 14 '21 18:06 kootenpv

I like it.. what would be other examples? This might be the only one?

Maybe something like:

When Josh got interviewed about his new song, he got asked the meaning of the sentence:
"You're never gonna believe this"
He couldn't answer at the time.

Yes that's a dumb example but I mean, quotes shouldn't change because they need to give the exact meaning the writer wanted to give

Animenosekai avatar Jun 14 '21 23:06 Animenosekai

I like it.. what would be other examples? This might be the only one?

Maybe something like:

When Josh got interviewed about his new song, he got asked the meaning of the sentence:
"You're never gonna believe this"
He couldn't answer at the time.

Yes that's a dumb example but I mean, quotes shouldn't change because they need to give the exact meaning the writer wanted to give

Difficult to know which quotes belong to each other though...

Example: "what to" "replace here"

kootenpv avatar Jun 15 '21 01:06 kootenpv

Difficult to know which quotes belong to each other though...

Example: "what to" "replace here"

I mean, maybe by counting the number of "?

I don't know it was an idea but you could let the user do it by himself and don't change anything

Animenosekai avatar Jun 15 '21 10:06 Animenosekai

Difficult to know which quotes belong to each other though... Example: "what to" "replace here"

I mean, maybe by counting the number of "?

I don't know it was an idea but you could let the user do it by himself and don't change anything

Yea I think unfortunately this is not easy to get right I feel. Also the algorithm doesn't lend itself well for it. It would be only good for fixed-length string patterns. So in that sense, "u" could work, but anything beyond that is not really possible.

kootenpv avatar Jun 15 '21 21:06 kootenpv