agent-as-policy-sim / documents /interfaces /interface-76b013ef.json
elsannaly's picture
RoboDojo seed 0 release
4166e5f
Raw History Blame Contribute Delete
12.6 kB
{
"server": "astra_control",
"instructions": "Each observe/step result starts with one compact JSON text block, followed by labelled top, left_wrist and right_wrist images. Never retry an uncertain action with a new action_id; use action_status.",
"tools": [
{
"name": "goal",
"description": "Return the task instruction.",
"inputSchema": {
"properties": {},
"title": "goalArguments",
"type": "object"
}
},
{
"name": "observe",
"description": "Current observation: compact state of both arms and top, left_wrist, right_wrist images. No physics advances.",
"inputSchema": {
"properties": {},
"title": "observeArguments",
"type": "object"
}
},
{
"name": "measure",
"description": "3D point at pixel (u,v) of one camera in the latest observation, expressed in the named arm's base frame (m). The images have no depth: with plane_z at the table (<= 0.005) the pixel ray is intersected with that horizontal plane; otherwise the height comes from matching the pixel in a second camera (top <-> that arm's wrist), returned as z_from match or uncertain with a review image, and a higher plane_z is only the fallback, used when the match is uncertain, missing or more than 0.02 m away from it (z_from fallback). on_robot marks a pixel inside a robot arm's outline. Returns measurement ids for step evidence. A query may give cands [[u,v],...] instead of u,v: all are measured and one is kept, the most reliable (pick solid: a plane or confident match before a fallback or uncertain one, off the robot) or the highest/lowest z (pick high|low), after dropping points outside zr [zmin,zmax]. label names the kept point for later run steps. A query may also be a string '[label:] L|R top|lw|rw u,v[/u,v...] [z=..] [pick=..] [zr=a,b] target text'. pose: true (string option `pose`, top camera only) also returns the footprint of the object at that pixel seen from above: xy centroid, axis_deg / tail_deg heading, edge_deg, length_mm, width_mm, status.",
"inputSchema": {
"$defs": {
"PosePointQuery": {
"additionalProperties": false,
"description": "A measure query at one pixel; pose: true (top camera only) also returns the footprint of the object seen from above.",
"properties": {
"arm": {
"enum": [
"left",
"right"
],
"title": "Arm",
"type": "string"
},
"cam": {
"enum": [
"top",
"left_wrist",
"right_wrist"
],
"title": "Cam",
"type": "string"
},
"u": {
"anyOf": [
{
"maximum": 639,
"minimum": 0,
"type": "integer"
},
{
"type": "null"
}
],
"default": null,
"title": "U"
},
"v": {
"anyOf": [
{
"maximum": 479,
"minimum": 0,
"type": "integer"
},
{
"type": "null"
}
],
"default": null,
"title": "V"
},
"target": {
"maxLength": 160,
"minLength": 1,
"title": "Target",
"type": "string"
},
"visibility": {
"anyOf": [
{
"maxLength": 200,
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Visibility"
},
"plane_z": {
"anyOf": [
{
"type": "number"
},
{
"type": "null"
}
],
"default": null,
"title": "Plane Z"
},
"height_basis": {
"anyOf": [
{
"maxLength": 200,
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Height Basis"
},
"cands": {
"anyOf": [
{
"items": {
"items": {
"type": "integer"
},
"maxItems": 2,
"minItems": 2,
"type": "array"
},
"maxItems": 8,
"minItems": 1,
"type": "array"
},
{
"type": "null"
}
],
"default": null,
"title": "Cands"
},
"pick": {
"anyOf": [
{
"enum": [
"solid",
"high",
"low"
],
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Pick"
},
"zr": {
"anyOf": [
{
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2,
"type": "array"
},
{
"type": "null"
}
],
"default": null,
"title": "Zr"
},
"label": {
"anyOf": [
{
"maxLength": 40,
"minLength": 1,
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Label"
},
"pose": {
"anyOf": [
{
"type": "boolean"
},
{
"type": "null"
}
],
"default": null,
"title": "Pose"
}
},
"required": [
"arm",
"cam",
"target"
],
"title": "PosePointQuery",
"type": "object"
}
},
"properties": {
"observation_id": {
"maxLength": 160,
"minLength": 1,
"title": "Observation Id",
"type": "string"
},
"queries": {
"items": {
"anyOf": [
{
"$ref": "#/$defs/PosePointQuery"
},
{
"type": "string"
}
]
},
"maxItems": 8,
"minItems": 1,
"title": "Queries",
"type": "array"
}
},
"required": [
"observation_id",
"queries"
],
"title": "measureArguments",
"type": "object"
}
},
{
"name": "step",
"description": "Execute one transaction for one or both arms on a shared clock; return compact outcome and fresh images. actions maps left/right to {command, args, intent, measurement_id?, evidence?}. Commands: move_ee(position{x,y,z} or position_offset + measurement_id, rotation{w,x,y,z}, mode plan|linear, speed_profile precision|transit), move_delta(dpos[3] m, optional drot_deg[3], speed_profile), move_joints(joints[6]), home, gripper(action open|close, or action width with width_mm: the pad gap in mm, 0.8 closed .. 88.8 fully open), hold(samples 1..25). Motion options: max_samples, settle_samples 0..10, position_tolerance_m, rotation_tolerance_rad.",
"inputSchema": {
"$defs": {
"ArmAction": {
"additionalProperties": false,
"properties": {
"command": {
"enum": [
"move_ee",
"move_delta",
"move_joints",
"home",
"gripper",
"hold"
],
"title": "Command",
"type": "string"
},
"args": {
"additionalProperties": true,
"title": "Args",
"type": "object"
},
"intent": {
"enum": [
"observe",
"grasp",
"transfer",
"contact",
"retreat",
"place",
"manipulate"
],
"title": "Intent",
"type": "string"
},
"measurement_id": {
"anyOf": [
{
"maxLength": 160,
"minLength": 1,
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Measurement Id"
},
"evidence": {
"anyOf": [
{
"additionalProperties": true,
"type": "object"
},
{
"type": "null"
}
],
"default": null,
"title": "Evidence"
}
},
"required": [
"command",
"args",
"intent"
],
"title": "ArmAction",
"type": "object"
}
},
"properties": {
"action_id": {
"maxLength": 160,
"minLength": 1,
"title": "Action Id",
"type": "string"
},
"observation_id": {
"maxLength": 160,
"minLength": 1,
"title": "Observation Id",
"type": "string"
},
"actions": {
"additionalProperties": {
"$ref": "#/$defs/ArmAction"
},
"maxProperties": 2,
"minProperties": 1,
"propertyNames": {
"enum": [
"left",
"right"
]
},
"title": "Actions",
"type": "object"
}
},
"required": [
"action_id",
"observation_id",
"actions"
],
"title": "stepArguments",
"type": "object"
}
},
{
"name": "run",
"description": "Execute up to 20 steps in order, server-side, stopping at the first surprise. Ids and observation threading are automatic; every action still passes the normal runtime checks. Step = {left?: arm, right?: arm, expect?: {arm: {gap_min_mm, gap_max_mm}}} or {measure: [queries], as: [labels]}. Arm = {do: ee|delta|open|close|home|hold|joints, intent?, to: [x,y,z] | {at: label_or_measurement_id, d: [dx,dy,dz]}, rot?: {w,x,y,z} | {down: deg} | {tilted: [az_deg, tilt_deg]} (default: keep current), mode?: linear|plan, speed?: precision|transit (default transit for observe/transfer/retreat intents), d: [dx,dy,dz] for delta, m?: measurement label or id, ev?: {...}, samples?}. show = {at: {\"<k>\": [labels]}, end: [labels], on_stop: [labels]}; evidence is shared by every arm action. A step may instead be a command string, e.g. 'L ee g+0,0,.05 down90 plan obs & R d 0,0,.03 retreat', 'B close gap>2', 'L open support=flat surface below', or a measure step '? g: L top 180,214 near object top'. show may be a string such as 'top lw 2:rw stop:top'. Retreat moves and home get a default clearance when none is given. do: width with width_mm (the pad gap in mm, 0.8 closed .. 88.8 fully open) moves the fingers to that gap, e.g. 'L width 30'. A measure query may add `pose` (e.g. '? t: L top 180,214 z=.015 pose object top') for the object's footprint.",
"inputSchema": {
"properties": {
"observation_id": {
"maxLength": 160,
"minLength": 1,
"title": "Observation Id",
"type": "string"
},
"steps": {
"items": {
"anyOf": [
{
"additionalProperties": true,
"type": "object"
},
{
"type": "string"
}
]
},
"maxItems": 20,
"minItems": 1,
"title": "Steps",
"type": "array"
},
"show": {
"anyOf": [
{
"additionalProperties": true,
"type": "object"
},
{
"items": {
"type": "string"
},
"type": "array"
},
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Show"
},
"evidence": {
"anyOf": [
{
"additionalProperties": true,
"type": "object"
},
{
"type": "null"
}
],
"default": null,
"title": "Evidence"
}
},
"required": [
"observation_id",
"steps"
],
"title": "runArguments",
"type": "object"
}
},
{
"name": "action_status",
"description": "Reconcile an existing action after an uncertain result. Never dispatches motion.",
"inputSchema": {
"properties": {
"action_id": {
"maxLength": 160,
"minLength": 1,
"title": "Action Id",
"type": "string"
}
},
"required": [
"action_id"
],
"title": "action_statusArguments",
"type": "object"
}
},
{
"name": "assess",
"description": "Record your final task judgement with evidence.summary. The benchmark evaluator decides independently.",
"inputSchema": {
"properties": {
"observation_id": {
"maxLength": 160,
"minLength": 1,
"title": "Observation Id",
"type": "string"
},
"outcome": {
"enum": [
"success",
"failure",
"unknown"
],
"title": "Outcome",
"type": "string"
},
"evidence": {
"additionalProperties": true,
"title": "Evidence",
"type": "object"
}
},
"required": [
"observation_id",
"outcome",
"evidence"
],
"title": "assessArguments",
"type": "object"
}
}
]
}