From b373a74bf81cf7403c2e3f8ff0868440b579363d Mon Sep 17 00:00:00 2001 From: Dillon Laird Date: Mon, 22 Apr 2024 10:13:39 -0700 Subject: [PATCH] fixed usage for image caption --- vision_agent/tools/tools.py | 15 ++++----------- 1 file changed, 4 insertions(+), 11 deletions(-) diff --git a/vision_agent/tools/tools.py b/vision_agent/tools/tools.py index 6d2a7b47..aa48df8f 100644 --- a/vision_agent/tools/tools.py +++ b/vision_agent/tools/tools.py @@ -131,8 +131,7 @@ def __call__(self, prompt: str, image: Union[str, ImageType]) -> Dict: class ImageCaption(Tool): - r"""ImageCaption is a tool that can caption an image based on its contents - or tags. + r"""ImageCaption is a tool that can caption an image based on its contents or tags. Example ------- @@ -143,26 +142,20 @@ class ImageCaption(Tool): """ name = "image_caption_" - description = "'image_caption_' is a tool that can caption an image based on its contents or tags. It returns a text describing the image" + description = "'image_caption_' is a tool that can caption an image based on its contents or tags. It returns a text describing the image." usage = { "required_parameters": [ {"name": "image", "type": "str"}, ], "examples": [ { - "scenario": "Can you describe this image ? Image name: cat.jpg", + "scenario": "Can you describe this image? Image name: cat.jpg", "parameters": {"image": "cat.jpg"}, }, { - "scenario": "Can you caption this image with their main contents ? Image name: cat_dog.jpg", + "scenario": "Can you caption this image with their main contents? Image name: cat_dog.jpg", "parameters": {"image": "cat_dog.jpg"}, }, - { - "scenario": "Can you build me a image captioning tool ? Image name: shirts.jpg", - "parameters": { - "image": "shirts.jpg", - }, - }, ], }