mirror of
https://github.com/BoardWare-Genius/jarvis-models.git
synced 2025-12-13 16:53:24 +00:00
Blackbox MeloTTS created
This commit is contained in:
@ -31,10 +31,10 @@ class Configuration():
|
||||
if cfg is None:
|
||||
cfg = self.cfg
|
||||
return self.get(path.split("."), cfg)
|
||||
lenght = len(path)
|
||||
if lenght == 0 or not isinstance(cfg, dict):
|
||||
length = len(path)
|
||||
if length == 0 or not isinstance(cfg, dict):
|
||||
return None
|
||||
if lenght == 1:
|
||||
if length == 1:
|
||||
return cfg.get(path[0])
|
||||
return self.get(path[1:], cfg.get(path[0]))
|
||||
|
||||
@ -43,5 +43,13 @@ class TesouConf():
|
||||
url: str
|
||||
|
||||
@inject
|
||||
def __init__(self,config: Configuration) -> None:
|
||||
def __init__(self, config: Configuration) -> None:
|
||||
self.url = config.get("tesou.url")
|
||||
|
||||
|
||||
class MeloConf():
|
||||
melotts: str
|
||||
|
||||
@inject
|
||||
def __init__(self, config: Configuration) -> None:
|
||||
self.melotts = config.get("melotts.url")
|
||||
|
||||
Reference in New Issue
Block a user