From a399ba814c34a2b7ec465100fbfa37e5a6c8b5c9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Florian=20Ho=CC=88nicke?= Date: Wed, 12 Apr 2023 00:31:28 +0200 Subject: [PATCH] refactor: retries for flow deployment --- README.md | 31 ++++++++++++++++++++----------- src/gpt.py | 3 ++- 2 files changed, 22 insertions(+), 12 deletions(-) diff --git a/README.md b/README.md index dda11dc..9f962eb 100644 --- a/README.md +++ b/README.md @@ -352,6 +352,14 @@ gptdeploy create --description "Generate QR code from URL" --test "https://www.e [//]: # (```) +[//]: # (### Sound Visualizer) + +[//]: # () +[//]: # (```bash) + +[//]: # (gptdeploy create --description "Visualize a sound file and output the visualization as video combined with the sound" --test "some/mp3/file.mp3") + +[//]: # (```) [//]: # (## Upcoming Challenges) @@ -399,35 +407,36 @@ In the following, you can find a list of things that need to be done. Critical: - [ ] check if windows and linux support works - [ ] support gpt3.5-turbo +- [ ] add video to README.md +- [ ] bug: it can happen that the code generation is hanging forever - in this case aboard and redo the generation Nice to have: +- [ ] if the user runs gptdeploy without any arguments, show the help message +- [ ] don't show this message: +🔐 You are logged in to Jina AI as florian.hoenicke (username:auth0-unified-448f11965ce142b6). +To log out, use jina auth logout. +- [ ] rest endpoint instead of grpc since it is more popular +- [ ] put the playground into the custom gateway (without rebuilding the custom gateway) - [ ] hide prompts in normal mode and show them in verbose mode - [ ] tests - [ ] clean up duplicate code - [ ] support popular cloud providers - lambda, cloud run, cloud functions, ... - [ ] support local docker builds - [ ] autoscaling enabled for cost saving -- [ ] don't show this message: -🔐 You are logged in to Jina AI as florian.hoenicke (username:auth0-unified-448f11965ce142b6). -To log out, use jina auth logout. - [ ] add more examples to README.md - [ ] support multiple endpoints - example: todolist microservice with endpoints for adding, deleting, and listing todos - [ ] support stateful microservices - [ ] The playground is currently printed twice even if it did not change. Make sure it is only printed twice in case it changed. - [ ] allow to update your microservice by providing feedback -- [ ] bug: it can happen that the code generation is hanging forever - in this case aboard and redo the generation -- [ ] feat: make playground more stylish by adding attributes like: clean design, beautiful, like it was made by a professional designer, ... -- [ ] support for other large language models like ChatGLM +- [ ] support for other large language models like Open Assistent - [ ] for cost savings, it should be possible to insert less context during the code generation of the main functionality - no jina knowledge is required - [ ] use gptdeploy list to show all deployments - [ ] gptdeploy delete to delete a deployment - [ ] gptdeploy update to update a deployment -- [ ] if the user runs gptdeploy without any arguments, show the help message -- [ ] start streamlit playground automatically after the deployment -- [ ] test param optional -- [ ] rest endpoint instead of grpc since it is more popular +- [ ] test param optional - but how would you test the pdf extractor without a pdf? - [ ] section for microservices built by the community -- [ ] selenium test for playground \ No newline at end of file +- [ ] test feedback for playground generation (could be part of the debugging) +- [ ] should we send everything via json in the text attribute for simplicity? diff --git a/src/gpt.py b/src/gpt.py index 7af6da8..0c97074 100644 --- a/src/gpt.py +++ b/src/gpt.py @@ -38,9 +38,10 @@ class GPTSession: model="gpt-4", messages=[{ "role": 'system', - "content": 'test' + "content": 'you respond nothing' }] ) + break except RateLimitError: sleep(1) continue