mirror of
https://github.com/comfyanonymous/ComfyUI.git
synced 2025-12-17 10:02:59 +08:00
- Frontend authentication with login page (auth_login.html) - API key injection script (auth_inject.js) - Session management (localStorage/sessionStorage) - Logout via URL: http://127.0.0.1:8188/auth_login.html?logout=true - Modified server.py to inject auth scripts into index.html - Added comprehensive documentation: * AUTHENTICATION_GUIDE.md - Complete authentication guide * FRONTEND_AUTH_GUIDE.md - Frontend-specific guide - Health endpoint accessible without authentication - Multiple auth methods: Bearer token, X-API-Key header, query parameter
9 lines
304 B
Python
9 lines
304 B
Python
from transformers import pipeline
|
|
import scipy
|
|
|
|
synthesiser = pipeline("text-to-audio", "facebook/musicgen-large")
|
|
|
|
music = synthesiser("lo-fi music with a soothing melody", forward_params={"do_sample": True})
|
|
|
|
scipy.io.wavfile.write("musicgen_out.wav", rate=music["sampling_rate"], data=music["audio"])
|