Objective
Make the first promised operator job genuinely useful: “What is my history with this person?”
Current search filters sender only and omits participants, labels, flags, and attachment summaries from results. Messages where the correspondent is only a recipient are therefore missed.
Relevant code
src/mailplus_intelligence/index_writer.py:236-318
src/mailplus_intelligence/cli.py:54-110
docs/index-query-contract.md
README.md:141-148
Scope
- Search a correspondent across
from, to, cc, and optionally bcc roles.
- Add recipient/domain, label, flag, mailbox/folder, date, attachment, and thread filters with composable semantics.
- Hydrate result rows with participants, labels, flags, attachment metadata summary, thread confidence, and locator status.
- Add stable pagination/cursor behavior rather than a bare unvalidated limit.
- Add
mpi history <address-or-domain> that presents a chronological/thread-grouped metadata timeline.
- Show source locators and explicit missing/ambiguous locator states.
- Keep raw bodies out of search results.
Non-goals
- No semantic relationship graph or inferred person merging.
- No raw full-text body search.
- No automatic contact identity merge across aliases.
- No remote UI.
Acceptance criteria
Validation
PYTHONDONTWRITEBYTECODE=1 PYTHONPATH=src python3.12 -m unittest tests.test_index_writer tests.test_cli -v
bash scripts/ci/run-fast-checks.sh
Dependency notes
Depends on the unified ingest/thread/reconciliation model. API design can begin in parallel, but implementation should not duplicate temporary thread or participant rules.
Exact dependencies
Implementation depends on #107. Query and CLI API design may begin earlier, but must not duplicate temporary participant or thread semantics.
Parent
Part of #98.
Objective
Make the first promised operator job genuinely useful: “What is my history with this person?”
Current search filters sender only and omits participants, labels, flags, and attachment summaries from results. Messages where the correspondent is only a recipient are therefore missed.
Relevant code
src/mailplus_intelligence/index_writer.py:236-318src/mailplus_intelligence/cli.py:54-110docs/index-query-contract.mdREADME.md:141-148Scope
from,to,cc, and optionallybccroles.mpi history <address-or-domain>that presents a chronological/thread-grouped metadata timeline.Non-goals
Acceptance criteria
mpi historygroups/orders messages deterministically and prints locators.Validation
Dependency notes
Depends on the unified ingest/thread/reconciliation model. API design can begin in parallel, but implementation should not duplicate temporary thread or participant rules.
Exact dependencies
Implementation depends on #107. Query and CLI API design may begin earlier, but must not duplicate temporary participant or thread semantics.
Parent
Part of #98.