mychen76 commited on
Commit
2912643
1 Parent(s): 826998f
Files changed (1) hide show
  1. README.md +53 -2
README.md CHANGED
@@ -3,7 +3,58 @@ tags:
3
  - autotrain
4
  - text-generation
5
  widget:
6
- - text: "I love AutoTrain because "
7
  ---
8
 
9
- # Model Trained Using AutoTrain
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3
  - autotrain
4
  - text-generation
5
  widget:
6
+ - text: "I love Train LLM because keep knowledge growth!"
7
  ---
8
 
9
+ # Medical Terminology Model
10
+
11
+ ***trained using dataset***
12
+ Credit :wiki_medical_terms
13
+
14
+ ### Model Usage:
15
+ ```
16
+ from transformers import AutoTokenizer
17
+ import transformers
18
+ import torch
19
+
20
+ model = "mychen76/llama2_medical_terms"
21
+
22
+ tokenizer = AutoTokenizer.from_pretrained(model)
23
+ pipeline = transformers.pipeline(
24
+ "text-generation",
25
+ model=model,
26
+ torch_dtype=torch.float16,
27
+ device_map="auto",
28
+ )
29
+
30
+ sequences = pipeline(
31
+ 'Question:\nWhat is Occipital neuralgia and explain in detail?\nAnswer:\n',
32
+ do_sample=True,
33
+ top_k=10,
34
+ num_return_sequences=1,
35
+ eos_token_id=tokenizer.eos_token_id,
36
+ max_length=200,
37
+ )
38
+ for seq in sequences:
39
+ print(f"Result: {seq['generated_text']}")
40
+
41
+ ```
42
+ Model Response:
43
+ ------------------------------
44
+ Question:
45
+ What is Occipital neuralgia and explain in detail?
46
+ Answer:
47
+ Occipital neuralgia is a type of headache disorder that is caused by pain in the occipital nerves, which are located in the back of the head and neck. These nerves transmit sensory information from the head and face to the brain. When the occipital nerves become irritated or compressed, it can cause intense pain in the back of the head, neck, and sometimes the eyes.
48
+
49
+ Causes:
50
+ Occipital neuralgia can be caused by a variety of factors, including:
51
+
52
+ 1. compression of the occipital nerves due to a muscle spasm or inflammation in the neck
53
+ 2. injury to the occipital nerves, such as a blow to the head or a fall
54
+ 3. a narrowing of the spinal canal, known as spinal sten
55
+
56
+ ```
57
+
58
+ ```
59
+
60
+