tmc / langchaingo

LangChain for Go, the easiest way to write LLM-based programs in Go
https://tmc.github.io/langchaingo/
MIT License
4.14k stars 578 forks source link

tracing: Implement Langsmith tracing handler #724

Open tmc opened 5 months ago

tmc commented 5 months ago

We should have a callback handler that supports sending tracing data to LangSmith

Refs #652

silver-chard commented 3 months ago

In the process of implementing LangSmith’s handler, I encountered some issues.

For Python, enabling LangSmith in LangChain is a seamless action that only requires an environment variable. However, for langchaingo, it’s not as easy. Currently, I haven’t found a place to globally control the invocation of various models. Developers can bypass llms and directly call a specific model’s methods, from New to Call. This way, there is no place to inject this handler.