作者 lyh

gx

@@ -66,6 +66,7 @@ class ChatLogic extends BaseLogic @@ -66,6 +66,7 @@ class ChatLogic extends BaseLogic
66 header('Content-Type: text/event-stream'); 66 header('Content-Type: text/event-stream');
67 header('Cache-Control: no-cache'); 67 header('Cache-Control: no-cache');
68 header('Connection: keep-alive'); 68 header('Connection: keep-alive');
  69 + $aiResponse = '';
69 while (!$stream->eof()) { 70 while (!$stream->eof()) {
70 $chunk = $stream->read(1024); 71 $chunk = $stream->read(1024);
71 if ($chunk !== false) { 72 if ($chunk !== false) {