We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ad6f6a1 commit b97eb2bCopy full SHA for b97eb2b
server/routes.go
@@ -289,6 +289,12 @@ func (s *Server) GenerateHandler(c *gin.Context) {
289
return
290
}
291
292
+ contentType := "application/json; charset=utf-8"
293
+ if req.Stream != nil && *req.Stream {
294
+ contentType = "application/x-ndjson"
295
+ }
296
+ c.Header("Content-Type", contentType)
297
+
298
299
300
@@ -1932,6 +1938,12 @@ func (s *Server) ChatHandler(c *gin.Context) {
1932
1938
1933
1939
1934
1940
1941
1942
1943
1944
1945
1946
1935
1947
1936
1948
1937
1949
0 commit comments