codetether-agent 4.7.0-a-002.4

A2A-native AI coding agent for the CodeTether ecosystem
Documentation
1
2
3
4
5
6
7
8
9
10
pub fn ratio(old: &str, new: &str) -> f32 {
    let old = super::lines::code_line_set(old);
    let new = super::lines::code_line_set(new);
    let base = old.len().min(new.len());
    if base == 0 {
        return 0.0;
    }
    let common = old.intersection(&new).count();
    common as f32 / base as f32
}