File size: 1,229 Bytes
811ffe8 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 |
from .detection_model import run_detection
from .segmentation_model import run_segmentation
__all__ = ["run_detection", "run_segmentation"]
FUNCTION_SCHEMA = [
{
"type": "function",
"function": {
"name": "run_detection",
"description": "Detect objects in an image and return bounding boxes and labels.",
"parameters": {
"type": "object",
"properties": {
"image_path": {"type": "string", "description": "Local path to the image file."},
"is_visualize":{"type": "bool", "description": "If true draw bboxes and save next to image."}
},
"required": ["image_path"]
},
},
},
{
"type": "function",
"function": {
"name": "run_segmentation",
"description": "Segment objects in an image and return binary masks.",
"parameters": {
"type": "object",
"properties": {
"image_path": {"type": "string", "description": "Local path to the image file."}
},
"required": ["image_path"]
},
},
},
]
|