Skip to content

Add system-tools: shell execution, file ops, directory listing#29

Open
dmoskov wants to merge 4 commits intoletta-ai:mainfrom
dmoskov:add-system-tools
Open

Add system-tools: shell execution, file ops, directory listing#29
dmoskov wants to merge 4 commits intoletta-ai:mainfrom
dmoskov:add-system-tools

Conversation

@dmoskov
Copy link

@dmoskov dmoskov commented Jan 16, 2026

Summary

Adds four system interaction tools that extend Letta's built-in capabilities:

Tool What it does Why needed
execute_shell_command Run shell commands with timeout Letta has no shell execution
read_file_contents Read files without limits Letta's read_from_text_file has 500 char limit
write_file_contents Overwrite files Letta's append_to_text_file only appends
list_directory_contents List directory contents Letta has no equivalent

Files

  • SKILL.md - Full documentation with examples
  • scripts/system_tools.py - Tool implementations
  • scripts/register_system_tools.py - Registration script
  • references/COMPARISON.md - Comparison with Letta built-ins

Usage

python scripts/register_system_tools.py --server http://localhost:8283

Or via SDK:

from letta import create_client
from system_tools import TOOLS

client = create_client(base_url="http://localhost:8283")
for tool_name, tool_def in TOOLS.items():
    client.create_tool(func=tool_def["func"], name=tool_name)

Security Note

execute_shell_command is intentionally not in Letta's built-ins for security in multi-tenant environments. These tools are designed for trusted, single-tenant deployments.

Test Plan

  • All tools tested locally with success/error cases
  • Timeout handling verified
  • Error messages are clear and actionable
  • Registration script syntax verified

🤖 Generated with Claude Code

Dustin Moskovitz and others added 2 commits January 15, 2026 16:40
Provides four system interaction tools that extend Letta's built-in capabilities:

- execute_shell_command: Run shell commands (not available in Letta built-ins)
- read_file_contents: Read files without character limits (Letta's built-in has 500 char limit
- write_file_contents: Overwrite files (Letta's built-in only appends)
- list_directory_contents: List directory contents (not available in Letta built-ins)

Includes registration script for easy setup via REST API.

Co-Authored-By: Claude <noreply@anthropic.com>
EOF
)
- smart_read_file: Uses LLM to extract only relevant snippets based on query
  Prevents context window blowup while still accessing full file content

- smart_grep_file: Regex search with configurable context lines
  No LLM required, returns matches with surrounding context

Both tools respect the principle behind Letta 500 char limit while
providing more intelligent file access.

Co-Authored-By: Claude <noreply@anthropic.com>
@cpfiffer
Copy link
Collaborator

Hey @letta-code could you take a look please?

@github-actions
Copy link

github-actions bot commented Jan 16, 2026

Letta Code encountered an error —— View job

Failed with exit code 128

The agent encountered an issue before updating the comment.

Dustin Moskovitz and others added 2 commits January 16, 2026 10:04
Self-contained Asana client with:
- 30-second timeouts and automatic retries
- Simple auth via ASANA_ACCESS_TOKEN env var
- Full task CRUD, search, comments, subtasks
- Both CLI and library usage
- Detailed setup guide for Personal Access Tokens

Also adds __pycache__ to .gitignore.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants