mirror of
https://github.com/wassname/Clover-Edition.git
synced 2026-09-24 13:00:12 +08:00
added warning and some documentation to new features
This commit is contained in:
@@ -9,3 +9,9 @@ removed useless dependencies
|
||||
added text wrapping
|
||||
added ability to save custom prompts
|
||||
added color support on windows via colorama
|
||||
changed to use pytorch gpt using the transformers module
|
||||
added ability to use 16bit mode on GPU to save significant VRAM
|
||||
added suggested actions
|
||||
added "d20" randomization of action sucess/failure
|
||||
added repetitiveness penalty for AI
|
||||
probably a lot of stuff I forgot to add here...
|
||||
|
||||
+3
-1
@@ -9,7 +9,9 @@
|
||||
# Ok coomers.
|
||||
temp = 0.4
|
||||
|
||||
repetition-penalty = 1.2
|
||||
#Repetitiveness Penalty
|
||||
#controls how repetitive the AIs output is allowed to be. Ideal values unknown and untested so far
|
||||
rep-pen = 1.2
|
||||
|
||||
#The number of words the AI has to choose from.
|
||||
# It always chooses the "top k" most likely next words before randomly picking one according to temperature.
|
||||
|
||||
@@ -8,9 +8,10 @@ The following commands can be entered for any action:
|
||||
"print" Prints a transcript of your adventure (without extra newline formatting)
|
||||
"help" Prints these instructions again
|
||||
"set SETTING VALUE" Sets the specified setting to the specified value.:
|
||||
temp Higher values make the AI more random. Default: 0.4
|
||||
rep-pen Controls how repetitive the AI is allowed to be. Default: 1.2
|
||||
text-wrap-width Maximum width of lines printed by computer. Default: 80
|
||||
console-bell Beep after AI generates text? Default: on
|
||||
temp Higher values make the AI more random. Default: 0.4
|
||||
top-keks Number of words the AI can randomly choose. Default: 20
|
||||
generate-num Default: 60
|
||||
top-p Default: 0.9
|
||||
|
||||
@@ -0,0 +1 @@
|
||||
ATTENTION: Clover-Edition has just gone through some major updates. You will have to reinstall if you are still on the old version. Many things have been changed. Please read the README.md or https://github.com/cloveranon/Clover-Edition
|
||||
@@ -1,7 +1,9 @@
|
||||
from pathlib import Path
|
||||
with open(Path('interface', 'start-message.txt'), 'r') as file:
|
||||
print('\x1B[7m'+file.read()+'\x1B[27m')
|
||||
import gc
|
||||
import random
|
||||
import textwrap
|
||||
from pathlib import Path
|
||||
from random import shuffle
|
||||
from shutil import get_terminal_size
|
||||
|
||||
@@ -64,7 +66,7 @@ def selectFile(p=Path('prompts')):
|
||||
for n in range(len(files)):
|
||||
colPrint(
|
||||
'{}: {}'.format(n, re.sub(r'\.txt$', '', files[n].name)),
|
||||
colors["menu"])
|
||||
colors['menu'])
|
||||
return selectFile(files[getNumberInput(len(files)-1)])
|
||||
else:
|
||||
with p.open('r', encoding='utf-8') as file:
|
||||
@@ -80,13 +82,13 @@ def instructions():
|
||||
def getGenerator():
|
||||
colPrint(
|
||||
"\nInitializing AI Engine! (This might take a few minutes)\n",
|
||||
colors["loading-message"])
|
||||
colors['loading-message'])
|
||||
return GPT2Generator(
|
||||
generate_num=settings.getint('generate-num'),
|
||||
temperature=settings.getfloat('temp'),
|
||||
top_k=settings.getint('top-keks'),
|
||||
top_p=settings.getfloat('top-p'),
|
||||
repetition_penalty=settings.getfloat('repetition-penalty')
|
||||
repetition_penalty=settings.getfloat('rep-pen')
|
||||
)
|
||||
|
||||
if not Path('prompts', 'Anime').exists():
|
||||
|
||||
Reference in New Issue
Block a user