n8n-io / n8n

Free and source-available fair-code licensed workflow automation tool. Easily automate tasks across different services.
https://n8n.io
Other
48.11k stars 7.44k forks source link

Token usage on Langchain nodes is no longer available in 1.40.0 #9294

Closed mprytoluk closed 5 months ago

mprytoluk commented 6 months ago

Bug Description

Token usage is no longer available at logs on Langchain nodes in 1.40.0. It was working up until at least 1.37.0.

1.37.0: image 1.40.0: image

Please note that the output on an added langchain callback on the llm is also empty:

1.37.0: image 1.40.0: image

To Reproduce

Use any LLM/Langchain related node and check the logs.

Expected behavior

There should be the token usage info on LLM/Langchain nodes logs.

Operating System

Ubuntu

n8n Version

1.40.0

Node.js Version

18.x

Database

SQLite (default)

Execution mode

main (default)

Joffcom commented 6 months ago

Hey @mprytoluk,

Thanks for the report, The team are looking into this now.

mprytoluk commented 6 months ago

Thank you for your reply @Joffcom. I can confirm the reported behavior for 1.37.0 is the same for 1.38.1, so it is still working on 1.38.1.

janober commented 5 months ago

Fix got released with n8n@1.42.0