RT
Infrastructure WednesdayOct 14, 20269 min read

How to choose a small AI app starting architecture

A reliable AI app starting architecture begins with workload, permissions, capacity, cost limits, failure modes, and recovery—not a pile of services. Here is a practical decision path using the supplied Azure and AWS guidance.

Răzvan Todică, Senior Full-Stack Engineer and Team Lead
Răzvan Todică

Lead software engineer and technical consultant working across React, Next.js, TypeScript, Node.js, product delivery, and team leadership.

  • ai-app-architecture
  • azure-ai-templates
  • aws-spend-limits
  • load-testing
  • document-security
Editorial cover for How to choose a small AI app starting architecture
Original editorial cover generated for this article.
On this page
  1. Official sources

An AI application can become operationally complicated before its workload is clear. Teams may discuss multiple endpoints, containers, permissions, load balancing, testing, and cloud account controls before answering a simpler question: what is the smallest system that can serve the current use case and still recover predictably?

That question matters now because the supplied cloud guidance points in two directions at once. Azure documents reference implementations for AI applications, including document security, load balancing, and load testing. AWS presents a project-oriented account path with spend controls and a defined pause behavior when a limit is reached. Neither source proves that one architecture fits every workload. Together, they support a more useful decision: start with a bounded, testable application shape, then add infrastructure when a specific constraint demands it.

Before choosing a service topology, write down the workload assumptions:

  • Application behavior: Is the system a chat application using its own data, or another AI workload? The Azure material specifically describes templates around chat applications and retrieval-augmented generation patterns.
  • Data permissions: Should answers reflect each user’s document permissions? Azure’s document-security building block describes that as a design concern: authorized users should receive answers from documents they can access, while unauthorized users should not.
  • Expected load: What request volume or concurrency must the system handle? The supplied sources do not provide a universal threshold, so record the expected workload rather than borrowing a generic scale target.
  • Region and availability: Which region will host the workload, and what availability does the product actually require? The sources do not establish a region-specific architecture or availability target, so these remain assumptions to confirm.
  • Storage, egress, and retention: What data is stored, for how long, and what leaves the environment? The supplied excerpts do not provide prices or limits for these items. They still belong in the decision record because they can change the operating shape.
  • Support and recovery: Who responds to failure, and what recovery path is acceptable? The sources do not state recovery objectives. Treat them as decisions, not implied properties of a template or cloud account.

This list separates verified source material from project-specific assumptions. It also prevents a reference implementation from becoming an accidental production design.

Use an AI template as a starting boundary, not a finished platform

Azure describes AI app templates as maintained, deployable reference implementations intended to provide a high-quality starting point for AI applications. The documentation separates smaller building blocks from end-to-end solutions, and its examples include a chat application using an application’s own data. The Azure template documentation also lists focused examples for document security, load balancing, and load testing.

That makes the template useful for narrowing an initial design. It does not establish that every application needs all of those building blocks.

A sensible interpretation is to begin with the smallest relevant template or reference path:

  1. Identify the core application flow.
  2. Add permission handling if the application answers from documents with different access rights.
  3. Add load testing when the expected workload needs evidence that the application can handle it.
  4. Consider load balancing when a stated quota or traffic constraint requires it.

The Azure excerpt describes one load-balancing approach using Azure Container Apps, three Azure OpenAI endpoints, and a primary container that directs incoming traffic. It also says this approach is intended to extend the application beyond Azure OpenAI token and model quota limits. That is a concrete option for a quota-bound design, not a general instruction to deploy three endpoints.

The same distinction applies to load testing. The documentation describes Locust as a way to test a Python chat application using the retrieval-augmented generation pattern, with the objective of checking whether expected load exceeds current Azure OpenAI transactions-per-minute capacity. The useful decision is therefore not “always load test with Locust.” It is “choose a repeatable test when capacity is a requirement that must be demonstrated.”

Put document security before throughput expansion

For an AI application that uses private or permissioned documents, authorization is an architectural boundary. The Azure source explicitly frames document security around preventing unauthorized users from receiving answers based on documents they are not allowed to access. That is a more fundamental concern than adding traffic distribution.

