c2p-cmd commited on
Commit
2aef08d
·
verified ·
1 Parent(s): 967a03d

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +18 -0
README.md CHANGED
@@ -7,6 +7,9 @@ tags:
7
  - trl
8
  - sft
9
  licence: license
 
 
 
10
  ---
11
 
12
  # Model Card for outputs
@@ -31,6 +34,21 @@ print(output["generated_text"])
31
 
32
  This model was trained with SFT.
33
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
34
  ### Framework versions
35
 
36
  - TRL: 0.12.0
 
7
  - trl
8
  - sft
9
  licence: license
10
+ language:
11
+ - en
12
+ pipeline_tag: text-generation
13
  ---
14
 
15
  # Model Card for outputs
 
34
 
35
  This model was trained with SFT.
36
 
37
+ ## Inference
38
+ ```python
39
+ import os
40
+ from dotenv import load_dotenv
41
+
42
+ load_dotenv('.env')
43
+ token = os.getenv('token')
44
+
45
+ from transformers import pipeline
46
+
47
+ pipe = pipeline('text-generation', "c2p-cmd/gemma-2-2b-quote-generator", token=token, device_map="mps")
48
+
49
+ print(pipe("Quote: I've succeeded", max_new_tokens=40))
50
+ ```
51
+
52
  ### Framework versions
53
 
54
  - TRL: 0.12.0