AI Engineer World's Fair 2025
Design like Karpathy is watching 😎
Read the talk
Design like Karpathy is watching
MenuGen turned restaurant menus into food illustrations, but getting it deployed exposed a harder problem: making APIs, documentation, and onboarding work for developers using AI assistants.
From a talk by Zeke Sikelianos
Before you start: Basic familiarity with HTTP APIs, JSON, and AI coding assistants will help; OpenAPI and MCP are explained as they appear.
Put current instructions into the assistant’s context
The first repair is to make documentation easy to consume as text. Sikelianos points to llms.txt and Markdown versions of documentation as ways to supply useful material without the surrounding HTML interface. The linked proposal has since evolved; the approach demonstrated here is straightforward text delivery. Karpathy’s preference, as quoted in the talk, is a single Markdown document and a copy button over elaborate documentation-page presentation.
Replicate responded by adding several routes from a model page into an assistant’s context:
- Copy Markdown: take the page’s instructions into the tool where the work is happening.
- Open in Claude: start a conversation with Claude about the model and its capabilities.
- Open in ChatGPT: use ChatGPT to explore the model interactively.
These routes turn documentation from a page the user must search into material an assistant can discuss with them.
The same Markdown also serves implementation. A developer using Cursor or Windsurf can put the model’s documentation into the editor so the assistant has current instructions for running it. This addresses the stale-knowledge problem directly: the relevant usage information enters the current conversation instead of depending entirely on what the model learned during training.
Suggest correction
This note stays in this page until you copy or download it. Nothing is submitted; reloading clears the draft.
Make the operational contract easy to read
Text documentation becomes especially useful when it includes a complete request. Sikelianos quotes Karpathy: “LLMs don't like to click, they like to curl.” The appeal of curl is its familiarity and independence from a specialized client interface. A request may look syntactically busy, but it puts the details needed to call a service in one place.
| Request detail | What the example communicates |
|---|---|
| Endpoint and HTTP method | Where to send the request and which operation to invoke |
| JSON payload | Which inputs the operation expects |
| Credentials | How to authenticate |
| Response type | What representation to request |
| Blocking or asynchronous behavior | Whether to wait or handle completion separately |
Together, these details make an example a compact operational contract. An assistant can use it to construct a request without reconstructing the interface from scattered descriptions.
Cog applies the same idea to model development. It packages machine-learning models in Docker containers and gives them standardized inputs and outputs described through OpenAPI. Replicate collected Cog’s documentation into a single llms.txt file so an editor could bring the relevant instructions into context.
The workflow starts with an unfamiliar project:
- Clone an existing open-source Cog model.
- Open the project in an AI-assisted editor.
- Reference Cog’s
llms.txtdocumentation. - Ask the editor to use that context while changing the model’s code.
The documentation supplies framework knowledge alongside the project being edited. This leads to Sikelianos’s central design thesis: treat the LLM as a primary audience for your product, service, or library. The human still has the goal, but an assistant increasingly reads the instructions and performs the integration work.
Suggest correction
This note stays in this page until you copy or download it. Nothing is submitted; reloading clears the draft.
Use one API description for documentation and tools
To explain MCP, Sikelianos first establishes what OpenAPI contributes. An OpenAPI document describes an HTTP API in JSON or YAML. It includes paths, operations, query parameters, request bodies, and responses; it is more than a JSON Schema for an individual payload. For Replicate, that description covers tasks such as creating predictions, retrieving predictions, and searching for models.
Replicate’s human-facing HTTP API reference is generated from that description. A template renders the structured definition into a page a developer can read. The public-model search example shows the result: documentation organized around an endpoint, its description, and an example request.
The same investment supports assistant-facing tools. Sikelianos introduces Model Context Protocol through Replicate’s approach of turning its OpenAPI description into capabilities an assistant can use. That conversion is an implementation strategy, not the definition of MCP itself: MCP standardizes communication for tools and context through JSON-RPC. OpenAPI describes the HTTP service; the MCP integration makes service operations available to the assistant.
The demonstrated Replicate MCP setup uses Claude Desktop’s developer settings, a JSON configuration, and a Replicate API token. Sikelianos describes the local server setup as handled through that client workflow. This is a historical desktop demonstration; current documentation distinguishes local installation from hosted remote connections, so it should not be read as a universal promise of installation-free setup. Once connected, Claude can issue authenticated Replicate API requests.
That connection supports several related activities:
- Discovery: ask what the service can do before knowing its interface.
- Search: have the assistant find relevant models.
- Project scaffolding: use those capabilities while assembling the beginning of an application.
The foundation is a well-documented, comprehensive OpenAPI description. Sikelianos emphasizes that this existing investment made exposing Replicate’s capabilities through MCP much easier. He names Claude, GitHub Copilot, Visual Studio Code, and the OpenAI Agents SDK as integration contexts in the expanding tool ecosystem.
Suggest correction
This note stays in this page until you copy or download it. Nothing is submitted; reloading clears the draft.
Let legitimate users get to work
Documentation and tool access do not help if the service blocks a legitimate customer. Returning to MenuGen, Sikelianos describes Karpathy registering for an API key, entering credit-card details, and then generating many images of French toast. In Sikelianos’s account, an approximately one-hour-old account sending 1,000 requests triggered an abuse mechanism and was blocked. Those numbers describe the incident as he recounts it, not a published rate-limit threshold.
Replicate’s CEO saw the public criticism and intervened to unblock the account, according to Sikelianos. That resolved one user’s problem, but most users cannot rely on a widely read blog post to get access restored. A product needs an ordinary path for legitimate users who arrive ready to do substantial work.
Sikelianos proposes prepaid credit as one such path: a user should be able to commit money up front and then use the service intensively. His $500 example illustrates that intent; it is not an announced price or a guarantee of unrestricted usage. He describes the change as work in progress. From there, he turns to another completion criterion: shipping a feature cannot end at merging its pull request.
Suggest correction
This note stays in this page until you copy or download it. Nothing is submitted; reloading clears the draft.
Document features and keep responses useful
Documentation is part of shipping. A feature needs published instructions that users can discover and an assistant can consume and put to work. Producing those instructions in accessible text formats is part of the product, not an optional presentation layer added after implementation.
Technology choices affect this experience too. Sikelianos uses SQL as the example of a mature language with a large body of existing usage. His rationale for choosing established, stable technology is that models have encountered many examples and have fewer changing conventions to navigate. This is a design heuristic about familiarity, not a measured guarantee of correct generated code.
Finally, an API response may become input to a model with a limited context window. Returning every available field about every model can bury the information needed for the task. Sikelianos recommends smaller, information-dense JSON responses: retain useful details while avoiding an exhaustive metadata dump. The response’s usefulness to its next reader matters as much as its completeness as a database export.
Suggest correction
This note stays in this page until you copy or download it. Nothing is submitted; reloading clears the draft.
From generated documentation to informed decisions
An audience question asks how to get started generating API documentation. Sikelianos’s answer begins before the choice of documentation site: write an OpenAPI description in YAML or JSON that captures the API’s behavior. He names Docusaurus, Read the Docs, and ReadMe as examples in the documentation ecosystem. Schema-driven tooling can also produce SDKs and clients in different languages, though those capabilities are not necessarily native to every named product. The reusable asset is the API description.
The final question extends the discussion from integration to discovery and distribution. If assistants increasingly inform purchasing decisions—and might eventually make some of them—what does a service need to expose? Sikelianos starts with strong search and API access to the information a user needs to make an informed choice.
Pricing is his concrete example. At the time of the talk, Replicate users had to visit pricing pages or individual model pages to find it. Exposing that information as public, structured JSON would let an assistant retrieve costs and compare options inside the conversation. This is a proposed capability in the discussion, not a demonstrated pricing endpoint.
The imagined request is to compare video models such as Veo, Kling, and MiniMax by expense, speed, and output quality. Pricing data would support the cost comparison; speed and quality would require corresponding evidence of their own. No model ranking is demonstrated. The substantive requirement is that the facts needed for a decision be available in a form the assistant can retrieve and reason over. Search can find the options, but structured decision data makes those options possible to evaluate.
Suggest correction
This note stays in this page until you copy or download it. Nothing is submitted; reloading clears the draft.
Resources
From the talk
Karpathy's account of building, deploying, and adding payments to a menu-illustration app.
Text documentation for packaging models in containers and exposing typed inference APIs.
Further reading
- Zeke's companion pageArticle
The speaker's presentation page with official and rough-cut recordings and a transcript.
- MCP specification from March 2025Documentation
A historical specification for connecting applications to model-facing context and tools.
The formal structure for describing HTTP operations, parameters, request bodies, and responses.
Updates since the talk
Instructions for connecting supported assistants to Replicate through local or remote MCP servers.
A later search endpoint covering models, collections, and documentation, with MCP response filtering.
Read the complete timestamped transcript
- 0:00
[upbeat music] How many of you know who Andrej Karpathy is?
- 0:18
Raise your hand. Okay, maybe half of you. Raise your hand if you are not Andrej Karpathy.
- 0:26
Just trying to gauge audience participation here. Okay, so I got 80% there, something like that. Got a lot of Andrejs in the room right now. Um, raise your hand if you work at Replicate.
- 0:37
All right, so if you wanna talk to any Replicate folks, there's, there's your group right there. All right, so, um, for those who don't know who Andrej Karpathy is, I will jump into that and explain that.
- 0:47
Um, these are my, uh-- There's a GitHub repo that corresponds to this, um, these slides, so if you wanna grab that, this will... I'll put this slide up at the end too, so you can, um, track down any URLs or anything that I mention in the talk.
- 1:03
Uh, my name is Zeke. I am Zeke on GitHub, um, Zeke on X as well, um, and I work for Replicate. So, uh, Replicate is a cloud platform that lets you run AI models with an A-API.
- 1:17
So we have, um, you know, open source models like all the great Fla- FLUX models from Black Forest Labs, but we also have, you know, proprietary models from Anthropic, OpenAI, Google, et cetera.
- 1:32
Um, and of course, you can also run your own custom public and private models on Replicate as well. So let's get to the point. Who is Andrej Karpathy? Well, he's an AI res-- he's an AI researcher who's worked at all these big, uh, companies and organizations, Google, OpenAI, Tesla, OpenAI, Eureka Labs.
- 1:53
Um, Eureka Labs is his new thing, uh, an educational, uh, platform. Uh, but most importantly to me, he is a YouTube educator and does some really amazing talks that are highly accessible that explain how AI and machine learning works for general audiences.
- 2:11
Um, he coined the term vibe coding a few months ago, and of course, that's taken the world by storm. We're all really interested in that now, and subscribes to the idea that the hottest new programming language is English.
- 2:23
Um, kind of a hot take. Um, he also wrote something called the Software 2.0 Manifesto, which was, um, now seven years ago, kind of a eternity in machine learning time.
- 2:35
Uh, basically predicting this world in which, uh, machine learning models would write code for us, um, and that it would be-- they would be better at it than, than humans.
- 2:46
And so of course, here we are. Um, so today I wanna talk about MenuGen. So MenuGen is, um, an app that Andrej created recently at a... I think he was at a hackathon doing like a, a vibe coding experiment.
- 3:00
So MenuGen is basically this, uh, web app where you take photos of a menu at a restaurant that's all in a text format, and it generates image representations of the contents of the menu for you.
- 3:15
So if you don't know what the words mean, or English isn't your first language, or you just like to see tantalizing photos of food that may be good, um, that was the idea behind it.
- 3:28
So he was actually able to build this app, which he described as an exhilarating and fun escapade as a local demo, but a bit of a painful slog as a deployed real app.
- 3:39
So you've probably-- many of you have probably experienced this, where you are working on something locally, you have it running on your machine. "Oh, cool. It really works. It's amazing."
- 3:48
And then you try to deploy it to, you know, Vercel or Cloudflare or something like that, and that's where a lot of the, the pain begins. Um, so we're gonna talk about that.
- 3:58
So, um, Andrej kind of wrote this blog post about the experience of creating MenuGen, um, and saying, "You know, I was able to make this thing, publish it, get it online, uh, add payments for it, and it's a working, functioning app that people can pay for, and it was super fun to build."
- 4:19
However, he kind of rakes all these different companies over the coals because of the sort of developer experience challenges of working with all of them. So for me, it was cool because it was like, okay, Replicate is mentioned among all these big hotshot companies like OpenAI and Vercel, um, but we also all have work to do to
- 4:37
improve our products to make them better. So here's a blurb about kind of what he, what he experienced when he started using Replicate API. So the LLM's knowledge of Replicate was outdated.
- 4:51
The docs on Replicate were out of date. Um, there were changes in the API. He experienced rate limiting, and it was harder to get started with a new legitimate paid account.
- 5:04
So this is kind of embarrassing, but it's also kind of like an opportunity to fix our product and make it better and really listen to, you know, the kind of voices that are loud and correct about the problems with our products.
- 5:19
So what can Replicate do better? Um, one of them is embracing llms.txt. llms.txt is this thing where you can, uh, basically, uh, modify your website or your API or existing services to, um, render text-based or Markdown-based versions of your documentation in a format that is friendly for language models to
- 5:43
consume. Um, more friendly than like the HTML contents of a webpage. So he said, "Tired: elaborate docs pages with fancy color palettes, branding, animations, transitions, dark mode. Wired: one single docs Markdown file and a copy to clipboard button."
- 6:02
So it sounds simple, um- And maybe not the most glamorous thing, but it is actually the thing that your language models want to consume. So in response to this, we added a new feature on the Replicate website where you're viewing any model page.
- 6:16
You have a button to copy the contents of that page, uh, as Markdown for a language model, or to send the page directly to Claude to have an interaction with the contents of the model page to learn more about what the model can do.
- 6:33
Similarly, we added that support for linking to ChatGPT. You basically just say, "I'm on a model page," you jump into ChatGPT, and you start having a conversation about the model.
- 6:43
So it's a lot more interactive than just going to a webpage and reading and trying to find the most relevant content.
- 6:52
Of course, we also just dump the Markdown here too. So if you're using a pro-- a tool like Cursor or Windsurf, grab this content, put it into your editor, and it knows how to run this model.
- 7:03
So next thing. This was not necessarily from the blog post, but this is from s-- I'm grabbing some quotes from recent, uh, tweets from Andrej Karpathy. So LLMs don't like to click, they like to curl.
- 7:17
So love it or l- love it or hate it, curl is, um, a tool that is here to stay. It's developed. It's been around for, I don't know, since the '90s maybe.
- 7:29
Um, it's installed on everyone's machine, and it is b- basically a standardized way to be able to make API calls without any specialized tooling. So let's look at this curl command.
- 7:41
Maybe it looks ugly, right? It's-- There's a lot of syntax. It's not, it's not glamorous, but it covers everything that you or that a language model needs to know about how to make an I- API request.
- 7:53
What is the HTTP method? What is the JSON payload? How do you send your credentials? What kind of response type do you want? Do you wanna make a blocking request or a, an asynchronous request?
- 8:06
What is the API endpoint? That's all covered in this one little line of code, and this is exactly the kind of thing that LLMs wanna consume. If you give this content to an LLM, it now knows how to make API requests to your service.
- 8:19
So it's really powerful. So we have a tool called Cog at cog.run, which is an open source tool that you can use to package machine learning models in production-ready Docker containers.
- 8:32
It creates a standardized API around your model, um, with standard inputs and outputs using OpenAPI. So we took all of Cog's documentation and stuffed it into a single llms.txt file at cog.run.
- 8:47
And what you can do with that is drop it into your editor
- 8:52
on an existing project. Let's say you've cloned some open source Cog model, and you're like, "I don't even really know how this code works, but I wanna change it."
- 9:00
You open up the model, you drop a reference to that llms.txt, and
- 9:06
your editor knows how to consume that content, bring it into context, and use it to write code.
- 9:14
So pretty powerful stuff. All right. So the primary audience of your thing, your product, service, library, et cetera, is now an LLM, not a human.
- 9:28
This might be, like, a tough pill to swallow, but I think it's the world that we're in right now.
- 9:34
Um, so if you've been at this conference for a couple days, you've probably heard everybody talking about MCP, right? It's, like, such a big deal. But what even is it?
- 9:43
Like, how many of you actually feel like you really know what MCP is?
- 9:49
Okay. I like the honesty here. Like, there's, like, eight hands going up. Okay. So I'm gonna explain this for you, hopefully. So OpenAPI is this thing where you write a JSON schema that defines the behavior of your HTTP API.
- 10:06
It's basically just a giant JSON file that says, "Here are the paths, here are the endpoints, here are the query parameters, here's the payload for the body. Here's how you run this thing.
- 10:17
Here's how you create a prediction. Here's how you get your predictions. Here's how you search," all that sort of stuff. And it's just one big, giant JSON file that describes your whole behavior of your API.
- 10:29
So we have that on Replicate, and when you go to our HT- HTTP API page, all the content on this page is generated from that schema. So we just have a template that renders it all out as a human-friendly representation of how to use our API.
- 10:45
Here's an example where you can search for models. So here's where the M- MCP part comes in. So MCP is basically a way of taking an OpenAPI schema
- 10:58
and stuffing it into a format where a language model knows what to do with it.
- 11:04
So we now have an MCP server for Replicate, which you can install very easily. You basically open up Claude Code, for example. Claude Desktop, not the web app.
- 11:17
Um, go into your developer settings, add this tiny little line of JSON,
- 11:22
and all of a sudden, Claude now knows how to do everything that the Replicate API can do, and it has an API token. So you didn't have to install any software.
- 11:33
All you had to do is go get a token from the Replicate website, and Claude takes care of the installation of the MCP server locally. And now you can see on this page,
- 11:46
you can actually have an interaction with Claude
- 11:50
where it's able to run API requests on Replicate for you. So there's a few factors here. There's-- You can use this for discovery, so you don't know how to use the product yet, and you wanna know what it's capable of.
- 12:04
Or you wanna use a language model to do searches for you. Or you wanna start, um, kind of scaffolding out the beginning of a project
- 12:14
And you want your language model to help you with that. So that's exactly what MCP is for. It's a way of connecting
- 12:21
tools to your language model so that it can do all sorts of powerful things. And I wanna emphasize here that
- 12:29
at Replicate, all we really had to do to make this possible was invest in having an OpenAPI schema that was very well written, very well documented, that, um, covered everything that our API is capable of doing, and the process of turning that into an MCP server that can then connect with tools like Claude, uh, GitHub Copilot, and
- 12:52
Visual Studio Code. Um, and now, actually, I think OpenAI added MCP p- support to their agents SDK earlier this week. So MCP is just gonna be all over the map, and it's a way to really accommodate language models helping you do things.
- 13:09
So, um, this is sort, sort of a note to self, uh, for the things that we got wrong for Andrej and the things that we wanna fix. Some of them we've already addressed, as I showed in this talk.
- 13:21
Some of them we still need to get right. So maybe kind of a no-brainer, accept payments. Okay, so Andrej went on the website, he signed up for an API key, he entered his credit card info, uh, in Replicate, you know, basically legitimate user.
- 13:39
And then he started hammering Replicate with API requests to generate images of French toast. And
- 13:45
whatever-- for whatever reason, the way he was doing it, he was making a ton of API requests, and he triggered some kind of abuse mechanism in our website that said, "Oh, well, this user's only existed for one hour, and they've already sent us 1,000 requests.
- 13:57
Something must be wrong." So we blocked him. And this isn't something you wanna do, right? You wanna let your power users come to your product, dive right in. They know what they're doing, they know what they want, and don't get in their way.
- 14:11
Luckily, uh, our CEO saw this, you know, blog post from Andrej and immediately contacted him and, you know, unblocked his account. But not everyone has the power of being able to write a blog post and have everybody in the world see it and know about it.
- 14:26
So the lesson here for us is Replicate should accept, um, payments for credit. So if I go on a website, I should be able to say, "Here's 500 bucks.
- 14:38
Let me go nuts, do whatever I want, and don't ban me." So we're working on that. We're gonna fix that. Uh, next, document your shit. Literally just when you ship features on your product, don't just merge the pull request and walk away.
- 14:55
It's not done until it's documented and the world knows about it, and an LLM can consume the content and put it to use. So always document everything, especially now that LLMs are in charge.
- 15:10
We're still in charge, but you know what I mean. Um, okay, so feed the machines. Uh, basically, it's just a matter of, um, producing content in forms that language models can understand and consume more easily than traditional HTML web pages.
- 15:27
Use boring technology. So this means, um, if a technology has been around for a long time, SQL. SQL statements have been around since,
- 15:37
hmm, I don't know, longer than some of us have been alive. That means that the language models know how to, how to write SQL because they've encountered so much of it.
- 15:47
So when you're building products, be sure to keep in mind that your language models are gonna have a better chance of writing these-- this software and using it if it's a well-established technology that doesn't change a lot.
- 16:03
And lastly, practice good API hygiene. This means when you're writing your HTTP service and you're designing what the JSON response should look like, keep in mind that it's probably going to be going into the context window of a language model now that has limitations.
- 16:21
So instead of dumping a JSON payload response that has everything about all the models under the sun, consider making it a more small, slimmed down,
- 16:34
information-dense version of what an LLM wants to see.
- 16:41
That's all I got. [audience applauding] Thank you. It looks like I've got
- 16:48
two minutes if anybody has questions. Maybe. No questions. Okay, I answered everything. Here we go.
- 17:03
Do you have any recommendations that were good at getting a jump start on, uh, generating your doc trigger API? I know that the scaler.com or, um, you're helping build through that.
- 17:13
Just like quick hot tips on that.
- 17:15
Yeah, the question is, what are some recommendations for generating docs? So first thing to do, just start by generating your own AP- OpenAPI schema. Write schemas in YAML or JSON that describe the behavior of your API.
- 17:29
There's a ton of tools out there. Um, there's Doxasaur- Docusaurus, there's, uh, Read the Docs, there's ReadMe dot... What is it? Readme.com. There's a whole bunch of these services that know how to take an OpenAPI schema and turn it into not only documentation, but also, you know, SDKs, um, clients in different programming languages, all that stuff.
- 17:53
Yeah.
- 17:54
Are some of the main ways that you're thinking about, uh, discovery or distribution in light of what you mentioned, like the LLMs being in charge and making the purchase decision, uh, in the future potentially?
- 18:04
Uh, yeah. So the question was, are we thinking about discovery as the LLMs start to make purchasing decisions? Was that it?
- 18:09
For like, uh, inform us on purchasing decisions and eventually, yeah, maybe even the whole sort of-
- 18:15
I think the key to that is making sure that our API, um, has really good search capabilities and that a lot of the information that users need to make informed decisions is actually available via API.
- 18:26
So for example, with Replicate models right now, um, the pricing is currently something that you have to go to the webpage to look at, either on the pricing page or on the individual model pages.
- 18:37
If we expose pricing, um, you know, as a JSON structure that our API can consume, that a public user can consume, then it becomes a lot easier for you to do something like jump into a session with Claude and say, "Oh, look, I'm ev- of-- evaluating all the video models.
- 18:52
I'm looking at, you know, Imagen and, or, uh, you know, Veo and Kling and MiniMax and all the other things that are, that are out there. Show me a comparison of which models are the most expensive, which ones are the fastest, which ones can produce the highest quality output, et cetera."
- 19:08
And if the language model has access to the structured data to answer those questions, then it's gonna be a lot easier to make those decisions.
- 19:18
All right. Thanks, y'all. [outro music]