Upload folder using huggingface_hub
Browse files- modeling_twentyq.py +3 -0
modeling_twentyq.py
CHANGED
|
@@ -165,6 +165,9 @@ class TwentyQForCausalLM(PreTrainedModel, GenerationMixin):
|
|
| 165 |
if qnum == 0:
|
| 166 |
return "Is it Animal, Vegetable, Mineral, or Other?"
|
| 167 |
|
|
|
|
|
|
|
|
|
|
| 168 |
nc, best_t, best_s, cidx, cscores = self._rank_targets(answers)
|
| 169 |
|
| 170 |
if nc == 0:
|
|
|
|
| 165 |
if qnum == 0:
|
| 166 |
return "Is it Animal, Vegetable, Mineral, or Other?"
|
| 167 |
|
| 168 |
+
if qnum >= 30:
|
| 169 |
+
return "I'm stumped! I can't figure out what you're thinking of."
|
| 170 |
+
|
| 171 |
nc, best_t, best_s, cidx, cscores = self._rank_targets(answers)
|
| 172 |
|
| 173 |
if nc == 0:
|