@llama_index: Ever wished your agent could read PDFs, images, and Office documents as easily as plain text? Or combine the safety of …
Summary
sandboxed-lit is a Rust CLI agent that parses PDFs, images, and Office documents securely via LiteParse and microsandbox, combining local file access with a sandboxed Bash environment.
View Cached Full Text
Cached at: 05/12/26, 02:53 PM
Ever wished your agent could read PDFs, images, and Office documents as easily as plain text? Or combine the safety of a secure sandbox with the full power of Bash access? We built exactly that. Meet 𝘀𝗮𝗻𝗱𝗯𝗼𝘅𝗲𝗱-𝗹𝗶𝘁, a Rust CLI agent that combines: - LiteParse, our lightning-fast local parser for PDFs, images, Office files, and more - A secure sandbox powered by @microsandbox - Full filesystem mounting, so your agent can safely interact with local files inside the sandbox Mount your local workspace, give the agent shell access, and let it do its magic GitHub: http://github.com/run-llama/sandboxed-lit… Learn more about LiteParse: https://developers.llamaindex.ai/liteparse?utm_medium=socials&utm_source=twitter&utm_campaign=2026…–
run-llama/sandboxed-lit
Source: https://github.com/run-llama/sandboxed-lit
sandboxed-lit
A small Rust CLI that runs an LLM agent inside a microsandbox VM. The agent uses OpenAI’s GPT models via agent-sdk and has tools to list files, read files (parsing PDFs / images / Office docs through liteparse), and run bash commands, all confined to the sandbox.
How it works
src/sandbox.rs— Creates (or reuses) a microsandbox namedlit-sandboxfrom theghcr.io/run-llama/liteparse:mainimage with 2 CPUs and 1 GB of RAM, working dir/app/, and a bind mount at/app/data. Exposes:create_or_get_sandbox(volume)— boots / attaches to the sandbox.list_files(sandbox, dir)— recursively lists files under/app/data.read_file(sandbox, path)— reads a file; routes PDFs, images and Office docs throughlit parsefor structured extraction.run_bash_command(sandbox, cmd, args)— runs an arbitrary command inside the sandbox and returns{stdout, stderr}.
src/agent.rs— Wraps those functions as threeagent-sdktools (list_files,read_file,bash), registers them, builds an OpenAI-backed agent, streams events to the terminal with colored output, and runs until completion.src/main.rs— AclapCLI that parses the prompt and optional mount path and callsagent::run_agent.
Requirements
- Rust (edition 2024)
- A running microsandbox host (see the microsandbox docs)
- An
OPENAI_API_KEYenvironment variable
Build
cargo build --release
Usage
sandboxed-lit --prompt "<your prompt>" [--volume <host-path>]
Options:
| Flag | Short | Description |
|---|---|---|
--prompt | -p | Prompt to send to the agent (required). |
--volume | -v | Host directory to mount at /app/data inside the sandbox. Defaults to the current directory. |
Examples
Run with the current directory mounted:
export OPENAI_API_KEY=sk-...
sandboxed-lit -p "Summarize every PDF in the working directory."
Mount a specific folder:
sandboxed-lit \
-p "List the files, then read report.pdf and extract the key findings." \
-v /Users/me/documents
Files in the mounted directory are visible to the agent at /app/data/....
Similar Articles
@jerryjliu0: Agents + file sandboxes are all in the range in 2026 This is a nifty reference implementation by @itsclelia showing you…
This reference implementation demonstrates how to run an LLM agent securely within a local sandbox to process and analyze various document types using Rust, LiteParse, and microsandbox. The open-source CLI leverages OpenAI's GPT models and native bash commands to perform file retrieval and analysis in an isolated environment.
@itsclelia: Do you actually own your document parsing infrastructure? At @llama_index, we wanted to make that easier, so we built �…
LlamaIndex introduces liteparse-server, an open-source, self-hosted HTTP backend for parsing PDFs, images, and Office documents with spatial layout extraction, OCR, and screenshot generation, designed for AI and data workflows.
@llama_index: When we say “LiteParse runs everywhere,” we mean it. Our WASM package is lightweight, minimal, and built for browser an…
LiteParse is a lightweight WASM-based PDF parser designed for browser and edge runtimes like Cloudflare Workers, enabling efficient document parsing in edge environments.
@jerryjliu0: LiteParse is the best open-source, model-free document parser for AI agents. Run it over over 50+ document types, and i…
LlamaIndex releases liteparse-server, a self-hosted, model-free HTTP API for parsing diverse document types with high spatial fidelity and privacy preservation.
@jerryjliu0: As agents are generating more and more documents, they need a better agent-native document format So far the two main c…
Jerry Liu discusses the need for an agent-native document format that balances human and AI readability, comparing markdown and HTML, and mentioning LlamaParse for handling existing formats.