markrodrigo commited on
Commit
ea6174b
·
1 Parent(s): 81c2d8b

finish this

Browse files
Files changed (1) hide show
  1. app.py +4 -3
app.py CHANGED
@@ -67,6 +67,10 @@ custom_css = """
67
  """
68
  global_counter = 0
69
 
 
 
 
 
70
  @spaces.GPU
71
  def respond(user_message, chat_history): # , counter):
72
 
@@ -146,9 +150,6 @@ with gr.Blocks(title="Text to PostGIS Postgresql via Llama 3.2") as demo:
146
  # CRITICAL: This triggers every time the page loads or refreshes!
147
  demo.load(fn=get_latest_counter, inputs=[], outputs=counter_display)
148
 
149
- def get_latest_counter():
150
- global global_counter
151
- return global_counter # Dynamically fetches the current server value
152
 
153
  if __name__ == "__main__":
154
  print("Gradio version:", gr.__version__)
 
67
  """
68
  global_counter = 0
69
 
70
+ def get_latest_counter():
71
+ global global_counter
72
+ return global_counter # Dynamically fetches the current server value
73
+
74
  @spaces.GPU
75
  def respond(user_message, chat_history): # , counter):
76
 
 
150
  # CRITICAL: This triggers every time the page loads or refreshes!
151
  demo.load(fn=get_latest_counter, inputs=[], outputs=counter_display)
152
 
 
 
 
153
 
154
  if __name__ == "__main__":
155
  print("Gradio version:", gr.__version__)