Async start the shell session and run startup commands.
Provides Glob and Grep search over filesystem files.
This middleware adds two tools that search through local filesystem:
Example:
from langchain.agents import create_agent
from langchain.agents.middleware import (
FilesystemFileSearchMiddleware,
)
agent = create_agent(
model=model,
tools=[], # Add tools as needed
middleware=[
FilesystemFileSearchMiddleware(root_path="/workspace"),
],
)Root directory to search.
Whether to use ripgrep for search.
Falls back to Python if ripgrep unavailable.
Maximum file size to search in MB.