langfuse generation spans with token usage; switch llm to vllm (qwen2.5-coder-7b on mcrndeb)
This commit is contained in:
@@ -128,7 +128,7 @@ async def _synthesize_node(state: RunState) -> dict[str, Any]:
|
||||
for f in findings
|
||||
)
|
||||
|
||||
with lf.span("synthesize", as_type="generation", input={"findings": len(findings)}) as span:
|
||||
with lf.span("synthesize", input={"findings": len(findings)}) as span:
|
||||
answer = chat(
|
||||
system=load("synthesize.system"),
|
||||
user=render(
|
||||
@@ -137,6 +137,7 @@ async def _synthesize_node(state: RunState) -> dict[str, Any]:
|
||||
findings_block=findings_block,
|
||||
),
|
||||
max_tokens=512,
|
||||
span_name="synthesize.gen",
|
||||
)
|
||||
span.update(output={"answer": answer})
|
||||
return {"answer": answer}
|
||||
|
||||
Reference in New Issue
Block a user