chat-ui icon indicating copy to clipboard operation
chat-ui copied to clipboard

Support for Llama-3-8B-Instruct model

Open cszhz opened this issue 10 months ago • 2 comments

hi, For model meta-llama/Meta-Llama-3-8B-Instruct, it is unlisted, not sure when will be supported?

https://github.com/huggingface/chat-ui/blob/3d83131e5d03e8942f9978bf595a7caca5e2b3cd/.env.template#L229

thanks.

cszhz avatar Apr 25 '24 14:04 cszhz

For me its working since release, here is the local.env:

MONGODB_URL=mongodb://localhost:27017
USE_LOCAL_WEBSEARCH=true
PUBLIC_APP_ASSETS=chatui
HF_ACCESS_TOKEN=hf_none
PUBLIC_APP_DESCRIPTION="ChatGPT But Open Source!"
PUBLIC_APP_NAME=ChatGPT
MODELS=`[
  {
      "name": "Llama-3",
      "description": "Meta Llama3 is a great overall model",
       "preprompt": "This is a conversation between User and Llama, a friendly chatbot. Llama is helpful, kind, honest, good at writing, and never fails to answer any 	requests immediately and with precision.",
       "promptExamples": [
      {
        "title": "Write an email from bullet list",
        "prompt": "As a restaurant owner, write a professional email to the supplier to get these products every week: \n\n- Wine (x10)\n- Eggs (x24)\n- Bread (x12)"
      }, {
        "title": "Code a snake game",
        "prompt": "Code a basic snake game in python and give explanations for each step."
      }, {
        "title": "Assist in a task",
        "prompt": "How do I make a delicious lemon cheesecake?"
      }
      ],
      "tokenizer" : "philschmid/meta-llama-3-tokenizer",
      "parameters": {
        "temperature": 0.2,
        "top_p": 0.95,
        "repetition_penalty": 1.0,
        "top_k": 50,
        "truncate": 4096,
        "max_new_tokens": 4096,
        "stop": ["<|eot_id|>"]
    },
	"endpoints": [
        {
         "type": "ollama",
         "url" : "http://127.0.0.1:11434",
         "ollamaName" : "llama3:instruct"
    }]
  }
]`

iChristGit avatar Apr 29 '24 12:04 iChristGit

Hi, I also could make it work with the latest release and a similar local.env - particularly with that stop-word in it. Right now I am having an issue, that it stops sometimes too early - but I don't know yet what the source is (could also be API-side not frontend). I didn't try that tokenizer yet though.

ruizcrp avatar Apr 30 '24 05:04 ruizcrp