hataraku
Version:
An autonomous coding agent for building AI-powered development tools. The name "Hataraku" (働く) means "to work" in Japanese.
61 lines (60 loc) • 2.07 kB
TypeScript
import { TaskConfig } from './taskConfig';
/**
* Manager for task configurations
* Handles CRUD operations for task configurations stored in the tasks directory
*/
export declare class TaskManager {
private tasksDir;
private agentManager;
constructor();
/**
* List all available task configurations
* @returns Array of task configuration names
*/
listTasks(): Promise<string[]>;
/**
* Get a specific task configuration
* @param name Task configuration name
* @returns Task configuration object
* @throws Error if task configuration not found or invalid
*/
getTask(name: string): Promise<TaskConfig>;
/**
* Create a new task configuration
* @param name Task configuration name
* @param config Task configuration object
* @throws Error if task configuration already exists or is invalid
*/
createTask(name: string, config: TaskConfig): Promise<void>;
/**
* Update an existing task configuration
* @param name Task configuration name
* @param updates Task configuration updates
* @throws Error if task configuration not found or is invalid
*/
updateTask(name: string, updates: Partial<TaskConfig>): Promise<void>;
/**
* Delete a task configuration
* @param name Task configuration name
* @throws Error if task configuration not found
*/
deleteTask(name: string): Promise<void>;
/**
* Validate agent reference in a task configuration
* @param agentName Agent name reference
* @throws Error if the referenced agent doesn't exist
*/
private validateAgentReference;
/**
* Process a task template with given input
* @param task Task configuration
* @param input Task input
* @returns Processed task prompt
*/
processTaskTemplate(task: TaskConfig, input: Record<string, any>): string;
/**
* Initialize default task configurations
* Creates default task configurations if they don't exist
*/
initializeDefaults(): Promise<void>;
}