CobraMamba commited on
Commit
0711aff
1 Parent(s): cb0b04b

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +88 -1
README.md CHANGED
@@ -1,3 +1,90 @@
1
  ---
2
- license: llama2
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3
  ---
 
 
 
1
  ---
2
+ language:
3
+ - en
4
+ library_name: transformers
5
+ tags:
6
+ - gpt
7
+ - llm
8
+ - large language model
9
+ inference: false
10
+ thumbnail: >-
11
+ https://h2o.ai/etc.clientlibs/h2o/clientlibs/clientlib-site/resources/images/favicon.ico
12
+ license: apache-2.0
13
+ ---
14
+ # Model Card
15
+
16
+ One of the best 7B model on the [Open LLM Leaderboard](https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard), with performance surpassing dolly-v2-12b!
17
+
18
+ The training code and data will be open sourced later on Github(https://github.com/chi2liu/mamba-gpt-3b).
19
+
20
+
21
+ ## Training Dataset
22
+
23
+ ` mamba-gpt-7b ` is trained on multiple datasets:
24
+ - [Stanford Alpaca (en)](https://github.com/tatsu-lab/stanford_alpaca)
25
+ - [Open Assistant (multilingual)](https://huggingface.co/datasets/OpenAssistant/oasst1)
26
+ - [LIMA (en)](https://huggingface.co/datasets/GAIR/lima)
27
+ - [CodeAlpaca 20k (en)](https://huggingface.co/datasets/sahil2801/CodeAlpaca-20k)
28
+ - [GPT-4 Generated Data (en&zh)](https://github.com/Instruction-Tuning-with-GPT-4/GPT-4-LLM)
29
+ - [UltraChat (en)](https://github.com/thunlp/UltraChat)
30
+
31
+
32
+ ## Summary
33
+
34
+ We have fine-tuned the OpenLLaMA model and surpassed the original model in multiple evaluation subtasks, making it currently one of the best performing 3B model, with comparable performance to llama-7b.
35
+ - Base model: [openlm-research/open_llama_7b_v2](https://huggingface.co/openlm-research/open_llama_7b_v2)
36
+
37
+
38
+ ## Usage
39
+
40
+ To use the model with the `transformers` library on a machine with GPU(s), first make sure you have the `transformers`, `accelerate` and `torch` libraries installed.
41
+
42
+ ```bash
43
+ pip install transformers==4.29.2
44
+ pip install accelerate==0.19.0
45
+ pip install torch==2.0.0
46
+ ```
47
+
48
+ Then, run the following Python snippet:
49
+
50
+ ```python
51
+ from transformers import AutoTokenizer, AutoModelForCausalLM
52
+
53
+ tokenizer = AutoTokenizer.from_pretrained("CobraMamba/mamba-gpt-7b")
54
+ model = AutoModelForCausalLM.from_pretrained("CobraMamba/mamba-gpt-7b", trust_remote_code=True, torch_dtype=torch.bfloat16)
55
+
56
+ # we use llama2 prompt
57
+ input_content = "Your text here"
58
+ input_ids = tokenizer.encode(input_content, return_tensors="pt")
59
+ output = model.generate(input_ids, max_length=128, temperature=0.7)
60
+ output_text = tokenizer.decode(output[0], skip_special_tokens=True)
61
+ print(output_text)
62
+
63
+ ```
64
+
65
+
66
+ ## Citation
67
+
68
+ If this work is helpful, please kindly cite as:
69
+
70
+ ```bibtex
71
+ @Misc{mamba-gpt-7b,
72
+ title = {Mamba-GPT-7b},
73
+ author = {chiliu},
74
+ howpublished = {\url{https://huggingface.co/CobraMamba/mamba-gpt-7b}},
75
+ year = {2023}
76
+ }
77
+ ```
78
+
79
+
80
+ ## Disclaimer
81
+
82
+ Please read this disclaimer carefully before using the large language model provided in this repository. Your use of the model signifies your agreement to the following terms and conditions.
83
+
84
+ - Biases and Offensiveness: The large language model is trained on a diverse range of internet text data, which may contain biased, racist, offensive, or otherwise inappropriate content. By using this model, you acknowledge and accept that the generated content may sometimes exhibit biases or produce content that is offensive or inappropriate. The developers of this repository do not endorse, support, or promote any such content or viewpoints.
85
+ - Limitations: The large language model is an AI-based tool and not a human. It may produce incorrect, nonsensical, or irrelevant responses. It is the user's responsibility to critically evaluate the generated content and use it at their discretion.
86
+ - Use at Your Own Risk: Users of this large language model must assume full responsibility for any consequences that may arise from their use of the tool. The developers and contributors of this repository shall not be held liable for any damages, losses, or harm resulting from the use or misuse of the provided model.
87
+
88
  ---
89
+ license: llama2
90
+ ---