Spaces:
Sleeping
Sleeping
Update main.py
Browse files
main.py
CHANGED
@@ -598,9 +598,8 @@ async def gemini_pro(item: GeminiPro):
|
|
598 |
|
599 |
BingImages = BingClient()
|
600 |
|
601 |
-
@asyncioPoliciesFix
|
602 |
@app.post("/Bing/Dall-E-3")
|
603 |
-
|
604 |
try:
|
605 |
set_cookies(
|
606 |
".bing.com",
|
@@ -612,7 +611,7 @@ async def bing_dalle(item: BingDalle):
|
|
612 |
raise HTTPException(status_code=500, detail="Invalid cookie string, check your cookie string and try again")
|
613 |
|
614 |
try:
|
615 |
-
response =
|
616 |
paths = []
|
617 |
base64_images = []
|
618 |
|
|
|
598 |
|
599 |
BingImages = BingClient()
|
600 |
|
|
|
601 |
@app.post("/Bing/Dall-E-3")
|
602 |
+
def bing_dalle(item: BingDalle):
|
603 |
try:
|
604 |
set_cookies(
|
605 |
".bing.com",
|
|
|
611 |
raise HTTPException(status_code=500, detail="Invalid cookie string, check your cookie string and try again")
|
612 |
|
613 |
try:
|
614 |
+
response = BingImages.images.generate(prompt=item.prompt, model="dall-e-3")
|
615 |
paths = []
|
616 |
base64_images = []
|
617 |
|