Agents 1.6.9
Edge AI Agents SDK
Loading...
Searching...
No Matches
agents::runtime::ComponentSpec Struct Reference

Specification for a supervised component. More...

#include <service_supervisor.h>

Static Public Member Functions

static ComponentSpec standard (std::string name, bool allow_spawn=true)
 Convention-based spec for an EdgeAI-installer service ("stt" or "tts").

Public Attributes

std::string name
 "stt" | "tts"
std::string url
 probed URL, e.g. http://127.0.0.1:8888/
std::string health_path = "health"
 appended to url
std::filesystem::path binary
 ~/.edgeai/bin/edgeai-<name>
std::vector< std::string > args
 extra argv passed to spawned child
std::filesystem::path log_dir
 ~/.edgeai/logs/
std::filesystem::path run_dir
 ~/.edgeai/run/ (lock files)
std::string launchd_label
 "ai.runedge.stt"
std::string systemd_unit
 "edgeai-stt.service"
std::chrono::milliseconds startup_timeout {15000}
 timeout to startup
std::chrono::milliseconds probe_timeout {1000}
 per-probe; httplib granularity is seconds
bool allow_spawn = true
 Hannah's –no-spawn flips this.

Detailed Description

Specification for a supervised component.

Hannah builds one of these per dependency (stt, tts) and hands it to ServiceSupervisor::ensure(). All paths are absolute.

Member Function Documentation

◆ standard()

ComponentSpec agents::runtime::ComponentSpec::standard ( std::string name,
bool allow_spawn = true )
static

Convention-based spec for an EdgeAI-installer service ("stt" or "tts").

Fills binary/log_dir/run_dir/launchd_label/systemd_unit from the installer convention rooted at runtime::edgeAiDir() (i.e. $EDGEAI_DIR or $HOME/.edgeai). URL defaults to http://127.0.0.1:<port>/ where port is 8888 for stt and 9999 for tts; override with $EDGEAI_<NAME_UPPER>_URL for dev against a non-default port.

Returned value is mutable — tweak any field after construction if you need to deviate from the defaults.