umaiku commited on
Commit
e061cc2
·
verified ·
1 Parent(s): 309b510

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -7
app.py CHANGED
@@ -50,12 +50,10 @@ def respond(
50
  context += "Case chunk: " + doc.page_content + "\n"
51
 
52
  message = f"""
53
- The user is asking for information about the following: {message}.
54
- Answer him in his own language using the information from the following Swiss federal jurisprudence cases:
55
- {context}
56
- Please mention your sources in your answer.
57
- If you don't know just mention the sources.
58
-
59
  """
60
 
61
  print(message)
@@ -90,7 +88,7 @@ demo = gr.ChatInterface(
90
  respond,
91
  additional_inputs=[
92
  gr.Textbox(value="You are an assistant in Swiss Jurisprudence cases.", label="System message"),
93
- gr.Slider(minimum=1, maximum=24000, value=512, step=1, label="Max new tokens"),
94
  gr.Slider(minimum=0.1, maximum=4.0, value=0.7, step=0.1, label="Temperature"),
95
  gr.Slider(
96
  minimum=0.1,
 
50
  context += "Case chunk: " + doc.page_content + "\n"
51
 
52
  message = f"""
53
+ The user is asking for information about the following: {message}.
54
+ Answer him in his own language using the information from the following Swiss federal jurisprudence cases:
55
+ {context}
56
+ Please mention your sources in your answer, including the urls
 
 
57
  """
58
 
59
  print(message)
 
88
  respond,
89
  additional_inputs=[
90
  gr.Textbox(value="You are an assistant in Swiss Jurisprudence cases.", label="System message"),
91
+ gr.Slider(minimum=1, maximum=24000, value=8000, step=1, label="Max new tokens"),
92
  gr.Slider(minimum=0.1, maximum=4.0, value=0.7, step=0.1, label="Temperature"),
93
  gr.Slider(
94
  minimum=0.1,