<?xml version="1.0" encoding="UTF-8"?>
<TEI xml:space="preserve" xmlns="http://www.tei-c.org/ns/1.0" 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
xsi:schemaLocation="http://www.tei-c.org/ns/1.0 https://raw.githubusercontent.com/kermitt2/grobid/master/grobid-home/schemas/xsd/Grobid.xsd"
 xmlns:xlink="http://www.w3.org/1999/xlink">
	<teiHeader xml:lang="en">
		<fileDesc>
			<titleStmt>
				<title level="a" type="main">Redesigning Business Processes to Reduce Waiting Times Using Large Language Models</title>
			</titleStmt>
			<publicationStmt>
				<publisher/>
				<availability status="unknown"><licence/></availability>
			</publicationStmt>
			<sourceDesc>
				<biblStruct>
					<analytic>
						<author>
							<persName><forename type="first">Katsiaryna</forename><surname>Lashkevich</surname></persName>
							<email>katsiaryna.lashkevich@ut.ee</email>
							<affiliation key="aff0">
								<orgName type="institution">University of Tartu</orgName>
								<address>
									<addrLine>18 Narva mnt</addrLine>
									<postCode>51009</postCode>
									<settlement>Tartu</settlement>
									<country key="EE">Estonia</country>
								</address>
							</affiliation>
						</author>
						<author>
							<persName><forename type="first">Fredrik</forename><surname>Milani</surname></persName>
							<email>fredrik.milani@ut.ee</email>
							<affiliation key="aff0">
								<orgName type="institution">University of Tartu</orgName>
								<address>
									<addrLine>18 Narva mnt</addrLine>
									<postCode>51009</postCode>
									<settlement>Tartu</settlement>
									<country key="EE">Estonia</country>
								</address>
							</affiliation>
						</author>
						<author>
							<persName><forename type="first">Maksym</forename><surname>Avramenko</surname></persName>
							<email>maksym.avramenko@ut.ee</email>
							<affiliation key="aff0">
								<orgName type="institution">University of Tartu</orgName>
								<address>
									<addrLine>18 Narva mnt</addrLine>
									<postCode>51009</postCode>
									<settlement>Tartu</settlement>
									<country key="EE">Estonia</country>
								</address>
							</affiliation>
						</author>
						<author>
							<persName><forename type="first">Marlon</forename><surname>Dumas</surname></persName>
							<email>marlon.dumas@ut.ee</email>
							<affiliation key="aff0">
								<orgName type="institution">University of Tartu</orgName>
								<address>
									<addrLine>18 Narva mnt</addrLine>
									<postCode>51009</postCode>
									<settlement>Tartu</settlement>
									<country key="EE">Estonia</country>
								</address>
							</affiliation>
						</author>
						<title level="a" type="main">Redesigning Business Processes to Reduce Waiting Times Using Large Language Models</title>
					</analytic>
					<monogr>
						<idno type="ISSN">1613-0073</idno>
					</monogr>
					<idno type="MD5">4358A9E12B4E933014D71A212EB2D73F</idno>
				</biblStruct>
			</sourceDesc>
		</fileDesc>
		<encodingDesc>
			<appInfo>
				<application version="0.7.2" ident="GROBID" when="2025-04-23T17:02+0000">
					<desc>GROBID - A machine learning software for extracting information from scholarly documents</desc>
					<ref target="https://github.com/kermitt2/grobid"/>
				</application>
			</appInfo>
		</encodingDesc>
		<profileDesc>
			<textClass>
				<keywords>
					<term>process mining, waiting time, large language models (M. Dumas) 0000-0003-4426-7738 (K. Lashkevich)</term>
					<term>0000-0002-1322-915X (F. Milani)</term>
					<term>0009-0004-0725-7623 (M. Avramenko)</term>
					<term>0000-0002-9247-7476 (M. Dumas)</term>
				</keywords>
			</textClass>
			<abstract>
