Spaces:
Paused
Paused
Commit
·
3aa774f
1
Parent(s):
4671d1f
Updates Dockerfile
Browse files- static/index.html +2 -2
static/index.html
CHANGED
|
@@ -68,7 +68,7 @@
|
|
| 68 |
replyAudio.src = '';
|
| 69 |
|
| 70 |
try {
|
| 71 |
-
const res = await fetch('https://doublesizebed-chatbot.hf.space', {
|
| 72 |
method: 'POST',
|
| 73 |
headers: { 'Content-Type': 'application/json' },
|
| 74 |
body: JSON.stringify({ message: msg, gender })
|
|
@@ -77,7 +77,7 @@
|
|
| 77 |
|
| 78 |
if (res.ok) {
|
| 79 |
replyText.textContent = data.response;
|
| 80 |
-
replyAudio.src = data.
|
| 81 |
replyAudio.hidden = false;
|
| 82 |
} else {
|
| 83 |
replyText.textContent = 'Error: ' + (data.error || res.statusText);
|
|
|
|
| 68 |
replyAudio.src = '';
|
| 69 |
|
| 70 |
try {
|
| 71 |
+
const res = await fetch('https://doublesizebed-chatbot.hf.space/chat', {
|
| 72 |
method: 'POST',
|
| 73 |
headers: { 'Content-Type': 'application/json' },
|
| 74 |
body: JSON.stringify({ message: msg, gender })
|
|
|
|
| 77 |
|
| 78 |
if (res.ok) {
|
| 79 |
replyText.textContent = data.response;
|
| 80 |
+
replyAudio.src = data.audiofile;
|
| 81 |
replyAudio.hidden = false;
|
| 82 |
} else {
|
| 83 |
replyText.textContent = 'Error: ' + (data.error || res.statusText);
|