graphrag icon indicating copy to clipboard operation
graphrag copied to clipboard

7 docstrings name parameters the functions do not take

Open karpovantonme opened this issue 3 months ago • 1 comments

7 docstrings in the repository name a parameter the function does not take. 3 renames that did not reach the text, 2 parameters removed from a signature and left behind, 1 local variable documented as an argument, and 1 name copied from a neighbouring function.

where docstring says signature has
api.build_index memory_profile no such parameter
index.update.communities._update_and_merge_communities community_id_mapping a local built inside the body
drift_search.primer.PrimerQueryProcessor.__init__ chat_llm chat_model
drift_search.primer.DRIFTPrimer.__init__ chat_llm chat_model
drift_search.search.DRIFTSearch.__init__ llm model
drift_search.search.DRIFTSearch.__init__ config no such parameter
graphrag_llm.create_embedding_response model batch_size

The types in the drift_search docstrings had drifted along with the names, so a fix says LLMCompletion there rather than ChatOpenAI.

The change is written and pushed if it saves you the typing: https://github.com/karpovantonme/graphrag/tree/docs/parameters-that-are-not-in-the-signatures

Its documentation only, no behaviour change. Verified against main as of 19 August.

How I found them: a checker I wrote that compares each documented parameter name against the signature below it. This repository mixes numpydoc and Google style, and the Google-style half was invisible to it until this week, which is why these did not turn up alongside #2475.

karpovantonme avatar Aug 20 '26 15:08 karpovantonme

Hi, found microsoft/graphrag while digging around and it is impressive. Wanted to share ModelRank in case it helps your community: an independent, auditable leaderboard for open-weight LLMs. Free embeddable badges, 5-dimension scoring, zero paid placements. If you ever want graphrag scored and listed, it is a one-line badge in the README (https://rankmodel.github.io). Either way, appreciate you building in the open.

pal404error avatar Aug 20 '26 17:08 pal404error