Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
30546d1
refactor: event callbacks for extension system
celunah Jun 17, 2026
ae421ae
Merge remote-tracking branch 'origin' into dev
celunah Jun 17, 2026
09de030
Merge remote-tracking branch 'origin' into dev
celunah Jun 18, 2026
1c872ed
feat: base VC support
celunah Jun 18, 2026
46315a8
Merge remote-tracking branch 'origin' into dev
celunah Jun 18, 2026
23ba74a
feat: backend reloading in place, move cache directory to be detachable
celunah Jun 20, 2026
f1cc863
Merge branch 'dev' of https://github.com/celunah/celune into dev
celunah Jun 20, 2026
91212a7
feat: better persona prompt handling with emotions and CEVOICE-driven…
celunah Jun 21, 2026
50b3e67
chore: import and type formatting
celunah Jun 21, 2026
d4b0572
chore: align code formatting of persona responses
celunah Jun 21, 2026
bb06e99
Merge remote-tracking branch 'origin' into dev
celunah Jun 22, 2026
534aad7
fix: made warnings real warnings and not just bare logs
celunah Jun 22, 2026
53bb99c
chore: more UX, do not lock speech during readiness
celunah Jun 22, 2026
450251f
fix: proper TTFC, log redirecting actually works
celunah Jun 23, 2026
705e439
chore: we dont need that
celunah Jun 23, 2026
3e89cbc
chore: fix final bits of @coderabbitai warnings
celunah Jun 24, 2026
8708821
fix: fix this and fast
celunah Jun 24, 2026
fc5b536
refactor: i18n support
celunah Jun 24, 2026
8395f2e
fix: missing osc strings
celunah Jun 24, 2026
9286c0a
feat: SeedVC support, i18n from json
celunah Jun 26, 2026
2c475af
chore(ci): install all package groups
celunah Jun 26, 2026
2247c3d
chore: batch fix actionable
celunah Jun 27, 2026
a7982cf
Merge branch 'dev' of https://github.com/celunah/celune into dev
celunah Jun 27, 2026
5102953
fix: unexpected auth, VC sounds bad in Gradio
celunah Jun 27, 2026
152b850
feat: let Celune choose specified input/output audio devices, and fix…
celunah Jun 27, 2026
0dabc2f
fix: don't pitch shift twice
celunah Jun 27, 2026
71a415e
refactor: refactor UI/core to be startable without models in test mode
celunah Jun 28, 2026
0e341f3
Merge branch 'dev' of https://github.com/celunah/celune into dev
celunah Jun 28, 2026
35e31fb
feat: make VC buttons auto-hide when not in use
celunah Jun 28, 2026
4ee7271
chore: fixed some more edge cases
celunah Jun 28, 2026
078f667
fix: pipeline optimizations
celunah Jun 29, 2026
f9c7455
chore: fixed both actionable comments
celunah Jun 29, 2026
9ec2ec8
fix: move SeedVC checkpoints into shared app cache
celunah Jun 29, 2026
8712ffc
Merge branch 'dev' of https://github.com/celunah/celune into dev
celunah Jun 29, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ jobs:
uses: astral-sh/setup-uv@v7

- name: Sync dependencies
run: uv sync --dev
run: uv sync --dev --all-extras

- name: Verify formatting
run: uv run ruff format --check .
Expand Down
20 changes: 15 additions & 5 deletions AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,15 +73,15 @@ Do not modify the execution environment to work around failures.

Before CI, format the repository with `uv run ruff format .`.

Expected CI runtime is 3-5 minutes.
Expected CI runtime is around 5 minutes.

If CI runtime exceeds 5 minutes:
- Assume it may have stalled.
- Stop it from running any further.
- Report that the CI has taken too long.
- Do not try to extend any timeouts.
- Do not try to work around the problem.
- Wait for any further guidance.
- Attempt to run again only the relevant CI steps in isolation.
- If the isolated CI attempts also fail or time out, report it back.

After each task, run `scripts/update_docstrings.py` and then replace placeholders in docstrings like:

Expand All @@ -100,15 +100,25 @@ Returns:

with proper documentation, while preserving the docstring format.

If this process updates typing or dataclass related docstrings, remove the placeholders instead of completing them.

This process may leave some formatting inaccuracies, run `uv run ruff format .` again after completing docstrings.

If CI fails or times out, report the actual failure clearly. Do not claim success.
## Localization

Celune does not use hardcoded strings in English. Define each new string you add into Celune's localization string database.

Do not use raw string literals in the code. Always use `string("key_name", **kwargs)` in string literals to populate them from the global localization string database.

If you find any raw strings in the code, add them to the localization string database, and remove the hardcoded string.

