Skip to content

Docs: Clarify rjieba installation for RoFormerTokenizer#40738

Open
dipanshuchoudhary-data wants to merge 1 commit into
huggingface:mainfrom
dipanshuchoudhary-data:fix-doc-rjieba
Open

Docs: Clarify rjieba installation for RoFormerTokenizer#40738
dipanshuchoudhary-data wants to merge 1 commit into
huggingface:mainfrom
dipanshuchoudhary-data:fix-doc-rjieba

Conversation

@dipanshuchoudhary-data

Copy link
Copy Markdown

This PR improves the RoFormer documentation by clearly explaining how to install rjieba
before using RoFormerTokenizer. Previously the install command was either missing or commented
out, which could confuse new users. This update adds proper pip install rjieba code blocks
in both Pipeline and AutoModel examples.

@Rocketknight1

Copy link
Copy Markdown
Member

cc @stevhliu

@stevhliu stevhliu left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thanks!

Can you revert all the other changes to the doc? Those aren't necessary and may break the doc-builder

```py
# uncomment to install rjieba which is needed for the tokenizer
# !pip install rjieba
# To use RoFormerTokenizer, first install `rjieba`:

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Let's move this above the <hfoptions> blocks.

Suggested change
# To use RoFormerTokenizer, first install `rjieba`:
Install [rjieba](https://github.com/messense/rjieba-py) with the following command to use [`RoFormerTokenizer`].
<tadd code here>

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