Lowenzahn commited on
Commit
b71abe0
·
verified ·
1 Parent(s): ddce75e

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +48 -3
README.md CHANGED
@@ -1,3 +1,48 @@
1
- ---
2
- license: apache-2.0
3
- ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ library_name: peft
3
+ base_model: meta-llama/Llama-2-7b-hf
4
+ license: apache-2.0
5
+ language:
6
+ - en
7
+ ---
8
+ ## Training:
9
+
10
+ Check out our githbub: https://github.com/HIRC-SNUBH/Curation_LLM_PathoReport.git
11
+
12
+ ## Inference
13
+ ``` python
14
+ from datasets import load_dataset
15
+ from transformers import AutoTokenizer, AutoModelForCausalLM
16
+ from peft import PeftModel
17
+
18
+
19
+ base_model = AutoModelForCausalLM.from_pretrained(
20
+ 'meta-llama/Llama-2-7b-chat-hf',
21
+ trust_remote_code=True,
22
+ device_map="auto",
23
+ torch_dtype=torch.float16, # optional if you have enough VRAM
24
+ )
25
+ tokenizer = AutoTokenizer.from_pretrained('meta-llama/Llama-2-7b-hf')
26
+
27
+ model = PeftModel.from_pretrained(base_model, 'Lowenzahn/PathoIE-Llama-2-7B')
28
+ model = model.eval()
29
+ ```
30
+
31
+ - PEFT 0.5.0
32
+
33
+
34
+ ## Citation
35
+ ```
36
+ @article{cho2024ie,
37
+ title={Extracting lung cancer staging descriptors from pathology reports: a generative language model approach},
38
+ author={Hyeongmin Cho and Sooyoung Yoo and Borham Kim and Sowon Jang and Leonard Sunwoo and Sanghwan Kim and Donghyoung Lee and Seok Kim and Sejin Nam and Jin-Haeng Chung},
39
+ journal={},
40
+ volume={},
41
+ pages={},
42
+ year={},
43
+ publisher={},
44
+ issn={},
45
+ doi={},
46
+ url={}
47
+ }
48
+ ```