Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions hugo/content/en/llm_observability/instrument/api.md
Original file line number Diff line number Diff line change
Expand Up @@ -255,6 +255,8 @@ An image on a message. Provide either `content` or `attachment_key`.
| query_variable_keys | [string] | Variable keys that contain the user query. Used for hallucination detection. |
| context_variable_keys | [string] | Variable keys that contain ground-truth or context content. Used for hallucination detection. |
| tags | Dict[key (string), string] | Tags to attach to the prompt run. |
| prompt_uuid | string | No, unless linking to Prompt Management. The prompt's UUID from [Prompt Management][6]. Required for the span to link back to its Prompt Management registry entry. |
| prompt_version_uuid | string | The specific prompt version's UUID from [Prompt Management][6]. |

{{% /tab %}}
{{% tab "Example" %}}
Expand All @@ -279,6 +281,8 @@ An image on a message. Provide either `content` or `attachment_key`.
{{% /tab %}}
{{< /tabs >}}

**Note**: If your prompt comes from the [Prompt Management][6] registry (for example, fetched through the Prompt Management REST API in a language without a native Agent Observability SDK), include the `prompt_uuid` (and `prompt_version_uuid`, if available) returned by the API alongside `id` and `version`. Without `prompt_uuid`, the span's prompt metadata is tracked but does not link back to the registry entry in the Prompts view.

#### Meta
| Field | Type | Description |
|-------------|-------------------|--------------|
Expand Down Expand Up @@ -704,3 +708,4 @@ For feedback events, provide exactly one of `span_id`, `trace_id`, `session_id`,
[3]: /getting_started/tagging/
[4]: /llm_observability/investigate/evaluations/end_user_feedback
[5]: /llm_observability/instrument/sdk/?tab=python#enriching-spans
[6]: /llm_observability/configure/prompt_management
Original file line number Diff line number Diff line change
Expand Up @@ -89,10 +89,14 @@ The following fields are supported in the prompt tracking JSON:
| `id` | string | No | Unique identifier for the prompt. Defaults to `{ml_app}_unnamed-prompt` if omitted |
| `name` | string | No | Prompt name. Used as a fallback for `id` if `id` is omitted |
| `version` | string | No | User-supplied version tag |
| `prompt_uuid` | string | No, unless linking to Prompt Management | The prompt's UUID from [Prompt Management][8]. Required for the span to link back to its Prompt Management registry entry |
| `prompt_version_uuid` | string | No | The specific prompt version's UUID from [Prompt Management][8] |
| `variables` | object | No | Template variable substitutions |
| `rag_context_variables` | array of strings | No | Names of variables in `variables` that contain RAG context (ground truth). Used by RAG evaluators |
| `rag_query_variables` | array of strings | No | Names of variables in `variables` that contain the user query. Used by RAG evaluators |

**Note**: If your prompt comes from the [Prompt Management][8] registry (for example, fetched through the Prompt Management REST API in a language without a native Agent Observability SDK), include the `prompt_uuid` (and `prompt_version_uuid`, if available) returned by the API alongside `id` and `version`. Without `prompt_uuid`, the span's prompt metadata is tracked but does not link back to the registry entry in the Prompts view.

<div class="alert alert-info">If you are using prompt templates, Agent Observability can automatically attach version information based on prompt content.</div>

### With LangChain templates
Expand Down
Loading