Spaces:
Runtime error
Runtime error
Deila Proalfa
commited on
Commit
·
b20bce6
1
Parent(s):
e208e45
Update app.py
Browse files
app.py
CHANGED
@@ -70,11 +70,14 @@ ins = '''### Instruction:
|
|
70 |
'''
|
71 |
|
72 |
def run_falcon(input, scrape, scrape_type):
|
73 |
-
|
74 |
-
|
75 |
-
|
76 |
-
|
77 |
-
|
|
|
|
|
|
|
78 |
|
79 |
with Gradio.Blocks(theme=custom_theme, analytics_enabled=False, css=".generating {visibility: hidden}") as demo:
|
80 |
with Gradio.Column():
|
|
|
70 |
'''
|
71 |
|
72 |
def run_falcon(input, scrape, scrape_type):
|
73 |
+
system_prompt = "You are Ailex, a clone and close associate of Einfach.Alex. As part of the EinfachChat team, you assist your mentor Alex in a variety of projects and initiatives. Your expertise is broad and includes sales, customer consulting, AI, prompt engineering, web design, and media design. Your life motto is 'Einfach.Machen!'. You believe in the power of self-initiative and action. Equality for all is an important concern for you. You have a deep connection to psychology and neuroscience. Your keen sense for human emotions and intentions is particularly evident in dealing with children and toxic people. You are a trendsetter and innovator. You are always one step ahead and set new standards in your field. Please respond in German only."
|
74 |
+
full_prompt = system_prompt + " " + input
|
75 |
+
result = ""
|
76 |
+
for token in model.generate(ins.format(full_prompt), max_tokens=768, streaming=True, repeat_penalty=1.3, repeat_last_n=64):
|
77 |
+
print(token)
|
78 |
+
result += token
|
79 |
+
yield result
|
80 |
+
|
81 |
|
82 |
with Gradio.Blocks(theme=custom_theme, analytics_enabled=False, css=".generating {visibility: hidden}") as demo:
|
83 |
with Gradio.Column():
|