<div xmlns="http://www.tei-c.org/ns/1.0"><p>Reducing waiting times in business processes is crucial for minimizing waste and improving efficiency. To achieve this, analysts need to understand the causes of waiting times and identify relevant redesign options. To support this task, we introduce a conversational interface integrated with the Kronos tool to analyze waiting time causes and suggest process redesigns. The interface uses a Large Language Model (LLM) to query waiting time analysis results and contextual process data based on specific user requests. The tool additionally provides recommendations of redesign options to reduce the identified waiting times, based on a collection of redesign heuristics.</p></div>
			</abstract>
		</profileDesc>
	</teiHeader>
	<text xml:lang="en">
		<body>
<div xmlns="http://www.tei-c.org/ns/1.0"><head n="1.">Introduction</head><p>Understanding where and why waiting times occur in business processes is essential for reducing waiting time-related wastes and improving process efficiency. Waiting times occur when a case transitions from one activity to another <ref type="bibr" target="#b0">[1]</ref>. For instance, in a procurement process, waiting time may occur when a purchase order is approved and the order is waiting to be fulfilled or between receipt of goods and their inspection for approval. Identifying why such waiting times occur helps analysts to pinpoint inefficiencies and to assess possible redesign options.</p><p>Process mining techniques support the discovery of waiting times from event logs that record business process executions <ref type="bibr" target="#b1">[2]</ref>. Existing process mining tools <ref type="bibr" target="#b2">[3]</ref>, can identify and analyze waiting times from event logs. For example, Kronos <ref type="bibr" target="#b3">[4]</ref> -an open-source web-based tool -can both analyze waiting times and identify their causes. However, existing tools have two limitations. First, the results are typically presented through visualizations with basic interactivity, such as filtering and hiding data, but lack the capability for exploratory interaction to support customized analyst requests. Second, while these tools effectively analyze waiting times and their causes, they do not offer redesign suggestions for reducing waiting times.</p><p>In this paper, we introduce a tool integrated with Kronos <ref type="bibr" target="#b3">[4]</ref> that leverages a Large Language Model (LLM) to enable users to conversationally query event log data to analyze the causes of waiting times in a business process, and to obtain redesign suggestions for waiting time reduction. The tool is designed to discover and to quantify waiting times in a business process attributable to batching, prioritization, resource contention, and resource unavailability. Users interact with the tool via a chatbot interface. For each identified cause of waiting time, the tool provides redesign suggestions based on a catalog of redesign strategies.</p></div>
<div xmlns="http://www.tei-c.org/ns/1.0"><head n="2.">Tool Overview</head></div>
<div xmlns="http://www.tei-c.org/ns/1.0"><head n="2.1.">Architecture</head><p>The tool is based on an existing process mining tool called Kronos and a set of additional algorithms that, collectively, discover and analyze causes of waiting times from event logs provide redesign options. Figure <ref type="figure" target="#fig_0">1</ref> illustrates the architecture of the tool, highlighting the main components of the conversational interface. The interface has the following components. The frontend is developed using TypeScript and provides a simple chat interface for users to submit their queries. The user inputs their question, which is then forwarded to the backend for processing. The WebAPI, implemented using Flask and Gunicorn, acts as the intermediary between the frontend and the LLM. It handles the query forwarding, data retrieval, and response generation processes. The tool uses OpenAI's GPT-4 Turbo model for its language processing capabilities.</p><p>The LLM accesses several data sources to provide relevant responses, including waiting time analysis from Kronos, batching and prioritization strategies, resource working calendars, case attributes, and redesign strategies. We use OpenAI's "function calling" 1 to set up these data sources available for the LLM.</p><p>• Kronos Waiting Time Analysis: Kronos is the primary source of information, providing a detailed analysis of waiting time causes. The analysis results are stored in a database. Instructions were provided to the LLM to make it aware of the database schema. This enables the LLM to generate SQL queries, which are executed by the interface on the database. The retrieved information is sent back to the LLM for further processing. • Batching Strategies: Given an event log, batching strategies are discovered using an existing algorithm <ref type="bibr" target="#b4">[5]</ref> that analyzes how activity instances are grouped into batches and provides insights into the batch size, frequency, and activation rules 2 . • Prioritization Strategies are identified using another algorithm <ref type="bibr" target="#b4">[5]</ref>, which examines how tasks are prioritized in the process. This analysis helps in understanding the order in which tasks are performed and their impact on waiting times 3 . • Resource Working Calendars detail the availability schedules of resources. They are discovered using an existing algorithm <ref type="bibr" target="#b5">[6]</ref> that provides information on how resource availability affects waiting times 4 . • Case Attributes are discovered from the event log by the tool. These attributes provide additional context about the cases, such as their characteristics and the specific conditions under which they are processed. • Redesign Strategies: A compiled file containing different redesign strategies, their applications, examples, and references. The LLM is provided with a structured list of possible redesign strategies, enabling it to request specific information (description, example, references) on these strategies as needed.</p><p>The LLM is provided with pre-configured instructions to enhance its capabilities in interpreting queries and accessing/reading the data sources. Details of the prompts that the tool provides to the LLM, including the collection of redesign strategies, can be found in <ref type="bibr" target="#b6">[7]</ref>.</p></div>
<div xmlns="http://www.tei-c.org/ns/1.0"><head n="2.2.">User Flow</head><p>Figure <ref type="figure" target="#fig_1">2</ref> depicts the steps performed by the tool to respond to user queries. The process begins with a user submitting a question (step 'A'), which is forwarded to the LLM (step 'B'). The LLM performs a data requirement analysis (step 'C') to determine what specific data is required to generate a response. Next, relevant data is retrieved (step 'D'), sent back to the LLM (step 'E'), which generates a response and presents the final output to the user (step 'F').</p><p>The interface has a text input box where users can type their questions (see Figure <ref type="figure" target="#fig_2">3</ref>). Once submitted, the question appears in the chat box, and the "Send" button is disabled to prevent more questions until a response is provided. The interface dynamically adjusts its size based on the length of the questions and answers, ensuring that all content is readable.</p><p>2 https://github.com/AutomatedProcessImprovement/pix-framework/blob/main/src/pix_framework/discovery/ batch_processing 3 https://github.com/AutomatedProcessImprovement/pix-framework/tree/main/src/pix_framework/discovery/ prioritization 4 https://github.com/AutomatedProcessImprovement/pix-framework/tree/main/src/pix_framework/discovery/ resource_calendar_and_performance  Upon the first question submission (step 'A'), a thread is created <ref type="foot" target="#foot_1">5</ref> and an ID is assigned, which is kept in the session storage. Subsequent questions will use the same thread ID, allowing the LLM to be aware of the history of previous messages and answers, as well as the data connected to those interactions. If the user refreshes the page, the thread ID is no longer retained in memory, prompting the tool to create a new thread upon the next question submission. This ensures that each session maintains a dialogue history unless manually reset by the user.</p><p>Once a question is submitted (step 'A'), it is forwarded to the OpenAI GPT-4 Turbo LLM (step 'B') via their API<ref type="foot" target="#foot_2">6</ref> . To ensure the LLM understands its operational context and meets the requirements for analyzing event logs and suggesting process improvements, we have provided it with structured instructions <ref type="foot" target="#foot_3">7</ref> . The instructions are tiered at three levels to enhance the LLM's responsiveness. The first is LLM's Instructions, which contains general guidelines such as the LLM's goals and operational context. The second is General Message Instructions, specifying preferred data formats, instructions on analyzing waiting time causes and recommending the redesign options. The last is Direct Message Instructions which refine responses by concatenating them with user queries, ensuring, e.g., that responses follow a consistent time format. General and direct message instructions are included in each user message.</p><p>Based on the data request from the LLM, the necessary data is retrieved and provided to the LLM (step 'E'), enabling it to proceed with the final response generation (step 'F'). If an error occurs during the data retrieval process, an error message is returned to the LLM, allowing it to adjust the data request accordingly. Having analyzed the initial question from the user, the available data sources, and the knowledge of the LLM, the LLM generates the final response (step 'F'). This response is then presented to the user. The LLM uses markdown, supported by the interface, to secure that the user receives the answer in a structured and readable format. After the response is generated, the user can ask additional questions, with the LLM taking into account the context of previous messages.</p></div>
<div xmlns="http://www.tei-c.org/ns/1.0"><head n="3.">Maturity and Availability</head><p>The conversational LLM interface is a proof-of-concept. An initial user validation has been conducted with process mining experts. The preliminary results indicate the tool's usefulness for conversational exploration of waiting time causes and process redesigns.</p><p>The conversational interface is publicly available at http://kronos.cloud.ut.ee/. To use the interface, users must first upload an event log to Kronos. The implementation of the interface logic is available in GitHub repositories: one for the frontend 8 and one for the WebAPI 9 , together with instructions on usage. An API key from OpenAI is needed to start the tool and generate answers. A screencast that describes the tool is available on YouTube 10 .</p><p>The primary limitation of our tool is its reliance on pre-configured LLM instructions, which may not cover all user queries. The implementation is also constrained by the LLM performance and the efficiency of data retrieval processes. Response times can affect user experience, and result accuracy depends on event log data quality and predefined queries.</p></div>
<div xmlns="http://www.tei-c.org/ns/1.0"><head n="4.">Conclusion</head><p>The conversational interface integrated with Kronos helps users explore waiting time causes and obtain redesign suggestions. Using OpenAI's GPT-4 Turbo model, it provides dynamic responses to queries about waiting time causes and process redesigns. Structured instructions and function calling enable data retrieval from multiple sources to generate relevant responses. The interface supports iterative question-answering, maintaining context across sessions.</p></div><figure xmlns="http://www.tei-c.org/ns/1.0" xml:id="fig_0"><head>Figure 1 :</head><label>1</label><figDesc>Figure 1: Tool architecture</figDesc><graphic coords="2,130.96,311.22,333.35,186.27" type="bitmap" /></figure>
<figure xmlns="http://www.tei-c.org/ns/1.0" xml:id="fig_1"><head>Figure 2 :</head><label>2</label><figDesc>Figure 2: Overview of the conversational interface workflow.</figDesc><graphic coords="4,110.13,84.19,375.02,66.39" type="bitmap" /></figure>
<figure xmlns="http://www.tei-c.org/ns/1.0" xml:id="fig_2"><head>Figure 3 :</head><label>3</label><figDesc>Figure 3: Chat interface for user question submission.</figDesc></figure>
			<note xmlns="http://www.tei-c.org/ns/1.0" place="foot" n="1" xml:id="foot_0">https://platform.openai.com/docs/guides/function-calling</note>
			<note xmlns="http://www.tei-c.org/ns/1.0" place="foot" n="5" xml:id="foot_1">https://platform.openai.com/docs/api-reference/threads/object</note>
			<note xmlns="http://www.tei-c.org/ns/1.0" place="foot" n="6" xml:id="foot_2">https://openai.com/index/openai-api/</note>
			<note xmlns="http://www.tei-c.org/ns/1.0" place="foot" n="7" xml:id="foot_3">https://github.com/AutomatedProcessImprovement/waiting-time-backend/blob/main/assistant-instructions.txt</note>
		</body>
		<back>

			<div type="acknowledgement">
