Skip to content

[Agent Lee] Refresh overview, complete rename, document access controls - #33648

Merged
kale-stew merged 2 commits into
productionfrom
kylie/docs/agent-lee-audit
Sep 24, 2026
Merged

kale-stew merged 2 commits into
productionfrom
kylie/docs/agent-lee-audit

Conversation

@kale-stew

@kale-stew kale-stew commented Sep 24, 2026 •

Copy link
Copy Markdown
Member

what

Audit of the Agent Lee docs against the implementation (cloudflare-agent @ 7966d6f3, stratus). Three things: the overview had drifted since the beta page was written, the rename from "Cloudflare Agent" left the old name on user-facing surfaces, and the access/permission controls were entirely undocumented.

naming

The rename shipped in #29901 (2026-04-15) moved the page and added the redirect, but missed the entry points:

  • Rename ai/related-products/cloudflare-agent.mdx → agent-lee.mdx and retitle. It still read "Cloudflare Agent" and pointed at /cloudflare-agent/, so readers took a 301 to reach the page.
  • Point the RelatedProduct cards in ai/index.mdx and ai/related-products/index.mdx at /agent-lee/ with product="agent-lee". src/icons/agent-lee.svg was added by the rename but never wired up — both cards were still resolving the old icon name.
  • Delete src/icons/cloudflare-agent.svg: byte-identical to agent-lee.svg and now unreferenced.
  • Drop the stray products: browser-run from the related-products entry; every sibling lists ai alone.
  • Add "Agent Lee was previously referred to as Cloudflare Agent" to the overview so the old name stays searchable.

No new redirect needed. /cloudflare-agent/ → /agent-lee/ already exists (__redirects:2453), and src/content/docs/cloudflare-agent/ only ever contained index.mdx across the whole repo history, so there are no sub-routes to catch. I deliberately did not add a splat — it would mask genuine 404s on invented paths.

redirect fix

