Commit Graph

18 Commits

Author SHA1 Message Date
Kyle Corbitt
a5378b106b store model and use to calculate completion costs 2023-07-14 11:06:07 -07:00
Kyle Corbitt
4770ea34a8 Use javascript functions for prompt completions instead of templated json 2023-07-13 18:01:07 -07:00
Kyle Corbitt
a8db6cadfd format with prettier 3 2023-07-08 22:12:47 -07:00
Kyle Corbitt
46344d8fc4 small bugfixes 2023-07-07 12:22:27 -07:00
arcticfly
a2c7ef73ec Retry requests that receive 429 (#15)
* List number of scenarios

* Retry requests after 429

* Rename requestCallback

* Add sleep function

* Allow manual retry on frontend

* Remove unused utility functions

* Auto refetch

* Display wait time with Math.ceil

* Take one second modulo into account

* Add pluralize
2023-07-06 21:39:23 -07:00
arcticfly
fe501a80cb Add total token cost to variant stats (#13)
* Add total token cost to variant stats

* Copy over token counts for new variants

* Update invalidate call
2023-07-06 15:33:49 -07:00
Kyle Corbitt
1fa0d7bc62 bugfixes 2023-07-06 15:22:35 -07:00
Kyle Corbitt
f728027ef6 add evaluations 2023-07-06 13:44:03 -07:00
arcticfly
1ae5612d55 Add promptTokens and completionTokens to model output (#11)
* Default to streaming in config

* Add tokens to database

* Add NEXT_PUBLIC_SOCKET_URL to .env.example

* Disable streaming for functions

* Add newline to types
2023-07-06 13:12:59 -07:00
David Corbitt
d434545fdf Rename channelId to channel 2023-07-03 20:22:38 -07:00
David Corbitt
5f11b258ca Streaming works for normal text 2023-07-03 19:51:34 -07:00
arcticfly
6389bd54de Save and display timeToComplete on model outputs (#6)
* Calculate and save timeToComplete on model outputs

* Add output stats to function call as well

* Record timeToComplete before parsing response json

* Add default value for timeToComplete
2023-06-30 21:29:28 -07:00
Kyle Corbitt
ab32995eb9 slightly better error handling 2023-06-27 10:48:09 -07:00
Kyle Corbitt
bca35c9eb2 tighter types and linting 2023-06-26 23:40:05 -07:00
Kyle Corbitt
dbc61b8672 attempt render deploy 2023-06-26 15:26:40 -07:00
Kyle Corbitt
ce783f6279 do some completion caching 2023-06-26 14:44:47 -07:00
Kyle Corbitt
ca78406ad1 saving prompt configs works 2023-06-23 12:18:09 -07:00
Kyle Corbitt
a31c112745 we're actually calling openai 2023-06-22 17:57:21 -07:00