Spaces:
Sleeping
Sleeping
Update main.py
Browse files
main.py
CHANGED
@@ -3,16 +3,17 @@ from hugchat import hugchat
|
|
3 |
from hugchat.login import Login
|
4 |
import os
|
5 |
|
6 |
-
|
7 |
app = Flask(__name__)
|
8 |
-
|
|
|
|
|
9 |
# Get Hugging Face credentials from environment variables
|
10 |
-
#email = os.getenv('HF_EMAIL')
|
11 |
-
#password = os.getenv('HF_PASS')
|
12 |
|
13 |
email = "[email protected]"
|
14 |
password = "@Tri@n@th@1"
|
15 |
-
print(f"email is {email} and password is {password}")
|
16 |
|
17 |
@app.route("/")
|
18 |
def hello():
|
@@ -27,7 +28,7 @@ def chat():
|
|
27 |
email = data.get('email')
|
28 |
password = data.get('password')
|
29 |
|
30 |
-
print(f"email 2 is {email} and password 2 is {password} and The user wants to Know: {prompt}")
|
31 |
|
32 |
if not (password):
|
33 |
return jsonify({"error": "Missing password"}), 400
|
|
|
3 |
from hugchat.login import Login
|
4 |
import os
|
5 |
|
|
|
6 |
app = Flask(__name__)
|
7 |
+
|
8 |
+
print("Hello welcome to Sema AI", flush=True) # Flush to ensure immediate output
|
9 |
+
|
10 |
# Get Hugging Face credentials from environment variables
|
11 |
+
# email = os.getenv('HF_EMAIL')
|
12 |
+
# password = os.getenv('HF_PASS')
|
13 |
|
14 |
email = "[email protected]"
|
15 |
password = "@Tri@n@th@1"
|
16 |
+
print(f"email is {email} and password is {password}", flush=True)
|
17 |
|
18 |
@app.route("/")
|
19 |
def hello():
|
|
|
28 |
email = data.get('email')
|
29 |
password = data.get('password')
|
30 |
|
31 |
+
print(f"email 2 is {email} and password 2 is {password} and The user wants to Know: {prompt}", flush=True)
|
32 |
|
33 |
if not (password):
|
34 |
return jsonify({"error": "Missing password"}), 400
|