acecalisto3 commited on
Commit
f04f929
·
verified ·
1 Parent(s): 6661be0

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -2
app.py CHANGED
@@ -87,7 +87,7 @@ def respond(
87
  programming_language,
88
  *args,
89
  **kwargs,
90
- ) -> str:
91
  # Initialize the model
92
  model = pipeline("text-generation", model="enricoros/big-agi")
93
 
@@ -103,7 +103,11 @@ def respond(
103
  # Extract the assistant's response
104
  assistant_response = response[0]['generated_text'].strip()
105
 
106
- return assistant_response
 
 
 
 
107
  )
108
 
109
  with gr.Blocks() as demo:
 
87
  programming_language,
88
  *args,
89
  **kwargs,
90
+ ) -> dict:
91
  # Initialize the model
92
  model = pipeline("text-generation", model="enricoros/big-agi")
93
 
 
103
  # Extract the assistant's response
104
  assistant_response = response[0]['generated_text'].strip()
105
 
106
+ return {
107
+ 'assistant_response': assistant_response,
108
+ 'severity': severity,
109
+ 'programming_language': programming_language,
110
+ }
111
  )
112
 
113
  with gr.Blocks() as demo: