Weave, a new Git merge driver from Ataraxy Labs, achieved 31 out of 31 clean merges compared to Git's 15 out of 31 on real merge commits from major open-source repositories by using semantic understanding rather than line-based comparison. The tool parses code into semantic entities using tree-sitter grammars and only conflicts on actual semantic collisions, eliminating false conflicts that occur when independent changes happen in the same file area.
Semantic Entity Matching Replaces Line-Based Comparison
Weave fundamentally rethinks merge conflict detection by parsing all three versions (base, ours, theirs) into semantic entities—functions, classes, JSON keys, and other language constructs. Entities are matched across versions by identity using name, type, and scope. This approach only triggers conflicts when two branches make incompatible changes to the same entity, whereas Git produces false conflicts on independent changes that happen to be adjacent in a file.
Zero Regressions on Major Open-Source Repositories
Benchmark testing replayed real merge commits from major open-source repositories using both Git and Weave, then compared results against human-authored merge resolutions. Weave achieved zero regressions across all tested repositories, with every "win" representing a scenario where developers had to manually resolve a false conflict that Weave handled automatically. The tool successfully resolved twice as many merges cleanly as Git's default merge algorithm.
Broad Language Support via Tree-Sitter
Weave currently supports TypeScript, JavaScript, Python, Go, Rust, JSON, YAML, TOML, and Markdown through tree-sitter grammar integration. The project is available on GitHub and can be integrated as a custom Git merge driver. Tree-sitter's parsing infrastructure provides the semantic understanding needed to identify language-specific entities across different programming languages.
Git Merge Algorithm Creator Endorses Approach
According to creator Rohan Sharma, the person who wrote Git's merge algorithm reviewed Weave and called it "a very reasonable way to tackle the problem," noting that language-aware content merging is needed more than ever for AI agents. This endorsement from Git's original architect validates the semantic approach as a necessary evolution of version control for modern development workflows.
Critical for AI Agent Code Generation
The tool addresses a growing challenge as AI agents increasingly generate code. Semantic merging could dramatically reduce merge conflicts in agent-generated codebases where traditional line-based merging struggles with code that machines write and modify. The Hacker News discussion received 115 points and 65 comments, indicating strong developer community interest in solutions for AI-era version control challenges.
Key Takeaways
- Weave achieved 31/31 clean merges versus Git's 15/31 on real merge commits from major open-source repositories
- Uses semantic entity matching (functions, classes, JSON keys) via tree-sitter instead of line-based comparison to eliminate false conflicts
- Achieved zero regressions across all tested repositories, with every win being a false conflict Git couldn't handle
- Supports TypeScript, JavaScript, Python, Go, Rust, JSON, YAML, TOML, and Markdown through tree-sitter grammars
- Git's merge algorithm creator endorsed the approach as "very reasonable" and noted language-aware merging is increasingly needed for AI agents