A native macOS app for assembling large context prompts from your codebase. Select files from a project tree, add instructions, and copy the complete prompt to clipboard — ready to paste into Claude, ChatGPT, Ollama, or any other LLM.
Modern LLMs like Claude (up to 1M tokens) and GPT-4 (128k) can digest entire codebases in a single prompt. The challenge is assembling that prompt — selecting the right files, formatting them properly, and keeping track of the token count.
RepoPrompt does this, but it costs money and caps you at ~35k tokens. Prompt Builder is free, open-source, and has no token limit — build prompts as large as your model can handle.
- Native macOS app — built with SwiftUI, single binary (~380KB), no Electron, no runtime dependencies
- Project file tree with recursive folder selection and tri-state checkboxes (checked / unchecked / partial)
- Smart file filtering — automatically skips
node_modules,.git, binary files, and respects.gitignore - Exclude patterns — filter out files by glob masks (e.g.
*.css, *.md, *.test.ts) - Live token counter — estimates token count as you select files
- One-click copy — builds the prompt and copies to clipboard in one action
- Structured output — generates
<file_map>,<file_contents>, and<user_instructions>XML sections
The generated prompt has three XML sections:
<file_map> — ASCII tree of the project with * marking selected files:
/path/to/project
├── src
│ ├── api
│ │ └── client.ts *
│ └── main.tsx *
└── package.json
<file_contents> — full source code of each selected file, wrapped in fenced code blocks with language detection.
<user_instructions> — your custom instructions/prompt.
brew install --cask alexrett/tap/prompt-builderGrab the latest PromptBuilder.dmg from Releases.
Signed and notarized with Apple Developer ID — no Gatekeeper warnings.
Requires Xcode Command Line Tools and macOS 13+.
git clone https://github.com/alexrett/prompt-builder.git
cd prompt-builder
swift build -c release
open .build/release/PromptBuilderTo build a universal binary (Intel + Apple Silicon):
swift build -c release --arch arm64 --arch x86_64# Build
swift build -c release --arch arm64 --arch x86_64
# Create bundle
mkdir -p PromptBuilder.app/Contents/MacOS PromptBuilder.app/Contents/Resources
cp .build/apple/Products/Release/PromptBuilder PromptBuilder.app/Contents/MacOS/
cp AppIcon.icns PromptBuilder.app/Contents/Resources/
cat > PromptBuilder.app/Contents/Info.plist << 'EOF'
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleExecutable</key>
<string>PromptBuilder</string>
<key>CFBundleIdentifier</key>
<string>com.whitehappypony.prompt-builder</string>
<key>CFBundleName</key>
<string>Prompt Builder</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>1.0</string>
<key>CFBundleIconFile</key>
<string>AppIcon</string>
<key>LSMinimumSystemVersion</key>
<string>13.0</string>
<key>NSHighResolutionCapable</key>
<true/>
</dict>
</plist>
EOF- Open Folder (⌘O) — select your project directory
- Select files — click folders to select recursively, click individual files to toggle
- Exclude patterns — type glob masks like
*.css, *.md, *.test.tsand press Apply - Add instructions — write your prompt in the Instructions panel
- Copy Prompt (⌘⇧C) — builds and copies the complete prompt to clipboard
You can also pass a project path as a CLI argument:
./PromptBuilder /path/to/your/project| Shortcut | Action |
|---|---|
| ⌘O | Open folder |
| ⌘⇧C | Build & copy prompt |
- macOS 13.0 (Ventura) or later
- Works on both Apple Silicon and Intel Macs
MIT
