Community report context building re-renders and re-tokenizes the whole context after every edge
维护者通常 5 天内回复
还没有人认领这个 Issue。
评估
- 难度
- 2/5
- 预计耗时
- 1-3 小时
- 新手友好度
- 25/100
- Issue 类型
- 缺陷
- 描述清晰度
- 描述清楚
- 活跃度
- 活跃
- 技术栈
- python
- 领域
- data, performance
调研方向
Read summarize_communities/graph_context/sort_context.py and trace how build_mixed_context calls sort_context without a token limit. Use the tests/verbs/data fixture to compare build_local_context runtime and output; done means avoiding the repeated per-edge work while preserving byte-identical output. The issue author says a PR is ready, so check with them before starting.
由索引模型根据 Issue 内容生成。
描述
sort_context in the graph context builder for community reports (summarize_communities/graph_context/sort_context.py) adds edges one at a time and, after each edge, rebuilds the entity, claim and relationship DataFrames, renders them with to_csv and tokenizes the whole context again. That's quadratic in the number of edges per community, and it also runs when no token limit is passed (how build_mixed_context calls it), where the per-edge work is thrown away.
On the tests/verbs/data fixture build_local_context takes 0.91 s, and on a synthetic 10k-entity graph 12.5 s. Recording the prefix sizes once and searching for the first edge that exceeds the limit gives 0.14 s and 2.85 s with byte-identical output. I have a PR ready if that's welcome.
- 主要语言
- Python
- 星标
- 36.6k
- 派生
- 3.9k
- 平均合并
- 4 天 11 小时
- 30 天内合并 PR
- 1
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
microsoft/graphrag 的其他 Issue
-
难度 2/5 1-3 小时 新手友好度 74/100
microsoft/graphrag#2626 · 1 条评论 ·
维护者通常 5 天内回复
-
[Bug]: response_format_json_object=True is silently dropped, so JSON mode never reaches the model未关闭bug triage
难度 2/5 1-3 小时 新手友好度 72/100
microsoft/graphrag#2625 · 1 条评论 ·
维护者通常 5 天内回复
-
难度 1/5 1 小时以内 新手友好度 95/100
维护者通常 5 天内回复
-
[Bug]: JsonCache.get() crashes with unhandled AttributeError on non-dict or invalid envelope JSON payloads可能重新可做 关联的 PR 已关闭且未合并。 未关闭
难度 2/5 1-3 小时 新手友好度 82/100
microsoft/graphrag#2614 · 2 条评论 ·
维护者通常 5 天内回复
-
难度 2/5 1-3 小时 新手友好度 85/100
microsoft/graphrag#2594 · 1 条评论 ·
维护者通常 5 天内回复
查看 microsoft/graphrag 的全部 Issue
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 62/100
roman-corgi/corgisim#327 ·
维护者通常 2 天内回复
-
[Bug]: opencode_go chat route drops reasoning_effort (even 'none'), while the same endpoint honors it via custom_llm_provider=openai可能已有人在做 @arvindkumar-ship-it 今天认领。 未关闭llm translation
难度 2/5 1-3 小时 新手友好度 70/100
BerriAI/litellm#51871 · 1 条评论 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 72/100
维护者通常 1 天内回复
-
PolicyEngine backdates South Carolina’s EITC into 2015–2017可能已有人在做 @MaxGhenis 今天认领。 未关闭
难度 2/5 1-3 小时 新手友好度 72/100
PolicyEngine/policyengine-us#10944 ·
维护者通常 2 天内回复
-
fix(frontend): resolve SSE parser crash on unhandled Ref methods and undefined actions identifier未关闭bug
难度 2/5 1-3 小时 新手友好度 75/100
kodokbakar/MiroFish-Local#94 ·
维护者通常 1 天内回复