- Always stream the visible scenarios, if the modelProvider supports it
- Never stream the invisible scenarios
Also actually runs our query tasks in a background worker, which we weren't quite doing before.
* Add descriptions of fields in llama 2 input schema
* Let GPT-4 know when the provider stays the same
* Allow refetching in the event of any errors
* Define refinement actions in model providers
* Fix prettier
Storing the model on promptVariant is problematic because it isn't always in sync with the actual prompt definition. I'm removing it for now to see if we can get away with that -- might have to add it back in later if this causes trouble.
Added `cost` to modelOutput as well so we can cache that, which is important given that the cost calculations won't be the same between different API providers.
* Add dropdown header for model switching
* Allow variant duplication
* Fix prettier
* Use env variable to restrict prisma logs
* Fix env.mjs
* Remove unnecessary scroll bar from function call output
* Properly record when 404 error occurs in queryLLM task
* Add SelectedModelInfo in SelectModelModal
* Add react-select
* Calculate new prompt after switching model
* Send newly selected model with creation request
* Get new prompt construction function back from GPT-4
* Fix prettier
* Fix prettier
* Prevent zoom in on iOS
* Expand function return code background to fill cell
* Keep OutputStats on far right of cells
* Continue polling prompt stats while cells are retrieving from LLM
* Add comment to _document.tsx
* Fix prettier
* Rename tables, add graphile workers, update types
* Add dev:worker command
* Update pnpm-lock.yaml
* Remove sentry config import from worker.ts
* Stop generating new cells in cell router get query
* Generate new cells for new scenarios, variants, and experiments
* Remove most error throwing from queryLLM.task.ts
* Remove promptVariantId and testScenarioId from ModelOutput
* Remove duplicate index from ModelOutput
* Move inputHash from cell to output
* Add TODO
* Add todo
* Show cost and time for each cell
* Always show output stats if there is output
* Trigger LLM outputs when scenario variables are updated
* Add newlines to ends of files
* Add another newline
* Cascade ModelOutput deletion
* Fix linting and prettier
* Return instead of throwing for non-pending cell
* Remove pnpm dev:worker from pnpm:dev
* Update pnpm-lock.yaml
* 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