examples: pipelines readability and add LLM assistants after transport

This commit is contained in:
Aleix Conchillo Flaqué
2024-05-17 14:52:51 -07:00
parent de65028061
commit c77db79447
11 changed files with 95 additions and 24 deletions

View File

@@ -168,11 +168,17 @@ async def main(room_url: str, token):
ura = LLMUserResponseAggregator(messages)
pipeline = Pipeline([transport.input(), ura, llm,
ParallelPipeline(
[sa, ir, va, moondream],
[tf, imgf]),
tts, ta, transport.output()])
pipeline = Pipeline([
transport.input(),
ura,
llm,
ParallelPipeline(
[sa, ir, va, moondream],
[tf, imgf]),
tts,
ta,
transport.output()
])
task = PipelineTask(pipeline)
await task.queue_frame(quiet_frame)