Generating str/int/float/bool values with GPT2 using generate.json leads to absurd results #461
gaspard-dv
started this conversation in
Weird model output
Replies: 2 comments 1 reply
-
Will take a look! |
Beta Was this translation helpful? Give feedback.
0 replies
-
Just as described in #460 (comment), this should be converted to a discussion. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Describe the issue as clearly as possible:
I experimented a bit with outlines and I wonder what would be the recommended way to generate bools/numbers/ints.
generate.format(model, <type>, allow_empty_tokens=False)
the resulting response is often just an empty string, which can't be converted to the desired<type>
.generate.json(model, json.dumps({"type": "<type_in_json_schema_style>"})
the model tends to "block" or to produce stupid answers.Regardless of my question, I believe that this second bullet point is an issue, so I'm adding a reproduction snippet below.
NB: I'm not allowed to add the "correctness" label.
Steps/code to reproduce the bug:
Expected result:
EXPECTED: g h i j k (...) g h i j k (...) ACTUAL: g h i j k (...) for all readable words H. Servo Oamber Trident Warrior Drug of others (...)
Error message:
No response
Outlines/Python version information:
Context for the issue:
No response
Beta Was this translation helpful? Give feedback.
All reactions