Sarah Ciston
commited on
Commit
·
f0acf12
1
Parent(s):
d4c0968
pipeline auth test
Browse files- sketch.js +3 -2
- tutorial.md +3 -1
sketch.js
CHANGED
@@ -235,7 +235,7 @@ new p5(function (p5) {
|
|
235 |
|
236 |
|
237 |
async function runModel(PREPROMPT, PROMPT){
|
238 |
-
// //
|
239 |
|
240 |
// let MODELNAME = 'mistralai/Mistral-Nemo-Instruct-2407'
|
241 |
let MODELNAME = "HuggingFaceH4/zephyr-7b-beta"
|
@@ -251,7 +251,8 @@ async function runModel(PREPROMPT, PROMPT){
|
|
251 |
|
252 |
// pipeline/transformers version
|
253 |
let pipe = await pipeline('text-generation', {
|
254 |
-
model: MODELNAME
|
|
|
255 |
});
|
256 |
// seems to work with default model distilgpt2 ugh
|
257 |
|
|
|
235 |
|
236 |
|
237 |
async function runModel(PREPROMPT, PROMPT){
|
238 |
+
// // pipeline version
|
239 |
|
240 |
// let MODELNAME = 'mistralai/Mistral-Nemo-Instruct-2407'
|
241 |
let MODELNAME = "HuggingFaceH4/zephyr-7b-beta"
|
|
|
251 |
|
252 |
// pipeline/transformers version
|
253 |
let pipe = await pipeline('text-generation', {
|
254 |
+
model: MODELNAME,
|
255 |
+
accessToken: HFAUTH
|
256 |
});
|
257 |
// seems to work with default model distilgpt2 ugh
|
258 |
|
tutorial.md
CHANGED
@@ -225,4 +225,6 @@ When you next load your app, click `Authorize`
|
|
225 |
|
226 |
To check if your authorization has worked, visit the Settings for your Hugging Face profile. Click `Connected Apps` and you should see the name of your `Space`.
|
227 |
|
228 |
-
![screenshot of authorized space in Hugging Face Settings interface]()
|
|
|
|
|
|
225 |
|
226 |
To check if your authorization has worked, visit the Settings for your Hugging Face profile. Click `Connected Apps` and you should see the name of your `Space`.
|
227 |
|
228 |
+
![screenshot of authorized space in Hugging Face Settings interface]()
|
229 |
+
|
230 |
+
<!-- EXAMPLES: https://huggingface.co/docs/huggingface.js/main/en/index#huggingfaceinference-examples -->
|