/workers/ai/ pointed at /agent-lee/, sending the legacy Workers AI URL to the dashboard assistant. It entered as /workers/ai/ → /cloudflare-agent/ in 377142dbda ("[Chore] tech cleanup", #29194) with no stated rationale, and the rename only retargeted it. src/content/docs/workers/ai/ has never existed in repo history, so this reads as a copy-paste of the wrong product. Retargeted to /workers-ai/.

Please sanity-check this one — if someone parked that URL on the assistant on purpose, say so and I will drop the hunk.

corrections to the overview

Was Reality
"only available to accounts on a Free plan" Available to accounts on a Free plan and to select Enterprise customers. Enterprise readers are pointed at their account team.
"does not currently reference previous conversation context" False since CFSA-1042 shipped list/search/get/summarize over your own conversations (agent.ts:2798-2812).
"cannot remember previous conversations: each session starts fresh" Same — removed.
retention "one year" from creation Measured from last activity, so an active conversation is not purged mid-use (agent.ts:5606-5615).
"renders inline charts directly in the chat panel" Only the artifact card renders inline. Everything else is a card that opens the full-screen view (Message.tsx:370-400).
"cannot replace Support for billing issues…" Softened — it flatly denied what the support-case handoff now does.

additions to the overview

All verified in the implementation, not the specs:

  • Undo a change (prepareRevert) — live in production per wrangler.jsonc:320.
  • Support case handoff — with mandatory confirmation, eligibility framed by support entitlement rather than plan name.
  • Dashboard page search, entitlement and plan-tier lookups, product skills, changelog-grounded answers.
  • AI Gateway in the "Built on Cloudflare" table; model requests route through it (model.ts:26-30).

new page: Manage access and permissions

agent-lee/manage-access documents controls that exist today and were completely undocumented: hiding the assistant, permission templates, custom scopes, when changes take effect, the admin write restriction, and auditing the tokens it holds.

Every claim was verified against the frontend, and several draft claims were corrected in the process:

  • Keyboard shortcuts are Cmd/Ctrl + / and the t a sequence (AuthenticatedApp.tsx:195, DashHotkeys/constants.ts:96-101).
  • Custom scopes are a curated list across eight categories, not per-product, and not the full API-token catalogue.
  • Four areas are hard-denied for write regardless of what you select — account settings, membership, billing, API tokens (api/token.ts DENIED_WRITE_PATTERNS). Worth stating plainly; it is a genuine safety guarantee.
  • The admin indicator reads "Write off", not "Write disabled by admin".
  • Permission changes apply on your next message in the same conversation — an earlier draft claimed the current conversation keeps the old permissions, which is wrong (agent.ts:3593-3599).

Deliberately not documented, because they are internal rather than customer-facing:

  • The account-wide disable API (CFSA-596) — no dashboard UI, gated on an internal Flagship flag.
  • Account write policies (CFSA-1044) — the only UI is the AX-team admin app behind a Cloudflare Access group gate.

one naming problem docs cannot fix

The dashboard preferences card is still labelled "Cloudflare Agent" (common.json:38) while the sidebar says "Agent Lee" (ai-agent-sidebar.json:107-108). The new page tells users to look for "Cloudflare Agent" because that is what is on screen, and calls out the discrepancy in a note. This needs a product-side string change to actually resolve — flagging for whoever owns those strings.

deliberately not documented

  • Decision rail — DECISION_RAIL_ENABLED: "false" in production (wrangler.jsonc:321).
  • Image attachments — still a draft spec, no inbound image path exists.

notes for reviewers

  • Earlier preview failures were unrelated to this PR, and a rebase fixed them. The build failed on /rules/custom-errors/api-calls (Operation GET /zones/{zone_identifier}/custom_pages/{identifier} not found in schema). The API schema changed, and [Rules] Update Custom Errors API paths to use zone_id #33645 updated that page, but this stack was based on an older production. Both branches are now rebased onto current production with no changes to their content. A local build:incremental against a freshly fetched schema passes (9,103 pages). Thanks to Brayden for the logs.
  • Everything in ci.yml passes locally on the failing tree: pnpm run check (0 errors), lint, format:check, bin/validate-redirects.ts, bin/check-component-docs.ts, test:prebuild (196 tests), full pnpm run build (9082 pages, link check clean), test:postbuild (23 tests).
  • Stacked on [Agent Lee] Document take-home code export #33647 (take-home code export). Both edit the Limitations list and Related resources in agent-lee/index.mdx, so this branch is based on that one. Merge [Agent Lee] Document take-home code export #33647 first. Until then this PR's diff also shows [Agent Lee] Document take-home code export #33647's commit; review only the two [Agent Lee] commits after it.
  • The new page describes some controls that are still rolling out. It says so, rather than implying universal availability.

@github-actions github-actions Bot added product:ai Workers AI: https://developers.cloudflare.com/workers-ai/ product:agent-lee Related to Agent Lee product labels Sep 24, 2026
@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Sep 24, 2026 •

Copy link
Copy Markdown

🚀 Deploying Preview to Cloudflare 🚀

Preview URL: https://kylie-docs-agent-lee-audit.previews.developers.cloudflare.com (commit 4facfbb)

This URL reflects your latest Preview deployment

Preview Deployments by commit

Status Deployment URL Commit Updated (UTC) See this deployment's details
  • Build: In progress 🔵

View logs ↗
5a97c1d 2026-09-24T18:32:49.645Z View logs ↗
  • Build: Success ✅
  • Deployment: Success ✅

View logs ↗
https://87de8975.previews.developers.cloudflare.com 4facfbb 2026-09-24T18:00:38.248Z Visit the dashboard ↗
  • Build: Failed ❌

View logs ↗
07c321d 2026-09-24T05:36:48.557Z View logs ↗
  • Build: Failed ❌

View logs ↗
3278f2e 2026-09-24T02:31:04.899Z View logs ↗

@cloudflare-docs-bot

cloudflare-docs-bot Bot commented Sep 24, 2026 •

Copy link
Copy Markdown
Contributor

AI Review

✅ Reviewed 5a97c1d · 2 findings · incremental

👉 Fix in your agent 👈
Fix the following review findings in PR #33648 (https://github.com/cloudflare/cloudflare-docs/pull/33648).

Before making changes, review each finding and present a brief summary table:
- For each finding, state whether you agree, disagree, or need clarification.
- If you disagree, explain why.
- If you need clarification before deciding, ask those questions.
- Then share your plan for which issues to tackle and in what order.

After triaging, follow this order:
1. Post a comment on this PR for any findings you are skipping, with the finding ID and your reasoning.
2. Then commit the fixes for the legitimate findings.

The comment must come before the commit because the next review reads PR comments.

## Style Guide
- S-1e7eda59 | src/content/docs/agent-lee/manage-access.mdx:53 | Replace `see [link]` with `refer to [link]`
  The line uses `see [Review the tokens Agent Lee holds](#review-the-tokens-agent-lee-holds)` before a link. Per the links style rule, `see [link]` must be replaced with `refer to [link]`.
- S-0f306257 | src/content/docs/agent-lee/manage-access.mdx:112 | Semicolon joins two independent clauses
  `Deleting the token the assistant is currently using revokes its access immediately; you are asked to grant permissions again...` joins two independent clauses with a semicolon. Per the writing style rule, break them into two sentences.

Style Guide

Skipped: no new docs content changes since the last review.

  • src/content/docs/agent-lee/manage-access.mdx:53 · Replace see [link] with refer to [link]

    The line uses see [Review the tokens Agent Lee holds](#review-the-tokens-agent-lee-holds) before a link. Per the links style rule, see [link] must be replaced with refer to [link].

  • src/content/docs/agent-lee/manage-access.mdx:112 · Semicolon joins two independent clauses

    Deleting the token the assistant is currently using revokes its access immediately; you are asked to grant permissions again... joins two independent clauses with a semicolon. Per the writing style rule, break them into two sentences.

Not reviewed (2)
  • src/content/docs/ai/related-products/cloudflare-agent.mdx — deleted file
  • src/icons/cloudflare-agent.svg — deleted file
Commands
  • /review Run a review now.
  • /full-review Review the entire PR diff.
  • /disable-auto-review Stop automatic reviews.
  • /rebase Rebase against production.

@kale-stew
kale-stew force-pushed the kylie/docs/agent-lee-audit branch from 3278f2e to 07c321d Compare September 24, 2026 05:28
@kale-stew
kale-stew force-pushed the kylie/docs/CFSA-903-take-home-code branch from a0ddba4 to eb926e8 Compare September 24, 2026 17:45
@kale-stew
kale-stew requested a review from a team as a code owner September 24, 2026 17:45
@kale-stew
kale-stew force-pushed the kylie/docs/agent-lee-audit branch from 07c321d to 4facfbb Compare September 24, 2026 17:45
Base automatically changed from kylie/docs/CFSA-903-take-home-code to production September 24, 2026 18:17
Audit of the Agent Lee docs against the implementation
(cloudflare-agent @ 7966d6f3). The overview had drifted since the beta
page was written, and the rename from "Cloudflare Agent" left the old
name on user-facing surfaces.

Naming:

- Rename ai/related-products/cloudflare-agent.mdx to agent-lee.mdx and
  retitle it. It still read "Cloudflare Agent" and pointed at
  /cloudflare-agent/, taking readers through a 301 to reach the page.
- Point the RelatedProduct cards in ai/index.mdx and
  ai/related-products/index.mdx at /agent-lee/ with product="agent-lee".
  src/icons/agent-lee.svg was added by the rename but never wired up, so
  both cards were still resolving the old icon name.
- Delete src/icons/cloudflare-agent.svg, byte-identical to agent-lee.svg
  and now unreferenced.
- Drop the stray products: browser-run from the related-products entry;
  every sibling lists ai alone.
- Note the former name on the overview so searches for "Cloudflare Agent"
  still land. The /cloudflare-agent/ 301 already covers the old URL and
  that path never had sub-routes, so no new redirect is needed.

Redirect fix:

- /workers/ai/ pointed at /agent-lee/, sending the legacy Workers AI URL
  to the dashboard assistant. It entered as /workers/ai/ ->
  /cloudflare-agent/ in 377142d ("[Chore] tech cleanup", #29194) with
  no stated rationale, and the rename only retargeted it.
  src/content/docs/workers/ai/ has never existed in repo history, so this
  reads as a copy-paste of the wrong product. Retargeted to /workers-ai/.

Corrections:

- Availability was "only available to accounts on a Free plan". There is
  no plan gate in the implementation; it is Free plus select Enterprise.
  Points Enterprise readers at their account team.
- "Does not currently reference previous conversation context" and
  "cannot remember previous conversations" are both false since CFSA-1042
  shipped list/search/get/summarize over your own conversations, ungated.
- Retention is measured from last activity, not creation, so an active
  conversation is not purged mid-use (agent.ts:5609-5619).
- Generative UI said charts render inline in the chat panel. Only the
  artifact card does; everything else is a card that opens the
  full-screen view.
- Softened the support limitation, which flatly denied what the
  support-case handoff now does.

Additions, all verified in the implementation:

- Undo a change (prepareRevert), live in production per
  wrangler.jsonc:320.
- Support case handoff, with confirmation and eligibility framed by
  support entitlement rather than plan name.
- Dashboard page search, entitlement and plan-tier lookups, product
  skills and changelog-grounded answers.
- AI Gateway in the "Built on Cloudflare" table; model requests go
  through it (model.ts:26-30).

Deliberately not documented: the decision rail, which is disabled in
production (DECISION_RAIL_ENABLED false, wrangler.jsonc:321), and image
attachments, which are still a draft spec with no inbound image path.
Adds agent-lee/manage-access, covering controls that exist today and
were completely undocumented: hiding the assistant, permission
templates, custom scopes, when permission changes take effect, the
admin write restriction, and auditing the API tokens Agent Lee holds.
Links it from the overview's write-operations section and related
resources.

Verified against stratus and cloudflare-agent rather than carried over
from an earlier draft. Corrections made while verifying:

- Shortcuts are Cmd//Ctrl+/ and the `t` `a` sequence
  (AuthenticatedApp.tsx:195, DashHotkeys/constants.ts:96-101). The
  draft listed only the first and only for macOS.
- Custom scopes are a curated list across eight categories with
  independent read/write toggles, not per-product, and not the full
  API-token catalogue.
- Four areas are hard-denied for write regardless of selection:
  account settings, membership, billing, API tokens
  (api/token.ts DENIED_WRITE_PATTERNS).
- The admin indicator reads "Write off" with a tooltip, not "Write
  disabled by admin".
- Permission changes apply on the next message in the same
  conversation (agent.ts:3593-3599). The draft claimed the current
  conversation keeps the old permissions, which is wrong.

Wording chosen to stay true in the failure cases:

- Opt-out "attempts to delete" the API token rather than guaranteeing
  revocation, because the client path is fire-and-forget and can no-op
  when the token id read is stale (useLeeEnabledSetting.ts:217-223).
- Permission changes say both tokens "may exist briefly" rather than
  claiming atomic replacement; the flow creates the new token before
  revoking the old (PermissionStore.ts:523-539).
- Both cases point the reader at My Profile > API Tokens, which is the
  reliable way to confirm access is gone.

Not documented, because they are internal rather than customer-facing:
the account-wide disable API (CFSA-596, no dashboard UI, internal
Flagship flag) and account write policies (CFSA-1044, AX-team-only
admin app behind Cloudflare Access).

The preferences card is still labelled "Cloudflare Agent" in the
dashboard (common.json:38) while the sidebar says "Agent Lee". The page
uses the on-screen label so readers can find the control, and notes the
discrepancy. Resolving it needs a product-side string change.
@kale-stew
kale-stew force-pushed the kylie/docs/agent-lee-audit branch from 4facfbb to 5a97c1d Compare September 24, 2026 18:20
@github-actions

Copy link
Copy Markdown
Contributor

This PR changes current filenames or deletes current files. Make sure you have redirects set up to cover the following paths:

  • /ai/related-products/cloudflare-agent/

@kale-stew
kale-stew enabled auto-merge (squash) September 24, 2026 18:33
@kale-stew
kale-stew merged commit 0ac6439 into production Sep 24, 2026
14 of 15 checks passed
@kale-stew
kale-stew deleted the kylie/docs/agent-lee-audit branch September 24, 2026 18:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

product:agent-lee Related to Agent Lee product product:ai Workers AI: https://developers.cloudflare.com/workers-ai/ size/m

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants