sarahciston commited on
Commit
0b9db9e
1 Parent(s): a6f115b

try text2text-generation, update pipeline too

Browse files
Files changed (1) hide show
  1. sketch.js +5 -3
sketch.js CHANGED
@@ -21,7 +21,7 @@ async function textGenTask(pre, prompt){
21
  let INPUT = prompt
22
 
23
  // PICK MODEL
24
- let MODEL = 'Xenova/stablelm-2-zephyr-1_6b'
25
 
26
  // MODELS LIST
27
  // - Xenova/bloom-560m
@@ -31,10 +31,12 @@ async function textGenTask(pre, prompt){
31
  // - Xenova/llama2.c-stories15M // only fairytails
32
  // - webml/TinyLlama-1.1B-Chat-v1.0
33
  // - Xenova/TinyLlama-1.1B-Chat-v1.0
34
- // - Xenova/stablelm-2-zephyr-1_6b
 
35
 
36
 
37
- const pipe = await pipeline('text-generation', MODEL)
 
38
 
39
  // RUN INPUT THROUGH MODEL,
40
  var out = await pipe(INPUT, { max_new_tokens: 60, top_k: 90, repetition_penalty: 1.5 })
 
21
  let INPUT = prompt
22
 
23
  // PICK MODEL
24
+ let MODEL = 'Xenova/flan-alpaca-large'
25
 
26
  // MODELS LIST
27
  // - Xenova/bloom-560m
 
31
  // - Xenova/llama2.c-stories15M // only fairytails
32
  // - webml/TinyLlama-1.1B-Chat-v1.0
33
  // - Xenova/TinyLlama-1.1B-Chat-v1.0
34
+
35
+ // - Xenova/flan-alpaca-large //text2text
36
 
37
 
38
+ // const pipe = await pipeline('text-generation', MODEL)
39
+ const pipe = await pipeline('text2text-generation', MODEL)
40
 
41
  // RUN INPUT THROUGH MODEL,
42
  var out = await pipe(INPUT, { max_new_tokens: 60, top_k: 90, repetition_penalty: 1.5 })