fix prototype backend review issues
This commit is contained in:
parent
94bdb44b93
commit
37643a9695
9 changed files with 182 additions and 46 deletions
|
|
@ -4,8 +4,6 @@ from dataclasses import dataclass
|
|||
from typing import AsyncIterator
|
||||
from urllib.parse import parse_qsl, urlencode, urlsplit, urlunsplit
|
||||
|
||||
import aiohttp
|
||||
|
||||
from sdk.interface import MessageChunk, MessageResponse, PlatformError
|
||||
|
||||
|
||||
|
|
@ -41,6 +39,8 @@ class AgentSessionClient:
|
|||
)
|
||||
|
||||
async def stream_message(self, *, thread_key: str, text: str) -> AsyncIterator[MessageChunk]:
|
||||
import aiohttp
|
||||
|
||||
async with aiohttp.ClientSession() as session:
|
||||
async with session.ws_connect(
|
||||
self._ws_url(thread_key),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue