0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

Ollama-MMLU-Proを動かすまで

Last updated at Posted at 2024-08-03

Ollama-MMLU-Proとは

https://github.com/chigkim/Ollama-MMLU-Pro
LLMの新しいテストの一つのMMLU-Proをvllmやgeminiではなく、Ollamaでテストを実行するためのもの。ChatGPT互換なのでgroqでも動く(tokenが制限に引っかかります)

インストールと実行

git clone https://github.com/chigkim/Ollama-MMLU-Pro
pip install -r requirements.txt

追加で必要なこともある

pip install --upgrade datasets

これをしないと以下エラーが出ることがある。phindに聞けば教えてくれるけど

1284, in generate_from_dict
    return Sequence(feature=generate_from_dict(obj["feature"]), length=obj["length"])
KeyError: 'length'

実行

設定ファイルの config.tomlを好きなモデルに修正

model = "llama3.1:8b-instruct-q8_0"

モデルをダウンロードしておく。ちなみにダウンロード先は
Linux: /usr/share/ollama/.ollama/models
https://github.com/ollama/ollama/blob/main/docs/faq.md

ollama pull llama3.1:8b-instruct-q8_0

あとは実行するだけ

python run_openai.py 

ただ、一つのカテゴリーでA4000でも数時間ぐらいかかる。
どうも、1問ごとに保存しているだけあって、途中で終わっても、再開できるみたいだ。(最後までテスト終わってない)

テスト結果で気をつけるべきは、無回答の場合、randomで答えを割り振るみたいです。結果を見るとき注意が必要

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?