You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
> Where `hfup` stands for HuggingFace up, and the word `up` was inspired from `rollup`, `tsup`, you may think it means "to make your HuggingFace work up and running".
8
-
9
-
## Features
6
+
A collection of tools to help you deploy, bundle HuggingFace Spaces and related assets with ease.
10
7
11
-
- Still manually writing HuggingFace Spaces configurations?
12
-
- Having trouble to quickly handle and edit the `.gitattributes` file for Git LFS?
13
-
- Don't want any of the HuggingFace Spaces front-matter appear in `README.md`?
14
-
- Fighting against annoying errors when deploying your HuggingFace Spaces?
15
-
16
-
`hfup` is here to help you!
17
-
18
-
- 🚀 Automatically...
19
-
- generate `.gitattributes` file for Git LFS.
20
-
- generate HuggingFace Spaces front-matter in `README.md`.
21
-
- search for your `README.md` file and merge the front-matter header.
22
-
- generate a dedicated `README.md` file right inside the `outDir` of build.
23
-
- 🔐 Intellisense ready, type safe for Spaces configurations.
24
-
- 📦 Out of the box support for Vite.
8
+
> Where `hfup` stands for HuggingFace up, and the word `up` was inspired from `rollup`, `tsup`, you may think it means "to make your HuggingFace work up and running".
25
9
26
10
## Installation
27
11
@@ -34,11 +18,13 @@ yarn i hfup -D
34
18
npm i hfup -D
35
19
```
36
20
37
-
## Usage
21
+
<details>
22
+
<summary>Vite</summary><br/>
38
23
39
24
```ts
40
-
import { LFS, SpaceCard } from'hfup/vite'
25
+
//vite.config.ts
41
26
import { defineConfig } from'vite'
27
+
import { LFS, SpaceCard } from'hfup/vite'
42
28
43
29
exportdefaultdefineConfig({
44
30
plugins: [
@@ -59,6 +45,172 @@ export default defineConfig({
59
45
})
60
46
```
61
47
48
+
<br/></details>
49
+
50
+
<details>
51
+
<summary>Rollup</summary><br/>
52
+
53
+
```js
54
+
// rollup.config.js
55
+
import { LFS, SpaceCard } from'hfup/rollup';
56
+
57
+
exportdefault {
58
+
plugins: [
59
+
LFS(),
60
+
SpaceCard({
61
+
title:'Real-time Whisper WebGPU (Vue)',
62
+
emoji:'🎤',
63
+
colorFrom:'gray',
64
+
colorTo:'green',
65
+
sdk:'static',
66
+
pinned:false,
67
+
license:'mit',
68
+
models: ['onnx-community/whisper-base'],
69
+
short_description:'Yet another Real-time Whisper with WebGPU, written in Vue',
0 commit comments