public float getEarliness() {
        if (matches == 0) return 0; // Covers field.length==0 too
        if (source.getField().terms().size() == 1) return 1;
        return 1 - (float)head/(max(6, source.getField().terms().size()) - 1);
    }
A normalized measure of how early the first segment occurs in this field: <code>1-head/(max(6,field.length)-1)</code>
searchlib/src/main/java/com/yahoo/searchlib/ranking/features/fieldmatch/FieldMatchMetrics.java