Omnibus commited on
Commit
9e9992f
1 Parent(s): 8d5f956

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -2
app.py CHANGED
@@ -111,7 +111,8 @@ def comment_generate(prompt, history,post_check,full_conv, agent_name=agents[0],
111
  print("###############\nRUNNING QUESTION GENERATOR\n###############\n")
112
  seed = random.randint(1,1111111111111111)
113
  #agent=prompts.COMMENTER.format(focus=main_point[0])
114
- agent=prompts.COMMENTER.format(focus=history[0][0])
 
115
  system_prompt=agent
116
  temperature = float(temperature)
117
  if temperature < 1e-2:
@@ -127,7 +128,8 @@ def comment_generate(prompt, history,post_check,full_conv, agent_name=agents[0],
127
  seed=seed,
128
  )
129
  #history.append((prompt,""))
130
- formatted_prompt = format_prompt(f"{system_prompt}, {prompt}", history)
 
131
  client=client_z[0]
132
 
133
  stream = client.text_generation(formatted_prompt, **generate_kwargs, stream=True, details=True, return_full_text=False)
 
111
  print("###############\nRUNNING QUESTION GENERATOR\n###############\n")
112
  seed = random.randint(1,1111111111111111)
113
  #agent=prompts.COMMENTER.format(focus=main_point[0])
114
+ bp,_,_=history[0]
115
+ agent=prompts.COMMENTER.format(focus=bp)
116
  system_prompt=agent
117
  temperature = float(temperature)
118
  if temperature < 1e-2:
 
128
  seed=seed,
129
  )
130
  #history.append((prompt,""))
131
+ #formatted_prompt = format_prompt(f"{system_prompt}, {prompt}", history)
132
+ formatted_prompt = f"{system_prompt}, {prompt}"
133
  client=client_z[0]
134
 
135
  stream = client.text_generation(formatted_prompt, **generate_kwargs, stream=True, details=True, return_full_text=False)