Skip to content

docs: add image for secure remote experiment triggers and update documentation for request signing - #3458

Open
marliessophie wants to merge 1 commit into
mainfrom
feat-add-img-changelog-remote-runs
Open

docs: add image for secure remote experiment triggers and update documentation for request signing#3458
marliessophie wants to merge 1 commit into
mainfrom
feat-add-img-changelog-remote-runs

Conversation

@marliessophie

@marliessophie marliessophie commented Aug 3, 2026

Copy link
Copy Markdown
Member

Greptile Summary

This PR adds social-preview artwork for the secure remote experiment trigger changelog and refreshes the experiment setup screenshot and signing guidance.

  • Adds an ogImage to the changelog entry.
  • Documents optional request signing, custom headers, and asynchronous trigger handling.
  • Improves the setup screenshot’s alternative text.

Confidence Score: 4/5

The PR appears safe to merge, with a non-blocking documentation gap around obtaining the experiment trigger signing secret.

The image and metadata changes follow established repository conventions, while the signing guidance should explicitly identify where users retrieve or regenerate the secret required for verification.

Files Needing Attention: content/docs/evaluation/experiments/experiments-via-sdk.mdx

Prompt To Fix All With AI
### Issue 1
content/docs/evaluation/experiments/experiments-via-sdk.mdx:674
**Clarify signing secret retrieval**

The new guidance explains how to enable request signing but not where to retrieve or regenerate the experiment trigger's signing secret. Users can implement the linked HMAC algorithm yet configure the wrong secret, resulting in rejected trigger requests or verification being disabled.

---

For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.

Reviews (1): Last reviewed commit: "docs: add image for secure remote experi..." | Re-trigger Greptile

Context used (3)

@dosubot dosubot Bot added the size:XS This PR changes 0-9 lines, ignoring generated files. label Aug 3, 2026
@vercel

vercel Bot commented Aug 3, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
langfuse-docs Ready Ready Preview Aug 3, 2026 11:58am

Request Review

@dosubot dosubot Bot added the docs label Aug 3, 2026
@github-actions

github-actions Bot commented Aug 3, 2026

Copy link
Copy Markdown

@claude review

@claude claude Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM — approving despite the minor nit flagged inline (portrait OG image), since it's a cosmetic social-preview issue only and doesn't affect the doc content or build.

Extended reasoning...

Overview

This is a small, purely additive docs PR: it adds an ogImage frontmatter field to a changelog entry, updates an image alt-text description in the SDK experiments doc, and adds a new PNG asset (which is a copy of an existing docs screenshot). No code, config, or logic is touched.

Security risks

None. This is static content (Markdown/MDX frontmatter and an image alt attribute) with no user input, auth, or executable code involved.

Level of scrutiny

Low. This falls squarely into 'simple, mechanical, self-contained content change' — the only functional addition is a frontmatter key consumed by the existing, unmodified buildOgImageUrl logic in lib/og-url.ts. The one issue found (reusing a portrait screenshot as a landscape OG card) is a cosmetic nit that affects only the social-share preview image, not page rendering, links, or build correctness.

Other factors

No CODEOWNER-sensitive paths are touched, no outstanding review comments are unaddressed, and this is my first review pass on this PR. The bug-hunting system's two other candidate issues (hover-preview crop, header stretching) were investigated and ruled out, leaving only the one nit-level OG image concern, which doesn't warrant blocking approval.

description: Authenticate remote experiment trigger requests with signed and custom headers.
author: Marlies
canonical: /docs/evaluation/experiments/experiments-via-sdk#optional-trigger-sdk-experiment-from-ui
ogImage: /images/changelog/2026-07-28-secure-remote-experiment-triggers.png

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 The new ogImage for this changelog post reuses trigger-remote-experiment-2.png — a 1360x1786 portrait screenshot of the setup form — instead of a landscape social card. Every other changelog ogImage in the repo is ~16:9 landscape, and since lib/og-url.ts serves this image directly as the OG/Twitter preview (no compositing), the portrait screenshot will be heavily cropped to an unreadable state when the post is shared on Twitter/LinkedIn. Consider using a dedicated landscape OG card image instead.

Extended reasoning...

What's happening: content/changelog/2026-07-28-secure-remote-experiment-triggers.mdx sets ogImage: /images/changelog/2026-07-28-secure-remote-experiment-triggers.png. That new file is byte-identical (same md5, 41a0323edb41c0e9292420610ab4f681) to public/images/docs/trigger-remote-experiment-2.png, which is a 1360x1786 portrait screenshot of the trigger setup form used in the docs page. Every other ogImage sampled across the changelog collection is landscape and close to the standard 1.91:1 social-card ratio (e.g. 3308x1860, 2786x1567, 1567x882, 956x538). This one is the only portrait outlier.\n\nCode path: lib/mdx-page.ts passes the frontmatter ogImage value as staticOgImage into buildOgImageUrl() in lib/og-url.ts. When a static image is provided, that function returns BASE_URL + staticOgImage verbatim — there's no server-side compositing into a landscape /api/og card the way there is for changelog posts without an explicit ogImage. That URL is then set directly as both openGraph.images and twitter.images in the page metadata. So the raw 1360x1786 PNG is exactly what gets fetched by Twitter, LinkedIn, Slack, etc. as the link preview.\n\nWhy nothing catches this today: there's no lint/CI check on OG image aspect ratio, and the build only verifies the file exists and links resolve — not that the referenced image is a sensible shape for its usage context. The docs page usage (the Frame in experiments-via-sdk.mdx) is a perfectly fine home for this portrait screenshot; it's only the changelog ogImage reuse that's mismatched.\n\nConcrete proof of impact: (1) Confirmed via file(1) that public/images/changelog/2026-07-28-secure-remote-experiment-triggers.png reports 1360 x 1786. (2) Confirmed via md5sum that it is byte-identical to public/images/docs/trigger-remote-experiment-2.png. (3) Sampled ~14 other changelog ogImage files (e.g. 2025-06-30-histogram-charts.png = 3186x1976, 2026-07-10-boolean-score-filters.png = 956x538, 2026-05-28-code-evaluators.png = 1024x576) — all landscape. (4) Social platforms crop OG/Twitter card images to roughly a 1.91:1 landscape box; a 1360x1786 portrait image cropped to that ratio keeps only the vertical middle band (~712px tall out of 1786px), cutting off the top and bottom of the setup form screenshot and likely rendering the preview illegible. Separately, ChangelogHeader.tsx also renders this same ogImage inline at a fixed width=1200, so the tall portrait image will additionally appear stretched/oversized in the changelog page header itself, not just in social previews.\n\nSuggested fix: generate or crop a dedicated landscape (e.g. 1200x630 or similar) OG card image for this changelog entry rather than reusing the doc's portrait screenshot, or omit ogImage entirely and let the default /api/og card compositing handle it as other changelog posts without a custom image do.\n\nSeverity: this is purely a social-share-preview and changelog-header cosmetic issue — the page renders correctly, all links resolve, and the build succeeds. Nothing functionally breaks, so this is a nit rather than a blocking issue.

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

Labels

docs size:XS This PR changes 0-9 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant