Skip to content

feat(llm): extract standalone graph design and extraction SDK - #387

Merged
imbajin merged 19 commits into
apache:mainfrom
hugegraph:codex/graph-extraction-sdk
Oct 28, 2026
Merged

imbajin merged 19 commits into
apache:mainfrom
hugegraph:codex/graph-extraction-sdk

Conversation

@imbajin

@imbajin imbajin commented Oct 28, 2026 •

Copy link
Copy Markdown
Member

Before → After

Before: graph schema design and extraction require importing the application and global configuration.
After: provide an independently installable hugegraph-llm-core SDK with a Pydantic-only base dependency. Share one implementation through compatibility adapters while exposing synchronous/asynchronous design, extraction, validation and bounded repair with caller-supplied models and workflow steps. Keep UI, persistence and application configuration outside the SDK.

Validation boundary

The author reports core, isolated-wheel Python 3.10–3.13, optional-adapter and legacy compatibility tests. Base-wheel environments intentionally skip optional-provider cases. The author now reports a source-built pycgraph ABI fix and local HTTP container smoke checks; these have not been independently rerun. Retain draft status. No package publication, external model calls or graph writes are claimed.
Source: 🔗 hugegraph/hugegraph-ai #84

Visual overview

Standalone graph design and extraction SDK boundaries

Standalone graph-design/extraction SDK and application boundaries. The author reports an ABI fix and local HTTP container smoke checks; these were not independently rerun. No package publication, real-model invocation, graph write or RC acceptance is implied.

怎么用,怎么改

image

传入文本和自己的模型,即可生成 schema 草案;业务修改并校验 schema 后,再抽取属性图。同步与异步入口都支持,返回图数据和按块排列的问题,便于业务决定接受、重试或人工处理。

可以直接使用完整流程,也可以只替换模型、提示词、校验规则或抽取/审阅/修复步骤。默认执行本地校验与有限审阅修复;关闭审阅后,结果明确标记为 validated,方便调用方区分质量保障程度。
image

接入指南与 editable 开发方式 · 最小调用示例

image

orion and others added 8 commits October 28, 2026 05:40
Release factory-owned clients in bounded groups so long batches do not
exhaust descriptors. Drain sibling clients when aclose itself cancels,
while preserving caller ownership and cleanup-thread semantics.

Distinguish class construction from async instance calls and reject
explicit edge frequency/sort-key/nullable-key contradictions before
inference. Preserve omitted defaults and legacy custom-ID metadata.

Add 35 regression cases. Core: 646 passed. Isolated Python 3.10-3.13
wheels: 591 passed, 55 skipped per version. Legacy CI selection:
1334 passed, 3 skipped, 18 deselected; coverage 63.62%.

Addresses the four PR #84 comments published before this repair.
Remove the Tenacity wrapper that only retried generator creation. Clarify
streaming delta and replay behavior, and cover transient provider and
callback failures without changing non-streaming retries.

Record the second independent review, published comments, and source and
installed-wheel validation.
Drain shielded default-executor futures before propagating cancellation,
preserving ContextVars and retrieving late failures. Cover real-resource
ownership, repeated cancellation, and asyncio.run shutdown.

Document cancellation latency and record independent Python 3.10-3.13
installed-wheel validation.
@imbajin
imbajin marked this pull request as ready for review October 28, 2026 07:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants