Recovering a codebase's component structure improved by 19.5 percent in ARI over the strongest baseline once neighbourhood thresholds adapted to each repository and a second agent checked uncertain boundaries against code evidence
AspireAI community · arXiv (cs.SE)
Repository-level coding agents benefit from knowing which files belong to which architectural component, and recovering that partition is harder than it looks. Functionally related files do not necessarily share architectural responsibility, fixed thresholds and Top-K neighbourhoods break differently as repository size and local similarity distributions change, and an unconstrained LLM refinement step can quietly break correct assignments. ASNER addresses all three.
It derives structured file responsibilities with an LLM, builds semantic neighbourhoods that adapt to repository scale and local similarity, augments a static dependency graph with selected semantic relations and weak directory cues, recovers a component backbone with community detection, and then hands uncertain boundary files to a Responsibility-Ownership-Aware agent that changes assignments only when project-level responsibilities and traceable code evidence support the change. Across 12 open-source projects in C, C++, Java and Python, the paper reports the best macro-average on all five metrics of the common benchmark, improving ARI and c2c@66 over GAER-GAT by 19.5 and 32.9 percent, and a downstream evaluation shows ASNER-guided LocAgent improving file-, module- and function-level code localization on 24 LOC-BENCH issues.
The coverage caveats are stated in the paper itself. Those headline gains are on the subset of projects every baseline could be run on, and the baseline set is uneven across languages - SARIF produced no valid partition for TeamMates, and on the Python projects only GAER-GAT, SemArc and ASNER were runnable because the traditional results come from a Java-and-C++ reproduction package. The refinement stage also needs an LLM to produce file responsibilities in the first place, so the method trades a model call for a better partition.
Read the story and explore more from the AspireAI community.
Two sparse-autoencoder analyses have resisted scaling: matching semantically similar features across layers, and compressing large feature circuits into interpretable supernodes. This paper argues both are the same underlying problem, estimating semantic distances between SAE features that sit on different activation manifolds. Its representation treats each feature not as a single decoder vector but as an activation-weighted distribution over the hidden states expressing it, projects those distributions into a shared reference space, and compares them with Wasserstein distance. The representation is proved invariant to activation rescaling and stable under perturbation, and recovers true matches under finite-sample margin conditions. Empirically it outperformed decoder-vector and LLM-based baselines and captured subtle functional distinctions between related features, and it compressed large feature circuits into interpretable supernodes automatically. The limitation is that this is interpretability tooling: the paper demonstrates better feature matching and circuit compression, not that downstream interpretability claims become more accurate.