Replication Data for: Compositio Prompto: An Architecture to Employ Large Language Models in Automated Service Computing

DOI

A classic, central Service-Oriented Computing (SOC) challenge is the service composition problem. It concerns solving a user-defined task by selecting a suitable set of services, possibly found at runtime, determining an invocation order, and handling request and response parameters. The solutions proposed in the past two decades mostly resort to additional formal modeling of the services, leading to extra effort, scalability issues, and overall brittleness. With the rise of Large Language Models (LLMs), it has become feasible to process semistructured information like state-of-practice OpenAPI documentation containing formal parts like endpoints and free-form elements like descriptions. We propose Compositio Prompto to generate service compositions based on those semi-structured documents. Compositio Prompto acts as an encapsulation of the prompt creation and the model invocation such that the user only has to provide the service specifications, the task, and which input and output format they expect, eliminating any manual and laborious annotation or modeling task by relying on already existing documentation. To validate our approach, we implement a fully operational prototype, which operates on a set of OpenAPIs, a plain text task, and an input and output JSON schema as input and returns the generated service composition as executable Python code. We measure the effectiveness of our approach on a parking spot booking case study. Our experiments show that models can solve several tasks, especially those above 70B parameters, but none can fulfill all tasks. Furthermore, compared with manually created sample solutions, the ones generated by LLMs appear to be close approximations.

Methodology (summarized): We perform an automated service composition for parking spot booking using LLMs for the study. There are six parking services and two payment services. The six parking services are duplicated with different distances and prices to create distinct sets 1 and 2. We define eight prompts and perform the composition using 14 different LLMs. We use a best-of-three-shot approach to reduce the influence of randomness. Finally, we assess functionality manually and apply code similarity metrics to a manually crafted sample solution. All experiments are described in detail in the full paper.

Content:

