This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module ScaleHelper | |
def create_annotation_task(callback_url, objects_to_annotate, attachment) | |
@@connection.post '/v1/task/annotation', { | |
:callback_url => callback_url, | |
:objects_to_annotate => objects_to_annotate, | |
:attachment => attachment, | |
:attachment_type => "image", | |
:instruction => "Annotate the specified objects", | |
:urgency => "immediate" | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
curl "https://api.scaleapi.com/v1/task/annotation" \ | |
-u YOUR_SCALE_API_KEY: \ | |
-d callback_url="http://www.example.com/callback" \ | |
-d instruction="Draw a box around each baby cow and adult cow." \ | |
-d attachment_type=image \ | |
-d attachment="http://i.imgur.com/v4cBreD.jpg" \ | |
-d objects_to_annotate="baby cow" \ | |
-d objects_to_annotate="adult cow" \ | |
-d with_labels=true |
NewerOlder