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:

File Operations

Read, write, and edit files with encoding support

Directory Operations

List, create, and manage directories

Search Operations

Find files with glob patterns and search content with regex

Advanced Editor

Multi-operation file editor for complex workflows

Code Execution

Secure multi-language code execution:

Sandboxed Execution

Secure execution in isolated E2B containers

Local Execution

High-performance local code execution

Language Support

Python, JavaScript, TypeScript, Bash, and more

Streaming Output

Real-time stdout/stderr streaming

System Operations

Command line and system interaction:

Shell Commands

Execute shell commands with proper isolation

Environment Control

Manage environment variables and working directories

Process Management

Control process execution and resource limits

Output Handling

Capture and process command output

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

File System Tools

Complete guide to file system operations

Code Execution Tools

Secure multi-language code execution

Command Line Tools

Shell command execution and system operations

MCP Integration

External tool ecosystem integration