Question Answering
Transformers
PyTorch
Chinese
English
llama
text-generation
text-generation-inference
Instructions to use FlagAlpha/Llama2-Chinese-7b-Chat with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use FlagAlpha/Llama2-Chinese-7b-Chat with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("question-answering", model="FlagAlpha/Llama2-Chinese-7b-Chat")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("FlagAlpha/Llama2-Chinese-7b-Chat") model = AutoModelForCausalLM.from_pretrained("FlagAlpha/Llama2-Chinese-7b-Chat", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Download special_tokens_map.json from FlagAlpha/Llama2-Chinese-7b-Chat: direct link, hf CLI and curl.
- Browser
- Download file 414 Bytes
-
https://huggingface.co/FlagAlpha/Llama2-Chinese-7b-Chat/resolve/main/special_tokens_map.json
- Command line
-
hf download hf://FlagAlpha/Llama2-Chinese-7b-Chat/special_tokens_map.json
-
curl -L -o special_tokens_map.json https://huggingface.co/FlagAlpha/Llama2-Chinese-7b-Chat/resolve/main/special_tokens_map.json
414 Bytes
| { | |
| "bos_token": { | |
| "content": "<s>", | |
| "lstrip": false, | |
| "normalized": false, | |
| "rstrip": false, | |
| "single_word": false | |
| }, | |
| "eos_token": { | |
| "content": "</s>", | |
| "lstrip": false, | |
| "normalized": false, | |
| "rstrip": false, | |
| "single_word": false | |
| }, | |
| "unk_token": { | |
| "content": "<unk>", | |
| "lstrip": false, | |
| "normalized": false, | |
| "rstrip": false, | |
| "single_word": false | |
| } | |
| } | |