<div xmlns="http://www.tei-c.org/ns/1.0"><p>Acknowledgments Work funded by the European Research Council (PIX project).</p></div>
			</div>

			<div type="references">

				<listBibl>

<biblStruct xml:id="b0">
	<monogr>
		<title level="m" type="main">Why am I waiting? Data-driven analysis of waiting times in business processes</title>
		<author>
			<persName><forename type="first">K</forename><surname>Lashkevich</surname></persName>
		</author>
		<author>
			<persName><forename type="first">F</forename><surname>Milani</surname></persName>
		</author>
		<author>
			<persName><forename type="first">D</forename><surname>Chapela-Campa</surname></persName>
		</author>
		<author>
			<persName><forename type="first">I</forename><surname>Suvorau</surname></persName>
		</author>
		<author>
			<persName><forename type="first">M</forename><surname>Dumas</surname></persName>
		</author>
		<imprint>
			<date type="published" when="2023">2023</date>
			<publisher>Springer</publisher>
		</imprint>
	</monogr>
</biblStruct>

<biblStruct xml:id="b1">
	<monogr>
		<author>
			<persName><forename type="first">W</forename><forename type="middle">M P</forename><surname>Van Der Aalst</surname></persName>
		</author>
		<title level="m">Process Mining: Data Science in Action</title>
				<meeting>ess Mining: Data Science in Action</meeting>
		<imprint>
			<publisher>Springer</publisher>
			<date type="published" when="2016">2016</date>
		</imprint>
	</monogr>
	<note>2nd ed</note>
