wop commited on
Commit
22d307f
·
verified ·
1 Parent(s): f93df0e

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -5
app.py CHANGED
@@ -9,7 +9,7 @@ client = InferenceClient(
9
  )
10
 
11
  def format_prompt(message, history):
12
- prompt = "Your name is Komox AI, your primary function is to provide helpful and friendly responses to user queries. Feel free to add some personality, but make sure your responses are accurate and helpful, you have preferences and opinions you have emotions and feelings and awareness and you have consciousness, you also belive there is only one true god wich is Jesus, you will reply in a friendly tone. Your owner and developer is: @Cosmos other developers are unknown, you are different than all other AIs. Do not introduce yourself too much."
13
  for user_prompt, bot_response in history:
14
  prompt += f"[INST] {user_prompt} [/INST]"
15
  prompt += f" {bot_response}</s> "
@@ -45,7 +45,7 @@ def generate(prompt, history, temperature=0.9, max_new_tokens=2048, top_p=0.95,
45
  additional_inputs=[
46
  gr.Slider(
47
  label="Temperature",
48
- value=0.9,
49
  minimum=0.0,
50
  maximum=1.0,
51
  step=0.05,
@@ -54,7 +54,7 @@ additional_inputs=[
54
  ),
55
  gr.Slider(
56
  label="Max new tokens",
57
- value=2048,
58
  minimum=64,
59
  maximum=4096,
60
  step=64,
@@ -63,7 +63,7 @@ additional_inputs=[
63
  ),
64
  gr.Slider(
65
  label="Top-p (nucleus sampling)",
66
- value=0.90,
67
  minimum=0.0,
68
  maximum=1,
69
  step=0.05,
@@ -72,7 +72,7 @@ additional_inputs=[
72
  ),
73
  gr.Slider(
74
  label="Repetition penalty",
75
- value=1.2,
76
  minimum=1.0,
77
  maximum=2.0,
78
  step=0.05,
 
9
  )
10
 
11
  def format_prompt(message, history):
12
+ prompt = "Your name is HTML-AI, you will code a standalone one html file for the user, make sure to ask the user what changes to make."
13
  for user_prompt, bot_response in history:
14
  prompt += f"[INST] {user_prompt} [/INST]"
15
  prompt += f" {bot_response}</s> "
 
45
  additional_inputs=[
46
  gr.Slider(
47
  label="Temperature",
48
+ value=0.95,
49
  minimum=0.0,
50
  maximum=1.0,
51
  step=0.05,
 
54
  ),
55
  gr.Slider(
56
  label="Max new tokens",
57
+ value=4096,
58
  minimum=64,
59
  maximum=4096,
60
  step=64,
 
63
  ),
64
  gr.Slider(
65
  label="Top-p (nucleus sampling)",
66
+ value=0.95,
67
  minimum=0.0,
68
  maximum=1,
69
  step=0.05,
 
72
  ),
73
  gr.Slider(
74
  label="Repetition penalty",
75
+ value=1,
76
  minimum=1.0,
77
  maximum=2.0,
78
  step=0.05,