Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Fix Entity Source IDs Tracking ProblemDuring Relationship Processing#2279

Merged
danielaskdd merged 6 commits intoHKUDS:mainfrom
danielaskdd:fix-edge-merge-stage
Oct 28, 2025
Merged

Fix Entity Source IDs Tracking ProblemDuring Relationship Processing#2279
danielaskdd merged 6 commits intoHKUDS:mainfrom
danielaskdd:fix-edge-merge-stage

Conversation

@danielaskdd
Copy link
Collaborator

Fix Entity Source IDs Tracking ProblemDuring Relationship Processing

Problem

Missing source_id updates for entities created via relationships - In_merge_edges_then_upsert(), when processing relationships, existing entities weren't getting theirsource_id lists updated with chunks when source or target node missing in new relationships of current document.

Impact:

  • Entity-chunk tracking became incomplete
  • Miss deleting nodes or edges in documnent deleting process because of lack of chunk tracking information
  • Rebuilding knowledge graph from chunks would miss some entity occurrences

Solution

When an existing entity is encountered during relationship processing, the code now:

  1. Retrieves existing full source_ids fromentity_chunks_storage
  2. Merges with new source_ids from the current relationship
  3. Conditionally updatesentity_chunks_storage (only when data actually changes)
  4. Applies source_ids limit usingapply_source_ids_limit()
  5. Conditionally updates graph database and vector database (only when limited source_ids differ)

Testing Recommendations

  1. Entity Source IDs: Process a document with relationships, verify entities get source_ids from both direct entity extraction and relationship processing
  2. Deletion Order: Delete documents and verify no orphaned edges remain in graph database
  3. Performance: Measure database operation count before/after on large datasets

• Remove verbose entity rebuild logging• Sort IDs before vector DB updates• Keep graph storage with original order
- Handle existing node updates properly in edge merging stage- Fix source_ids merging logic- Reorder entity deletion and optimize node operations- Delete relationships before entities- Add edge existence debugging logs
@danielaskdd
Copy link
CollaboratorAuthor

@codex review

Copy link

@chatgpt-codex-connectorchatgpt-codex-connectorbot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Copy link

@chatgpt-codex-connectorchatgpt-codex-connectorbot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

- Add /static to VITE_API_ENDPOINTS- Update proxy rewrite rules- Include static file serving- Sync sample env file
@danielaskdddanielaskdd merged commitec79727 intoHKUDS:mainOct 28, 2025
1 check passed
@danielaskdddanielaskdd deleted the fix-edge-merge-stage branchOctober 28, 2025 18:35
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@chatgpt-codex-connectorchatgpt-codex-connector[bot]chatgpt-codex-connector[bot] left review comments

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

1 participant

@danielaskdd

Comments


[8]ページ先頭

©2009-2026 Movatter.jp