Make sure to only modify user-facing strings (both normal and dev mode strings), don't change anything internal.

## Python and Environment

* Supported Python versions are 3.12 and 3.13.
* Use `uv` for environment management.
* Do not use `pip` directly unless explicitly required.
* Do not use `pip` directly unless explicitly required. If you need to run `pip` alone, do it so with `uv pip` instead.
* Do not assume CPU-only mode supports all features. CPU-only execution is only supported with Celune Mini.
* Be aware that many features require an RTX 30 series GPU or newer.

Expand Down
27 changes: 27 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -331,6 +331,33 @@ Without this, Celune may require elevated permissions or fall back to slower beh
See [API.md](./API.md) for REST API configuration, authentication, endpoints, and cURL examples.
The API allows programmatic usage of all Celune features. It can be used both as a public and local interface.

## Extensions

Celune comes with extension support, allowing custom code to run with the engine.

Extensions may subscribe at will to certain core events with `@celune.subscribe(...)`.

Celune exposes the following core events to extensions:

- `ready`
- `shutdown`
- `fatal`
- `error`
- `voice_changed`
- `state_changed`
- `generation_start`
- `generation_end`
- `generation_error`
- `audio_start`
- `audio_end`
- `character_changed`
- `character_loaded`
- `character_unloaded`

For example extension usage, check the [example extension](./extensions/test.py).

The aforementioned extension defines a basic usage case for Celune extensions.

## Web UI

Celune exposes a web interface for remote access to Celune. It reuses the Celune API commands to provide an interface for control.
Expand Down
25 changes: 22 additions & 3 deletions celune/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,21 @@
import sys as _sys
import inspect as _inspect
import subprocess as _subprocess
from typing import TYPE_CHECKING, Union
from typing import TYPE_CHECKING, Callable, Union

from .constants import APP_NAME
from .paths import (
configure_huggingface_cache_environment,
configure_huggingface_runtime,
)

configure_huggingface_cache_environment()
configure_huggingface_runtime()

if TYPE_CHECKING:
from .celune import Celune
from .extensions.base import CeluneContext, CeluneExtension
from .extensions.events import subscribe


def _get_revision() -> str:
Expand Down Expand Up @@ -60,7 +68,7 @@ def _caller_is_repl() -> bool:


REVISION = _get_revision()
VERSION = "4.1.2"
VERSION = "4.2.0"

if REVISION:
_local = REVISION.rstrip("*")
Expand All @@ -84,7 +92,12 @@ def _caller_is_repl() -> bool:

def __getattr__(
name: str,
) -> Union[type["Celune"], type["CeluneContext"], type["CeluneExtension"]]:
) -> Union[
type["Celune"],
type["CeluneContext"],
type["CeluneExtension"],
Callable[..., Callable[..., None]],
]:
if name == "Celune":
from .celune import Celune

Expand All @@ -100,6 +113,11 @@ def __getattr__(

return CeluneExtension

if name == "subscribe":
from .extensions.events import subscribe

return subscribe

raise AttributeError(f"module '{__name__!r}' has no attribute '{name!r}'")


Expand All @@ -108,6 +126,7 @@ def __getattr__(
"CeluneContext",
"CeluneExtension",
"REVISION",
"subscribe",
"__version__",
"__tagline__",
"__codename__",
Expand Down
9 changes: 8 additions & 1 deletion celune/analysis.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,11 @@
from transformers import AutoModel, AutoProcessor

from .cevoice import ManifestValue, default_loader
from .constants import VOICE_EMBEDDING_MODEL, N_A_NUMERIC
from .constants import (
VOICE_EMBEDDING_MODEL,
N_A_NUMERIC,
remote_code_model_revision,
)
from .typing.analysis import (
EmbeddingPayload,
EmbeddingModel,
Expand Down Expand Up @@ -318,18 +322,21 @@ def _load_embedding_model() -> tuple[EmbeddingProcessor, EmbeddingModel]:
global _EMBEDDING_MODEL, _EMBEDDING_PROCESSOR

if _EMBEDDING_MODEL is None or _EMBEDDING_PROCESSOR is None:
revision = remote_code_model_revision(VOICE_EMBEDDING_MODEL)
_EMBEDDING_PROCESSOR = cast(
EmbeddingProcessor,
AutoProcessor.from_pretrained(
VOICE_EMBEDDING_MODEL,
trust_remote_code=True,
revision=revision,
),
)
_EMBEDDING_MODEL = cast(
EmbeddingModel,
AutoModel.from_pretrained(
VOICE_EMBEDDING_MODEL,
trust_remote_code=True,
revision=revision,
),
)
_EMBEDDING_MODEL.eval()
Expand Down
Loading
Loading