New command `unpac monorepo` creates a standalone directory containing all
projects and their vendored dependencies, suitable for building with dune.
No git history is included - only the current state of each branch.
Features:
- Exports all projects from project/* branches
- Exports vendored opam packages from opam/patches/* branches
- Exports vendored git repos from git-repos/patches/* branches
- Generates root dune-project and dune files
- Creates unified vendor/ directory with (vendored_dirs opam git)
- Strips vendor/ from individual projects (uses shared root vendor/)
Options:
- -p/--project: Export specific projects (can repeat)
- --no-opam: Exclude vendored opam packages
- --no-git: Exclude vendored git repositories
Usage:
unpac monorepo /path/to/output
cd /path/to/output && dune build
cd /path/to/output && dune build @doc
馃 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
Promotion:
- Add `unpac project promote <name> --backend <opam|git>` command
- Filters vendor/ directory from project history
- Creates upstream/vendor/patches branches for the backend
Export (inverse of vendoring):
- Add `unpac export <name> --backend <backend>` command
- Moves files from vendor/<backend>/<name>/ back to root
- Add `unpac export-set-remote` and `unpac export-push` commands
- Add `unpac export-list` to show exported packages
Upstream remote for promoted packages:
- Add `unpac opam set-upstream <name> <url>` command
- Allows `unpac opam update` to work on promoted local packages
- Symmetric flow: export-push to publish, set-upstream + update to fetch
Branch model:
- upstream/ - pristine external state (files at root)
- vendor/ - upstream with vendor/<backend>/<name>/ prefix
- patches/ - vendor + local modifications
- export/ - patches transformed back to root (for pushing)
馃 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Rewrite tools.ml to use Claude.Tool.create and Claude.Mcp_server
- Tools are now bundled into an in-process MCP server named "unpac"
- Custom tools accessible as mcp__unpac__<tool_name>
- Update agent.ml to register MCP server via Options.with_mcp_server
- Simplify handler: built-in tools handled by Claude CLI, custom tools via MCP
- Remove manual tool dispatch in on_tool_use handler
- Add on_tool_result handler for logging
This aligns with the Python Claude Agent SDK's approach where:
- Built-in tools (Read, Write, Bash, etc.) are handled by Claude CLI
- Custom tools are defined via MCP servers executed in-process
馃 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
New --web PORT option enables a real-time dashboard that shows:
- Agent thinking/activity status
- Tool calls with input/output
- Text responses as they stream
- Errors and sync events
- Turn costs and running total
Architecture:
- event.ml: Event types and pub/sub bus for broadcasting
- web.ml: Minimal WebSocket server with inline HTML/CSS/JS
- SHA1/Base64 for WebSocket handshake (digestif, base64)
- Each WS connection subscribes directly to event bus
- Dark theme, monospace font, auto-reconnect
Usage:
unpac-claude --web 8080 # Interactive with web UI
unpac-claude -a --web 8080 -w /path # Autonomous with web UI
The UI auto-scrolls to show latest events and displays:
- Tool names with syntax-highlighted JSON input
- Collapsible tool output (truncated for large results)
- Turn count and cumulative cost in footer
馃 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Major enhancements to the Claude agent:
- Add autonomous mode (-a) that continuously analyzes all projects
- Add workspace path argument (-w) for specifying workspace location
- Add periodic sync (unpac status/push) with configurable interval
- Add rate limit handling with exponential backoff (5s base, 5min max)
New file operation tools:
- read_file: Read source code and config files
- write_file: Write/update files (code, STATUS.md)
- list_directory: Explore directory structure
- glob_files: Find files by pattern (*.ml, etc)
New shell execution tool:
- run_shell: Execute commands like dune build/test
New workspace sync tools:
- unpac_status_sync: Update README.md and sync state
- unpac_push: Push all branches to remote
- git_commit: Commit changes with message
Autonomous mode workflow:
1. List all projects in workspace
2. For each project, read STATUS.md and source files
3. Analyze code quality (Stdlib combinators, higher-order functions)
4. Check test coverage and flag missing tests
5. Update STATUS.md with findings and shortcomings
6. Make focused improvements and commit changes
7. Periodically sync with remote
馃 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- unpac opam init: Create new local opam packages from scratch
- Generates scaffold with dune-project, lib/dune, and module files
- Recorded in config with url='local' for identification
- Comprehensive documentation for AI agent usage
- unpac opam promote: Graduate projects to vendored dependencies
- Copies project content to opam/vendor/<name> branches
- Enables code reuse between projects
- Original project remains unchanged
- Enhanced opam command documentation:
- Three package sources: External, Local, Promoted
- Workflow guides for each source type
- AI agent usage examples
- Added audit operation types: Opam_init, Opam_promote
馃 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Add vendored_package type to Config with name, url, and optional branch
- Add TOML codec for [[opam.vendored]] sections
- Update opam add command to record packages in config after vendoring
- Add ensure_vendored_remotes function to Git module to recreate remotes
from config on-demand (useful after cloning a workspace)
- Add helper functions: add/remove/find/list vendored packages
This allows workspaces to be cloned and have their remotes automatically
recreated based on the tracked vendored packages in unpac.toml.
馃 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>