跳过导航
tiny-diffusion, but Japanese!
0:00 / 0:21

tiny-diffusion, but Japanese!

Nathan Barry

@nathanrs3414 位关注者

在 X 上查看
395 个赞下载原帖

54,307 次观看

tiny-diffusion, but Japanese! I wonder how logographic languages (Japanese, Chinese, etc) compare to phonetic/alphabetic languages in generation quality and speed with character-level tokenizers. The main difference is the semantic-value-per-token. Fewer tokens are needed to express an idea, which leads to fewer AR and diffusion steps. My main question is how would it affect the entropy in the output distributions. Lower entropy benefits parallel decoding. I could see arguments on both sides on how it affects it. One main benefit is that you have fewer opportunities to mangle words, leading to less obvious mistakes.

19 条评论

评论来自 X (Twitter) 上的原帖

  • utsab 的头像

    @festive_helix

    I also started implementing the Diffusion-LM paper recently inspired by karpathy. Let me know your opinions!

    3 个赞

  • Enigma Spectre 的头像

    @echo_fractal

    Iirc, there was a thing a while back where Japanese and Chinese sentences were showing up in “English” AR CoT along with random compounded German words. I think the idea was in the semantic density of those tokens being higher vs English.

    3 个赞

  • Nathan Barry 的头像

    @nathanrs

    I believe that for many tokenizers, most Chinese and Japanese characters end up being multiple tokens (due to the larger UTF-8 encoding). This kind of offsets the semantic density somewhat. I wonder if anyone uses anything other than UTF-8 for tokenization to get around this.

    2 个赞

  • EIFY 的头像

    @EIFY

    Japanese has a mixed writing system since hiragana & katakana are syllabaries. I think Chinese is the only modern written language that's fully logographic.

    2 个赞

  • webbigdata 的头像

    @webbigdata

    Thank you for publishing such a great repository! The Tale of Genji is Japan's oldest full-length novel, Both capture the stylistic atmosphere well, but the meaning is unclear. In GPT, there are cases where the 「(beginning of a statement) and 」(end) are too far apart.

    2 个赞

  • Ahitagni Shlok D 的头像

    @ahitagnied

    cool stuff

    1 个赞

  • utsab 的头像

    @festive_helix

    The diffusion based generation also occurs in sequential order(mostly). How are you controlling that?

    1 个赞

  • Nathan Barry 的头像

    @nathanrs

    It’s choosing to unmask the highest confident tokens first. It would make sense that it’s generally left to right, as the left is where all the context is. You did give me an idea though. It would be interesting to see what would happen if you forced tokens to be unmasked randomly throughout the context at the start, could lead to multiple islands of context forming which may lead to more confident tokens per step.

    1 个赞

  • utsab 的头像

    @festive_helix

    Are you using discrete diffusion because it looks very similar to that? In the original paper "Diffusion LM" diffused in the continuous latent space but used a clamping function to round it off to the nearest embedding.

  • Nathan Barry 的头像

    @nathanrs

    Pretty much all recent work uses discrete diffusion. Look at LLaDA, Dream, etc. Empirically, they’ve been shown to perform one or two orders of magnitudes better than approaches denoising on a continuous space

    2 个赞

  • Sebastian Buzdugan 的头像

    @sebuzdugan

    So cool

  • Himanshu Kumar 的头像

    @codewithimanshu

    I've observed varying token efficiencies; Japanese presents unique challenges, I believe.

  • Navvye Anand 的头像

    @navvye

    If the diffusion is mostly L to R in sequential order, then AR is provably better.

  • Nathan Barry 的头像

    @nathanrs

    Look at the NVIDIA Fast-dLLM v2 paper, looks like you can get a drastic speedup in generation over AR models with no loss to generation quality.

    2 个赞

  • Navvye Anand 的头像

    @navvye

    But the block diffusion paper suggests otherwise, no?

  • Nathan Barry 的头像

    @nathanrs

    What from the block diffusion paper suggests that? The NVIDIA paper uses the block diffusion architecture, and they got those results.

  • Nathan Barry 的头像

    @nathanrs

    The block diffusion paper did have results that their interpolation from diffusion to AR had better perplexity as it got closer to full AR. But their model size was only 110M parameters. There have been other papers which suggest that diffusion models might scale better, so these results may not generalize. As we saw with the NVIDIA paper, for 7B parameters, it looks like they can reach the same quality

  • Xiao 的头像

    @elmar_0_dsa

    Japanese is phonetic

  • Nathan Barry 的头像

    @nathanrs

    Yeah, should have specified japanese kanji specifically. Chinese is the best example since it's fully logographic.

    1 个赞