A practical sequence is:

  • define which users may access which documents;
  • ensure the answer path preserves those permissions;
  • test authorized and unauthorized cases;
  • only then evaluate whether the application needs additional capacity mechanisms.

The supplied source does not provide an implementation algorithm, security guarantee, or test result. The sequence above is an editorial recommendation based on the order of consequences: an answer derived from restricted content is a correctness and access-control failure, while insufficient capacity is an operational limitation that can be measured and addressed separately.

This is also why a visually impressive architecture diagram can be misleading. More endpoints or containers do not compensate for an unclear permission model. The smallest reliable solution is the smallest one that protects the data boundary and makes failure visible.

Make cost control an explicit operating boundary

AWS’s current start-here material describes a new-customer Free plan with $100 in credits immediately and the possibility of earning up to $100 more while exploring key services. It states that the credits can be used for up to six months or until they run out, whichever comes first. These are provider-published plan terms in the supplied excerpt, dated October 14, 2026; they are not a project cost estimate. The AWS sign-up material

The same material describes a paid-plan project spend limit. If the limit is reached, resources pause until the next month, unless the limit is raised and service resumes. It also describes notifications at 50%, 75%, and 90% thresholds, along with optional early cost controls.

That behavior suggests a useful operational boundary for experimentation: make the budget limit part of the project design rather than treating cost as a report reviewed after deployment. But the pause behavior also has to be treated as a failure mode. A paused workload may stop serving requests, interrupt testing, or require an explicit decision to resume. The source does not state how a particular application behaves during a pause, so that behavior must be tested or documented separately.

Record cost information in four distinct categories:

  • List price: a provider-published price for a named unit, region, or plan. No detailed service prices are supplied here.
  • Estimate: a forecast based on workload assumptions. None is calculated in the supplied material.
  • Calculation: the formula and inputs used to produce an estimate. No project inputs are provided.
  • Observed result: an actual measured bill, usage value, or test outcome. No observed result is supplied.

Keeping those categories separate is especially important when using credits. Credits reduce or defer eligible charges under stated terms; they do not establish the long-term cost of a production workload.

A reusable decision path for the first deployment

Use this sequence when deciding whether to stay with a small architecture or add another component:

  1. State the workload. Name the application flow, data source, users, expected load, region, availability expectation, storage, egress, retention, and support model.
  2. Choose the smallest reference path. Use an appropriate AI template or building block as a starting point, not as proof that every component is required.
  3. Protect the data boundary. If the application uses permissioned documents, validate authorization before expanding throughput.
  4. Define the failure modes. Include quota exhaustion, failed requests, unavailable dependencies, incorrect access decisions, and cloud-project pausing when a spend limit is reached.
  5. Add observability. Decide what signals reveal rejected requests, permission failures, capacity pressure, and paused resources. The supplied sources do not name a complete monitoring design, so document the signals your workload needs.
  6. Test recovery. Confirm who resumes service, what data must be retained, and how the application behaves after a dependency or project boundary interrupts it.
  7. Scale only against evidence. If a quota or expected load is the constraint, evaluate load testing and, where appropriate, a load-balancing pattern. Do not add components merely because they are available in a reference architecture.

This is intentionally a decision record rather than a universal diagram. The right output may be a small application with one clear data path and explicit limits. A larger arrangement becomes justified when it answers a documented requirement such as permission isolation, capacity testing, or quota-bound traffic distribution.

Conclusion: reliability is a set of explicit boundaries

A practical AI app starting architecture is not defined by how many cloud services it includes. It is defined by whether the workload, data permissions, capacity assumptions, budget boundary, failure modes, and recovery responsibilities are visible.

The supplied Azure guidance offers reusable starting points for AI application concerns such as document security, load testing, and quota-related load balancing. The AWS material offers an account and project boundary with published credit terms, spend limits, notifications, and pause behavior. Use those capabilities as inputs to a decision, not as substitutes for one.

Start small, write down what must be true, and add the next component only when a named constraint earns it. If you are reviewing an AI application’s architecture, cost boundary, or operational readiness, I can help turn those assumptions into a concise technical decision record.

Official sources

· Updated