A topology-derived sparse attention kernel