@vibe-kit/grok-cli
Version:
An open-source AI agent that brings the power of Grok directly into your terminal.
31 lines (30 loc) • 730 B
TypeScript
export interface ToolResult {
success: boolean;
output?: string;
error?: string;
data?: any;
}
export interface Tool {
name: string;
description: string;
execute: (...args: any[]) => Promise<ToolResult>;
}
export interface EditorCommand {
command: 'view' | 'str_replace' | 'create' | 'insert' | 'undo_edit';
path?: string;
old_str?: string;
new_str?: string;
content?: string;
insert_line?: number;
view_range?: [number, number];
replace_all?: boolean;
}
export interface AgentState {
currentDirectory: string;
editHistory: EditorCommand[];
tools: Tool[];
}
export interface ConfirmationState {
skipThisSession: boolean;
pendingOperation: boolean;
}