docs: fix stale Args in EmbeddingsRegistry.register_model docstring#635
docs: fix stale Args in EmbeddingsRegistry.register_model docstring#635FBISiri wants to merge 1 commit into
Conversation
register_model() only accepts (name, embedding_cls), but its docstring also documented 'pattern' and 'supported_types' parameters that do not exist on the method. Those belong to the separate register_pattern() and register_types() classmethods. Remove the two stale Args entries so the docstring matches the actual signature.
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Code Review
This pull request updates the docstring for the register_model method in src/chonkie/embeddings/registry.py by removing the documentation for the pattern and supported_types arguments, which are no longer part of the function signature. I have no feedback to provide.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
What
EmbeddingsRegistry.register_model()accepts only(name, embedding_cls), but its docstring documents two extra parameters that don't exist on the method:patternandsupported_typesbelong to the sibling classmethodsregister_pattern()andregister_types(), which were split out into their own methods. Theregister_model()docstring was left describing the old combined signature.This PR removes the two stale
Argsentries so the docstring matches the actual signature.Why
The docstring is the public API reference (and feeds the generated docs). Documenting non-existent
pattern/supported_typesarguments misleads users into passing kwargs that raiseTypeError, and trips docstring/signature consistency checks.How verified
register_pattern()/register_types()confirmed as the real homes of these parameters (same file).ruff check src/chonkie/embeddings/registry.py→All checks passed!Scope
Small and self-contained — a 2-line docstring correction in a single file. No behavior change.