Commit Graph

9 Commits

Author SHA1 Message Date
quzard
1b8feae0b6 Do not return when not present (#294) 2023-05-02 21:41:21 +04:00
Liu Shuang
d6ab1b3a4f fix: chat stream resp error (#259) 2023-04-19 13:05:00 +01:00
harry
2f3700f4c5 to fix v1.5.8 Usage return (#223)
* add ChatCompletionStream Usage return

* ChatCompletionStreamResponse will bot return Usage

* remove the Usage field from the response, it would not be there anyway.

---------

Co-authored-by: lihang <nasa.li@deepres.com>
2023-04-04 16:10:54 +04:00
harry
b542086cbb add ChatCompletionStream Usage return (#215)
Co-authored-by: lihang <nasa.li@deepres.com>
2023-04-01 20:06:22 +04:00
Jo
2ebb265e71 refactor: Refactor endpoint and model compatibility check (#180)
* Add model check for chat stream

* Sync model checks

* Fix typo

* Fix functino

* refactor: Refactor endpoint and model compatibility check

* apply review suggestions

* minor fix

* invert return boolean flag

* fix test
2023-03-22 17:46:08 +04:00
Liu Shuang
a5a945ad14 fix: stream return EOF when openai return error (#184)
* fix: stream return EOF when openai return error

* perf: add error accumulator

* fix: golangci-lint

* fix: unmarshal error possibly null

* fix: error accumulator

* test: error accumulator use interface and add test code

* test: error accumulator add test code

* refactor: use stream reader to re-use stream code

* refactor: stream reader use generics
2023-03-22 09:32:47 +04:00
sashabaranov
a8acb5f63b Add tests (#171)
* test models listing

* remove non-needed method

* test for .streamFinished

* add more error tests

* improve stream testing

* fix typo
2023-03-16 19:10:27 +04:00
Alexander Baranov
9eea94730a rename internally 2023-03-04 15:29:42 +04:00
Afeyer
39ca4e9488 Implement chat completion streaming (#101)
* Implement chat completion streaming

* Optimize the implementation of chat completion stream

* Fix linter error
2023-03-03 09:52:02 +04:00