Skip to content

feat(retrieval): explore tables/images and align GREP to term index - #428

Merged
EricNGOntos merged 4 commits into
mainfrom
feat/wuchengke/2026-09-17
Sep 20, 2026
Merged

EricNGOntos merged 4 commits into
mainfrom
feat/wuchengke/2026-09-17

Conversation

@EricNGOntos

Copy link
Copy Markdown
Contributor

Summary

  • GREP searches published term text on the existing term index (single and multi-term use the same LIKE/OR shape); drop the unused content trigram index.
  • Explore mount shows small tables in full and large tables as headers plus query_table; no cell-focus window. Table download failure no longer fails the whole GREP/read call.
  • Finish refs treat query_table as looked-at evidence, matching read/assets.

Test plan

  • make check
  • grep / explore-table / harness / schema-contract tests
  • After merge, retest the medical case on remote

Made with Cursor

EricNGOntos and others added 4 commits September 18, 2026 21:46
- Introduced `FinishRefResolution` class to encapsulate resolved and dropped references during the finish resolution process.
- Updated `resolve_finish_refs` to return an instance of `FinishRefResolution`, providing detailed feedback on reference handling.
- Implemented `select_episode_refs` to manage fallback logic for episode references, ensuring explicit empty lists are respected.
- Enhanced tests to cover new functionality, including scenarios for omitted and explicit references.
- Refactored related components to integrate the new reference resolution structure, improving clarity and maintainability.
…dling

- Added `beautifulsoup4` as a dependency for HTML parsing.
- Introduced new constants for large table handling and focus radius in settings.
- Enhanced `cursor_execute_content` to include HTTPS image parts in responses.
- Updated `recall` and `read` tools to support rendering of images and tables, including handling of large tables and their focus windows.
- Improved tests to validate new functionalities, including image handling and table queries.
- Removed the focus radius setting and related logic from the table handling process.
- Updated the `load_table_html` function to raise a `TableDownloadError` on download failures, allowing for better error handling.
- Adjusted the `read` and `query_table` functions to handle table download errors gracefully, ensuring that body content is still returned even if a table fails to load.
- Enhanced tests to cover scenarios for table download failures and ensure proper error messages are returned.
- Refactored related components to improve clarity and maintainability in table processing.
Declare download_raw_to_temp on the storage protocol, narrow BeautifulSoup tags, and count cited finish refs so make check stays green.

Co-authored-by: Cursor <cursoragent@cursor.com>

from alembic import op

revision: str = "1a2b3c4d5e6f"
from alembic import op

revision: str = "1a2b3c4d5e6f"
down_revision: str | Sequence[str] | None = "0b1c2d3e4f5a"

revision: str = "1a2b3c4d5e6f"
down_revision: str | Sequence[str] | None = "0b1c2d3e4f5a"
branch_labels: Sequence[str] | None = None
revision: str = "1a2b3c4d5e6f"
down_revision: str | Sequence[str] | None = "0b1c2d3e4f5a"
branch_labels: Sequence[str] | None = None
depends_on: Sequence[str] | None = None
@EricNGOntos
EricNGOntos merged commit 0498d8a into main Sep 20, 2026
6 checks passed
@EricNGOntos
EricNGOntos deleted the feat/wuchengke/2026-09-17 branch September 20, 2026 11:25
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.

2 participants