ParthSadaria commited on
Commit
0ebc28b
·
verified ·
1 Parent(s): f70d6d7

Update main.py

Browse files
Files changed (1) hide show
  1. main.py +3 -2
main.py CHANGED
@@ -251,7 +251,7 @@ async def generate_image(
251
  params['enhance'] = str(enhance).lower()
252
 
253
  try:
254
- timeout = httpx.Timeout(30.0) # Set a reasonable timeout
255
  async with httpx.AsyncClient(timeout=timeout) as client:
256
  response = await client.get(url, params=params, follow_redirects=True)
257
 
@@ -309,7 +309,8 @@ async def startup_event():
309
  print("GET /models")
310
  print("GET /searchgpt") # We now have the new search API
311
  print("POST /chat/completions")
312
-
 
313
  if __name__ == "__main__":
314
  import uvicorn
315
  uvicorn.run(app, host="0.0.0.0", port=8000)
 
251
  params['enhance'] = str(enhance).lower()
252
 
253
  try:
254
+ timeout = httpx.Timeout(60.0) # Set a reasonable timeout
255
  async with httpx.AsyncClient(timeout=timeout) as client:
256
  response = await client.get(url, params=params, follow_redirects=True)
257
 
 
309
  print("GET /models")
310
  print("GET /searchgpt") # We now have the new search API
311
  print("POST /chat/completions")
312
+ print("GET /images/generations")
313
+
314
  if __name__ == "__main__":
315
  import uvicorn
316
  uvicorn.run(app, host="0.0.0.0", port=8000)