Spaces:
Running
Running
Update gateway_client.py
Browse files- gateway_client.py +3 -7
gateway_client.py
CHANGED
|
@@ -1,12 +1,10 @@
|
|
| 1 |
import os
|
|
|
|
| 2 |
from datetime import datetime
|
| 3 |
|
| 4 |
-
import requests
|
| 5 |
|
| 6 |
-
# Backend server URL - can be set via environment variable
|
| 7 |
-
# For Hugging Face Spaces: Set MEMORY_SERVER_URL in Space settings (Repository secrets)
|
| 8 |
-
# For local development: Set MEMORY_SERVER_URL in your .env file
|
| 9 |
MEMMACHINE_PORT = os.getenv("MEMORY_SERVER_URL")
|
|
|
|
| 10 |
|
| 11 |
<CURRENT_DATE>
|
| 12 |
{current_date}
|
|
@@ -70,6 +68,4 @@ def delete_profile(user_id: str) -> bool:
|
|
| 70 |
"agent-id": "agent",
|
| 71 |
}
|
| 72 |
requests.delete(f"{MEMMACHINE_PORT}/v1/memories", headers=headers, json={})
|
| 73 |
-
return True
|
| 74 |
-
|
| 75 |
-
|
|
|
|
| 1 |
import os
|
| 2 |
+
import requests
|
| 3 |
from datetime import datetime
|
| 4 |
|
|
|
|
| 5 |
|
|
|
|
|
|
|
|
|
|
| 6 |
MEMMACHINE_PORT = os.getenv("MEMORY_SERVER_URL")
|
| 7 |
+
PROMPT = """You are a helpful AI assistant. Use the provided context and profile information to answer the user's question accurately and helpfully.
|
| 8 |
|
| 9 |
<CURRENT_DATE>
|
| 10 |
{current_date}
|
|
|
|
| 68 |
"agent-id": "agent",
|
| 69 |
}
|
| 70 |
requests.delete(f"{MEMMACHINE_PORT}/v1/memories", headers=headers, json={})
|
| 71 |
+
return True
|
|
|
|
|
|