Merged in develop (pull request #59)
Fix speaking self._conf["slides"]["avatar"] giving 'list indices must be integers or slices, not str'
This commit is contained in:
@@ -35,14 +35,14 @@ class ELAI(IVideoGeneratorService):
|
|||||||
voice_provider = self._avatars[avatar].get("voice_provider")
|
voice_provider = self._avatars[avatar].get("voice_provider")
|
||||||
|
|
||||||
self._conf["slides"][0]["canvas"]["objects"][0]["src"] = avatar_url
|
self._conf["slides"][0]["canvas"]["objects"][0]["src"] = avatar_url
|
||||||
self._conf["slides"]["avatar"] = {
|
self._conf["slides"][0]["avatar"] = {
|
||||||
"code": avatar_code,
|
"code": avatar_code,
|
||||||
"gender": avatar_gender,
|
"gender": avatar_gender,
|
||||||
"canvas": avatar_canvas
|
"canvas": avatar_canvas
|
||||||
}
|
}
|
||||||
self._conf["slides"]["speech"] = text
|
self._conf["slides"][0]["speech"] = text
|
||||||
self._conf["slides"]["voice"] = voice_id
|
self._conf["slides"][0]["voice"] = voice_id
|
||||||
self._conf["slides"]["voiceProvider"] = voice_provider
|
self._conf["slides"][0]["voiceProvider"] = voice_provider
|
||||||
|
|
||||||
response = await self._http_client.post(self._ELAI_ENDPOINT, headers=self._POST_HEADER, json=self._conf)
|
response = await self._http_client.post(self._ELAI_ENDPOINT, headers=self._POST_HEADER, json=self._conf)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user