Expand description
Machine-readable line counts at the end of a file-mutating tool result.
write, edit and apply_patch end a successful result with a line of
the form [+12 -3]; the session sums these into its edit statistics.
The counts are what the tool replaced (an edit counts the whole
replaced block), not a minimal diff, so consumers label them approximate.
Functionsยง
- edit_
trailer [+added -removed], placed on its own line at the end of a result.- parse_
edit_ trailers - Sum every
[+N -M]line incontent(a multi-file patch emits one per file).Nonewhen there is no trailer at all.