As shown in the figure above, we need to build an API cloud to main all tools.
Build a controller like the guides in readme.
Our tool workers and llm-model workers share the same controller.
We provide all model workers in the serve/
folder. The tool worker is named as {tool_name}_worker.py
. To run a worker, make sure you have installed the required tool(or copy the worker file to different tool folders).
An example for the Grounded-SAM, whch includes Grounding-DINO, SAM, and Grounded-SAM.
git clone https://github.com/IDEA-Research/Grounded-Segment-Anything
python -m pip install -e GroundingDINO
python -m pip install -e segment_anything
python serve/grounding_dino_worker.py
Wait until the process finishes loading the model and you see "Uvicorn running on ...". You need to open another terminal process for other operations.
Test the worker:
python serve/grounding_dino_test_message.py