dshin commited on
Commit
eeee7ee
·
1 Parent(s): 25d7c2a

Push model using huggingface_hub.

Browse files
Files changed (2) hide show
  1. README.md +3 -3
  2. tokenizer.json +16 -2
README.md CHANGED
@@ -24,7 +24,7 @@ You can then generate text as follows:
24
  ```python
25
  from transformers import pipeline
26
 
27
- generator = pipeline("text-generation", model="dshin//tmp/tmpwsp9x9w9/dshin/flan-t5-ppo-testing-violation")
28
  outputs = generator("Hello, my llama is cute")
29
  ```
30
 
@@ -34,8 +34,8 @@ If you want to use the model for training or to obtain the outputs from the valu
34
  from transformers import AutoTokenizer
35
  from trl import AutoModelForCausalLMWithValueHead
36
 
37
- tokenizer = AutoTokenizer.from_pretrained("dshin//tmp/tmpwsp9x9w9/dshin/flan-t5-ppo-testing-violation")
38
- model = AutoModelForCausalLMWithValueHead.from_pretrained("dshin//tmp/tmpwsp9x9w9/dshin/flan-t5-ppo-testing-violation")
39
 
40
  inputs = tokenizer("Hello, my llama is cute", return_tensors="pt")
41
  outputs = model(**inputs, labels=inputs["input_ids"])
 
24
  ```python
25
  from transformers import pipeline
26
 
27
+ generator = pipeline("text-generation", model="dshin//tmp/tmp2rccfo3i/dshin/flan-t5-ppo-testing-violation")
28
  outputs = generator("Hello, my llama is cute")
29
  ```
30
 
 
34
  from transformers import AutoTokenizer
35
  from trl import AutoModelForCausalLMWithValueHead
36
 
37
+ tokenizer = AutoTokenizer.from_pretrained("dshin//tmp/tmp2rccfo3i/dshin/flan-t5-ppo-testing-violation")
38
+ model = AutoModelForCausalLMWithValueHead.from_pretrained("dshin//tmp/tmp2rccfo3i/dshin/flan-t5-ppo-testing-violation")
39
 
40
  inputs = tokenizer("Hello, my llama is cute", return_tensors="pt")
41
  outputs = model(**inputs, labels=inputs["input_ids"])
tokenizer.json CHANGED
@@ -1,7 +1,21 @@
1
  {
2
  "version": "1.0",
3
- "truncation": null,
4
- "padding": null,
 
 
 
 
 
 
 
 
 
 
 
 
 
 
5
  "added_tokens": [
6
  {
7
  "id": 0,
 
1
  {
2
  "version": "1.0",
3
+ "truncation": {
4
+ "direction": "Right",
5
+ "max_length": 198,
6
+ "strategy": "LongestFirst",
7
+ "stride": 0
8
+ },
9
+ "padding": {
10
+ "strategy": {
11
+ "Fixed": 198
12
+ },
13
+ "direction": "Right",
14
+ "pad_to_multiple_of": null,
15
+ "pad_id": 0,
16
+ "pad_type_id": 0,
17
+ "pad_token": "<pad>"
18
+ },
19
  "added_tokens": [
20
  {
21
  "id": 0,