aboutsummaryrefslogtreecommitdiff
path: root/app/backends/audiocpp/__init__.py
blob: 3344eb5264da748dce17c02e19badcf83f1699fa (plain)
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
"""audio.cpp backend — setup wizard, server config, model management.

A package of focused modules behind one import surface: everything public
is re-exported here, so callers (the hub, the CLI, tests) keep using
``backends.audiocpp.<name>`` regardless of which module implements it.

Modules:
    constants   shared constants (backends, tasks, checkout location)
    catalog     the model_specs catalog + server.json building/selections
    models      install state on disk, missing-model guidance, downloads
    voices      reference-.wav transcription planning and execution
    configsync  app/converter/config.py + server.json port/backend sync
    build       checkout lifecycle: ggml patches, binary build, update,
                uninstall
    remote      querying a running server for its models/voices
    status      detect() for the hub's backend menu
    wizard      the TUI wizard and the CLI entry points
"""

from .constants import (
    AUDIOCPP_DIR_NAME,
    AUDIOCPP_GIT_URL,
    BACKENDS,
    DEFAULT_HOST,
    FALLBACK_PORT,
    PATCH_DIR,
    TASK_CLON,
    TASK_TTS,
    TASK_VDES,
)
from .catalog import (
    detect_backend,
    entry_model_path,
    is_clone_only_family,
    is_design_package,
    hosting_task,
    load_model_catalog,
    package_dir_options,
    sanitize_model_spec,
    build_model_entry,
    build_server_config,
    load_server_config,
    server_config_selections,
    rehost_clone_only_entries,
    request_options_families,
    supports_request_options,
    apply_entry_session_options,
)
from .models import (
    delete_model_files,
    hand_install_guidance,
    install_models,
    installed_model_entries,
    missing_model_entries,
    missing_model_install_guidance,
    model_install_hints,
    unused_installed_entries,
)
from .voices import (
    print_empty_transcript_warning,
    transcribe_wav_dir,
)
from .configsync import (
    config_port,
    update_config_api_url_port,
    update_server_backend,
    update_server_config_port,
)
from .build import (
    apply_ggml_patches,
    build_audiocpp,
    find_build_script,
    find_local_checkout,
    find_audiocpp_server_bin,
    uninstall,
    update,
)
from .prebuilt import (
    fetch_latest_release,
    install_prebuilt,
    installed_release,
    resolve_latest_tag,
    select_assets,
    synthesize_assets,
)
from .remote import fetch_server_models, fetch_server_voices
from .wizard import (
    build_parser,
    build_screen,
    main,
    run_tui,
    setup_screen,
)
from .status import detect

__all__ = [
    # constants
    "AUDIOCPP_DIR_NAME", "AUDIOCPP_GIT_URL", "BACKENDS", "DEFAULT_HOST",
    "FALLBACK_PORT", "PATCH_DIR", "TASK_TTS", "TASK_CLON", "TASK_VDES",
    # catalog
    "detect_backend", "load_model_catalog", "is_design_package",
    "is_clone_only_family", "hosting_task", "package_dir_options",
    "build_model_entry", "build_server_config",
    "load_server_config", "server_config_selections", "rehost_clone_only_entries",
    "request_options_families", "supports_request_options",
    "entry_model_path", "sanitize_model_spec", "apply_entry_session_options",
    # models
    "missing_model_entries", "installed_model_entries",
    "unused_installed_entries", "delete_model_files", "install_models",
    "hand_install_guidance", "missing_model_install_guidance",
    "model_install_hints",
    # voices
    "transcribe_wav_dir", "print_empty_transcript_warning",
    # configsync
    "config_port", "update_config_api_url_port",
    "update_server_config_port", "update_server_backend",
    # build
    "find_local_checkout", "find_audiocpp_server_bin", "find_build_script",
    "apply_ggml_patches", "build_audiocpp", "uninstall", "update",
    # prebuilt
    "fetch_latest_release", "install_prebuilt", "installed_release",
    "select_assets", "resolve_latest_tag", "synthesize_assets",
    # remote
    "fetch_server_models", "fetch_server_voices",
    # wizard / status
    "setup_screen", "build_screen", "run_tui", "build_parser", "detect",
    "main",
]