Skip to content

feat: unified chunk relations, importance, and entities-first metadata - #462

Merged
EricNGOntos merged 2 commits into
mainfrom
feat/wuchengke/unified-chunk-relation-schema
Oct 16, 2026
Merged

EricNGOntos merged 2 commits into
mainfrom
feat/wuchengke/unified-chunk-relation-schema

Conversation

@EricNGOntos

Copy link
Copy Markdown
Contributor

Summary

  • Add bidirectional chunk relations (embeds / embedded_by / related), filter hydration to forward relations only, and align ZIP image connect_to with API/DB.
  • Expose retrieval hit-heat importance on public results; prefer entities (with legacy keywords/tokens fallback) in search, asset tools, and graph keyword extraction.
  • Stop emitting redundant metadata.tokens from chunk/ZIP payloads; keep keywords/length for SDK and offline-table compatibility.

Test plan

  • pytest contract suite for relations / page-memory / table embeds
  • make check (ruff + pyright)
  • CI green on PR
  • Spot-check retrieval result includes importance and asset chunks carry embedded_by

Made with Cursor

EricNGOntos and others added 2 commits October 16, 2026 10:34
- Removed the `chunk_stats.json` reference from the documentation as it is no longer used.
- Updated the `importance` field in the metadata schema to improve clarity on its usage.
- Refactored the asset connection logic to streamline the addition of `embedded_by` relationships for images and tables.
- Introduced a new `asset_region` metadata structure to encapsulate asset positioning and dimensions.
- Adjusted tests to validate the new asset metadata and connection behaviors, ensuring consistency across chunk and zip formats.
Wire retrieval importance into the public result projection, migrate
metadata consumers to entities with legacy fallbacks, and stop emitting
redundant metadata.tokens from chunk/ZIP payloads.

Co-authored-by: Cursor <cursoragent@cursor.com>
@EricNGOntos
EricNGOntos merged commit fa49eb1 into main Oct 16, 2026
6 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.

1 participant