/**
 * Computer Skills Module
 *
 * Skills library for reusable automations and workflows.
 * Inspired by Open Interpreter's computer.skills capabilities.
 */
import { EventEmitter } from 'events';
export interface Skill {
    /** Unique skill identifier */
    id: string;
    /** Display name */
    name: string;
    /** Description */
    description: string;
    /** Version */
    version: string;
    /** Author */
    author?: string;
    /** Tags for categorization */
    tags: string[];
    /** Input parameters schema */
    parameters: SkillParameter[];
    /** Steps to execute */
    steps: SkillStep[];
    /** Required capabilities */
    capabilities?: string[];
    /** Example usage */
    examples?: SkillExample[];
    /** Source file path */
    sourcePath?: string;
    /** Built-in skill */
    builtin?: boolean;
}
export interface SkillParameter {
    name: string;
    type: 'string' | 'number' | 'boolean' | 'array' | 'object';
    description: string;
    required?: boolean;
    default?: unknown;
    enum?: unknown[];
}
export interface SkillStep {
    id?: string;
    type: 'code' | 'shell' | 'llm' | 'condition' | 'loop' | 'skill';
    content: string;
    language?: string;
    condition?: string;
    items?: string;
    skillId?: string;
    args?: Record<string, unknown>;
    onError?: 'stop' | 'continue' | 'retry';
    retryCount?: number;
}
export interface SkillExample {
    input: Record<string, unknown>;
    description: string;
}
export interface SkillRunResult {
    skillId: string;
    success: boolean;
    output: unknown;
    error?: string;
    duration: number;
    steps: StepResult[];
}
export interface StepResult {
    stepId: string;
    success: boolean;
    output: unknown;
    error?: string;
    duration: number;
}
export interface SkillSearchResult {
    skill: Skill;
    score: number;
    matchedTags: string[];
    matchedDescription: boolean;
}
export interface SkillLibraryConfig {
    /** Paths to search for skills */
    skillPaths: string[];
    /** Enable built-in skills */
    enableBuiltin: boolean;
    /** Cache skills */
    cacheEnabled: boolean;
}
export declare const DEFAULT_SKILL_LIBRARY_CONFIG: SkillLibraryConfig;
export declare class ComputerSkills extends EventEmitter {
    private config;
    private skills;
    private loaded;
    constructor(config?: Partial<SkillLibraryConfig>);
    /**
     * Load all available skills
     */
    load(): Promise<void>;
    /**
     * Load skills from a directory
     */
    private loadSkillsFromPath;
    /**
     * List all available skills
     */
    list(filter?: {
        tags?: string[];
        search?: string;
    }): Skill[];
    /**
     * Search for skills
     */
    search(query: string): SkillSearchResult[];
    /**
     * Get a skill by ID
     */
    get(skillId: string): Skill | undefined;
    /**
     * Run a skill
     */
    run(skillId: string, params?: Record<string, unknown>): Promise<SkillRunResult>;
    /**
     * Execute a single step
     */
    private executeStep;
    private executeCodeStep;
    private executeShellStep;
    private executeLLMStep;
    private executeConditionStep;
    private executeLoopStep;
    /**
     * Register a new skill
     */
    register(skill: Skill): void;
    /**
     * Unregister a skill
     */
    unregister(skillId: string): boolean;
    /**
     * Save a skill to disk
     */
    save(skill: Skill, filePath?: string): Promise<void>;
    /**
     * Delete a skill from disk
     */
    delete(skillId: string): Promise<boolean>;
    private validateParams;
    private applyDefaults;
    private validateSkill;
    private interpolate;
    private resolvePath;
    /**
     * Get skill count
     */
    get count(): number;
    /**
     * Get all tags
     */
    getTags(): string[];
}
export declare function getComputerSkills(config?: Partial<SkillLibraryConfig>): ComputerSkills;
export declare function resetComputerSkills(): void;
export default ComputerSkills;
