Skip to content

Replace agent directive snippet with per-page directive in docs.yml#4751

Open
devin-ai-integration[bot] wants to merge 1 commit intomainfrom
devin/1775239640-remove-agent-directive-snippet
Open

Replace agent directive snippet with per-page directive in docs.yml#4751
devin-ai-integration[bot] wants to merge 1 commit intomainfrom
devin/1775239640-remove-agent-directive-snippet

Conversation

@devin-ai-integration
Copy link
Copy Markdown
Contributor

Summary

Migrates the agent directive from a manually-included snippet (<Markdown src="/snippets/agent-directive.mdx"/>) to the new agents.page-directive setting in docs.yml. This means the directive text is now injected automatically by the docs engine on every page, eliminating the need to include it in each file individually.

Changes:

  • fern/docs.yml: Added agents.page-directive with the directive text previously in the snippet
  • 315 MDX files: Removed <Markdown src="/snippets/agent-directive.mdx"/> line
  • fern/snippets/agent-directive.mdx: Deleted
  • AGENTS.md: Updated "New pages" section to reflect that the directive is now automatic

Review & Testing Checklist for Human

  • Verify agents.page-directive is a supported and deployed feature — if the docs engine doesn't process this key yet, all pages lose their agent directive with no replacement. Check that a deployed preview still serves the directive text when fetching a page as Markdown (append .md to any page URL).
  • Spot-check the directive text in docs.yml matches the original snippet content exactly (the text: "For clean Markdown content of this page, append .md to this URL...")
  • Confirm snippet-only files still render correctly — files like fern/products/sdks/snippets/basic-auth-params.mdx also had the snippet removed. Verify these transcluded snippets don't need their own directive.

Notes

  • The removal leaves double blank lines in most files (where the snippet line sat between two blank lines). This is cosmetic and doesn't affect rendering.

Link to Devin session: https://app.devin.ai/sessions/cca428aa2de14fe390a4361c2a6ac8d2

- Remove <Markdown src="/snippets/agent-directive.mdx"/> from all 315 files
- Add agents.page-directive to docs.yml with the snippet text
- Delete the agent-directive.mdx snippet file
- Update AGENTS.md to reflect the new approach

Co-Authored-By: bot_apk <apk@cognition.ai>
@devin-ai-integration
Copy link
Copy Markdown
Contributor Author

🤖 Devin AI Engineer

I'll be helping with this pull request! Here's what you should know:

✅ I will automatically:

  • Address comments on this PR. Add '(aside)' to your comment to have me ignore it.
  • Look at CI failures and help fix them

Note: I can only respond to comments from users who have write access to this repository.

⚙️ Control Options:

  • Disable automatic comment and CI monitoring

@devin-ai-integration devin-ai-integration bot requested a review from devalog as a code owner April 3, 2026 18:09
@fern-api
Copy link
Copy Markdown
Contributor

fern-api bot commented Apr 3, 2026

Requested by: devin
Slack thread: View conversation

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants