dreasysnail / POINTER

MIT License
112 stars 19 forks source link

How to restrict some key words as a whole instead of seperating them? #14

Open etrigger opened 3 years ago

etrigger commented 3 years ago

For example, I have the following key words:

Hello kitty blanket Fleece

I want to treat the whole of "Hello kitty" as a key word, and generates text similar to the following:

Cartoon Hello Kitty Printing Throw Blanket Soft Cover Flannel Cozy Plush Fleece Blanket for Boys Girls Kids

Sentences like ' hello kitty ...' are not corrected.

dreasysnail commented 3 years ago

It's fixed now. Please see the updated version of code and demo. What you need to do is to separate the constraints by ";"

etrigger commented 3 years ago

Thanks for your replay.

One more question is how to limitate the max length of the generated text?