Skip to content

Commit 9640a36

Browse files
committed
Update README
1 parent a2c6ee6 commit 9640a36

File tree

3 files changed

+41
-25
lines changed

3 files changed

+41
-25
lines changed

README.md

Lines changed: 16 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,14 @@
11

2-
# Transformers.js
32

3+
<p align="center">
4+
<br/>
5+
<picture>
6+
<source media="(prefers-color-scheme: dark)" srcset="https://huggingface.co/datasets/Xenova/transformers.js-docs/raw/main/transformersjs-dark.svg" width="500" style="max-width: 100%;">
7+
<source media="(prefers-color-scheme: light)" srcset="https://huggingface.co/datasets/Xenova/transformers.js-docs/raw/main/transformersjs-light.svg" width="500" style="max-width: 100%;">
8+
<img alt="transformers.js javascript library logo" src="https://huggingface.co/datasets/Xenova/transformers.js-docs/raw/main/transformersjs-light.svg" width="500" style="max-width: 100%;">
9+
</picture>
10+
<br/>
11+
</p>
412

513
<p align="center">
614
<a href="https://www.npmjs.com/package/@xenova/transformers">
@@ -99,13 +107,13 @@ Alternatively, you can use it in vanilla JS, without any bundler, by using a CDN
99107

100108
Want to jump straight in? Get started with one of our sample applications/templates:
101109

102-
| Platform | Description | Source code |
103-
|-------------------|--------------------------------------|-------------------------------|
104-
| React | Multilingual translation application | [link](./examples/react-translator/) |
105-
| Browser extension | Text classification extension | [link](./examples/extension/) |
106-
| Electron | Text classification application | [link](./examples/electron/) |
107-
| Next.js | *Coming soon* | [link](./examples/next/) |
108-
| Node.js | *Coming soon* | [link](./examples/node/) |
110+
| Platform | Description | Source code |
111+
|-------------------|----------------------------------|-------------------------------|
112+
| React | Multilingual translation website | [link](./examples/react-translator/) |
113+
| Browser extension | Text classification extension | [link](./examples/extension/) |
114+
| Electron | Text classification application | [link](./examples/electron/) |
115+
| Next.js | *Coming soon* | [link](./examples/next/) |
116+
| Node.js | *Coming soon* | [link](./examples/node/) |
109117

110118

111119
## Custom usage

docs/scripts/build_readme.py

Lines changed: 25 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,31 @@
11

22
import re
33
README_TEMPLATE = """
4-
# Transformers.js
4+
5+
<p align="center">
6+
<br/>
7+
<picture>
8+
<source media="(prefers-color-scheme: dark)" srcset="https://huggingface.co/datasets/Xenova/transformers.js-docs/raw/main/transformersjs-dark.svg" width="500" style="max-width: 100%;">
9+
<source media="(prefers-color-scheme: light)" srcset="https://huggingface.co/datasets/Xenova/transformers.js-docs/raw/main/transformersjs-light.svg" width="500" style="max-width: 100%;">
10+
<img alt="transformers.js javascript library logo" src="https://huggingface.co/datasets/Xenova/transformers.js-docs/raw/main/transformersjs-light.svg" width="500" style="max-width: 100%;">
11+
</picture>
12+
<br/>
13+
</p>
14+
15+
<p align="center">
16+
<a href="https://www.npmjs.com/package/@xenova/transformers">
17+
<img alt="NPM" src="https://img.shields.io/npm/v/@xenova/transformers">
18+
</a>
19+
<a href="https://www.npmjs.com/package/@xenova/transformers">
20+
<img alt="Downloads" src="https://img.shields.io/npm/dw/@xenova/transformers">
21+
</a>
22+
<a href="https://github.com/xenova/transformers.js/blob/main/LICENSE">
23+
<img alt="License" src="https://img.shields.io/github/license/xenova/transformers.js">
24+
</a>
25+
<a href="https://huggingface.co/docs/transformers.js/index">
26+
<img alt="Documentation" src="https://img.shields.io/website/http/huggingface.co/docs/transformers.js/index.svg?down_color=red&down_message=offline&up_message=online">
27+
</a>
28+
</p>
529
630
{intro}
731

docs/snippets/0_introduction.snippet

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,4 @@
11

2-
<p align="center">
3-
<a href="https://www.npmjs.com/package/@xenova/transformers">
4-
<img alt="NPM" src="https://img.shields.io/npm/v/@xenova/transformers">
5-
</a>
6-
<a href="https://www.npmjs.com/package/@xenova/transformers">
7-
<img alt="Downloads" src="https://img.shields.io/npm/dw/@xenova/transformers">
8-
</a>
9-
<a href="https://github.com/xenova/transformers.js/blob/main/LICENSE">
10-
<img alt="License" src="https://img.shields.io/github/license/xenova/transformers.js">
11-
</a>
12-
<a href="https://huggingface.co/docs/transformers.js/index">
13-
<img alt="Documentation" src="https://img.shields.io/website/http/huggingface.co/docs/transformers.js/index.svg?down_color=red&down_message=offline&up_message=online">
14-
</a>
15-
</p>
16-
17-
182
State-of-the-art Machine Learning for the web. Run 🤗 Transformers directly in your browser, with no need for a server!
193

204
Transformers.js is designed to be functionally equivalent to Hugging Face's [transformers](https://github.com/huggingface/transformers) python library, meaning you can run the same pretrained models using a very similar API. These models support common tasks in different modalities, such as:

0 commit comments

Comments
 (0)