CLI tool for LLM prompt construction
Top 21.4% on sourcepulse
This tool concatenates files from a directory into a single prompt for Large Language Models (LLMs), aiding users in providing comprehensive context. It's designed for developers and researchers working with LLMs who need to efficiently bundle codebases or documentation.
How It Works
The tool recursively traverses specified directories, optionally filtering by file extension, including hidden files, and respecting .gitignore
patterns. It outputs file contents, prefixed by their relative paths, separated by ---
. Special formatting options include Claude XML and Markdown fenced code blocks for LLM-specific prompt structuring.
Quick Start & Requirements
pip install files-to-prompt
Highlighted Details
-e
).--include-hidden
) and ignore specific patterns (--ignore
).--cxml
) and Markdown (--markdown
).--null
) for filenames with spaces.Maintenance & Community
Licensing & Compatibility
Limitations & Caveats
The tool's primary function is file concatenation; it does not perform semantic analysis or intelligent summarization of the content. Large numbers of files or very large files may result in prompts exceeding LLM context window limits.
5 months ago
1+ week