фикс неправильного создания модели ответа
This commit is contained in:
parent
69f67a7f42
commit
394249f3c7
3 changed files with 4 additions and 1 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
|
@ -1,4 +1,5 @@
|
||||||
.idea/
|
.idea/
|
||||||
|
workspace/
|
||||||
|
|
||||||
# Byte-compiled / optimized / DLL files
|
# Byte-compiled / optimized / DLL files
|
||||||
__pycache__/
|
__pycache__/
|
||||||
|
|
|
||||||
|
|
@ -13,6 +13,8 @@ services:
|
||||||
build:
|
build:
|
||||||
context: .
|
context: .
|
||||||
target: development
|
target: development
|
||||||
|
tags:
|
||||||
|
- mrkan0/lambda-agent:dev
|
||||||
additional_contexts:
|
additional_contexts:
|
||||||
agent_api: ${AGENT_API_PATH}
|
agent_api: ${AGENT_API_PATH}
|
||||||
volumes:
|
volumes:
|
||||||
|
|
|
||||||
|
|
@ -40,5 +40,5 @@ async def process_message(ws: WebSocket, msg, agent_service: AgentService):
|
||||||
match msg:
|
match msg:
|
||||||
case MsgUserMessage():
|
case MsgUserMessage():
|
||||||
async for chunk in agent_service.astream(msg.text):
|
async for chunk in agent_service.astream(msg.text):
|
||||||
await ws.send_text(MsgEventTextChunk(text=chunk).model_dump_json())
|
await ws.send_text(chunk.model_dump_json())
|
||||||
await ws.send_text(MsgEventEnd(tokens_used=0).model_dump_json())
|
await ws.send_text(MsgEventEnd(tokens_used=0).model_dump_json())
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue