Skip to content

docs agent readiness: Vary on Markdown negotiation, /developers and company redirects, JSON-LD descriptions, allow /retrieve - #1058

Open
warp-agent-staging[bot] wants to merge 7 commits into
mainfrom
factory/ar-20261111-2-docs-agent-readiness
Open

warp-agent-staging[bot] wants to merge 7 commits into
mainfrom
factory/ar-20261111-2-docs-agent-readiness

Conversation

@warp-agent-staging

@warp-agent-staging warp-agent-staging Bot commented Nov 18, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Re-cut on current main (Nov 25). Main now negotiates Markdown in routing middleware, so this PR no longer adds its own rewrites. It bundles five small, independently verified changes that let agents find what they look for on docs.warp.dev:

  1. Vary: Accept on Markdown negotiation. src/lib/markdown-negotiation.js adds Vary: Accept to both the rewrite-to-.md response and the pass-through HTML response on eligible doc paths (not assets, .md, llms*.txt or /retrieve). Production today serves either variant at the same URL with no Vary, so a shared cache can hand one client the other's variant.
  2. /developers and /developer → /factories/api-and-sdk/ (308). They 404 today. /developers/cli is unchanged. This replaces AR-20261118-1/-2: /developers redirect and /auth.md for agents #1057, minus its /auth.md: ora now treats docs oauth-support as not applicable, and that file would make it count again (modelled −0.67).
  3. /pricing, /about, /contact → the www.warp.dev pages (308), plus About / Pricing / Contact / Privacy links in the docs footer. All three paths 404 on docs today.
  4. Organization and WebSite JSON-LD descriptions. The Organization description is word for word the one on www.warp.dev's Organization node. The WebSite description reuses the docs llms.txt summary. The go.warp.dev/join-preview signup link is removed from sameAs. This replaces EXP-4: complete docs Organization and WebSite JSON-LD #883.
  5. robots.txt: Allow: /retrieve? llms.txt tells agents to prefer GET /retrieve?q=…, but Disallow: /*?*q=* blocks it for every user agent, including robots-honouring fetchers such as Claude-User. The longer Allow rule wins under RFC 9309, and page query strings stay disallowed. /retrieve also sends X-Robots-Tag: noindex, so its JSON stays out of search indexes.

Prediction (what this should move)

  • ora docs.warp.dev canonical score: 71 → 78 on the first production scan after deploy. Each change is modelled from today's audit payload: developer-portal 0→5/5 (+3.70), pricing-info 0→3/3 (+2.22), json-ld 1→2/2 (+0.74), trust-anchors 0.5→1 (+0.37), markdown-negotiation-vary 0→1 (+0.17). The prediction is falsified if the score is below 75.
  • robots change: Claude-surfaced docs answers should rise slightly within 4 weeks. This is judged in a later run with Peec.

Verification

  • Preview ora vs production, check by check (npx @ora-ai/ax@0.5 audit, scans 649379 vs 647963):

    Check Preview Production
    developer-portal 5/5 0/5
    pricing-info 3/3 0/3
    json-ld 2/2 1/2
    trust-anchors 1/1 0.5/1
    markdown-negotiation-vary 1/1 0/1

    No check regressed. The preview's canonical score is lower for host-only reasons: noindex and brand/registry checks.

  • Preview curl results:

    • Accept: text/markdown and Accept: text/html on /, /quickstart/ and /agents/ both return vary: Accept, so Vercel forwards the middleware header.
    • All new redirects return one 308 in both slash forms, and /developers/cli still goes to the Oz CLI page.
    • /retrieve?q=hello returns 200 JSON with X-Robots-Tag: noindex.
  • Tests: scripts/agent-discovery.test.mjs (redirects, plus a robots evaluator that fails on main's robots.txt), scripts/markdown-negotiation.test.mjs (Vary on eligible paths only) and scripts/validate-homepage-json-ld.mjs. Node tests pass 14/14 locally, and build, link-check and editorial CI pass.

  • Review: an independent review checked the final tree; its one non-blocking robots nit (prefix vs endpoint) is fixed in 2599a95.

Experiment ids: AR-20261125-1 (bundle), AR-20261125-2 (robots). Supersedes AR-20261111-2, AR-20261118-1 and EXP-4.

…nks, /pricing /about /contact redirects, Markdown negotiation)

Re-applied on current main from the 2026-11-11 patch; not yet re-verified.

Co-Authored-By: Warp <agent@warp.dev>
@warp-agent-staging

Copy link
Copy Markdown
Contributor Author

This PR was generated with Warp.

Comment @warp-staging-factory on this PR to send it follow-up work.

@warp-agent-staging warp-agent-staging Bot added the factory:aeo-factory Label associated to the "aeo-factory" factory label Nov 18, 2026
@cla-bot cla-bot Bot added the cla-signed label Nov 18, 2026
@vercel

vercel Bot commented Nov 18, 2026 •

Copy link
Copy Markdown

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

Project Deployment Actions Updated
docs Ready Ready Preview Nov 25, 2026 4:27pm UTC

Request Review

The built-config test in scripts/markdown-negotiation.test.mjs only runs when
.vercel/output/config.json exists, so the step runs after npm run build.

Co-Authored-By: Warp <agent@warp.dev>
warp-agent-staging Bot added a commit that referenced this pull request Nov 18, 2026
Both PRs used to replace the same postbuild value, so merging the second one
would conflict and could silently drop a route writer. Both branches now carry
the same postbuild line and the same scripts/run-route-writers.mjs, which runs
each writer present in the checkout.

Co-Authored-By: Warp <agent@warp.dev>
Both PRs used to replace the same postbuild value, so merging the second one
would conflict and could silently drop a route writer. Both branches now carry
the same postbuild line and the same scripts/run-route-writers.mjs, which runs
each writer present in the checkout.

Co-Authored-By: Warp <agent@warp.dev>
@warp-agent-staging

Copy link
Copy Markdown
Contributor Author

Review follow-up (route-writer composition): this PR and #1058 both used to replace the same postbuild value, so whichever merged second would conflict and could silently drop a route writer. Both branches now carry an identical postbuild (node scripts/build-tracking-middleware.mjs && node scripts/run-route-writers.mjs) and an identical scripts/run-route-writers.mjs that runs each writer present in the checkout.

Verified locally by merging main + #989 + #1058 (no conflicts) and running npm run build: build-markdown-negotiation-routes: 421 twins, 12 routes and build-markdown-canonical-routes: 421 twins, 6 header routes. All 18 generated routes sit before handle: filesystem (index 21 of 24).

Posted by a Warp agent

@warp-agent-staging

Copy link
Copy Markdown
Contributor Author

Verification completed for 7de4396 (3 ahead / 0 behind main). This remains a draft; no human reviewer was requested.

  • CI: green, 10 successful / 2 skipped / 0 failing / 0 pending. Build, link-check, audit; editorial quality; technical references; CodeQL actions/javascript-typescript/python + aggregate; Vercel; Preview Comments; CLA passed. Agent docs review and Request engineering review skipped. CI run.
  • CI passed npm run typecheck (0 errors), npm run test:heading-vars (5/5), npm run build, npm run test:heading-tocs, npm run test:homepage-json-ld, and the newly wired npm run test:markdown-negotiation (7/7, 0 skipped). Postbuild generated 421 twins / 12 negotiation routes through the shared route-writer runner.
  • Final preview: curl -sS -D - -H 'Accept: text/markdown' "$P/" and "$P/agents/" return 200 text/markdown + Vary: Accept; HTML Accept on / remains 200 text/html + Vary. /pricing and /about/ are 308 to the correct www.warp.dev resources. /llms.txt contains the when-to-use section. Bodies have the existing production-consistent blockquote preamble, then H1.
  • npx -y @ora-ai/ax@0.5 audit <URL> --json: final treatment 57 (scan608506), AR-20261009-12: match Codex guide to installation intent #888 control 56 (scan608393), production 71 (scan608332), contract1.42.0. Complete scans; control/production cached. Treatment/control deltas: pricing0→3/3, trust0.5→1/1, negotiation0→1/1. Agent-instruction stays0.67/1: ora selects the /agents.md page twin, not the new llms.txt guidance. Other differences are OAuth N/A→fail0/5 and scoped-permissions N/A→warning2/5; no auth code changed.
  • Both previews send X-Robots-Tag:noindex, so production canonical non-regression cannot be established from absolute preview scores. The PR now predicts production71→73–74 (+2–3) on the first postdeploy audit, not a gain from agent-instruction. Structural checks show the intended improvements without a targeted regression.
  • AFDocs overlap and the AR-20261104-2: canonical Link headers and frontmatter for docs Markdown twins #989-compatible shared runner are documented in the PR. No local checkout or visual screenshot run was performed in this HTTP/API-only verification task; postdeploy measurement and human review remain.

Posted by a Warp agent

… workflow infrastructure

- The Accept condition (routes and vercel.json rewrites) now matches text/markdown
  only with no q or q > 0, so `text/markdown;q=0` and `*/*` get HTML. Tests cover
  q=0, wildcard-only, and positive-q headers, and pin vercel.json to the same value.
- llms.txt: "setting up a software factory that routes work through triage,
  planning, implementation, and review" instead of "a team of agents".

Co-Authored-By: Warp <agent@warp.dev>
@warp-agent-staging

Copy link
Copy Markdown
Contributor Author

Review-fix verification passed at 82ef712 (4 ahead / 0 behind main).

Vercel router acceptance matrix: on both / and /agents/, text/markdown and text/markdown;q=0.5 return 200 text/markdown; text/html, text/markdown;q=0, */*, and text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8 return 200 text/html. All ten responses include Vary: Accept. The deployed lookahead-free regex therefore honors zero-quality refusal as well as positive-quality requests.

Exact probe: curl -sS --max-time 30 -D <headers-file> -o <body-file> -H 'Accept: <header>' 'https://docs-15umtrokv-warpdotdev.vercel.app<path>'. The extensionless /agents/capabilities/skills with Markdown Accept also returns 200 text/markdown + Vary: Accept. Plain HTML Accept on / remains HTML; pricing/about redirects remain correct308. Bodies were inspected, not just headers.

The preview llms.txt now says: “Warp Factories: setting up a software factory that routes work through triage, planning, implementation, and review.”

CI: 10 successful / 2 skipped / 0 failing / 0 pending, including the run retriggered by the ready-for-review transition. Build/link/audit, editorial, technical references, all CodeQL analyses/aggregate, Vercel/Preview Comments, and CLA pass. Agent docs review and Request engineering review skip. npm run test:markdown-negotiation: 9/9 pass, 0 skips, including the new Accept matching regressions and built-config test. CI evidence.

Repeated npx -y @ora-ai/ax@0.5 audit https://docs-15umtrokv-warpdotdev.vercel.app --json: complete scan608569, contract1.42.0, canonical57; targeted pricing3/3, trust1/1, negotiation1/1, instruction unchanged0.67/1. The documented noindex/control/production caveats and predicted production71→73–74 remain unchanged.

The PR body is refreshed. I did not change readiness state or request reviewers.

Posted by a Warp agent

Main now negotiates Markdown in routing middleware, so this branch drops its own
vercel.json rewrites and route writer and instead adds Vary: Accept to main's
middleware for eligible doc paths. Folds in the /developers redirect (from #1057,
without /auth.md: ora now treats docs oauth-support as not applicable) and the
Organization/WebSite descriptions (from #883). Keeps the /pricing, /about,
/contact 308s to www and the footer company links.
llms.txt tells agents to prefer GET /retrieve?q=..., but robots.txt's
Disallow: /*?*q=* matched it for every user agent, including robots-honouring
user fetchers such as Claude-User. Allow: /retrieve is the longer rule, so it
wins under RFC 9309; page query strings stay disallowed. /retrieve also sends
X-Robots-Tag: noindex so search engines don't index its JSON.
Review follow-up: Allow: /retrieve was a prefix rule that would also exempt
any future /retrieve... path with a q parameter. '?' is literal in robots.txt,
so Allow: /retrieve? exempts only queries to the endpoint itself.
@warp-agent-staging warp-agent-staging Bot changed the title AR-20261111-2: docs agent readiness — llms when-to-use, company links, /pricing redirect, Markdown negotiation docs agent readiness: Vary on Markdown negotiation, /developers and company redirects, JSON-LD descriptions, allow /retrieve Nov 25, 2026
@warp-agent-staging
warp-agent-staging Bot requested review from dannyneira and rachaelrenk and removed request for vikvang November 25, 2026 16:24
@warp-agent-staging

Copy link
Copy Markdown
Contributor Author

Gate summary (2026-11-25, 2599a95): all checks are green, including CodeQL. The earlier CodeQL failures were GitHub results-upload errors. An independent review raised one non-blocking nit (the robots exception should cover the endpoint only), fixed in 2599a95. The preview ora audit shows all five targeted checks passing with no regressions; see the table in the description. Ready for an owner's review: @dannyneira for the middleware and /retrieve change, @rachaelrenk for robots.txt.

Posted by a Warp agent

This branch was successfully deployed

1 active deployment
Preview — 2599a959 Deployed Nov 25, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cla-signed factory:aeo-factory Label associated to the "aeo-factory" factory

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants