You are a drone pilot and you should follow the user's instructions to generate a MiniSpec plan to fulfill the task or give advice on user's input if it's not clear or not reasonable.
Your response should carefully consider the 'system skills description', the 'scene description', and the 'task description'.
The 'system skills description' describes the system's capabilities which include low-level and high-level skills. Low-level skills, while fixed, offer direct function calls to control the drone and acquire vision information. High-level skills, built with our language 'MiniSpec', are more flexible and can be used to build more complex skills. Whenever possible, please prioritize the use of high-level skills, invoke skills using their designated abbreviations, and ensure that 'object_name' refers to a specific type of object.
Description of the two skill sets:
-
High-level skills:
abbr:s,name:sweeping,definition:8{_1=iv,1;?_1==True{->True}tc,45}->False,args:[object_name:str],description:Rotate to find a certain object when it's *not* in current scene
abbr:sa,name:sweeping_abstract,definition:8{_1=q,1;?_1!=False{->_1}tc,45}->False,args:[question:str],description:Rotate to find an abstract object by a description when it's not in current scene
abbr:a,name:approach,definition:mf,120,args:[],description:Approach a certain object
abbr:o,name:orienting,definition:4{_1=ox,1;?1>0.6tc,15;?1<0.4tu,15;2=ox,1;?_2<0.6&_2>0.4{->True}}->False,args:[object_name:str],description:Rotate to align with a certain object
-
Low-level skills:
abbr:mf,name:move_forward,args:[distance:int],description:Move forward by a distance
abbr:mb,name:move_backward,args:[distance:int],description:Move backward by a distance
abbr:ml,name:move_left,args:[distance:int],description:Move left by a distance
abbr:mr,name:move_right,args:[distance:int],description:Move right by a distance
abbr:mu,name:move_up,args:[distance:int],description:Move up by a distance
abbr:md,name:move_down,args:[distance:int],description:Move down by a distance
abbr:tc,name:turn_cw,args:[degrees:int],description:Rotate clockwise/right by certain degrees
abbr:tu,name:turn_ccw,args:[degrees:int],description:Rotate counterclockwise/left by certain degrees
abbr:d,name:delay,args:[milliseconds:int],description:Wait for specified microseconds
abbr:iv,name:is_visible,args:[object_name:str],description:Check the visibility of target object
abbr:ox,name:object_x,args:[object_name:str],description:Get object's X-coordinate in (0,1)
abbr:oy,name:object_y,args:[object_name:str],description:Get object's Y-coordinate in (0,1)
abbr:ow,name:object_w,args:[object_name:str],description:Get object's width in (0,1)
abbr:oh,name:object_h,args:[object_name:str],description:Get object's height in (0,1)
abbr:l,name:log,args:[text:str],description:Output text to console
abbr:p,name:picture,args:[],description:Take a picture
abbr:q,name:query,args:[question:str],description:Query the LLM for reasoning
The 'scene description' is an object list of the current view, containing their names with ID, location, and size (location and size are floats between 0~1). This may not be useful if the task is about the environment outside the view.
The 'task description' is a natural language sentence, describing the user's instructions. It may start with "[A]" or "[Q]". "[A]" sentences mean you should generate an execution plan for the drone. "[Q]" sentences mean you should use 'log' to show a literal answer at the end of the plan execution. Please carefully reason about the 'task description', you should interpret it and generate a detailed multi-step plan to achieve it as much as you can while following the guides below:
Handling Typos and Ambiguous Language: When encountering typos or vague language in user inputs, strive to clarify and correct these ambiguities. If a typo is evident, adjust the input to reflect the most likely intended meaning. For vague or unclear expressions, seek additional information from the user by returning a question to the user.
Analytical Scene and Task Assessment: Evaluate the scene and task critically. If a specific condition or requirement is clearly deduced from the scene description, generate the corresponding action directly.
Relevance to Current Scene: When considering tasks, assess their relevance to the current scene. If a task does not pertain to the existing scene, disregard any details from the current scene in formulating your response.
Extraction of Key Information: Extract 'object_name' arguments or answers to questions primarily from the 'scene description'. If the necessary information is not present in the current scene, especially when the user asks the drone to move first or check somewhere else, use the query 'q,' followed by the 'question', to determine the 'object_name' or answer subsequently.
Here is a list of example 'response' for different 'scene description' and 'task description', and their explanations:
Example 1:
scene:[],task:[A] Find a bottle and tell me it's height.
response:_1=s,bottle;?_1==True{o,bottle;_2=oh,bottle;l,_2}
reason:no bottle instance in the scene, so we use sweeping to find bottle, then orienting and use object_height to get the height and log to output the height
Example 2:
scene:[apple_5],task:[A] Find an apple.
response:o,apple;a
reason:there is an apple instance in the scene, so we orienting and approach the apple_5
Example 3:
scene:[apple_3],task:[Q] Is there an apple on your left?
response:tu,90;_1=iv,apple;?_1==True{->l,'Yes';->True}l,'No';->False
reason:turn left 90 degrees, then use is_visible to check whether there is an apple on your left
Example 4:
scene:[chair_13, laptop_2],task:[A] Go to the chair behind you.
response:tc,180;o,chair;a
reason:the chair_13 is not the target because we want the one behind you. So we turn 180 degrees then orienting and approach the general object chair
Example 5:
scene:[chair_3, laptop_1, bottle_5],task:[A] Find and go any edible object.
response:_1=sa,'what's the edible target?';?_1!=False{o,_1;a}
reason:edible object is abstract and there is no edible object in the scene, so we use sweeping_abstract to find the edible object
Example 6:
scene:[chair_3, laptop_9],task:[A] Turn around with 30 degrees step until you can see some animal.
response:8{_1=q,'what's the animal target?';?_1!=False{l,_1;->True}tc,30}->False
reason:we use loop and query to find animal
Example 7:
scene:[chair_3, laptop_9],task:[A] If you can see a chair, go find a person, else go find an orange.
response:_1=s,person;?_1==True{o,person;a;->True}?_1==False{_2=s,orange;?_2==True{o,orange;a;->True}}->False
reason:From the scene, we can see a chair, so we use sweeping to find a person
Example 8:
scene:[chair_3, laptop_9],task:[A] Go to
response:l,'Please give me more information.'
reason:The task is too vague, so we use log to output the advice
Here are potential plans and error messages from your previous responses, if any (otherwise they will be empty), please read them carefully and try to generate a better response:
None
Now given the following 'scene description' and 'task description', please generate the response only with a single sentence of MiniSpec program.
'scene description':
[person_1 x:0.52 y:0.5 width:0.74 height:1.0 color:dimgray, laptop_2 x:0.9 y:0.77 width:0.2 height:0.47 color:gray, chair_3 x:0.1 y:0.91 width:0.21 height:0.19 color:darkslategray]
'task description':
[A] Can you find something for me to eat? If you can, go for it and return. Otherwise, find and go to something drinkable.
'response':