{"info":{"title":"meta/sam2/auto-segment","version":"1.0.0"},"paths":{"/":{"post":{"summary":"Segment Anything 2 (Auto-Segment)","responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Output"}}},"description":"Successful Response"}},"operationId":"sam2_auto_segment","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Input"}}},"required":true}}},"/health-check":{"get":{"summary":"Healthcheck","responses":{"200":{"content":{"application/json":{"schema":{"title":"Response Healthcheck Health Check Get"}}},"description":"Successful Response"}},"operationId":"healthcheck_health_check_get"}}},"openapi":"3.1.0","components":{"schemas":{"Input":{"type":"object","title":"Input","required":["image_url"],"properties":{"image_url":{"type":"string","title":"Image URL","format":"uri","x-order":0,"description":"URL of the image to be automatically segmented."},"output_format":{"allOf":[{"$ref":"#/components/schemas/OutputFormatEnum"}],"title":"Output Format","default":"png","x-order":1,"description":"Format of the returned mask image."},"points_per_side":{"type":"integer","title":"Points Per Side","default":32,"x-order":2,"description":"Number of points sampled along each side of the image grid. Higher values produce more, finer masks but run slower."},"pred_iou_thresh":{"type":"number","title":"Pred IoU Thresh","default":0.88,"x-order":3,"description":"Predicted IoU quality threshold; masks below this confidence are discarded. Raise for fewer, cleaner masks."},"min_mask_region_area":{"type":"integer","title":"Min Mask Region Area","default":100,"x-order":5,"description":"Minimum mask region area in pixels; smaller disconnected regions are removed."},"stability_score_thresh":{"type":"number","title":"Stability Score Thresh","default":0.95,"x-order":4,"description":"Stability score threshold for filtering masks. Raise for fewer, more stable masks."}},"x-fal-order-properties":["image_url","output_format","points_per_side","pred_iou_thresh","stability_score_thresh","min_mask_region_area"]},"Output":{"type":"string","title":"Output","format":"uri","description":"URL of the combined segmentation mask image."},"OutputFormatEnum":{"enum":["jpeg","png"],"type":"string","title":"OutputFormatEnum"}}}}