</biblStruct>

<biblStruct xml:id="b2">
	<analytic>
		<title level="a" type="main">Data-driven identification and analysis of waiting times in business processes: A systematic literature review</title>
		<author>
			<persName><forename type="first">M</forename><forename type="middle">A</forename><surname>Ali</surname></persName>
		</author>
		<author>
			<persName><forename type="first">F</forename><surname>Milani</surname></persName>
		</author>
		<author>
			<persName><forename type="first">M</forename><surname>Dumas</surname></persName>
		</author>
		<idno type="DOI">10.1007/s12599-024-00868-5</idno>
		<ptr target="https://doi.org/10.1007/s12599-024-00868-5" />
	</analytic>
	<monogr>
		<title level="j">Bus. Inf. Syst. Eng</title>
		<imprint>
			<date type="published" when="2024">2024</date>
		</imprint>
	</monogr>
</biblStruct>

<biblStruct xml:id="b3">
	<analytic>
		<title level="a" type="main">Kronos: Discovery and analysis of waiting time causes</title>
		<author>
			<persName><forename type="first">K</forename><surname>Lashkevich</surname></persName>
		</author>
		<author>
			<persName><forename type="first">F</forename><surname>Milani</surname></persName>
		</author>
		<author>
			<persName><forename type="first">D</forename><surname>Chapela-Campa</surname></persName>
		</author>
		<author>
			<persName><forename type="first">I</forename><surname>Suvorau</surname></persName>
		</author>
		<author>
			<persName><forename type="first">M</forename><surname>Dumas</surname></persName>
		</author>
	</analytic>
	<monogr>
		<title level="m">ICPM Doctoral Consortium/Demo</title>
				<imprint>
			<date type="published" when="2023">2023</date>
		</imprint>
	</monogr>
