sugiv commited on
Commit
ca08394
·
1 Parent(s): 30fc77d

Debugging shit

Browse files
Files changed (1) hide show
  1. app.py +2 -1
app.py CHANGED
@@ -148,7 +148,7 @@ Here's the complete Python function implementation:
148
  formatted_code = extract_and_format_code(generated_text)
149
  logger.info(f"Formatted code: {formatted_code}")
150
  logger.info(f"Formatted code length: {len(formatted_code)}")
151
- yield formatted_code
152
 
153
  def random_problem(token: str) -> Dict[str, Any]:
154
  if not verify_token(token):
@@ -173,6 +173,7 @@ generate_interface = gr.Interface(
173
 
174
  stream_interface = gr.Interface(
175
  fn=stream_solution,
 
176
  inputs=[gr.Textbox(label="Problem Instruction"), gr.Textbox(label="JWT Token")],
177
  outputs=gr.JSON(),
178
  title="Stream Solution API",
 
148
  formatted_code = extract_and_format_code(generated_text)
149
  logger.info(f"Formatted code: {formatted_code}")
150
  logger.info(f"Formatted code length: {len(formatted_code)}")
151
+ yield {"response": formatted_code}
152
 
153
  def random_problem(token: str) -> Dict[str, Any]:
154
  if not verify_token(token):
 
173
 
174
  stream_interface = gr.Interface(
175
  fn=stream_solution,
176
+ Probblem_Instruction = gr.Textbox(label="Problem Instruction")
177
  inputs=[gr.Textbox(label="Problem Instruction"), gr.Textbox(label="JWT Token")],
178
  outputs=gr.JSON(),
179
  title="Stream Solution API",