Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix example code #68

Merged
merged 2 commits into from
May 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -38,10 +38,10 @@ Example
async def main():
async with Client() as client:
audio_query = await client.create_audio_query(
"こんにちは!", style_id=1
"こんにちは!", speaker=1
)
with open("voice.wav", "wb") as f:
f.write(await audio_query.synthesis(style_id=1))
f.write(await audio_query.synthesis(speaker=1))


if __name__ == "__main__":
Expand Down
3 changes: 3 additions & 0 deletions vvclient/http.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,3 +61,6 @@ async def core_versions(self) -> List[str]:

async def initialize_speaker(self, params: Dict[str, Union[str, int]]) -> None:
return await self.request(Route("POST", "/initialize_speaker"), params=params)

async def is_initialized_speaker(self, params: Dict[str, Union[str, int]) -> bool:
return await self.request(Route("GET", "/is_initialized_speaker"), params=params)
Loading