Skip to content

Some more explanation improvements #16267

Description

@slow-J

Description

A recent Explanation change I done, (#16229) has led me to more explanation improvements.

I am thinking of looking at the following:

  1. Testing gap in testExplainFailingOptionalClauses. It only asserts on the failingOptionals list, not the main subs list. Adding a subs.clear() into BooleanWeight doesn't fail any tests.
  2. CheckHits.checkNoMatchExplanations is shallow. It only checks the root explanation's isMatch() == false and never looks at its sub-details. Nested non-match sub-explanations are never structurally verified.
  3. Improve the KNN explain message. When testing BooleanWeight.explain prints failing optional clauses (when required) #16229, we saw some unclear output, see below.
0.0 = no match on optional clause (track(knn=DocAndScoreQuery[1404635,...][0.7655482,...],0.7655482))
    0.0 = not in top 1 docs
  1. TestComplexExplanations has a long-standing // :TODO: we really need more crazy complex cases.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions