Skip to content
Hacker News front page

Weave: merge by language structure, not by lines

Weave: Merging based on language structure and not lines

Weave is a Git merge driver that parses code into entities like functions and classes via tree-sitter, then merges at that level instead of line-by-line. Two agents editing different functions in the same file merge cleanly. It scored 31/31 on a 31-scenario benchmark, while native Git scored 15/31. It also layers a CRDT state for pre-merge conflict detection and an MCP server exposing 15 tools for Claude and other agents. 28 languages and 5 data formats are supported, with 4,917 file merges tested and zero regressions on C, Python, and Go.

Why it matters: Weave parses code with tree-sitter and merges by function and class instead of by line, so two AI agents editing different functions in one file stop colliding.

Read the original ↗Export Markdown