Skip to content

feat: add .cursor/rules/echo_rules.mdc to all echo-start templates#814

Open
baibaozhuanyong wants to merge 1 commit into
Merit-Systems:masterfrom
baibaozhuanyong:feat/add-cursor-rules
Open

feat: add .cursor/rules/echo_rules.mdc to all echo-start templates#814
baibaozhuanyong wants to merge 1 commit into
Merit-Systems:masterfrom
baibaozhuanyong:feat/add-cursor-rules

Conversation

@baibaozhuanyong
Copy link
Copy Markdown

What

Adds .cursor/rules/echo_rules.mdc to every echo-start template so Cursor (and other AI editors) understand Echo SDK patterns out of the box.

Why

When devs scaffold a project with pnpx echo-start, their AI coding assistant should immediately know:

  • Use Echo-wrapped providers, never raw @ai-sdk/openai etc.
  • How auth works (EchoProvider, EchoSignIn)
  • Which env vars to use
  • That Echo handles billing/metering

This prevents AI assistants from generating code that bypasses Echo or uses incorrect imports.

Templates covered

Template Rule focus
next Server handler + client providers
next-chat Streaming chat with useChat
next-image Same as next
next-video-template Same as next
nextjs-api-key-template Same as next
authjs Same as next
react Client-only SPA with Vite
react-chat Same as react
react-image Same as react
assistant-ui Echo + Assistant UI
echo-cli Node.js CLI with EchoClient

Testing

Opened each template in Cursor and verified the rules load correctly in the rules panel.

Closes #636

Add Cursor AI rules files to each template so that AI coding assistants
understand Echo SDK conventions when working within generated projects.

Each rules file is tailored to the template type:
- Next.js templates: server/client separation, createEchoNextHandler
- React SPA templates: EchoProvider, useEchoModelProviders
- Chat templates: useChat, streaming, EchoChatProvider
- CLI template: EchoClient, ApiKeyTokenProvider
- Assistant UI template: Echo + Assistant UI integration

Closes Merit-Systems#636
@vercel
Copy link
Copy Markdown
Contributor

vercel Bot commented May 14, 2026

@baibaozhuanyong is attempting to deploy a commit to the Merit Systems Team on Vercel.

A member of the Team first needs to authorize it.

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.

Add .cursor/rules/echo_rules.mdc to echo-start templates

1 participant