Skip to content

docs: fix 5 docstring errors in Gemma3nTextConfig (typos, grammar, formatting)#45370

Merged
Rocketknight1 merged 1 commit intohuggingface:mainfrom
RudrenduPaul:fix/gemma3n-docstring-clean
Apr 13, 2026
Merged

docs: fix 5 docstring errors in Gemma3nTextConfig (typos, grammar, formatting)#45370
Rocketknight1 merged 1 commit intohuggingface:mainfrom
RudrenduPaul:fix/gemma3n-docstring-clean

Conversation

@RudrenduPaul
Copy link
Copy Markdown
Contributor

What does this PR do?

Fixes five documentation errors in the Gemma3nTextConfig docstring in modular_gemma3n.py (and the generated configuration_gemma3n.py):

  1. Typo: "emebeddings""embeddings" in hidden_size_per_layer_input
  2. Incomplete sentence: altup_active_idx description was cut off at "or correct" — completed to "or correct the active prediction."
  3. Grammar: "should be make""should make" in altup_num_inputs
  4. Grammar: "number of layer""number of layers" in num_kv_shared_layers
  5. Formatting: Added missing backticks around type annotations for laurel_rank and activation_sparsity_pattern to match HF docstring conventions used consistently throughout the file

Both the modular source file (modular_gemma3n.py) and the generated configuration file (configuration_gemma3n.py) are updated in sync.

Before submitting

  • This PR fixes a typo or improves the docs (you can dismiss the "Test" section below).
  • Did you read the contributor guideline, Pull Request section?
  • Was this discussed/approved via a Github issue or the forum? Please add a link to it if that's the case.
  • Did you make sure to update the documentation with your changes? Here are the documentation guidelines, and here are tips on formatting docstrings.
  • Did you write any new necessary tests?

Note to maintainers: These are purely documentation corrections — no logic changes. The modular file is the source of truth; the generated file was updated by hand to match (identical diff in both files). Running make fix-repo will confirm the generated file is in sync.

AI disclosure

  • AI-assisted contribution (Claude Code used to identify and draft fixes; all changes reviewed and validated by Rudrendu Paul)
  • I confirm this is NOT a pure code agent PR — the human submitter (Rudrendu Paul) has reviewed every changed line

Who can review?

@stevhliu @zucchini-nlp

Fix five documentation errors in Gemma3nTextConfig docstring:
- Typo: "emebeddings" → "embeddings"
- Incomplete sentence for altup_active_idx (truncated at "or correct")
- Grammar: "should be make" → "should make" in altup_num_inputs
- Grammar: "number of layer" → "number of layers" in num_kv_shared_layers
- Formatting: add missing backticks around type annotations for
  laurel_rank and activation_sparsity_pattern to match HF docstring
  conventions

Both modular_gemma3n.py (source of truth) and the generated
configuration_gemma3n.py are updated in sync.

Built by Rudrendu Paul, developed with Claude Code
@github-actions
Copy link
Copy Markdown
Contributor

[For maintainers] Suggested jobs to run (before merge)

run-slow: gemma3n

Copy link
Copy Markdown
Member

@Rocketknight1 Rocketknight1 left a comment

Choose a reason for hiding this comment

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

Yep, looks good!

@Rocketknight1 Rocketknight1 enabled auto-merge April 13, 2026 12:53
@Rocketknight1 Rocketknight1 added this pull request to the merge queue Apr 13, 2026
@HuggingFaceDocBuilderDev
Copy link
Copy Markdown

The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update.

Merged via the queue into huggingface:main with commit 6db69b9 Apr 13, 2026
17 checks passed
sirzechs66 pushed a commit to sirzechs66/transformers that referenced this pull request Apr 18, 2026
…rmatting) (huggingface#45370)

docs: fix docstring errors in Gemma3nTextConfig

Fix five documentation errors in Gemma3nTextConfig docstring:
- Typo: "emebeddings" → "embeddings"
- Incomplete sentence for altup_active_idx (truncated at "or correct")
- Grammar: "should be make" → "should make" in altup_num_inputs
- Grammar: "number of layer" → "number of layers" in num_kv_shared_layers
- Formatting: add missing backticks around type annotations for
  laurel_rank and activation_sparsity_pattern to match HF docstring
  conventions

Both modular_gemma3n.py (source of truth) and the generated
configuration_gemma3n.py are updated in sync.

Built by Rudrendu Paul, developed with Claude Code

Co-authored-by: Rudrendu <RudrenduPaul@users.noreply.github.com>
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.

3 participants