facebookresearch / ParlAI

A framework for training and evaluating AI models on a variety of openly available dialogue datasets.
https://parl.ai
MIT License
10.49k stars 2.1k forks source link

HF Llama #5037

Closed jxmsML closed 1 year ago

jxmsML commented 1 year ago

Patch description Add 2 agents:

  1. LlamaAgent For CausalLM parlai i -m hugging_face/llama --inference greedy --skip-generation False --llama-model-dir <MODEL_DIR>
  2. ParlaiLlamaClassifierAgent for Sequence_level classification parlai i -m parlai.agents.hugging_face.llama:ParlaiLlamaClassifierAgent --classes __notok__ __ok__ --llama-model-dir <MODEL_DIR>

Testing steps

7B model parlai i -m hugging_face/llama --skip-generation False --llama-model-dir /checkpoint/jingxu23/genesis/7B_1T/hf_converted_resharded_mp2 1.5B model parlai i -m hugging_face/llama --skip-generation False --llama-model-dir /checkpoint/jingxu23/genesis/1.5B_1T_v0/hf_converted Other information

mojtaba-komeili commented 1 year ago

Please fix the lint errors before merging.

mojtaba-komeili commented 1 year ago

Could you do a quick rebase/merge with main to fix the tests as well? Thanks!

klshuster commented 1 year ago

could you merge with latest main branch? looks like your tests are failing because of that