Repository navigation
Expand file tree
/
Copy path.env.example
More file actions
153 lines (139 loc) · 9.59 KB
/
Copy path.env.example
File metadata and controls
153 lines (139 loc) · 9.59 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
# Settings for compose.yaml. Copy to .env and edit; .env is not committed (it can hold a token).
# A missing or empty value uses the default shown.
# --- Who the container runs as: your own user, so ./data and the model cache stay yours.
# Find yours with: id -u and id -g
STUDIO_UID=1000
STUDIO_GID=1000
# --- Where it listens. 0.0.0.0 = reachable from your LAN at http://<spark-address>:8081 (the port below).
# 127.0.0.1 = only on the Spark itself (use an SSH tunnel or an NVIDIA Sync custom app).
STUDIO_BIND=0.0.0.0
# The port on the Spark that you open in the browser (compose.yaml publishes it to the container's own 8080, which never changes).
# It was 8080 up to 1.19: if your .env still says 8080, change it, or the page stays there.
STUDIO_PORT=8081
# Optional DNS-rebinding guard: the host names/addresses you browse to, comma-separated,
# e.g. spark-1a2b.local,192.168.1.20 (localhost always works). Empty = accept any.
STUDIO_ALLOWED_HOSTS=
# --- Model
STUDIO_MODEL=Qwen/Qwen-Image-2.1
# Hugging Face cache folder on the Spark (default: ~/.cache/huggingface, the usual shared one).
# HF_CACHE_DIR=/home/you/.cache/huggingface
# Only needed if the model repo is gated or private.
HF_TOKEN=
# Where model files come from. auto (the default) = use the local cache and touch the network only if files are
# missing from it, so after the first download nothing is fetched again, even if the model's authors publish an
# update. true = never contact Hugging Face (a missing file is an error). false = ask the hub on every load, as
# versions before 1.8 did (and download an update if there is one).
STUDIO_LOCAL_FILES_ONLY=auto
# --- Music (the Music tab, MiniMax-Music3; see docs/SPARK_TEST.md section 20)
# The first load downloads about 29 GB (up to 57 GB if the whole repository is fetched). Have 60 GB free.
STUDIO_MUSIC_MODEL=MiniMaxAI/MiniMax-Music3
# Refuse to load the music model unless this many GB are free (it needs about 24 GB). 40 is an estimate. 0 = no check.
STUDIO_MUSIC_MIN_FREE_GB=40
# The longest track you may ask for, in seconds (10-360, the model's own limit), and how many versions one request may make.
STUDIO_MUSIC_MAX_SECONDS=300
STUDIO_MUSIC_MAX_TRACKS=4
# --- Memory (the Spark's 128 GB is shared by the CPU, the GPU and everything else, Hermes included)
# Refuse to load the model unless at least this many GB are free (MemAvailable). 40 is an estimate,
# to be replaced by the number you measure (docs/SPARK_TEST.md). 0 = no check.
STUDIO_MIN_FREE_GB=40
# Unload the model after this many idle minutes, to give the memory back. 0 = right away.
STUDIO_IDLE_TIMEOUT_MIN=30
# true = keep parts of the model in CPU memory between uses (slower; rarely useful on the Spark).
STUDIO_CPU_OFFLOAD=false
# --- History
STUDIO_QUEUE_CAP=10
# Delete finished runs older than this many days, with their images; 0 = never. Checked at start-up
# and then once a day. Runs you press Keep on, and runs still waiting or running, are never deleted.
# A card warns when fewer than 7 days remain. Such runs, and runs you delete, go to the bin (below) first.
STUDIO_RETENTION_DAYS=30
# How many days a deleted run stays in the bin (the Deleted view) before it is deleted for good, with its files; you can restore it
# until then, or empty the bin yourself. 0 = no bin: Delete and the clean-up delete for good at once.
STUDIO_BIN_DAYS=30
# --- Drafts (the Draft button): a small, quick try of your prompt that jumps ahead of waiting full-size runs.
# The long side in pixels (256-1024, a multiple of 32), and the most steps a draft may use.
STUDIO_DRAFT_SIZE=512
STUDIO_DRAFT_STEPS=12
# --- Editing (the Edit mode on the page; scripts/edit_via_api.sh drives the same API from a terminal)
# How many images one edit may use, 1-10. Qwen allows ten; 4 until memory and time are measured on the Spark.
STUDIO_MAX_INPUT_IMAGES=4
# An uploaded image that no edit has used is deleted after this many hours.
STUDIO_UPLOAD_TTL_HOURS=24
# The largest single upload, in MB (an image may also have at most 16 megapixels).
STUDIO_MAX_UPLOAD_MB=20
# The page shows a "this edit is heavy" warning above this many units, where one unit is one image at 1K and
# the cost grows as images x (resolution / 1024)^2 (so 4 images at 2K is 16). 8 is a guess until the Spark has
# measured it (SPARK_TEST.md section 18); 0 turns the warning off.
STUDIO_EDIT_WARN_UNITS=8
# --- Enlarge (the page's Enlarge button: the same picture bigger and sharper, with an upscaler model; DESIGN.md section 28)
# The model file is yours to download, once (the studio never fetches it; the model has its own terms, read them):
# mkdir -p ~/.cache/huggingface/upscalers
# curl -L -o ~/.cache/huggingface/upscalers/RealESRGAN_x2plus.pth \
# https://github.com/xinntao/Real-ESRGAN/releases/download/v0.2.1/RealESRGAN_x2plus.pth
# Leave this empty to use that file (the container sees it as /models/upscalers/RealESRGAN_x2plus.pth); or name another
# x2 upscaler file, as the container sees it.
STUDIO_UPSCALER_MODEL=
# auto (the GPU if there is one), cuda, or cpu (minutes per picture).
STUDIO_UPSCALER_DEVICE=auto
# --- Prompt builder (the fourth tab: a chat with a language model that turns a rough idea into an image prompt; DESIGN.md section 37)
# It needs an Ollama server (https://ollama.com) that you run yourself, on this Spark or elsewhere on your network. The studio never
# starts, stops or installs it. Leave the address empty and the tab says how to set it up.
# Where Ollama listens, as this container sees it. http or https, a host and a port, nothing after the port. The address is kept in this file
# and nowhere else: the page, the logs and every message leave it out. For an Ollama on the Spark itself use host.docker.internal; Ollama
# must listen beyond 127.0.0.1 for a container to reach it (on its machine: OLLAMA_HOST=0.0.0.0, then restart it).
STUDIO_OLLAMA_URL=
# The model for the conversation, exactly as `ollama list` names it, with its tag. One that can look at pictures (qwen3.8:27b can) lets you
# attach a picture to a message.
STUDIO_OLLAMA_MODEL=
# Only if the model above cannot look at pictures: another model, that can, used for messages that carry a picture. Empty = none.
STUDIO_OLLAMA_VISION_MODEL=
# How long Ollama keeps the model in memory after a reply (a number with s, m or h; 0 = unload at once; -1 = never). The tab has an
# Unload from memory button for giving the memory back sooner.
STUDIO_OLLAMA_KEEP_ALIVE=5m
# The conversation window in tokens (512-1048576). More remembers more and needs more memory.
STUDIO_OLLAMA_NUM_CTX=32768
# Let the model think before it answers: on, off, or model (leave it to the model's own default). A message can override this for itself.
STUDIO_OLLAMA_THINK=on
# Give up when Ollama has said nothing for this many seconds (5-3600), and never let one reply last longer than the second number (10-7200,
# not less than the first). A long think that keeps streaming is not silence.
STUDIO_OLLAMA_TIMEOUT_S=120
STUDIO_OLLAMA_MAX_REPLY_S=900
# How many conversations may wait on the model at once (1-4). 1 = one reply at a time, which is what one GPU shared with the image model wants.
STUDIO_BUILDER_AT_ONCE=1
# --- Speech (the fifth tab: text read aloud; DESIGN.md section 38)
# Which engines to offer, as a comma list of ids: qwen3-tts, voxtral, kokoro, piper. Empty = all of them. An engine whose libraries are not in the image is
# shown as "not installed" with the reason, and the others work.
STUDIO_SPEECH_ENGINES=
# A model of your own for an engine, instead of the one it downloads: a local folder or a Hugging Face id. Empty = the engine's own. Qwen3-TTS: a folder (or
# namespace) that holds the three checkpoints under the names Qwen3-TTS-12Hz-1.7B-CustomVoice, -VoiceDesign and -Base. Kokoro: a folder with config.json,
# kokoro-v1_0.pth and a voices folder. Piper: the .onnx file of a voice, with its .onnx.json beside it. Voxtral: a model id for vLLM.
STUDIO_SPEECH_QWEN3_TTS_MODEL=
STUDIO_SPEECH_VOXTRAL_MODEL=
STUDIO_SPEECH_KOKORO_MODEL=
STUDIO_SPEECH_PIPER_MODEL=
# Memory the studio wants free before it loads a speech engine, in GB. Empty = the engine's own estimate.
STUDIO_SPEECH_MIN_FREE_GB=
# The share of the GPU's memory that Voxtral's own server may take (0.05-0.9). vLLM takes most of a GPU unless told otherwise; the Spark's memory is shared with
# the image model, Ollama and the rest. 0.2 is an estimate to check (docs/SPARK_TEST.md section 31).
STUDIO_SPEECH_GPU_FRACTION=0.2
# Limits: the most text one reading may hold (characters), the longest part of a reading, the biggest file to read aloud (.txt .md .pdf .epub .docx) and web page (MB),
# and the time allowed for each step of fetching a web page (seconds).
STUDIO_SPEECH_MAX_CHARS=1500000
STUDIO_SPEECH_PART_MAX_CHARS=30000
STUDIO_SPEECH_MAX_UPLOAD_MB=50
STUDIO_SPEECH_FETCH_MAX_MB=5
STUDIO_SPEECH_FETCH_TIMEOUT_S=20
# The silence after a paragraph, in milliseconds (after a heading, twice that).
STUDIO_SPEECH_PAUSE_MS=450
# How short and how long (seconds) a recording of your voice may be, the biggest file to upload for it (MB), the program that reads one that is not a plain WAV
# (MP3, M4A, OGG, FLAC, WebM) and how long it may take (seconds).
STUDIO_SPEECH_VOICE_MIN_SECONDS=8
STUDIO_SPEECH_VOICE_MAX_SECONDS=60
STUDIO_SPEECH_RECORDING_MAX_MB=30
STUDIO_SPEECH_FFMPEG=ffmpeg
STUDIO_SPEECH_DECODE_TIMEOUT_S=30
# How many hours the three clips of a voice design, a recording you uploaded and did not save, and the short jobs behind a sample are kept.
STUDIO_SPEECH_TEMP_HOURS=24
# To build Voxtral's server into the image (large, optional, and not reported on a Spark): SPEECH_VOXTRAL=1 docker compose build
SPEECH_VOXTRAL=0
# --- Build: NVIDIA PyTorch release (nvcr.io/nvidia/pytorch:<tag>). 25.10 or newer for the Spark.
NGC_TAG=25.10-py3