@gacua/backend
Version:
GACUA Backend
56 lines (55 loc) • 1.85 kB
TypeScript
/**
* @license
* Copyright 2025 MuleRun
* SPDX-License-Identifier: Apache-2.0
*/
import type { Part } from '@google/genai';
import { type GroundedToolCall, BaseGroundableTool } from './groundable-tool.js';
import { type Box, type Image } from '../screen.js';
export interface ComputerDragAndDropArgs {
starting_image_id: number;
starting_description: string;
ending_image_id: number;
ending_description: string;
hold_keys?: string[];
}
export declare class ComputerDragAndDrop extends BaseGroundableTool<ComputerDragAndDropArgs> {
readonly functionDeclaration: {
name: string;
parametersJsonSchema: {
properties: {
starting_image_id: {
description: string;
type: string;
minimum: number;
};
starting_description: {
description: string;
type: string;
};
ending_image_id: {
description: string;
type: string;
minimum: number;
};
ending_description: {
description: string;
type: string;
};
hold_keys: {
description: string;
type: string;
items: {
type: string;
};
default: never[];
};
};
required: string[];
type: string;
};
};
ground(args: ComputerDragAndDropArgs, screenshot: Image, croppedScreenshotParts: {
imagePart: Part;
}[], detectElement: (imagePart: Part, elementDescription: string) => Promise<Box>): Promise<GroundedToolCall | string>;
}