Spaces:
Running
Running
V2 last but not least
Browse files- README.md +1 -1
- router.py +3 -3
- searcher.py.gpg +0 -0
README.md
CHANGED
|
@@ -8,4 +8,4 @@ pinned: false
|
|
| 8 |
short_description: '--'
|
| 9 |
---
|
| 10 |
|
| 11 |
-
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
|
|
|
|
| 8 |
short_description: '--'
|
| 9 |
---
|
| 10 |
|
| 11 |
+
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
|
router.py
CHANGED
|
@@ -28,10 +28,10 @@ class InputData(BaseModel):
|
|
| 28 |
async def run_script(input_Data: InputData, token: str = Header(None, alias="api-token")):
|
| 29 |
try:
|
| 30 |
if token:
|
| 31 |
-
if input_Data.data:
|
| 32 |
-
res = user_Agent.get_Search_Results(input_Data
|
| 33 |
if res:
|
| 34 |
-
return {"status": 200, "data": res}
|
| 35 |
else:
|
| 36 |
raise HTTPException(status_code=500, detail="The request can not be fulfilled")
|
| 37 |
else:
|
|
|
|
| 28 |
async def run_script(input_Data: InputData, token: str = Header(None, alias="api-token")):
|
| 29 |
try:
|
| 30 |
if token:
|
| 31 |
+
if input_Data := input_Data.data:
|
| 32 |
+
res = user_Agent.get_Search_Results(input_Data, token)
|
| 33 |
if res:
|
| 34 |
+
return {"status": 200, "user_ID": input_Data.user_ID, "data": res}
|
| 35 |
else:
|
| 36 |
raise HTTPException(status_code=500, detail="The request can not be fulfilled")
|
| 37 |
else:
|
searcher.py.gpg
CHANGED
|
Binary files a/searcher.py.gpg and b/searcher.py.gpg differ
|
|
|