pub struct ComputerUseActionResponseDto {
pub actions: Vec<ComputerUseActionResponseDtoActionsItem>,
pub memory: Option<String>,
pub thoughts: Option<String>,
pub unknown: Option<String>,
}Expand description
ComputerUseActionResponseDto
JSON schema
{
"type": "object",
"required": [
"actions"
],
"properties": {
"actions": {
"type": "array",
"items": {
"description": "All possible computer use actions, with optional callId",
"type": "object",
"oneOf": [
{
"description": "Click the mouse at the specified coordinates",
"type": "object",
"required": [
"button",
"type",
"x",
"y"
],
"properties": {
"button": {
"description": "Mouse button flag combination. 1: left, 2: right, 4: middle, 8: back, 16: forward; add them together to press multiple buttons at once.",
"type": "number"
},
"holdKey": {
"description": "Key to hold down during click, in xdotool key syntax. Example: \"ctrl\", \"alt\", \"alt+shift\".",
"type": "string"
},
"relative": {
"description": "Whether the coordinates are relative to the current mouse position.",
"type": "boolean"
},
"type": {
"type": "string",
"enum": [
"mouse:click"
]
},
"x": {
"description": "X coordinate",
"oneOf": [
{
"description": "Length in pixels",
"type": "object",
"required": [
"type",
"value"
],
"properties": {
"type": {
"description": "Indicates the unit is pixel",
"type": "string",
"enum": [
"px"
]
},
"value": {
"description": "Length in pixels",
"type": "number"
}
}
},
{
"description": "Length as a fraction",
"type": "object",
"required": [
"denominator",
"numerator",
"type"
],
"properties": {
"denominator": {
"description": "Denominator of the fraction",
"type": "number"
},
"numerator": {
"description": "Numerator of the fraction",
"type": "number"
},
"type": {
"type": "string",
"enum": [
"/"
]
}
}
}
]
},
"y": {
"description": "Y coordinate",
"oneOf": [
{
"description": "Length in pixels",
"type": "object",
"required": [
"type",
"value"
],
"properties": {
"type": {
"description": "Indicates the unit is pixel",
"type": "string",
"enum": [
"px"
]
},
"value": {
"description": "Length in pixels",
"type": "number"
}
}
},
{
"description": "Length as a fraction",
"type": "object",
"required": [
"denominator",
"numerator",
"type"
],
"properties": {
"denominator": {
"description": "Denominator of the fraction",
"type": "number"
},
"numerator": {
"description": "Numerator of the fraction",
"type": "number"
},
"type": {
"type": "string",
"enum": [
"/"
]
}
}
}
]
}
}
},
{
"description": "Double click the mouse at the specified coordinates",
"type": "object",
"required": [
"button",
"type",
"x",
"y"
],
"properties": {
"button": {
"description": "Mouse button index",
"type": "number"
},
"holdKey": {
"description": "Key to hold down during double click, in xdotool key syntax. Example: \"ctrl\", \"alt\", \"alt+shift\".",
"type": "string"
},
"relative": {
"description": "Whether the coordinates are relative to the current mouse position.",
"type": "boolean"
},
"type": {
"type": "string",
"enum": [
"mouse:doubleClick"
]
},
"x": {
"description": "X coordinate",
"oneOf": [
{
"description": "Length in pixels",
"type": "object",
"required": [
"type",
"value"
],
"properties": {
"type": {
"description": "Indicates the unit is pixel",
"type": "string",
"enum": [
"px"
]
},
"value": {
"description": "Length in pixels",
"type": "number"
}
}
},
{
"description": "Length as a fraction",
"type": "object",
"required": [
"denominator",
"numerator",
"type"
],
"properties": {
"denominator": {
"description": "Denominator of the fraction",
"type": "number"
},
"numerator": {
"description": "Numerator of the fraction",
"type": "number"
},
"type": {
"type": "string",
"enum": [
"/"
]
}
}
}
]
},
"y": {
"description": "Y coordinate",
"oneOf": [
{
"description": "Length in pixels",
"type": "object",
"required": [
"type",
"value"
],
"properties": {
"type": {
"description": "Indicates the unit is pixel",
"type": "string",
"enum": [
"px"
]
},
"value": {
"description": "Length in pixels",
"type": "number"
}
}
},
{
"description": "Length as a fraction",
"type": "object",
"required": [
"denominator",
"numerator",
"type"
],
"properties": {
"denominator": {
"description": "Denominator of the fraction",
"type": "number"
},
"numerator": {
"description": "Numerator of the fraction",
"type": "number"
},
"type": {
"type": "string",
"enum": [
"/"
]
}
}
}
]
}
}
},
{
"description": "Triple click the mouse at the specified coordinates",
"type": "object",
"required": [
"button",
"type",
"x",
"y"
],
"properties": {
"button": {
"description": "Mouse button index",
"type": "number"
},
"holdKey": {
"description": "Key to hold down during triple click, in xdotool key syntax. Example: \"ctrl\", \"alt\", \"alt+shift\".",
"type": "string"
},
"relative": {
"description": "Whether the coordinates are relative to the current mouse position.",
"type": "boolean"
},
"type": {
"type": "string",
"enum": [
"mouse:tripleClick"
]
},
"x": {
"description": "X coordinate",
"oneOf": [
{
"description": "Length in pixels",
"type": "object",
"required": [
"type",
"value"
],
"properties": {
"type": {
"description": "Indicates the unit is pixel",
"type": "string",
"enum": [
"px"
]
},
"value": {
"description": "Length in pixels",
"type": "number"
}
}
},
{
"description": "Length as a fraction",
"type": "object",
"required": [
"denominator",
"numerator",
"type"
],
"properties": {
"denominator": {
"description": "Denominator of the fraction",
"type": "number"
},
"numerator": {
"description": "Numerator of the fraction",
"type": "number"
},
"type": {
"type": "string",
"enum": [
"/"
]
}
}
}
]
},
"y": {
"description": "Y coordinate",
"oneOf": [
{
"description": "Length in pixels",
"type": "object",
"required": [
"type",
"value"
],
"properties": {
"type": {
"description": "Indicates the unit is pixel",
"type": "string",
"enum": [
"px"
]
},
"value": {
"description": "Length in pixels",
"type": "number"
}
}
},
{
"description": "Length as a fraction",
"type": "object",
"required": [
"denominator",
"numerator",
"type"
],
"properties": {
"denominator": {
"description": "Denominator of the fraction",
"type": "number"
},
"numerator": {
"description": "Numerator of the fraction",
"type": "number"
},
"type": {
"type": "string",
"enum": [
"/"
]
}
}
}
]
}
}
},
{
"description": "Move the mouse to the specified coordinates",
"type": "object",
"required": [
"type",
"x",
"y"
],
"properties": {
"holdKey": {
"description": "Key to hold down during move, in xdotool key syntax. Example: \"ctrl\", \"alt\", \"alt+shift\".",
"type": "string"
},
"relative": {
"description": "Whether the coordinates are relative to the current mouse position.",
"type": "boolean"
},
"type": {
"type": "string",
"enum": [
"mouse:move"
]
},
"x": {
"description": "X coordinate",
"oneOf": [
{
"description": "Length in pixels",
"type": "object",
"required": [
"type",
"value"
],
"properties": {
"type": {
"description": "Indicates the unit is pixel",
"type": "string",
"enum": [
"px"
]
},
"value": {
"description": "Length in pixels",
"type": "number"
}
}
},
{
"description": "Length as a fraction",
"type": "object",
"required": [
"denominator",
"numerator",
"type"
],
"properties": {
"denominator": {
"description": "Denominator of the fraction",
"type": "number"
},
"numerator": {
"description": "Numerator of the fraction",
"type": "number"
},
"type": {
"type": "string",
"enum": [
"/"
]
}
}
}
]
},
"y": {
"description": "Y coordinate",
"oneOf": [
{
"description": "Length in pixels",
"type": "object",
"required": [
"type",
"value"
],
"properties": {
"type": {
"description": "Indicates the unit is pixel",
"type": "string",
"enum": [
"px"
]
},
"value": {
"description": "Length in pixels",
"type": "number"
}
}
},
{
"description": "Length as a fraction",
"type": "object",
"required": [
"denominator",
"numerator",
"type"
],
"properties": {
"denominator": {
"description": "Denominator of the fraction",
"type": "number"
},
"numerator": {
"description": "Numerator of the fraction",
"type": "number"
},
"type": {
"type": "string",
"enum": [
"/"
]
}
}
}
]
}
}
},
{
"description": "Scroll the mouse",
"type": "object",
"required": [
"stepHorizontal",
"stepVertical",
"type",
"x",
"y"
],
"properties": {
"holdKey": {
"description": "Key to hold down during scroll, in xdotool key syntax. Example: \"ctrl\", \"alt\", \"alt+shift\".",
"type": "string"
},
"relative": {
"description": "Whether the coordinates are relative to the current mouse position.",
"type": "boolean"
},
"stepHorizontal": {
"description": "Horizontal scroll steps",
"type": "number"
},
"stepVertical": {
"description": "Vertical scroll steps",
"type": "number"
},
"type": {
"type": "string",
"enum": [
"mouse:scroll"
]
},
"x": {
"description": "X coordinate",
"oneOf": [
{
"description": "Length in pixels",
"type": "object",
"required": [
"type",
"value"
],
"properties": {
"type": {
"description": "Indicates the unit is pixel",
"type": "string",
"enum": [
"px"
]
},
"value": {
"description": "Length in pixels",
"type": "number"
}
}
},
{
"description": "Length as a fraction",
"type": "object",
"required": [
"denominator",
"numerator",
"type"
],
"properties": {
"denominator": {
"description": "Denominator of the fraction",
"type": "number"
},
"numerator": {
"description": "Numerator of the fraction",
"type": "number"
},
"type": {
"type": "string",
"enum": [
"/"
]
}
}
}
]
},
"y": {
"description": "Y coordinate",
"oneOf": [
{
"description": "Length in pixels",
"type": "object",
"required": [
"type",
"value"
],
"properties": {
"type": {
"description": "Indicates the unit is pixel",
"type": "string",
"enum": [
"px"
]
},
"value": {
"description": "Length in pixels",
"type": "number"
}
}
},
{
"description": "Length as a fraction",
"type": "object",
"required": [
"denominator",
"numerator",
"type"
],
"properties": {
"denominator": {
"description": "Denominator of the fraction",
"type": "number"
},
"numerator": {
"description": "Numerator of the fraction",
"type": "number"
},
"type": {
"type": "string",
"enum": [
"/"
]
}
}
}
]
}
}
},
{
"description": "Drag the mouse from start to end coordinates",
"type": "object",
"required": [
"endX",
"endY",
"startX",
"startY",
"type"
],
"properties": {
"button": {
"description": "Mouse button index",
"type": "number"
},
"endRelative": {
"description": "Whether the coordinates are relative to the current mouse position.",
"type": "boolean"
},
"endX": {
"description": "End X coordinate",
"oneOf": [
{
"description": "Length in pixels",
"type": "object",
"required": [
"type",
"value"
],
"properties": {
"type": {
"description": "Indicates the unit is pixel",
"type": "string",
"enum": [
"px"
]
},
"value": {
"description": "Length in pixels",
"type": "number"
}
}
},
{
"description": "Length as a fraction",
"type": "object",
"required": [
"denominator",
"numerator",
"type"
],
"properties": {
"denominator": {
"description": "Denominator of the fraction",
"type": "number"
},
"numerator": {
"description": "Numerator of the fraction",
"type": "number"
},
"type": {
"type": "string",
"enum": [
"/"
]
}
}
}
]
},
"endY": {
"description": "End Y coordinate",
"oneOf": [
{
"description": "Length in pixels",
"type": "object",
"required": [
"type",
"value"
],
"properties": {
"type": {
"description": "Indicates the unit is pixel",
"type": "string",
"enum": [
"px"
]
},
"value": {
"description": "Length in pixels",
"type": "number"
}
}
},
{
"description": "Length as a fraction",
"type": "object",
"required": [
"denominator",
"numerator",
"type"
],
"properties": {
"denominator": {
"description": "Denominator of the fraction",
"type": "number"
},
"numerator": {
"description": "Numerator of the fraction",
"type": "number"
},
"type": {
"type": "string",
"enum": [
"/"
]
}
}
}
]
},
"holdKey": {
"description": "Key to hold down during drag, in xdotool key syntax. Example: \"ctrl\", \"alt\", \"alt+shift\".",
"type": "string"
},
"startRelative": {
"description": "Whether the coordinates are relative to the current mouse position.",
"type": "boolean"
},
"startX": {
"description": "Start X coordinate",
"oneOf": [
{
"description": "Length in pixels",
"type": "object",
"required": [
"type",
"value"
],
"properties": {
"type": {
"description": "Indicates the unit is pixel",
"type": "string",
"enum": [
"px"
]
},
"value": {
"description": "Length in pixels",
"type": "number"
}
}
},
{
"description": "Length as a fraction",
"type": "object",
"required": [
"denominator",
"numerator",
"type"
],
"properties": {
"denominator": {
"description": "Denominator of the fraction",
"type": "number"
},
"numerator": {
"description": "Numerator of the fraction",
"type": "number"
},
"type": {
"type": "string",
"enum": [
"/"
]
}
}
}
]
},
"startY": {
"description": "Start Y coordinate",
"oneOf": [
{
"description": "Length in pixels",
"type": "object",
"required": [
"type",
"value"
],
"properties": {
"type": {
"description": "Indicates the unit is pixel",
"type": "string",
"enum": [
"px"
]
},
"value": {
"description": "Length in pixels",
"type": "number"
}
}
},
{
"description": "Length as a fraction",
"type": "object",
"required": [
"denominator",
"numerator",
"type"
],
"properties": {
"denominator": {
"description": "Denominator of the fraction",
"type": "number"
},
"numerator": {
"description": "Numerator of the fraction",
"type": "number"
},
"type": {
"type": "string",
"enum": [
"/"
]
}
}
}
]
},
"type": {
"type": "string",
"enum": [
"mouse:drag"
]
}
}
},
{
"description": "Type text content",
"type": "object",
"required": [
"content",
"treatNewLineAsEnter",
"type"
],
"properties": {
"content": {
"description": "Text content to type",
"type": "string"
},
"treatNewLineAsEnter": {
"description": "Whether to treat line breaks as enter. If true, any line breaks(\\n) in content will be treated as enter key press, and content will be split into multiple lines.",
"default": false,
"type": [
"boolean",
"null"
]
},
"type": {
"type": "string",
"enum": [
"keyboard:type"
]
}
}
},
{
"description": "Press a keyboard hotkey",
"type": "object",
"required": [
"keys",
"type"
],
"properties": {
"duration": {
"description": "Duration in milliseconds. If specified, the hotkey will be held for a while and then released.",
"type": "number",
"maximum": 5000.0,
"minimum": 1.0
},
"keys": {
"description": "Hotkey combination, in xdotool key syntax. Examples: \"a\", \"Return\", \"alt+Tab\", \"ctrl+s\", \"Up\", \"KP_0\" (for the numpad 0 key).",
"type": "string"
},
"type": {
"type": "string",
"enum": [
"keyboard:hotkey"
]
}
}
},
{
"description": "Take a screenshot of the current screen",
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"screenshot"
]
}
}
},
{
"description": "Wait for a specified duration",
"type": "object",
"required": [
"duration",
"type"
],
"properties": {
"duration": {
"description": "Duration in milliseconds",
"type": "number"
},
"type": {
"type": "string",
"enum": [
"wait"
]
}
}
},
{
"description": "Indicates the action has finished",
"type": "object",
"required": [
"type"
],
"properties": {
"message": {
"description": "Completion message",
"type": "string"
},
"type": {
"type": "string",
"enum": [
"finished"
]
}
}
},
{
"description": "Indicates the action has failed",
"type": "object",
"required": [
"type"
],
"properties": {
"message": {
"description": "Failure message",
"type": "string"
},
"type": {
"type": "string",
"enum": [
"failed"
]
}
}
},
{
"description": "Indicates the human user should take over the control",
"type": "object",
"required": [
"type"
],
"properties": {
"type": {
"type": "string",
"enum": [
"client:user-takeover"
]
}
}
},
{
"description": "Press ONE key down, in xdotool key syntax. Only use this action if hotkey or type cannot satisfy your needs.",
"type": "object",
"required": [
"key",
"type"
],
"properties": {
"key": {
"description": "Key to press",
"type": "string"
},
"type": {
"type": "string",
"enum": [
"key:down"
]
}
}
},
{
"description": "Release ONE key, in xdotool key syntax. Only use this action if keydown cannot satisfy your needs and only after a key down.",
"type": "object",
"required": [
"key",
"type"
],
"properties": {
"key": {
"description": "Key to release",
"type": "string"
},
"type": {
"type": "string",
"enum": [
"key:up"
]
}
}
}
],
"properties": {
"callId": {
"description": "Optional call identifier",
"type": "string"
}
}
}
},
"memory": {
"description": "Memory that is not parsed",
"type": "string"
},
"thoughts": {
"description": "Thoughts that are not parsed",
"type": "string"
},
"unknown": {
"description": "Unknown text that is not thoughts nor actions, commonly due to the misformat of model output",
"type": "string"
}
}
}Fields§
§actions: Vec<ComputerUseActionResponseDtoActionsItem>§memory: Option<String>Memory that is not parsed
thoughts: Option<String>Thoughts that are not parsed
unknown: Option<String>Unknown text that is not thoughts nor actions, commonly due to the misformat of model output
Trait Implementations§
Source§impl Clone for ComputerUseActionResponseDto
impl Clone for ComputerUseActionResponseDto
Source§fn clone(&self) -> ComputerUseActionResponseDto
fn clone(&self) -> ComputerUseActionResponseDto
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ComputerUseActionResponseDto
impl Debug for ComputerUseActionResponseDto
Source§impl<'de> Deserialize<'de> for ComputerUseActionResponseDto
impl<'de> Deserialize<'de> for ComputerUseActionResponseDto
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl From<&ComputerUseActionResponseDto> for ComputerUseActionResponseDto
impl From<&ComputerUseActionResponseDto> for ComputerUseActionResponseDto
Source§fn from(value: &ComputerUseActionResponseDto) -> Self
fn from(value: &ComputerUseActionResponseDto) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for ComputerUseActionResponseDto
impl RefUnwindSafe for ComputerUseActionResponseDto
impl Send for ComputerUseActionResponseDto
impl Sync for ComputerUseActionResponseDto
impl Unpin for ComputerUseActionResponseDto
impl UnsafeUnpin for ComputerUseActionResponseDto
impl UnwindSafe for ComputerUseActionResponseDto
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more