code/:Code to perform the experiments. For details, see "code/README.md". code/evaluation/prompt_generation.py:Services and prompt generation. code/evaluation/sample_solution/:Sample solution and similarity evaluation. results/*:Results for the runs with the LLMs. Filename structure: "results/{model_name}-{run}/prompt_{prompt_number}set{set_number}_{artifact}". The artifact can be "code_0.py" for the generated code, "code_1.py" if tasked to improve the code, or "prompt.txt" for the used prompt. For the best run, the code metrics are in "comparison.json". prompt_template.txt:Pseudo code for the prompt template. Implemented in code/evaluation/prompt_generation.py.

Note: Please use the tree view to access the files. License: License for the "code/": MIT. License for the "results/": CC BY 4.0.

Identifier
DOI https://doi.org/10.18419/darus-4497
Metadata Access https://darus.uni-stuttgart.de/oai?verb=GetRecord&metadataPrefix=oai_datacite&identifier=doi:10.18419/darus-4497
Provenance
Creator Pesl, Robin D. ORCID logo; Mombrey, Carolin (ORCID: 0000-0002-2646-284X); Klein, Kevin ORCID logo; Georgievski, Ilche ORCID logo; Becker, Steffen ORCID logo; Herzwurm, Georg ORCID logo; Aiello, Marco ORCID logo
Publisher DaRUS
Contributor Pesl, Robin D.; Aiello, Marco
Publication Year 2024
Funding Reference BMWK 19S21002 ; MWK bwHPC
Rights info:eu-repo/semantics/openAccess
OpenAccess true
Contact Pesl, Robin D. (Universität Stuttgart); Aiello, Marco (Universität Stuttgart)
Representation
Resource Type Source Code; Dataset
Format text/x-python; text/x-python-script; application/json; text/plain; application/octet-stream; text/markdown
Size 857; 251; 3178; 4174953; 4175066; 4175124; 4175125; 4174965; 4175650; 4174959; 4175996; 4175290; 4175207; 4174903; 4175231; 4176853; 4175243; 1070; 549; 1097; 1175; 1187; 1920; 2076; 1487; 1548; 6090; 2088; 1358; 1561; 5970; 1360; 177; 2005; 1601; 1207; 1335; 3160; 1242; 902; 2075; 1923; 1502; 2073; 2964; 1927; 1302; 1665; 1734; 2288; 1713; 3497; 2427; 1696; 1653; 1047; 1385; 2365; 392; 2057; 2028; 1915; 1639; 175; 410; 555; 1818; 2344; 1544; 1573; 2159; 2089; 1716; 703; 1792; 1988; 3131; 3428; 2049; 2074; 2423; 1460; 1984; 308; 2554; 13305; 1475; 749; 1572; 1439; 153; 2625; 731; 1556; 701; 5493; 2455; 2141; 1434; 1802; 2111; 1267; 2831; 3910; 297; 1722; 1329; 1632; 1627; 1444; 1540; 1046; 765; 2729; 3744; 2022; 1554; 4169; 328; 2039; 898; 532; 621; 3062; 419; 2490; 144; 2774; 1218; 1684; 761; 1801; 2316; 1762; 1622; 2826; 836; 3569; 398; 2211; 2030; 1860; 1930; 1161; 2420; 1844; 13289; 1459; 1441; 1645; 1893; 1115; 1875; 1641; 600; 3297; 1173; 1066; 2067; 714; 743; 1222; 1323; 1181; 2165; 1942; 1983; 1768; 6342; 2376; 2969; 2122; 604; 2794; 2463; 692; 1418; 2647; 1156; 1446; 2051; 4360; 2042; 843; 2135; 2328; 1324; 1064; 677; 606; 1343; 2248; 716; 2272; 2615; 1892; 1050; 2121; 3271; 1130; 2829; 1758; 2058; 744; 671; 835; 1531; 13492; 1941; 1506; 3219; 1194; 1144; 1794; 633; 1966; 1785; 1421; 2939; 2245; 2417; 2918; 1464; 1793; 1393; 1204; 3034; 624; 2230; 2926; 1552; 871; 928; 1700; 1056; 3275; 2025; 1943; 1171; 994; 446; 1837; 2173; 950; 1090; 1249; 412; 2059; 1829; 952; 2876; 2786; 2037; 2709; 1787; 3457; 1438; 2834; 1125; 2882; 2246; 2137; 2219; 3039; 2158; 13476; 2065; 2872; 2347; 2163; 5255; 2863; 2101; 1809; 2388; 188; 2520; 2367; 4398; 1388; 3191; 2404; 4549; 2878; 2383; 2375; 2476; 762; 3209; 2384; 2332; 2114; 4095; 2470; 1748; 2716; 3464; 469; 186; 376; 382; 2229; 2461; 3417; 1628; 1170; 2335; 2543; 2873; 886; 3394; 3151; 1351; 2239; 5718; 1163; 582; 779; 5064; 2686; 3049; 2981; 2329; 2033; 888; 2031; 4634; 13691; 2348; 2169; 1815; 2433; 1391; 2673; 2600; 3006; 2099; 1264; 3375; 2900; 715; 2038; 1826; 1053; 5322; 519; 3192; 2393; 1184; 1901; 486; 2605; 2650; 1219; 1905; 2692; 3792; 2467; 3402; 2497; 1659; 1856; 2192; 2148; 2243; 1149; 2034; 903; 2772; 1870; 4066; 3019; 890; 2266; 2742; 1277; 2931; 1871; 2056; 2875; 3932; 2551; 1447; 13675; 2338; 2304; 3266; 2823; 1005; 1101; 3326; 3867; 1400; 725; 1767; 967; 6134; 2312; 1799; 2391; 1992; 1697; 3578; 1376; 2887; 2144; 3625; 2238; 940; 48; 2021; 1486; 2274; 1634; 1800; 3892; 2189; 1113; 2412; 2234; 3452; 1220; 3555; 2024; 516; 2216; 2326; 700; 1494; 450; 2781; 2886; 1006; 1370; 1426; 2315; 1925; 2663; 1133; 2927; 1664; 13594; 1726; 6393; 1295; 2102; 2386; 1402; 1807; 2465; 2149; 2783; 1666; 4264; 2797; 1290; 3058; 2269; 2723; 2020; 2214; 2482; 752; 2227; 2043; 2996; 2892; 1658; 1863; 2813; 1810; 1364; 2284; 3238; 2763; 1514; 2146; 3573; 1789; 2616; 3352; 2511; 335; 427; 2762; 820; 5144; 2510; 2015; 13578; 1744; 3079; 1541; 2415; 1120; 1978; 2222; 2493; 3414; 988; 979; 1661; 1430; 3934; 1529; 1516; 2960; 1962; 1059; 1877; 1330; 3921; 2854; 33; 2454; 2351; 1216; 2609; 2746; 1958; 2035; 1106; 834; 2195; 2935; 1825; 2194; 2193; 1079; 1581; 601; 595; 2991; 1304; 1804; 1842; 3318; 426; 1698; 215; 2120; 2469; 1808; 13890; 1576; 2055; 2662; 3939; 3222; 2809; 1635; 1683; 356; 2522; 1903; 1730; 2803; 3234; 1429; 2993; 1342; 1594; 1598; 1732; 2521; 1743; 1731; 1682; 2068; 2711; 1578; 686; 462; 2732; 1617; 1620; 1631; 2631; 3743; 1738; 2324; 460; 1352; 2508; 3476; 413; 13874; 1772; 3679; 2090; 2777; 3106; 911; 2736; 2317; 3496; 1523; 2790; 2567; 3480; 1260; 25; 2664; 3221; 3429; 3270; 2970; 3875; 3029; 2514; 4142; 1706; 3360; 1671; 5368; 3684; 2695; 2322; 221; 572; 1353; 577; 14; 763; 2952; 3568; 3031; 1895; 2496; 2477; 3274; 2041; 1027; 3702; 1708; 284; 3078; 3773; 2589; 512; 14647; 3955; 4304; 2976; 4039; 2103; 3288; 659; 3293; 2503; 4343; 2109; 2703; 3139; 1574; 4878; 3290; 2721; 2513; 365; 3518; 3199; 72; 2483; 2297; 449; 3149; 2168; 2494; 4003; 1168; 1332; 506; 1538; 1999; 3085; 3733; 341; 2013; 2014; 1313; 2750; 2754; 5951; 4268; 3117; 508; 2624; 3411; 2032; 4682; 14631; 3656; 1026; 840; 6766; 1244; 1340; 746; 1396; 1060; 1299; 1960; 1750; 2591; 3969; 2906; 1466; 3162; 2505; 2170; 4254; 1673; 1077; 1783; 1198; 722; 4582; 1990; 1788; 1770; 2677; 1051; 2601; 1258; 3009; 4056; 2341; 3224; 1318; 1536; 2016; 1755; 689; 2115; 6367; 1880; 3036; 2040; 2138; 1493; 2156; 13294; 1951; 3208; 4054; 913; 1235; 8013; 1448; 1723; 1553; 1401; 1390; 2118; 2998; 1969; 1248; 2294; 1955; 1239; 1672; 1311; 2430; 2708; 800; 977; 442; 2782; 1251; 2152; 307; 645; 4564; 1900; 2241; 4160; 2581; 4436; 1322; 1605; 2053; 2240; 1440; 1921; 2382; 1286; 1819; 1415; 667; 1442; 4922; 13278; 1922; 2968; 3136; 2768; 4275; 2714; 2296; 1057; 2896; 1853; 2911; 2305; 2665; 3109; 3614; 3853; 1013; 4726; 2995; 1241; 3216; 594; 733; 2190; 2698; 2119; 3860; 2278; 2405; 3929; 1741; 2026; 2670; 2853; 439; 991; 1044; 2373; 465; 989; 13681; 3508; 3419; 2559; 3147; 987; 1202; 2345; 3194; 2800; 2171; 3766; 1699; 4787; 2626; 1407; 3056; 2669; 1110; 1964; 3154; 3747; 3330; 2612; 2988; 1929; 1238; 1417; 4130; 736; 1129; 2901; 1298; 1602; 2771; 2117; 1155; 1935; 2805; 407; 2758; 3247; 348; 3044; 1084; 2440; 2492; 13665; 3479; 23384; 1702; 674; 1065; 1616
Version 1.0
Discipline Construction Engineering and Architecture; Engineering; Engineering Sciences