MCPcopy Create free account
hub / github.com/0xShug0/audio.cpp / models_json

Method models_json

app/server/runtime.cpp:740–758  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

738 voice.speaker->audio = minitts::cli::read_audio_buffer(resolve_path(request_base_, value->as_string()));
739 has_voice = true;
740 }
741 if (const auto * value = body.find("reference_text")) {
742 request.options["reference_text"] = value->as_string();
743 }
744 if (has_voice) {
745 request.voice = std::move(voice);
746 }
747 return request;
748}
749
750struct ServerState::TimedTaskResult {
751 engine::runtime::TaskResult result;
752 double wall_ms = 0.0;
753 std::optional<double> ttft_ms;
754};
755
756ServerState::TimedTaskResult ServerState::run_model(
757 LoadedModel & model,
758 const engine::runtime::TaskRequest & request) {
759 std::lock_guard<std::mutex> lock(model.mutex);
760 ensure_model_loaded_locked(model);
761 if (model.offline == nullptr) {

Callers

nothing calls this directly

Calls 4

strMethod · 0.80
json_quoteFunction · 0.70
to_stringFunction · 0.50
sizeMethod · 0.45

Tested by

no test coverage detected