Introduction
Large Language Models (LLMs) have demonstrated significant potential in generating user interface (UI) code from natural language descriptions. However, these models often produce generic, "one-size-fits-all" solutions that fail to account for specific user needs or task contexts. For instance, an LLM might default to a standard slider for any numerical input, regardless of whether a user requires high-precision control or rapid, exploratory adjustments. This "precision-control gap" highlights a disconnect between the ease of natural language interfaces and the functional requirements of traditional graphical user interfaces (GUIs).
To address this, we present CrowdGenUI, a framework designed to ground LLM reasoning in a crowdsourced library of real-world user preferences. By leveraging human design principles, CrowdGenUI generates adaptive UI widgets that are better aligned with human needs for predictability, efficiency, and explorability.
Methodology
CrowdGenUI utilizes a modular pipeline to transform user intent into functional, personalized UI components. The system moves beyond simple code generation by incorporating a structured reasoning process grounded in empirical user data.
- Preference Library Construction: The foundation of the system is a library of 720 unique user preferences. These were collected by having participants perform various image editing tasks and select their preferred widgets based on three dimensions: Predictability (results without surprises), Efficiency (minimal effort), and Explorability (high flexibility).
- Chain-of-Thought (CoT) Reasoning: Upon receiving a task description and user preferences, the framework employs an LLM (specifically GPT-4o) to analyze the context. The model searches the preference library for similar scenarios and rationales to determine the most appropriate widget types.
- Augmented Generation: The LLM reasons which specific widgets (e.g., preset buttons, sliders, or color wheels) best satisfy the user's stated goals. For example, a user wanting an "efficient overview" might be served preset buttons, while one seeking "fine-grained adjustment" would receive a slider.
- Code Implementation: Finally, the system generates executable Python code to render the selected widgets within a Jupyter Notebook environment, ensuring interactivity and reliability through the use of reference code templates.
Dataset and Evaluation
The research introduced a specialized User Preference Library containing 720 responses from 50 participants across eight image editing tasks, such as adjusting lightness, color matching, and watermark positioning.
To evaluate the framework, a user study with 78 participants compared CrowdGenUI (using varying library sizes: 10, 25, and 30 responses) against a baseline LLM without library guidance. The evaluation focused on how well the generated UIs aligned with user intentions across the core design dimensions of predictability, efficiency, and explorability.
Results
The experimental results demonstrate that grounding LLMs in a preference library significantly improves UI alignment:
- Superior Alignment: UIs generated with a 30-response library were consistently rated higher than the baseline across all measured dimensions. Larger libraries generally led to more consistent and reliable reasoning.
- The Power of Rationale: By providing the reasons behind user preferences, the library allows the LLM to generalize design logic to entirely new tasks. For instance, the model could successfully apply "color matching" logic to an unseen "image tinting" task.
- Scalability of "Small Data": Notably, even a minimal library of 10 responses provided a significant performance boost over the baseline, suggesting that effective UI personalization can be achieved without massive datasets.
- Generalizability: The framework successfully adapted to non-overlapping tasks, such as using image editing preferences to inform layout tasks like text alignment or logo positioning.
Discussion and Future Work
While CrowdGenUI represents a significant step toward adaptive, user-centric AI interfaces, several limitations remain. The current implementation is restricted to 2D widgets in Jupyter environments and does not yet address complex multi-step workflow layouts. Furthermore, the preference library reflects the biases of its primarily English-speaking participants; future iterations must incorporate more diverse cultural perspectives on UI metaphors.
Future research will explore extending this framework to AR/VR, voice-controlled interfaces, and wearable devices, as well as developing more sophisticated logic for full-page interface layouts and multi-step workflows.
Summary updated