mirror of
https://github.com/hiyouga/LLaMA-Factory.git
synced 2025-12-14 10:56:56 +08:00
[data] fix ollama template (#6902)
* fix ollama template
* add meta info
* use half precision
Former-commit-id: e1a7c1242c
This commit is contained in:
@@ -123,6 +123,7 @@ def test_ollama_modelfile():
|
||||
tokenizer = AutoTokenizer.from_pretrained(TINY_LLAMA)
|
||||
template = get_template_and_fix_tokenizer(tokenizer, DataArguments(template="llama3"))
|
||||
assert template.get_ollama_modelfile(tokenizer) == (
|
||||
"# ollama modelfile auto-generated by llamafactory\n\n"
|
||||
"FROM .\n\n"
|
||||
'TEMPLATE """<|begin_of_text|>'
|
||||
"{{ if .System }}<|start_header_id|>system<|end_header_id|>\n\n{{ .System }}<|eot_id|>{{ end }}"
|
||||
|
||||
Reference in New Issue
Block a user