Skip to content

Add truthful partial task-only Forecast queries (#85) - #224

Merged
deverman merged 1 commit into
masterfrom
agent/85-task-only-forecast
Oct 3, 2026
Merged

deverman merged 1 commit into
masterfrom
agent/85-task-only-forecast

Conversation

@deverman

@deverman deverman commented Oct 3, 2026

Copy link
Copy Markdown
Owner

Outcome

Refs #85. Add filter.forecast="past-and-today" to the existing list_tasks and get_task_counts surface, plus the equivalent CLI option. This is an explicit partial task-only contract, not an exact native OmniFocus Forecast total. No new model-facing tool or mutation is introduced.

The deduplicated union uses remaining actions with local due/planned dates before next local midnight, defer dates during today, effective flags, or the documented configured Tag.forecastTag (not a hard-coded name). Foundation supplies calendar-day boundaries, including DST. Unavailable scheduled actions are included by default; explicit filters still intersect. Project headers, completed/dropped actions and hidden children are excluded. Both list and count return limitations, and the CLI preserves them too.

See docs/forecast-contract.md for exclusions, visibility-preference differences, inherited-date limitations, and paging across day rollover. The roadmap now identifies #85 as the active slice following completed #92 feature UAT.

Validation impact and acceptance

query, with MCP wire coverage. BridgeClient changes attach the day window and propagate count warnings only; IPC, dispatch, retries and timeout policy are unchanged. This explains narrowing the conservative filename-based transport classification.

Acceptance journey: ask a real MCP client how many items are in Forecast (past and today), receive a dedicated deduplicated count matching the paginated list, and have the assistant explicitly qualify it as partial rather than equating it with native Forecast.

Completed:

  • Full Swift Testing suite and release build; new deterministic tests exercise the actual production Bridge JavaScript in JavaScriptCore.
  • UTC/Makassar day differences, 23/25-hour DST days, configured tag with a different name, absent configured tag, union/deduplication, unavailable actions, dropped/completed parents, project/tag/ID/inbox intersections, paging, cursor scope, and invalid/missing day windows.
  • Direct MCP schema/success/error probes: true, exact, and today are rejected; list/count agree for baseline, inbox, availability, flags and empty searches, including all pages and warning propagation.
  • Required script installation, one OmniFocus restart, healthy matching development plugin, and the query-tier live semantic canary. Existing baseline contracts remained green.
  • New opt-in Swift live regression test passed for Forecast list/count/warnings and inbox parity.
  • Native UI comparison: 8 Past / 0 Today badges versus the explicitly partial union of 58 actions. A native overdue/flagged sample matched; this is not an assertion of exact view parity.
  • OpenCode UAT used the candidate release binary: get_task_counts({filter:{forecast:"past-and-today"}}) returned 58 and its answer explicitly retained all limitations. The initial attempt accidentally launched the older command because project config overrode OPENCODE_CONFIG; that run is excluded from acceptance evidence. Runtime OPENCODE_CONFIG_CONTENT corrected the server selection without editing user config.
  • Whitespace and local Markdown link checks.
  • Targeted Forecast MCP smoke: 610.1 seconds of measured rounds, 28 count/list pairs plus 19 initial semantic calls (75 calls total), zero errors and zero parity failures. Baseline/inbox/availability/flagged scenarios rotated. Median 12.12s and p95 22.41s include MCP round-trip time; no performance improvement or comparative regression conclusion is claimed. Tail latency needs the separate release diagnostics. The final subsequent CLI-only warning projection was independently built/tested/live-probed; MCP/Bridge production code stayed unchanged during this smoke.

The selected Swiftly 6.3.3 compiler failed before package compilation against the installed SDK (-target-arch-variant); verification used Xcode's bundled Swift 6.4 via xcrun/PATH. No toolchain pin was changed.

Release boundary

The realistic 1.5-hour suite is still required on the frozen release candidate before release acceptance. This PR is not a release certificate and does not close #85. #222's release diagnostics remain separate. No Homebrew release, merge, or task write is performed here. Raw local harness artifacts remain under .build/benchmarks; only the selected evidence is published.

Checklist:

  • Implementation, automated contracts, release build, installed health/semantic canary, direct wire probes, client UAT, and targeted 10-minute smoke.
  • Realistic validation on the frozen release candidate before release acceptance.

Implementation commit: febbaab4734ff9f0fe273a666d364b41d35ef2ab.

@deverman
deverman merged commit 77995e9 into master Oct 3, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Prevent incorrect counts for OmniFocus Forecast queries

1 participant