langchain-ai / langsmith-cookbook

https://langsmith-cookbook.vercel.app
785 stars 149 forks source link

My traces aren't showing up in langsmith #248

Closed ojipadeson closed 4 months ago

ojipadeson commented 5 months ago

I added environment variables to my code:

os.environ["LANGCHAIN_TRACING_V2"] = "true"
os.environ["LANGCHAIN_API_KEY"] = "<my_api>"
os.environ["LANGCHAIN_ENDPOINT"] = "https://api.smith.langchain.com"
unique_id = uuid4().hex[0:8]
os.environ["LANGCHAIN_PROJECT"] = f"Tracing Walkthrough - {unique_id}"

However, the results of the program are not visible on Langsmith

I'm running a langchain example of the open-source model qwen

Is there something I'm missing?

hinthornw commented 5 months ago

Could you share a code snippet of what you run after setting the environment to show what you expect to be traced that isn't?

One thing we do not do is aggressively patch any model API you import - it has to either be a langchain object or something that's marked as being traced by the langsmith SDK (e.g., @traceable, trace(), or one of the wrappers like wrap_openai())

hinthornw commented 4 months ago

Seems like this is resolved?