rtt is a cli application which allows you to convert a repository of code/files
and webpages into flat files (both txt and md formats are supported) and
interact with LLMs all using one CLI
currently only supports macOS & Linux distros
curl -sfL https://raw.githubusercontent.com/shammianand/rtt/main/install.sh | sh# Add to your shell config (~/.zshrc or ~/.bashrc):
export GROQ_API_KEY=sk_xxxx # Convert current directory to rtt.txt (optimized format)
rtt
# Convert current directory to rtt.txt (explicit)
rtt .
# Convert directory to custom output file
rtt /path/to/dir -o output.txt# Save webpage as markdown
rtt url https://example.com -o page.md# Query current directory
rtt query . "Explain this codebase"
# Query webpage
rtt query url https://example.com "Summarize this article"- Current Directory Support: Run
rttwithout arguments to process the current directory - Automatic Cache Filtering: Always skips cache files, build artifacts, and non-code/text files
- Optimized Text Output: Always creates minimal-formatting text files that save tokens for LLM processing
- Comprehensive File Support: Processes code files, text files, markdown, configuration files, and more
The tool automatically skips:
- Cache files (
.cache,.tmp,.log, etc.) - Build artifacts (
node_modules,target,build,dist) - System files (
.DS_Store,Thumbs.db) - Binary and non-text files
The tool always creates optimized text files with:
- Minimal formatting and no extra spaces
- Simple
FILE: pathheaders for each file - No markdown syntax or file separators
- Ideal for token-efficient LLM processing
By default, queries use the Mixtral-8x7b model with a 32k context window.
For more details:
rtt help
rtt query --help