Full-Stack App Generation from a Single Prompt: AI Agent Practices and Boundaries

    This article explores the capabilities and limitations of AI agents in generating full-stack applications from a single prompt. By analyzing three distinct demo cases—a space travel booking site, a deep-sea research portal, and a luxury perfume landing page—we examine the frontend interactions, backend concurrency control challenges, and graphical rendering techniques involved. The article also outlines essential engineering acceptance criteria and practical recommendations for treating AI-generated code as a first draft before production deployment.

    This article does not reference specific model names, versions, or benchmark scores, as the existing materials did not provide this information. The following discussion focuses solely on what can be observed in three demo cases and their engineering implications.

    1. Case 1: Near-Earth Orbit Travel Company Website

    The demo requirement was to build an official website for a near-Earth orbit travel company, featuring space capsule seat selection and flight booking. The first screen uses a full-screen video background, implemented with the HTML5 video tag combined with the CSS object-fit: cover property to ensure the video fills the viewport across different screen sizes. This is a common practice and can be implemented directly.

    The monospace flight data panel in the bottom right and the online status indicator dot in the top left are lightweight UI details. The breathing effect of the status dot can be achieved using @keyframes, as shown in the example below:

    1. .status-dot {
    2. width: 10px;
    3. height: 10px;
    4. background-color: #00ffcc;
    5. border-radius: 50%;
    6. animation: pulse 2s infinite ease-in-out;
    7. }
    8. @keyframes pulse {
    9. 0%, 100% { opacity: 0.4; transform: scale(0.9); }
    10. 50% { opacity: 1; transform: scale(1.1); }
    11. }

    When scrolling down, the content unfolds according to a timeline: T-60:00 spaceport suiting up, G-force during the propulsion phase, zero-gravity experience, and finally, the capsule splashing down into the sea. Each phase is accompanied by images and key data, and the cabin layout is presented as an interactive SVG.

    2. Business Logic: Flight Booking and Seat Locking

    The demo claimed that the system implemented a complete flow of selecting dates, choosing seats, and filling in passenger information, with data being persisted. For the requirement of “a maximum of 6 seats per flight, automatically locking when full,” the demo stated that the system incorporated concurrency control and state validation.

    This claim needs correction. The code provided in the demo only performs state validation: it first reads the flight data, checks the remaining seats and seat status, and then writes back. This code follows a read-then-write pattern without any transactions, locks, or unique constraints in between. If two requests simultaneously read “1 seat remaining,” both will pass validation and write their data, resulting in overselling. Therefore, this code cannot be considered true concurrency control.

    In a production environment, you can prevent duplicate seat bookings using the following approaches:

    1. Add a unique constraint on the combination of (flight_id, seat_no) so that only one booking record can exist for a specific seat.
    2. Use conditional updates instead of read-then-write; if the update fails, it means the seat is already occupied.
    3. Within the same transaction, decrement the remaining seat count while ensuring the remaining count is greater than 0.
    4. Include an idempotency key in the request. Duplicate submissions should return the same result, preventing duplicate bookings caused by users clicking multiple times.

    Below is an illustrative SQL snippet. It cannot be used directly in a production environment and should be adjusted based on your database engine and isolation level:

    1. BEGIN;
    2. UPDATE seats
    3. SET booked_by = :passenger, booking_id = :booking_id
    4. WHERE flight_id = :flight_id AND seat_no = :seat_no AND booked_by IS NULL;
    5. -- If 0 rows affected, the seat is already booked
    6. UPDATE flights
    7. SET available_seats = available_seats - 1
    8. WHERE flight_id = :flight_id AND available_seats > 0;
    9. -- If 0 rows affected, the flight is full
    10. -- If 0 rows are affected in either step, execute ROLLBACK and return an error; otherwise, execute COMMIT
    11. COMMIT;

    3. Case 2: Deep Sea Research Station

    The first-screen camera movement in the demo shows the view sinking vertically from the North Atlantic surface. As it passes the waterline, the screen splits in half, with blue gradients transitioning from light to deep, and two warm yellow lights in the distance representing the submersibles. The demo did not explain the implementation method. Such effects are typically achieved using CSS Scroll-driven Animations or by using the Intersection Observer API to trigger animations after elements enter the viewport. Determining which method was used requires checking the source code.

    The page also includes parameter cards for three submersibles, detailing propulsion methods and observation window sizes, as well as six deep-sea creatures, each occupying a full screen. These are structured content pieces, and the data sources should be verified before publishing. In the field notes section, three articles are attributed to a Chief Scientist, a Marine Biologist, and a Documentary Director, demonstrating that the generated content can adapt its context based on roles. However, role attribution does not prove content accuracy, and professional editors are still required for review.

    4. Case 3: Luxury Perfume Brand Page

    In the demo, an amber perfume bottle rests on a marble countertop. The liquid rotates slowly, light passes through the glass to create caustic patterns, and the brand name is overlaid on the bottle using the Cormorant Garamond font.

    Simulating caustics and rotating liquids realistically with CSS alone is difficult and usually requires WebGL or frame-by-frame rendering with Canvas 2D. Since the demo did not specify the approach, we can only conclude that such effects require graphical rendering capabilities, making it impossible to determine which technology the agent used. Attention must also be paid to font licensing. Cormorant Garamond is an open-source font, but its license and loading method should still be verified before commercial use.

    5. Assessing Full-Stack Delivery

    The three cases show that the AI agent can infer page structures, interaction flows, and basic data models from a single description. This indicates its practical capability in generating runnable prototypes.

    However, the existing evidence mainly consists of descriptions and code snippets, lacking the following:

    • Complete project structure and dependency versions
    • Run commands and data initialization methods
    • Automated tests, especially for concurrency scenarios
    • Real-world deployment and monitoring records

    Without these elements, it is impossible to determine whether the system can withstand real traffic. The table below lists the items to check during acceptance.

    Check Item Acceptance Criteria Common Failures
    Frontend Displays correctly across all viewports; animations can be disabled Video fails to autoplay; lag on mobile devices
    Backend APIs Complete parameter validation; unified error codes Lack of authentication; error messages exposing internal details
    Data Persistence Table structures have constraints; migration scripts exist Data only kept in memory; lost after restart
    Concurrency Control No overselling under high concurrency Read-then-write pattern causing duplicate seat bookings
    Observability Logs, error reporting, and metrics are available Inability to locate root cause after errors occur

    6. Usage Recommendations

    Treat the code generated by the AI agent as a first draft. At a minimum, the following tasks should be completed before going live:

    1. Conduct a security audit: check authentication, input validation, and whether sensitive information is being logged.
    2. Verify the licenses of dependencies, especially images, fonts, and third-party libraries.
    3. Ensure privacy and data compliance requirements are met when dealing with personal information and payments.
    4. Write tests for critical business logic, including concurrency tests.
    5. Prepare a rollback plan and retain the previous version after deployment.

    AI agents can reduce repetitive labor, but architectural decisions, security responsibilities, and business rules still rest on the developers.