Skip to content

[P1] Extend entity_linker to process calendar event attendees #565

Description

@tinkermonkey

Problem

Calendar events include attendees: [{"name": str, "email": str}] in domain_metadata. The entity linker (core/entity_linker.py) queries $.sender and $.recipients when building cross-links, but does not query $.attendees[*].email.

A meeting with five contacts generates zero entity_links rows. Queries like "who is attending tomorrow's standup and what's my recent message history with them?" are unanswerable.

Proposed fix

Extend the domain→JSON-path mapping in entity_linker.py to include the events domain attendees:

DOMAIN_EMAIL_PATHS = {
    "messages": ["$.sender", "$.recipients[*]"],
    "events": ["$.attendees[*].email"],          # add this
    "tasks": ["$.collaborators[*]"],             # if applicable
}

The attendee email is already present and normalized in domain_metadata — this is purely an additive query in the linker with no upstream changes required.

Expected outcome

  • Every calendar event chunk with a known attendee gets a person_appearance link in entity_links
  • "Context about [contact] before [meeting]" becomes a satisfiable query once the entity_links query API is exposed (see P0 issue)

Notes

  • Attendee emails should be normalized to lowercase before comparison (contacts emails are already normalized via PeopleMetadata)
  • Linker should handle attendees being absent or an empty list gracefully (it may already do so for other optional fields)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions