Skip to main content

Deleting traces

Trace deletion permanently removes a set of traces from a project, together with everything Latitude derived from them. Use it when you need to erase specific data while keeping the rest of your telemetry, for example to honour a data processing agreement that requires deleting an end customer’s data within 30 days of off-boarding. Deletion is independent of your plan’s retention period. Traces are deleted when you ask, not when retention expires.
Deletion cannot be undone. Preview a selection before deleting it.

Make your data deletable

You select traces to delete the same way you filter them in the trace list. Plan for deletion when you instrument your application, so every trace that belongs to one of your customers can be found later:
  • Tag traces with a stable customer key, such as customer:acme.
  • Or set metadata, such as customer_id, and select on metadata.customer_id.
  • Or keep one project per customer when their data should never mix.
userId and sessionId also work as selectors when they identify the data you need to erase.

What gets deleted

For every selected trace, Latitude deletes:
  • the trace and all of its spans, including prompts, completions and tool calls
  • scores and annotations on the trace, and their contribution to signals
  • the trace’s search index entries
  • message embeddings and agent memory content that only the deleted traces used
  • the analyses of the sessions the trace belongs to (conversation insights, topics and flagger results). They are recomputed from whatever remains of the session
Deleted traces disappear from Latitude immediately; removal from underlying storage completes in the background. Spans your application still sends for a deleted trace are discarded for 30 days afterwards, so a late span cannot bring the trace back. What is not deleted:
  • Dataset rows you copied from traces, unless you ask for them. A dataset row is your own copy, so it stays by default. Turn on Also delete dataset rows copied from these traces, or pass includeDatasetRows: true through the API, to delete every copy, including its earlier versions, from every dataset of the organization. Rows you created by hand or imported from a file are never matched.
  • Billing usage records. They count usage per trace and contain no trace content.
  • Aggregate counters, such as the number of signal occurrences per hour. They contain no trace content.
  • Exports you downloaded. Export files are your own copies; their download links expire on their own.
Only traces that started before you request the deletion are deleted. A deletion never removes traces your application sends afterwards, even if they match the same filter.

Delete traces

From the trace list

Organization owners and admins can delete traces from the trace list:
  1. Filter the list, then select the traces to delete, or select them all.
  2. Choose Delete and check the number of traces that will be deleted.
  3. Type delete traces to confirm.
You get a notification when the deletion finishes. Settings → Data deletion lists every deletion of the project with its receipt id, the number of traces and records deleted, and who requested it. A deletion of everything a text search matched isn’t possible, because the search can’t be reproduced as filters. Select the traces individually, or narrow the list with filters instead of a search.

With the API, SDKs or CLI

Each deletion is a background job. Request it, then poll it until its status is completed. The finished deletion records what was selected, who requested it, and how many traces and records were deleted; keep it as evidence of erasure.
To delete specific traces instead, pass up to 100 ids: { "by": "ids", "ids": ["<trace id>", ...] }. Larger selections should use a filter. A filter must contain at least one condition, and percentile conditions (gtePercentile) are not accepted, because they select relative to the data rather than a stable set of traces.
  • PII redaction keeps sensitive values out of Latitude in the first place.
  • GDPR covers Latitude’s data protection approach.