You sketch three boxes, draw arrows between them, name them orders, billing, inventory — and immediately feel the doubt. Where do the network calls pile up? What happens when billing is down for 40 seconds and the saga halfway through? Will the event stream silently reorder something you assumed was ordered? Nobody on the team knows for sure, so the diagram ships to a wiki and everyone quietly hopes.
Here is the shift that changes this: an LLM is a genuinely useful architecture reviewer if you ask it to break your design instead of agreeing with it. Left alone, the model will happily generate a pretty C4 diagram and praise your choices. Give it a role, a constraint set, and a demand for failure modes, and it behaves like a senior architect in a design review who has seen this exact shape fail before.
The prompts below are the ones that consistently earn their keep. Each one is a mechanism, not a category — it exists because a specific class of reasoning about microservice architecture is something the model does badly by default and well under pressure.
Why an LLM is a mediocre architect and a decent reviewer
Ask a model to "design microservices for a food delivery app" and you get the LinkedIn version: an API Gateway, six services named after nouns, Kafka in the middle, and a confident sentence about scalability. It is not wrong. It is just empty — it has no cost, no ownership, no failure. More on the topic: “Microservices Architecture in Practice: Docker, Kubernetes, Queues, and Observability — A Real-World Scenario Breakdown”.
Now ask it: "Here is my service map. For each synchronous edge, give me the p99 latency budget it consumes and what the caller does when the callee times out." The output changes character completely. It becomes specific, because the question has a shape that only specific answers fit.
The whole trick with prompts for microservice architecture is that you are not asking for a design. You are asking for a critique against constraints you supply. The model is a pattern-matching engine over a very large corpus of post-mortems, blog posts, and conference talks — and it will retrieve from that corpus only when your prompt makes the retrieval necessary. More on the topic: “System Design: How Scaling Turns 1,000 Users into 10 Million”.
Prompt 1: Carve the monolith by bounded context, not by noun
The most common failure at the start is splitting by database table. You get a users service, an orders service, an order_items service — and every read now needs three network hops because the transactional boundary was never the table.
The prompt below forces the model to work from language and change frequency, which is what bounded contexts actually are. More on the topic: “From CrashLoopBackOff to a Working Helm Chart: 12 Prompts That Turn an LLM Into Your Kubernetes Sidekick”.
Prompt:
You are a domain-driven design reviewer. Below is a description of a monolith: its main entities, the top 5 user journeys, and which parts of the codebase change together most often (I will paste a short list of recent PRs and their touched modules).
Task:
1. Propose bounded contexts. For each, name the ubiquitous language term that only makes sense inside it (a word that means something different in another context).
2. For each context, state its transactional invariant — the rule that must never be violated within a single transaction.
3. Explicitly list the contexts you are NOT splitting out yet, and why (shared data, low change rate, unclear ownership).
4. Flag any entity that appears in more than two contexts — that is a sign of a missing context or a shared kernel, and I want to know which.
Do not produce a diagram. Produce a table: context | ubiquitous language | transactional invariant | owning team guess | reason to defer.
More on the topic: “System Design Interview: A Step-by-Step Preparation Plan for FAANG and Top-Tier Companies”.
Example run: given a marketplace monolith, the model typically separates Catalog (product as presented to buyers) from Inventory (units on a shelf) — two things a table-based split would merge into "products". The tell that it is working: it names a word like "available" and points out that it means purchasable right now in Catalog and physically in the warehouse in Inventory. That single observation usually prevents a month of arguments.
What this prompt buys you: a split you can defend in a review, plus an explicit list of what you are not splitting. The deferral list is the part most teams skip and later regret.
Prompt 2: Make the model price every synchronous edge
Synchronous calls are easy to draw and expensive to own. A chain of four services each at p99 = 200 ms is not "800 ms" — it is a tail that compounds, and the caller usually has no timeout budget left for retries.
This prompt turns the model into a latency accountant.
Prompt:
Here is my service map with synchronous edges (I will list them as caller -> callee). For each edge:
- Estimate a plausible p50 and p99 for the callee based on what it does (say if you are guessing).
- Compute the cumulative p99 along the longest call chain and show the arithmetic.
- State what the caller does on timeout: fail, retry, fall back to cache, or degrade the response.
- Name the edge most likely to become a cascading failure and explain the mechanism (thread pool exhaustion, connection pool, retry storm).
Then recommend one edge to convert to asynchronous, with the cost of that conversion in added complexity.
A typical result on a checkout flow: the model computes that the chain gateway -> checkout -> pricing -> tax -> currency has a cumulative p99 that exceeds the client timeout, and points at tax — a third-party call — as the cascade origin. That is not a revelation, but seeing it written with arithmetic is what moves it from "we should look at this" to a ticket.
Be honest with yourself about the estimates: the model is guessing latencies. The value is not the number, it is the shape of the reasoning — the compounding tail and the named failure mechanism. Replace its guesses with your real p99s from monitoring and the arithmetic still holds.
Prompt 3: Choose between a queue, a saga, and a synchronous call — with the bill attached
This is where event-driven architecture prompts earn their reputation, because the choice is genuinely hard and the model is good at laying out trade-offs when you force it to name a loser.
Prompt:
For each of the following cross-service steps, decide between: (a) synchronous call, (b) message queue with a single consumer, (c) choreographed saga via events, (d) orchestrated saga with a coordinator.
Steps: [list them, e.g. reserve stock, charge card, issue invoice, send confirmation].
For each step output a row: step | chosen pattern | what we gain | what we pay (latency, ordering, duplicate handling, operational surface) | compensating action if it fails | who owns the compensating action.
Rules: do not choose a saga for a step that has no meaningful compensation. Do not choose a queue for a step whose result the caller needs synchronously to continue. If a step needs both, say so and describe the outbox pattern you would use.
Example output for "charge card": the model picks orchestrated saga, because the compensation (refund) is real and must be owned by one place. For "send confirmation" it picks a queue with at-least-once delivery and notes that duplicates are acceptable for an email — which is exactly the kind of judgment call teams argue about for an hour.
The reason this works: the model is forced to name the compensating action and its owner, and that single column exposes steps that were never really transactions.
Prompt 4: Design the API contract and the event schema together
Most prompts for designing API stop at REST endpoints. That is half the job. The interesting failures live at the seam between the HTTP contract and the event schema — where a field is nullable in the API and required in the event, or where the API returns a list and the event carries a single item.
Prompt:
Design the API contract and the event schema for the [context] service together.
For the API: give OpenAPI-style paths, methods, request/response fields with types and nullability, and the error codes with their meaning. Mark which fields are derived and which are source of truth.
For the events this service publishes: event name, key, payload fields with types, and the ordering guarantee (per key? global? none?).
Then answer: which API fields exist that are NOT in any event, and which event fields have no API equivalent? For each mismatch, say whether it is intentional or a bug waiting to happen.
More on the topic: “API Design: How to Design APIs Like a Pro — REST, GraphQL, gRPC, OpenAPI, and Best Practices”.
That last question is the whole point. In a real run on an orders service, the model noticed the API returned total_amount computed at read time while the OrderPlaced event carried total_amount frozen at write time — a discrepancy that would have produced reconciliation tickets for months. More on the topic: “Real-Time Systems: Myths, Realities, and the Engineering Behind Live Apps”.
Prompt 5: Find the failure points before production does
This is the prompt that pays for the whole kit. It asks the model to walk the system as an adversary.
Prompt:
Act as an SRE reviewing this architecture for the first time. List the top 7 failure modes, ordered by (probability x blast radius).
For each: the trigger, the mechanism (what exactly breaks first, second, third), the user-visible symptom, and the cheapest mitigation that does not require a rewrite.
Include at least two failure modes that are NOT about a service being down — e.g. partial failure, stale cache, duplicate delivery, clock skew, schema drift, or a retry storm.
Do not include "the database is down" as a failure mode. It is not a design review, it is a fact of life.
More on the topic: “Serverless Architecture: Where Lambda and Cloud Functions Break, and How to Design Around It”.
Typical findings that surprise teams: the model flags that a consumer reading from a queue with at-least-once delivery will process the same PaymentCaptured event twice during a rebalance, and that the idempotency key is on the API but not on the event handler. Or it points out that two services both write to the same updated_at column through different paths, and clock skew between hosts makes the ordering meaningless.
These are the failures that eat a weekend. The model finds them in seconds because they are patterns it has seen in a thousand post-mortems.
Prompt 6: Interrogate the model's own answer
The final move is the one almost nobody makes: take the model's proposed design and ask it to attack it.
Prompt:
Here is the architecture you proposed. Now argue against it.
- Name the three decisions in this design that a skeptical staff engineer would push back on hardest.
- For each, give the strongest counter-argument, and the specific evidence (metrics, incident type, team size) that would settle the argument.
- Identify one decision that looks reasonable now but will become a bottleneck once traffic grows 10x. Explain the mechanism.
- If you had to remove one service from this design entirely, which one, and what would you merge it into?
That last question is underrated. "Remove one service" forces the model to find the boundary that is not carrying its weight — often a thin wrapper that only translates between two schemas and could be a library.
If you have been working with LLM-assisted backend design for a while, the same adversarial pattern shows up in other languages and stacks: forcing the model to defend its own output is what separates a useful review from autocomplete.
More on the topic: "Go, LLM, and the Race Against Races: How to Prompt for Idiomatic Concurrency, Explicit Errors, and Context-Aware Code".
What to do with the output
An LLM will not hand you a correct architecture. It will hand you a list of decisions with their costs attached, a ranked set of failure modes, and a set of questions you would have asked in a design review three weeks later — after the incident. That is not a design; it is a review, and a review is exactly the thing you were missing.
Run prompt 1 to get the seams. Run prompt 3 to choose the patterns and see the bill. Run prompt 5 last, on the design you actually intend to build, and keep the failure list as the agenda for your next architecture meeting. The model's job is to disagree with you productively — your job is to decide which disagreements are real.
Rules and figures are stated as of November 2026.