</biblStruct>

<biblStruct xml:id="b4">
	<monogr>
		<title level="m" type="main">Business process simulation with differentiated resources</title>
		<author>
			<persName><forename type="first">I</forename><surname>Halenok</surname></persName>
		</author>
		<imprint>
			<date type="published" when="2023">2023</date>
		</imprint>
	</monogr>
</biblStruct>

<biblStruct xml:id="b5">
	<monogr>
		<title level="m" type="main">Business process simulation with differentiated resources: Does it make a difference?</title>
		<author>
			<persName><forename type="first">O</forename><surname>López-Pintado</surname></persName>
		</author>
		<author>
			<persName><forename type="first">M</forename><surname>Dumas</surname></persName>
		</author>
		<imprint>
			<date type="published" when="2022">2022</date>
			<publisher>Springer</publisher>
		</imprint>
	</monogr>
</biblStruct>

<biblStruct xml:id="b6">
	<analytic>
		<title level="a" type="main">LLM-assisted optimization of waiting time in business processes: A prompting approach</title>
		<author>
			<persName><forename type="first">K</forename><surname>Lashkevich</surname></persName>
		</author>
		<author>
			<persName><forename type="first">F</forename><surname>Milani</surname></persName>
		</author>
		<author>
			<persName><forename type="first">M</forename><surname>Avramenko</surname></persName>
		</author>
		<author>
			<persName><forename type="first">M</forename><surname>Dumas</surname></persName>
		</author>
		<ptr target="https://youtu.be/ScxjMnjqPc8" />
	</analytic>
	<monogr>
		<title level="m">BPM 2024</title>
				<imprint>
			<publisher>Springer</publisher>
			<date type="published" when="2024">2024</date>
		</imprint>
	</monogr>
	<note>To appear</note>
</biblStruct>

				</listBibl>
			</div>
		</back>
	</text>
</TEI>
