Triangle104
commited on
Upload README.md with huggingface_hub
Browse files
README.md
CHANGED
@@ -18,62 +18,6 @@ tags:
|
|
18 |
This model was converted to GGUF format from [`FreedomIntelligence/HuatuoGPT-o1-7B`](https://huggingface.co/FreedomIntelligence/HuatuoGPT-o1-7B) using llama.cpp via the ggml.ai's [GGUF-my-repo](https://huggingface.co/spaces/ggml-org/gguf-my-repo) space.
|
19 |
Refer to the [original model card](https://huggingface.co/FreedomIntelligence/HuatuoGPT-o1-7B) for more details on the model.
|
20 |
|
21 |
-
---
|
22 |
-
Model details:
|
23 |
-
-
|
24 |
-
HuatuoGPT-o1 is a medical LLM designed for advanced
|
25 |
-
medical reasoning. It generates a complex thought process, reflecting
|
26 |
-
and refining its reasoning, before providing a final response.
|
27 |
-
|
28 |
-
|
29 |
-
For more information, visit our GitHub repository:
|
30 |
-
https://github.com/FreedomIntelligence/HuatuoGPT-o1.
|
31 |
-
|
32 |
-
|
33 |
-
Usage
|
34 |
-
|
35 |
-
|
36 |
-
|
37 |
-
|
38 |
-
You can use HuatuoGPT-o1-7B in the same way as Qwen2.5-7B-Instruct. You can deploy it with tools like vllm or Sglang, or perform direct inference:
|
39 |
-
|
40 |
-
from transformers import AutoModelForCausalLM, AutoTokenizer
|
41 |
-
|
42 |
-
model = AutoModelForCausalLM.from_pretrained("FreedomIntelligence/HuatuoGPT-o1-7B",torch_dtype="auto",device_map="auto")
|
43 |
-
tokenizer = AutoTokenizer.from_pretrained("FreedomIntelligence/HuatuoGPT-o1-7B")
|
44 |
-
|
45 |
-
input_text = "How to stop a cough?"
|
46 |
-
messages = [{"role": "user", "content": input_text}]
|
47 |
-
|
48 |
-
inputs = tokenizer(tokenizer.apply_chat_template(messages, tokenize=False,add_generation_prompt=True
|
49 |
-
), return_tensors="pt").to(model.device)
|
50 |
-
outputs = model.generate(**inputs, max_new_tokens=2048)
|
51 |
-
print(tokenizer.decode(outputs[0], skip_special_tokens=True))
|
52 |
-
|
53 |
-
HuatuoGPT-o1 adopts a thinks-before-it-answers approach, with outputs formatted as:
|
54 |
-
|
55 |
-
## Thinking
|
56 |
-
[Reasoning process]
|
57 |
-
|
58 |
-
## Final Response
|
59 |
-
[Output]
|
60 |
-
|
61 |
-
📖 Citation
|
62 |
-
|
63 |
-
|
64 |
-
|
65 |
-
|
66 |
-
@misc{chen2024huatuogpto1medicalcomplexreasoning,
|
67 |
-
title={HuatuoGPT-o1, Towards Medical Complex Reasoning with LLMs},
|
68 |
-
author={Junying Chen and Zhenyang Cai and Ke Ji and Xidong Wang and Wanlong Liu and Rongsheng Wang and Jianye Hou and Benyou Wang},
|
69 |
-
year={2024},
|
70 |
-
eprint={2412.18925},
|
71 |
-
archivePrefix={arXiv},
|
72 |
-
primaryClass={cs.CL},
|
73 |
-
url={https://arxiv.org/abs/2412.18925},
|
74 |
-
}
|
75 |
-
|
76 |
-
---
|
77 |
## Use with llama.cpp
|
78 |
Install llama.cpp through brew (works on Mac and Linux)
|
79 |
|
|
|
18 |
This model was converted to GGUF format from [`FreedomIntelligence/HuatuoGPT-o1-7B`](https://huggingface.co/FreedomIntelligence/HuatuoGPT-o1-7B) using llama.cpp via the ggml.ai's [GGUF-my-repo](https://huggingface.co/spaces/ggml-org/gguf-my-repo) space.
|
19 |
Refer to the [original model card](https://huggingface.co/FreedomIntelligence/HuatuoGPT-o1-7B) for more details on the model.
|
20 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
21 |
## Use with llama.cpp
|
22 |
Install llama.cpp through brew (works on Mac and Linux)
|
23 |
|