INNER CODE UNIT · Python

_resolve_train_argv

MakazhanAlpamys/Soup · src/soup_cli/ui/app.py:275

def _resolve_train_argv(config_path: str) -> list[str]:
    """Construct command-line arguments for launching training subprocess."""
    return [sys.executable, "-m", "soup_cli", "train", "--config", config_path, "--yes"]


# Global state for training process
_train_process: Optional[subprocess.Popen] = None
_train_config_path: Optional[str] = None
_train_log_buffer: Optional[TrainLogBuffer] = None
_train_drain_thread: Optional[threading.Thread] = None
_train_lock = threading.Lock()

# Auth token generated at startup — printed to console for the user.
# Reads/writes go through `_auth_token_lock` so token rotation never
# leaves a window where some requests see the old value and some the new.
_auth_token: str = secrets.token_urlsafe(32)
_auth_token_lock = threading.Lock()

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…