You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Instrument Jev calls from @langchain/typesafe as evaluate spans #24859
@langchain/typesafe (TypeSafeClassifier, a LangChain Runnable) calls Jev with fetch directly. It does not use @typesafe-ai/sdk, so our TypeSafe integration does not see these calls.
Our LangChain callback handler sees the run through handleChainStart. It records the run as an invoke_agent TypeSafeClassifier span (gen_ai.invoke_agent). This span has no request model, response model, token usage, questions or answers.
Expected
An evaluate <model> span (gen_ai.evaluate) with the same attributes as the TypeSafe integration (packages/server-utils/src/ai/typesafe/): gen_ai.input.messages (state + questions), gen_ai.output.messages (answers), request/response model and token usage.
Notes
Package: @langchain/typesafe 0.0.1, peer @langchain/core ^1.0.0. Default model jev-latest, endpoint POST {baseUrl}/v1/systemone.
Possible approach: detect TypeSafeClassifier in handleChainStart (lc_namespace is langchain/classifiers/typesafe) and reuse the TypeSafe attribute helpers (getEvaluationInputMessages, addResponseAttributes). The chain outputs are the parsed response.
Activity
linear-code commentedon Sep 30, 2026
JS-3853
feat(server-utils): Record LangChain TypeSafeClassifier runs as gen_a…
github-actions commentedon Oct 8, 2026
A PR closing this issue has just been released 🚀
This issue was referenced by PR #25120, which was included in the 11.6.0 release.