docs: move cuda sample command to first. (#981)

support-auth-token
Zhiming Ma 2023-12-08 10:57:09 +08:00 committed by GitHub
parent e2447df9ef
commit bdede03333
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 25 additions and 24 deletions

View File

@ -9,27 +9,11 @@ import Tabs from '@theme/Tabs';
import TabItem from '@theme/TabItem';
<Tabs>
<TabItem value="cpu" label="CPU">
```yaml title="docker-compose.yml"
version: '3.5'
services:
tabby:
restart: always
image: tabbyml/tabby
command: serve --model TabbyML/StarCoder-1B
volumes:
- "$HOME/.tabby:/data"
ports:
- 8080:8080
```
</TabItem>
<TabItem value="cuda" label="CUDA (requires NVIDIA Container Toolkit)">
```yaml title="docker-compose.yml"
version: '3.5'
services:
tabby:
restart: always
@ -48,6 +32,23 @@ services:
capabilities: [gpu]
```
</TabItem>
<TabItem value="cpu" label="CPU">
```yaml title="docker-compose.yml"
version: '3.5'
services:
tabby:
restart: always
image: tabbyml/tabby
command: serve --model TabbyML/StarCoder-1B
volumes:
- "$HOME/.tabby:/data"
ports:
- 8080:8080
```
</TabItem>
</Tabs>

View File

@ -10,18 +10,18 @@ import Tabs from '@theme/Tabs';
import TabItem from '@theme/TabItem';
<Tabs>
<TabItem value="cpu" label="CPU" default>
```bash title="run.sh"
docker run -it -p 8080:8080 -v $HOME/.tabby:/data tabbyml/tabby serve --model TabbyML/StarCoder-1B
```
</TabItem>
<TabItem value="cuda" label="CUDA (requires NVIDIA Container Toolkit)" default>
```bash title="run.sh"
docker run -it --gpus all -p 8080:8080 -v $HOME/.tabby:/data tabbyml/tabby serve --model TabbyML/StarCoder-1B --device cuda
```
</TabItem>
<TabItem value="cpu" label="CPU" default>
```bash title="run.sh"
docker run -it -p 8080:8080 -v $HOME/.tabby:/data tabbyml/tabby serve --model TabbyML/StarCoder-1B
```
</TabItem>
</Tabs>