Skip to content

feat(graph): add bulk graph import - #340

Merged
Kaap10 merged 1 commit into
codeforstartups:developmentfrom
GITHUBTANMAY2003:feat/issue-35-bulk-graph-import
Oct 7, 2026
Merged

Kaap10 merged 1 commit into
codeforstartups:developmentfrom
GITHUBTANMAY2003:feat/issue-35-bulk-graph-import

Conversation

@GITHUBTANMAY2003

Copy link
Copy Markdown
Contributor

Description

Adds bulk graph import support for Python records, JSON files, and separate node/edge CSV files. The importer validates the complete input before writing, prepares each unique node once, and groups outgoing edges into bounded DynamoDB UpdateItem operations.

Related issue

Closes #35

Changes

  • Added GraphStore.import_graph() and import_graph_file() with high-level Dynavec client wrappers.
  • Added shared validation for Python, JSON, and CSV inputs with contextual record, filename, and row errors.
  • Grouped edges by source and appended them in bounded chunks while preserving existing metadata, edges, document links, ordering, weights, properties, and namespace isolation.
  • Preserved existing append semantics for duplicate edges and repeated imports.
  • Added public documentation and comprehensive offline regression coverage.

Testing

  • Tests pass locally
  • Ruff checks pass
  • Documentation updated, if applicable

Verification completed:

  • Affected graph, client, namespace, and importer suite: 214 passed
  • Async DynamoDB Moto test: 1 passed
  • Semantic Kernel test in isolation: 8 passed
  • Ruff: passed
  • Formatting checks: passed
  • Mypy: passed across 81 source files
  • git diff --check: passed
  • Full pytest suite passed with OpenAI pre-imported, with 2 skipped

The standard local make run-ci invocation completed Ruff and Mypy successfully but its pytest collection was blocked by an existing DSPy/OpenAI/Semantic Kernel circular-import ordering conflict. The complete pytest suite passes when openai is imported before pytest; no tests were excluded.

Checklist

  • My changes are focused and relevant to this pull request.
  • I have added or updated tests where appropriate.
  • I have reviewed my changes for unrelated modifications.
  • I have updated documentation where necessary.

@Kaap10
Kaap10 self-requested a review October 7, 2026 14:48

@Kaap10 Kaap10 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Verified and tested locally across all graph test suites; all 209 tests pass with clean validation, boundary handling, and zero regressions.

Thanks for your contribution @GITHUBTANMAY2003
LGTM. Ready to merge.

@Kaap10
Kaap10 merged commit 56beb6b into codeforstartups:development Oct 7, 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.

Bulk graph import

2 participants