Skip to content

Double-check same-QID knowledge graph relations #78

Description

@Moskize91

Problem

Knowledge Graph relation discovery currently allows relations between two different mention IDs even when both mentions resolve to the same QID. That is intentional in some cases: same-entity relations can represent identity continuity, state change, development, transformation, or other self-referential semantics.

However, a same-QID relation is also a strong signal that the LLM may have selected the wrong endpoint or relation direction. For example, a possessive phrase may imply object owned_by person, but the model can accidentally connect two mentions of the same person and produce a self-loop at the QID triple level.

Desired Behavior

Do not blanket-ban same-QID relations. Instead, treat them as suspicious and require an additional confirmation step before accepting them.

Possible product rule:

  • First pass may propose a relation between two different mention IDs with the same QID.
  • If the resulting relation would become a QID self-loop, run a second check focused only on that relation.
  • Accept it only if the second check confirms that the source text explicitly supports a same-entity relation, such as identity continuity, state change, development, transformation, or a comparable self-referential semantic relation.
  • Otherwise reject or repair the relation.

Notes

This should be handled as a relation-discovery quality gate, not as a renderer/display rule. The renderer can still show same-QID triples if they were deliberately confirmed.

No source-book examples are included here to avoid copying copyrighted text into the public issue.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Fields

No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions