Toward Generating Microservice Architectures from Textual Requirements with Large Language Models

Large Language Models (LLMs) have demonstrated strong performance in natural language understanding and generation, opening new possibilities for automating software engineering tasks. This study evaluates whether the GPT-4 O3 model can generate microservice-oriented architectures directly from textual requirements. We applied two prompting strategies—zero-shot (ZS) and few-shot (FS)—to two real-world-inspired systems (Bookstore and PetClinic) and compared the outputs against their reference architectures. In ZS, GPT-4 identified 11 out of 14 expected services (precision, recall, and F1 ≈ 0.79) and recovered 33 out of 38 interservice links (precision ≈ 0.50, recall ≈ 0.87, F1 ≈ 0.64), but also introduced 34 unsupported links. Under FS, it matched all 14 services (precision ≈ 0.93, recall = 1.00, F1 ≈ 0.97) and recovered every expected link, while reducing spurious connections to 12 (precision ≈ 0.76, recall = 1.00, F1 ≈ 0.86). A mixed-methods evaluation by four senior architects confirmed these trends. The FS received the best expert scores (avg. correctness ≈ 4.6/5, plausibility ≈ 4.5/5) because they balanced full requirement coverage with sound modularity, whereas the ZS versions, though complete, were downgraded for dense bidirectional coupling (plausibility ≈ 2/5). The reference architecture sat in between, structurally tidy but functionally sparse. Overall, the study shows that supplying even a single exemplar can transform GPT-4 from a rough sketch generator into a credible assistant for microservice decomposition, giving architects a rapid and reliable starting point for design.

Authors

Publication Details

Published
2025-09-19
DOI
https://doi.org/10.5753/sbcars.2025.14591
Citations
1
Primary Topic
Software System Performance and Reliability
Type
article
Field-Weighted Citation Impact
1.49
Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
article

Toward Generating Microservice Architectures from Textual Requirements with Large Language Models

Ângelo Perkusich, Kyller Gorgônio, Guillermo Rodríguez, J. Andrés Díaz‐Pace et al.
1 citations
Software System Performance and Reliability
1.49
article

Toward Generating Microservice Architectures from Textual Requirements with Large Language Models

Ângelo Perkusich, Kyller Gorgônio, Guillermo Rodríguez, J. Andrés Díaz‐Pace, Danyllo Albuquerque, J. R. Pereira
article en
1 citations

Abstract

Large Language Models (LLMs) have demonstrated strong performance in natural language understanding and generation, opening new possibilities for automating software engineering tasks. This study evaluates whether the GPT-4 O3 model can generate microservice-oriented architectures directly from textual requirements. We applied two prompting strategies—zero-shot (ZS) and few-shot (FS)—to two real-world-inspired systems (Bookstore and PetClinic) and compared the outputs against their reference architectures. In ZS, GPT-4 identified 11 out of 14 expected services (precision, recall, and F1 ≈ 0.79) and recovered 33 out of 38 interservice links (precision ≈ 0.50, recall ≈ 0.87, F1 ≈ 0.64), but also introduced 34 unsupported links. Under FS, it matched all 14 services (precision ≈ 0.93, recall = 1.00, F1 ≈ 0.97) and recovered every expected link, while reducing spurious connections to 12 (precision ≈ 0.76, recall = 1.00, F1 ≈ 0.86). A mixed-methods evaluation by four senior architects confirmed these trends. The FS received the best expert scores (avg. correctness ≈ 4.6/5, plausibility ≈ 4.5/5) because they balanced full requirement coverage with sound modularity, whereas the ZS versions, though complete, were downgraded for dense bidirectional coupling (plausibility ≈ 2/5). The reference architecture sat in between, structurally tidy but functionally sparse. Overall, the study shows that supplying even a single exemplar can transform GPT-4 from a rough sketch generator into a credible assistant for microservice decomposition, giving architects a rapid and reliable starting point for design.

Openalex Percentile: Top 13%
Software System Performance and Reliability
1.49
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.