diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 20fac644..cb069eff 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -33,28 +33,7 @@ that you should be abloe to create a pull request for the main repository. ## Adding Toolbox Functions -Are you missing a function in the toolbox? It's easy to implement it yourself! - -It's even possible without a GPU, clone this repo and install it like this: - -``` -SETUP_PACKAGE=refact_scratchpads_no_gpu pip install -e refact/ -``` - -In this folder `refact_scratchpads_no_gpu/gpt_toolbox/toolbox_functions` there are some -functions implemented using OpenAI API. There you can add a new one by analogy, or even -make an existing function better. - -Add your new function to `infserver_no_gpu.py` and `modelcap_records.py`. - -To test your function, run `infserver_no_gpu` as in the previous section. - - -## Simplifying Toolbox (WORK IN PROGRESS) - -1. Toolbox for models with GPU https://github.com/smallcloudai/refact/pull/33 - -2. Simplify functions list, so you don't have to touch `infserver_no_gpu.py` and `modelcap_records` (no PR yet) +UPDATE: toolbox is under reconstruction. ## Install Linguist diff --git a/refact_scratchpads_no_gpu/stream_results.py b/refact_scratchpads_no_gpu/stream_results.py index 0d1d9b4f..87cd827e 100644 --- a/refact_scratchpads_no_gpu/stream_results.py +++ b/refact_scratchpads_no_gpu/stream_results.py @@ -142,13 +142,9 @@ def test_head_and_tail(): class UploadProxy: def __init__( self, - upload_q: Optional[multiprocessing.Queue], - cancelled_q: Optional[multiprocessing.Queue], + upload_q: Optional[multiprocessing.Queue] = None, + cancelled_q: Optional[multiprocessing.Queue] = None, ): - try: - multiprocessing.set_start_method("spawn") - except: # it could be already set - pass self.upload_q = upload_q or multiprocessing.Queue() self.cancelled_q = cancelled_q or multiprocessing.Queue() self.proc = None @@ -161,6 +157,7 @@ def start_upload_result_daemon(self): target=_upload_results_loop, args=(self.upload_q, self.cancelled_q), name="upload_results", + daemon=True ) self.proc.start() return self.proc