Skip to main content
AG-Kit provides a comprehensive set of built-in tools that cover the most common tasks AI agents need to perform. These tools are production-ready, well-tested, and designed to work seamlessly together.

Tool Categories

File System Operations

Complete file and directory management capabilities:

Code Execution

Secure multi-language code execution:

System Operations

Command line and system interaction:

Common Patterns

Tool Selection by Use Case

Choose the right combination of tools based on your agent’s purpose:
// File operations: filesystem + search tools
const filesystemToolkit = new FilesystemToolkit({ name: 'fs', context });

const fileTools = [
  ...filesystemToolkit.getTools(),
  createGrepTool(context),
  createGlobTool(context)
];

// Development workflow: code + files + shell
const devTools = [
  new BuiltInCodeExecutor(),
  ...filesystemToolkit.getTools(),
  createBashTool(context)
];

// Full-featured: all built-in tools
const allTools = [
  ...devTools,
  ...createMCPTools(mcpConfig)
];

Error Handling

All built-in tools follow consistent error handling patterns:
const result = await tool.invoke(input);

if (!result.success) {
  switch (result.error_type) {
    case 'validation':
      console.error('Invalid input:', result.error);
      break;
    case 'permission':
      console.error('Access denied:', result.error);
      break;
    case 'execution':
      console.error('Execution failed:', result.error);
      break;
    case 'network':
      console.error('Network error:', result.error);
      break;
  }
} else {
  console.log('Success:', result.data);
}

Next Steps