Skip to content

Document relevance_ai.request_id field in streaming events (TSP-1428) - #798

Open
claude[bot] wants to merge 1 commit into
mainfrom
docs/TSP-1428
Open

claude[bot] wants to merge 1 commit into
mainfrom
docs/TSP-1428

Conversation

@claude

@claude claude Bot commented Sep 1, 2026

Copy link
Copy Markdown

Summary

  • Added relevance_ai.request_id to the Logs base attributes table
  • Added relevance_ai.request_id to the Traces base attributes table
  • Updated the agent_deleted example log record JSON to include the field with a sample value
  • Added a new "Correlating API responses to OTEL records" section between the Logs and Traces sections, explaining how customers can use the x-request-id response header to filter their S3/Databricks exports to the exact OTEL records produced by a specific API call, with an AWS Athena SQL example

Context

Both OTEL streams (logs and traces) now carry relevance_ai.request_id, which matches the x-request-id header returned by the Relevance AI API on every response. This enables customers to link API calls to the OTEL records they produce — useful for debugging specific invocations, correlating application logs with OTEL records, compliance audits, and troubleshooting.

Feature implemented in relevanceai/relevance-api#17392.

Linear: https://linear.app/relevance/issue/TSP-1428/

🤖 Generated with Claude Code

Add relevance_ai.request_id to the base attributes tables for both logs
and traces, update the agent_deleted example JSON to include the field,
and add a new "Correlating API responses to OTEL records" section that
explains how to use the x-request-id response header to trace API calls
through to their corresponding OTEL records in S3 exports.

Implements field added in relevanceai/relevance-api#17392.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@claude claude Bot added the docs-drafter Documentation drafted by Claude label Sep 1, 2026
@mintlify

mintlify Bot commented Sep 1, 2026

Copy link
Copy Markdown
Contributor

Preview deployment for your docs. Learn more about Mintlify Previews.

Project Status Preview Updated (UTC)
relevanceai 🟢 Ready View Preview Sep 1, 2026, 4:36 AM

💡 Tip: Enable Workflows to automatically generate PRs for you.

@linear

linear Bot commented Sep 1, 2026

Copy link
Copy Markdown

TSP-1428

@github-actions

github-actions Bot commented Sep 1, 2026

Copy link
Copy Markdown
Contributor

🎯 Vibe check

Reviewed: 1 file (1 with issues, 0 clean)

Scores

Dimension Score What's holding it back
🟡 Consistency 7/10 Heading case error at line 88 (PII RedactionPII redaction). Bold text used as section titles in two places (lines 100–108 and 189–197), violating the "use proper headings" rule in CLAUDE.md.
🟢 Technical clarity 9/10 "Presidio-powered ML engine" (line 111) is dropped without explanation — most enterprise buyers won't know what Presidio is. Everything else is sharp.
🟡 Non-technical clarity 8/10 Three consecutive <Note> callouts at the top of the page (lines 24–28) create a heavy read before the intro is done. The PII section's bold-label layering (lines 100–108) fragments what could read as flowing prose.
🟡 Structure 8/10 <CardGroup> is used for 10 all-caps PII entity-type identifiers (lines 120–131) — these are reference constants, not navigable features. Two hollow section headings (### Supported events, ### Supported spans) have no body text and exist only as labels.

Score key: 🟢 9–10, 🟡 6–8, 🔴 1–5.

Overall vibe: Solid technical reference documentation — well-organized, migration warnings are specific and actionable, and the SQL example is exactly the kind of practical detail enterprise readers need. The issues are all surface-level: a capitalization slip, a couple of bold-as-heading antipatterns, and a CardGroup that trades scannability for visual flair in a context where scannability is the point.

🔧 Issues (4)
  • enterprise/streaming-events.mdx:88## PII Redaction (Enterprise feature) → sentence case: ## PII redaction (Enterprise feature). "Redaction" is not a proper noun. Note the inconsistency: the body text at lines 90 and 94 already correctly uses lowercase "redaction", but the heading doesn't match.

  • enterprise/streaming-events.mdx:100,108**1. Structured fields (always scrubbed automatically)** and **2. Unstructured text (scrubbed when PII redaction is enabled for your org)** are acting as section titles. CLAUDE.md says don't mix bold text with heading formats for section titles — use a proper heading. These should be #### headings.

  • enterprise/streaming-events.mdx:111 — "a Presidio-powered ML engine" — "Presidio" is jargon dropped cold with no explanation. Enterprise buyers evaluating PII redaction will want to know what this is. Add a brief descriptor: "a Presidio-powered ML engine" or "an ML engine (Microsoft Presidio)".

  • enterprise/streaming-events.mdx:189,192,197**Format**:, **File path pattern**:, and **Event types**: in the Delivery format section are functioning as mini-section labels. These should be #### headings for consistency with the rest of the page's heading hierarchy.

🧩 Component suggestions (3)
  • enterprise/streaming-events.mdx:24–28 — Three consecutive <Note> callouts appear before any substantive intro content has been delivered. The notes cover three distinct topics: PII redaction (a sales prompt), S3-only limitation, and retention control. The S3 limitation note (line 26) is genuinely useful up front; consider moving the retention-control note (line 28) to the Setup section where it's most relevant, and folding the PII redaction note into the dedicated PII Redaction section below — it already has one there (line 94).

  • enterprise/streaming-events.mdx:120–131<CardGroup> is used to display 10 PII entity type identifiers (e.g. EMAIL_ADDRESS, PHONE_NUMBER). These are reference constants that readers need to scan and match against their configuration — not navigable options or feature benefits. A markdown table with columns for entity type and icon would be faster to scan and easier to copy-paste from:

    | Entity type | Description |
    |-------------|-------------|
    | `EMAIL_ADDRESS` | Email addresses |
    | `PHONE_NUMBER` | Phone numbers |
    ...

    Or even a flat inline code list in prose. The CardGroup adds visual weight without helping the reader find what they need.

  • enterprise/streaming-events.mdx:162<Warning>There is currently no self-serve UI to toggle PII redaction...<Warning> implies something could go wrong or cause harm. An operational limitation ("contact your Account Manager") is informational, not a risk. Use <Note> instead.

🏗️ Page structure (1)
  • enterprise/streaming-events.mdx:247–249 and 507–509### Supported events and ### Supported spans are hollow section headings with no body content between them and the next ### sub-heading. They exist only as labels, which adds a heading level with no payoff. Either remove them and let the sub-headings (### Agent events, ### \invoke_agent``, etc.) stand on their own, or add a one-sentence orientation ("The following event types are emitted as log records...") so the heading earns its place.
✅ Clean files (0)

No files were entirely clean — the one reviewed file has the issues listed above.

🔋 Credit usage
Item Count
Files reviewed 1
Context pages read 2
Total lines processed ~1,182

Files read: enterprise/streaming-events.mdx (627 lines), enterprise/data-retention.mdx (389 lines), enterprise/analytics.mdx (166 lines)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

docs-drafter Documentation drafted by Claude

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant