koko210Serve 8d5137046c fix(shutdown): implement graceful async shutdown handler
Replace the minimal sync-only shutdown (which only saved autonomous state)
with a comprehensive async graceful_shutdown() coroutine that:

1. Ends active voice sessions (disconnect, release GPU locks, cleanup audio)
2. Saves autonomous engine state
3. Stops the APScheduler
4. Cancels all tracked background tasks (from task_tracker)
5. Closes the Discord gateway connection

Signal handlers (SIGTERM/SIGINT) now schedule the async shutdown on the
running event loop. The atexit handler is kept as a last-resort sync fallback.

Resolves #5, also addresses #4 (voice cleanup at shutdown)
2026-02-18 12:08:32 +02:00
2025-12-07 17:15:09 +02:00
Description
Llama.cpp-powered Hatsune Miku Discord bot with autonomous features, chat, and image generation
458 MiB
Languages
Python 82.1%
JavaScript 10.1%
HTML 4.1%
Jupyter Notebook 1.2%
Shell 1%
Other 1.5%