Skip to content

Update a trace #3556

Answered by dosubot bot
saiprasath21 asked this question in Support
Oct 2, 2024 · 2 comments · 10 replies
Discussion options

You must be logged in to vote

Hey @saiprasath21! How can I assist you today? If you have any questions or need help with anything, feel free to ask.

Yes, you can update the metadata of a trace using the Python SDK if you have the trace_id. You can do this by using the trace.update() method or by directly specifying the trace_id when creating or updating a trace. Here is an example of how you can update a trace using the trace_id:

# option 2: via trace_id, trace is upserted on id
langfuse.trace(id=trace_id, metadata={"new_key": "new_value"})

This code snippet demonstrates how to update the metadata of a trace by specifying the trace_id and providing the new metadata as a JSON object [1].

To continue talking to Dosu, m…

Replies: 2 comments 10 replies

Comment options

You must be logged in to vote
8 replies
@iamheavymetalx7
Comment options

@iamheavymetalx7
Comment options

@marcklingen
Comment options

@pedroallenrevez
Comment options

@marcklingen
Comment options

Answer selected by marcklingen
Comment options

You must be logged in to vote
2 replies
@marcklingen
Comment options

@hassiebp
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
6 participants