mirror of
https://github.com/wassname/Clover-Edition.git
synced 2026-10-29 12:40:16 +08:00
avoid loop
This commit is contained in:
1 parent
57432290ea
commit
90fdedcfc2
1 file changed
+2
-2
+2
-2
@@ -224,6 +224,6 @@ class GPT2Generator:
|
||||
result = text
|
||||
result = self.result_replace(result)
|
||||
if len(result) == 0:
|
||||
return self.generate(prompt)
|
||||
|
||||
logger.warn("Model generated empty text %s.", result)
|
||||
# return self.generate(prompt) # Woah recursion!
|
||||
return result
|
||||
Reference in new issue
Block a user