mirror of
https://github.com/meta-llama/llama-stack.git
synced 2025-08-03 09:21:45 +00:00
linting fix
This commit is contained in:
parent
60bf0eb532
commit
1381d3f3e8
1 changed files with 11 additions and 12 deletions
|
@ -29,12 +29,14 @@ llama stack build --template nvidia --image-type conda
|
||||||
|
|
||||||
```python
|
```python
|
||||||
import os
|
import os
|
||||||
|
|
||||||
os.environ["NVIDIA_API_KEY"] = "your-api-key"
|
os.environ["NVIDIA_API_KEY"] = "your-api-key"
|
||||||
os.environ["NVIDIA_CUSTOMIZER_URL"] = "http://nemo.test"
|
os.environ["NVIDIA_CUSTOMIZER_URL"] = "http://nemo.test"
|
||||||
os.environ["NVIDIA_USER_ID"] = "llama-stack-user"
|
os.environ["NVIDIA_USER_ID"] = "llama-stack-user"
|
||||||
os.environ["NVIDIA_DATASET_NAMESPACE"] = "default"
|
os.environ["NVIDIA_DATASET_NAMESPACE"] = "default"
|
||||||
os.environ["NVIDIA_PROJECT_ID"] = "test-project"
|
os.environ["NVIDIA_PROJECT_ID"] = "test-project"
|
||||||
from llama_stack.distribution.library_client import LlamaStackAsLibraryClient
|
from llama_stack.distribution.library_client import LlamaStackAsLibraryClient
|
||||||
|
|
||||||
client = LlamaStackAsLibraryClient("nvidia")
|
client = LlamaStackAsLibraryClient("nvidia")
|
||||||
client.initialize()
|
client.initialize()
|
||||||
```
|
```
|
||||||
|
@ -45,15 +47,12 @@ client.initialize()
|
||||||
client.datasets.register(
|
client.datasets.register(
|
||||||
purpose="post-training/messages",
|
purpose="post-training/messages",
|
||||||
dataset_id="my-training-dataset",
|
dataset_id="my-training-dataset",
|
||||||
source={
|
source={"type": "uri", "uri": "hf://datasets/default/sample-dataset"},
|
||||||
"type": "uri",
|
|
||||||
"uri": "hf://datasets/default/sample-dataset"
|
|
||||||
},
|
|
||||||
metadata={
|
metadata={
|
||||||
"format": "json",
|
"format": "json",
|
||||||
"description": "Dataset for LLM fine-tuning",
|
"description": "Dataset for LLM fine-tuning",
|
||||||
"provider": "nvidia"
|
"provider": "nvidia",
|
||||||
}
|
},
|
||||||
)
|
)
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue