OpenMOSS / OpenMOSS/MOSS

为什么logit向量的 vocab_size和实际使用的vocab.json 的大小不一致?

Open
#251 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
12.3k
Forks
1.1k
PR merge metrics
No merged PRs in 30d

Description

vocab.json中有 106029个 Token,但是模型最终生成的logit向量的维度的 107008,为什么不一致呢?这样就会出现有些 token无法解码吧?

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by comparing the 106029 entries in vocab.json with the model output that produces 107008 logit dimensions. Trace the tokenizer and model configuration to determine whether the additional dimensions correspond to valid tokens and whether they can be decoded; document the explanation and any required correction.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
machine-learning
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.