DEV Community

Cover image for Designing for developers means designing for LLMs too
Marcus Kohlberg for Encore

Posted on • Originally published at encore.dev

7 4 4 5 5

Designing for developers means designing for LLMs too

At Encore, we're passionate about making it easier to build great applications.

This is a constantly moving target, and as LLM powered tools quickly get more powerful, we're seeing more and more people use them to build Encore applications.

Stands to reason, we therefore need to ensure LLMs also have an easy time when building Encore applications.

The Challenge when you don't have 10 years of open-source projects for training data

Encore is a framework designed to streamline backend development, offering unique features and conventions. However, without having the luxury of 10 years+ of mass adoption and the open-source training data that comes with it, mainstream LLMs often struggled to:

  • Fully utilize Encore’s built-in features.
  • Adhere to framework-specific conventions.
  • Generate code that aligns with best practices for Encore applications.

This makes sense since Encore is a relatively new backend framework, so it's not surprising that LLMs aren't as good at Encore as they are at React for instance.
It's an important developer experience problem however, since developers are increasingly expecting to use LLMs to generate code.

Our Simple but Effective Solution

To address this, we created a tailored set of instructions specifically designed for LLMs. Here's how we approached the problem:

  1. Rewriting Documentation for LLMs:
    Using Claude from Anthropic, we rewrote our framework documentation and SDK reference following Anthropic’s guidelines for formatting instructions for LLMs. This ensured clarity and precision, making it easier for models to understand and apply Encore’s principles.

  2. Adding Conventions and Rules:
    Beyond basic documentation, we developed a set of conventions and general rules that LLMs can follow. These include coding standards, recommended practices, and specific tips for leveraging Encore’s unique features.

  3. Packaging the Instructions:
    The result was a comprehensive file of approximately 1,500 lines that encapsulates everything an LLM needs to know about building with Encore. This file can be added directly to your repository, giving your LLM tool automatic context about Encore.

For users of the Cursor IDE, simply renaming the file to .cursorrules enables automatic integration.

The Result — LLMs are now MUCH better at building Encore apps

We’re thrilled to share that the first set of LLM instructions for Encore.ts is now open source and available on GitHub.

This initial release has already shown a significant boost in LLM performance for generating Encore-compatible code. However, we’re not stopping here. We invite the community to share feedback and contribute through pull requests to help us refine and expand these instructions further.

We've also started working on instructions for Encore.go, and will release them soon.

By equipping LLMs with detailed guidance, we’ve bridged the gap between Encore’s powerful framework for building backends with declarative infrastructure and the growing potential of AI-powered development tools.
We’re excited to see how developers will use these enhanced capabilities to create even better Encore applications.

Explore the instructions and contribute at Encore’s GitHub. Let’s build the future of development together!

What's next

Beyond providing instructions, we're also working on tools LLM powered code generation for Encore.
If you're interested make sure to sign up for our newsletter below and follow us on Twitter for updates.

Image of AssemblyAI tool

Transforming Interviews into Publishable Stories with AssemblyAI

Insightview is a modern web application that streamlines the interview workflow for journalists. By leveraging AssemblyAI's LeMUR and Universal-2 technology, it transforms raw interview recordings into structured, actionable content, dramatically reducing the time from recording to publication.

Key Features:
🎥 Audio/video file upload with real-time preview
🗣️ Advanced transcription with speaker identification
⭐ Automatic highlight extraction of key moments
✍️ AI-powered article draft generation
📤 Export interview's subtitles in VTT format

Read full post

Top comments (0)

Billboard image

The Next Generation Developer Platform

Coherence is the first Platform-as-a-Service you can control. Unlike "black-box" platforms that are opinionated about the infra you can deploy, Coherence is powered by CNC, the open-source IaC framework, which offers limitless customization.

Learn more

👋 Kindness is contagious

Explore a sea of insights with this enlightening post, highly esteemed within the nurturing DEV Community. Coders of all stripes are invited to participate and contribute to our shared knowledge.

Expressing gratitude with a simple "thank you" can make a big impact. Leave your thanks in the comments!

On DEV, exchanging ideas smooths our way and strengthens our community bonds. Found this useful? A quick note of thanks to the author can mean a lot.

Okay