ff9d1ae1702cb699f503729034fedad11a59d16c
- Initialize self.ws to None and assign websocket connection in __aenter__ - Close client connection and reset ws to None in __aexit__ - Extend chat method signature with optional datasets parameter, defaulting to empty list - Pass datasets argument to underlying client.chat call - Fix close method to set self.ws to None instead of self.client
Yura LLM Client for Katya server
Part of project with as target replacing the native ollama protocol. This protocol supports streaming and is usable trough https and it is possible to directly attach a web client to the backend.
Install
pip install -e .
Build
make build
Command line usage
yura ws://[host]:[port]/[path]/
Python
import asyncio
from yura.client import AsyncClient
async def communicate():
client = AsyncClient("ws://[host]:[port]/[path]/")
async for response in client.chat("Your prompt"):
print(response)
asyncio.run(communicate())
Languages
Python
96.9%
Makefile
3.1%