<?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">Building Management using the Semantic Web and Hypermedia Agents</title>
			</titleStmt>
			<publicationStmt>
				<publisher/>
				<availability status="unknown"><licence/></availability>
			</publicationStmt>
			<sourceDesc>
				<biblStruct>
					<analytic>
						<author>
							<persName><forename type="first">Eoin</forename><surname>O'neill</surname></persName>
							<affiliation key="aff0">
								<orgName type="department">UCD School of Computer Science</orgName>
								<orgName type="institution">University College Dublin</orgName>
								<address>
									<settlement>Belfield, Dublin</settlement>
								</address>
							</affiliation>
						</author>
						<author>
							<persName><forename type="first">Katharine</forename><surname>Beaumont</surname></persName>
							<email>katharine.beaumont@ucdconnect.ie</email>
							<affiliation key="aff0">
								<orgName type="department">UCD School of Computer Science</orgName>
								<orgName type="institution">University College Dublin</orgName>
								<address>
									<settlement>Belfield, Dublin</settlement>
								</address>
							</affiliation>
						</author>
						<author>
							<persName><forename type="first">Nestor</forename><forename type="middle">Velasco</forename><surname>Bermeo</surname></persName>
							<email>nestorvb@ucd.ie</email>
							<affiliation key="aff0">
								<orgName type="department">UCD School of Computer Science</orgName>
								<orgName type="institution">University College Dublin</orgName>
								<address>
									<settlement>Belfield, Dublin</settlement>
								</address>
							</affiliation>
						</author>
						<author>
							<persName><forename type="first">Rem</forename><surname>Collier</surname></persName>
							<email>rem.collier@ucd.ie</email>
							<affiliation key="aff0">
								<orgName type="department">UCD School of Computer Science</orgName>
								<orgName type="institution">University College Dublin</orgName>
								<address>
									<settlement>Belfield, Dublin</settlement>
								</address>
							</affiliation>
						</author>
						<author>
							<affiliation key="aff1">
								<address>
									<country key="IE">Ireland</country>
								</address>
							</affiliation>
						</author>
						<title level="a" type="main">Building Management using the Semantic Web and Hypermedia Agents</title>
					</analytic>
					<monogr>
						<imprint>
							<date/>
						</imprint>
					</monogr>
					<idno type="MD5">D877F899CC6531A7FFB2C0744D1E3F86</idno>
				</biblStruct>
			</sourceDesc>
		</fileDesc>
		<encodingDesc>
			<appInfo>
				<application version="0.7.2" ident="GROBID" when="2023-03-25T00:48+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>Semantic Web</term>
					<term>Semantic Agents</term>
					<term>Intelligent Agents</term>
					<term>Multi-Agent Microservices</term>
				</keywords>
			</textClass>
			<abstract>
<div xmlns="http://www.tei-c.org/ns/1.0"><p>The following document describes the submission to the All The Agents Challenge of a system that interacts with the Built on Linked Data Server (BOLD) 1 . Our solution provides a Building Management Agent Oriented Micro Service (AOMS) built using Multi-Agent MicroServices (MAMS) technology in order to manage luminance levels on a per room basis based on the occupancy levels of each room. This solution provides showcases a collaboration between a multitude of different agents that work together in order to continuously monitor and interact with the server using REST, in accordance with updates applied to the system with each time tick.</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>When Ciortea et. al <ref type="bibr" target="#b0">[1]</ref> discussed the cross over between autonomous agents and the semantic web, they described agents being deployed in a semantically defined web environment that could be interacted with and reasoned about. This submission is a step towards achieving the link between autonomous agents and the web: a step towards hMAS <ref type="bibr" target="#b1">[2]</ref>. It is concerned with the design of agents that are able to interact with the Building on Linked Data (BOLD) environment, store semantic information from this environment within Knowledge Stores that are particular to each agent, and reason about this data in order to enact changes on the system. Our solution is implemented as a Multi-Agent MicroServices (MAMS) <ref type="bibr" target="#b2">[3]</ref> system that routinely polls the BOLD Server in order to check the status of each room.</p><p>Through the use of ontologies, agents have the ability to create an internal model of the building. By defining multiple ontologies we allowed the agents to adopt beliefs about different entities within the room, both static and dynamic values that change with each iteration of the simulation.</p></div>
<div xmlns="http://www.tei-c.org/ns/1.0"><head n="1.1.">Technologies</head><p>This system combines semantic web, multi-agent systems and web technologies. The overall system is build using the Multi-Agent MicroServices (MAMS) <ref type="bibr" target="#b2">[3,</ref><ref type="bibr" target="#b3">4,</ref><ref type="bibr" target="#b4">5]</ref> architectural style. MAMS promotes the creation of systems that are comprised of Agent-Oriented MicroServices (AOMS) and Plain-Old MicroServices (POMS). In this approach, AOMS are comprised of one or more agents whose state is partially exposed through a REpresentational StateTransfer (REST) interface. In our system, the AOMS is the Building Management Service presented in Figure <ref type="figure" target="#fig_0">1</ref>. This service interacts with the Built on Linked Data (BOLD) Server, a semantically defined building environment which models the IBM building in Dublin, Ireland. The agents in this system interact with the environment using REST to retrieve updates about the current state of the environment. This information is then incorporated into their logical reasoning apparatus.</p><p>The ASTRA programming language is used because BDI agents are both reactive and responsive to their environment. They continually receive events from the environment and update their beliefs, which are incorporated into flexible plans <ref type="bibr" target="#b5">[6]</ref>. They offer significant advantages in developing autonomous systems and support the incorporation of a range of AI techniques <ref type="bibr" target="#b6">[7]</ref>.</p><p>Using ASTRA allows agents to take advantage of ASTRA's modularity <ref type="bibr" target="#b7">[8]</ref>. ASTRA modules represent internal libraries, which allow for five kinds of annotation: terms, formulae, sensors, actions and events <ref type="bibr" target="#b7">[8]</ref>. A single agent can create several copies of the same module, with different names and states <ref type="bibr" target="#b7">[8]</ref>. The key module in the current system is the Jena Module, which acts both as a Knowledge Store for the agents and as an interface that connects agents to semantic web technology. The RDF Schema module allows the agent to identify the relationships between the different entities within the system in order to classify different parts of the building. This allows the agent to adopt beliefs about the environment which leads to action based on these entities. This is further discussed in 2.2. </p></div>
<div xmlns="http://www.tei-c.org/ns/1.0"><head n="2.">System architecture</head></div>
<div xmlns="http://www.tei-c.org/ns/1.0"><head n="2.1.">Building Management Service</head><p>The Building Management Service comprises of a number of BDI agents. A Main agent has initial beliefs concerning the sim url of the building and the building url: these are the BOLD Server endpoints. The Main agent starts the Sim agent and injects it with the sim url. The Sim agent iteratively queries the url, replacing the contents of the Knowledge Store with the results of each request.</p><p>During the first iteration, the Sim agent sends a message to the Main agent to inform it that the BOLD Server is running. The Main agent then creates the Building Manager which has the dual responsibility of mapping the building and creating Room agents for each room it finds. The building to be explored is passed by the Main agent.</p><p>To map the building, the Building Manager recursively iterates through the building using the brickf:hasPart predicate. The Building Manager uses it's Knowledge Store, referencing schema and maintaining a set of internal beliefs about the places that have been explored. Once complete, it queries the Knowledge Store returning the urls of all the rooms identified by the rdf:type predicate, where the object is the brick:Room concept. Once complete, the Building Manager creates a Room agent for each room, and initialises them with their individual room url.</p><p>Each Room agent then queries all of the resources that exist within it's room, searching for things using the brickf:isLocatedIn predicate. It maintains a set of beliefs about the properties associated with various things that it finds.</p><p>On successive iterations, the Room agents use these beliefs to capture the updated state of the building after each iteration. The Room agent is interesting because it maintains two RDF triple stores: a static one for triples that do not change; and a dynamic one for triples that do change (i.e. the properties of the things in the room). This allows us to minimise the number of GET requests required on each iteration.</p><p>The overall behaviour of the system is driven by the Sim agent which is responsible for detecting the start of each iteration of the simulator. Upon detection, the Sim agent informs all the Room agents via internal message passing which is routed via the Main agent and the Building agent. Upon receipt of this message, each Room agent updates their dynamic belief store by querying all the things that it knows of in the room. If the room is unoccupied but the lights are left on, the agent turns the light off by issuing a PUT request to the resource with the appropriate TURTLE content.</p></div>
<div xmlns="http://www.tei-c.org/ns/1.0"><head n="2.2.">Jena Module (RDF Knowledge Store) and RDF Schema Module</head><p>A core component of the agents is the use of Apache Jena and modules. Apache Jena is an open source framework that provides tools to interact with the Semantic Web and Linked Data applications. ASTRA uses modules to represent internal libraries and agents access the library via the module API <ref type="bibr" target="#b8">[9,</ref><ref type="bibr" target="#b7">8]</ref>.</p><p>The Knowledge Store is the module used by the Building Manager, Room and Sim to interact with the building via REST and add the information returned (in the form of turtle) to the Jena model contained within it. Each agent has an individual Knowledge Store. See Figure <ref type="figure" target="#fig_1">2</ref>. In addition, an RDF Schema module allows agents to interact with RDF Schema. Given Room agents must cater for both static and dynamic knowledge, they are given two Knowledge Stores: one for the static knowledge and one for the dynamic knowledge. In this way, the Room agents only need to update the dynamic knowledge on each iteration.</p><p>The Jena integration itself takes advantage of two ASTRA features: custom events and custom formulae. The custom event model allows agents to be notified when a url has successfully been read. The TripleFormula class is created to provide an internal representation of Triples. ASTRA includes a mechanism for expressing custom formulae in the agent code which is implemented using the RDFSchema module. For example, in ASTRA, to query room triples, we use rdf.type(string url, brick.qualifiedName("Room")). A NodeFactory class is then created to extend the basic reasoner to support the new triple formulae. The actual support is implemented in a TripleNode class. Finally, the Knowledge Store modules are registered with the agent using the Queryable interface. Implementors of this interface are sources of potential formulae to be matched against a query during the reasoning process. These potential formulae are then processed in the TripleNode<ref type="foot" target="#foot_0">1</ref> . </p></div>
<div xmlns="http://www.tei-c.org/ns/1.0"><head n="3.">Dynamicity and Coordination</head><p>The Building Management system supports dynamicity and coordination. The agents in this system are dynamic in the sense that they react to changes in the environment. Based on their updated set of beliefs, the Room agents enact changes on the environment individually by making RESTful calls to the BOLD server in order to turn light switches on and off based on the values of both luminance and occupancy levels.</p><p>The Room agents also update their state each time there is a time tick in the environment. Using the dynamic Knowledge Store, each Room agent maintains an up to date description of its room in accordance with the information provided by the server. To do this, Room agents clear their dynamic Knowledge Store and update their beliefs. This effects the actions they perform on the environment. This is a fully coordinated system with multiple agents communicating using FIPA-ACL. When created, the Sim agent issues a message to the Main agent. On receipt of this first message, the Main agent creates the Building Agent.</p><p>For every subsequent time tick, the Main agent forwards the message to the Building Manager agent, who in turn forwards the message to each Room agent, prompting them to act.</p></div>
<div xmlns="http://www.tei-c.org/ns/1.0"><head n="4.">Existing work and challenges</head><p>The combination of BDI agents with semantic web technology has been broached with JASDL <ref type="bibr" target="#b9">[10]</ref>. This uses an annotation system in a way that is similar to the way our approach uses ASTRA modules. However this can be seen as a tighter integration, with a strong coupling with an agent's beliefs. In the system presented in this paper, the use of modules is more akin to adding a skill to the agent, that informs but does not integrate with, nor enforce the consistency of beliefs. It is a more loosely coupled integration.</p><p>By allowing this, this system can integrate with multiple ontologies simultaneously. A disadvantage is that there is no enforced consistency, but an advantage is that it paves the way for future work involving the dynamic insertion of modules. This would allow agents to discover which ontologies are required at runtime, making them more flexible, and facilitating reuse across different environments.</p><p>In <ref type="bibr" target="#b10">[11]</ref>, the vision for the coming web is described in it's entirety. It describes how the semantic web will lend a hand in creating a web of resources, each of which could be it's own network in turn, such as an encapsulated neural network. This allows for resources such as computational entities to exist within the network, and for those resources to also make use of other resources within the network. This was one of the core tenets of the MAMS vision, with agents themselves exposing different aspects of themselves as virtual resources on the web, while also utilising the web in order to achieve system and individual agent goals.</p><p>It is the hope of the authors that future work will build on ideas in this submission, moving towards agent systems that are situated in a web environment, with a modular use of ontologies, in order to learn relationships that exist across the network. By observation and reasoning about the network, agents can start to autonomously, at runtime utilise semantically defined, previously unknown resources on the network.</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: System Diagram</figDesc><graphic coords="2,213.06,474.19,166.67,145.78" 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: Agent-BOLD Server Interaction</figDesc><graphic coords="4,233.89,285.82,125.00,179.98" type="bitmap" /></figure>
			<note xmlns="http://www.tei-c.org/ns/1.0" place="foot" n="1" xml:id="foot_0">Implementations of all these classes can be found in https://gitlab.com/mams-ucd/mams-cartago/-/tree/master/mams-astra-jena and are now part of the MAMS codebase.</note>
		</body>
		<back>

			<div type="acknowledgement">
<div xmlns="http://www.tei-c.org/ns/1.0"><head>Acknowledgments</head><p>This research is funded under the SFI Strategic Partnership Programme (16/SPP/3296) and is co-funded by Origin Enterprises plc.</p></div>
			</div>

			<div type="references">

				<listBibl>

<biblStruct xml:id="b0">
	<analytic>
		<title level="a" type="main">A decade in hindsight: the missing bridge between multi-agent systems and the world wide web</title>
		<author>
			<persName><forename type="first">A</forename><surname>Ciortea</surname></persName>
		</author>
		<author>
			<persName><forename type="first">S</forename><surname>Mayer</surname></persName>
		</author>
		<author>
			<persName><forename type="first">F</forename><surname>Gandon</surname></persName>
		</author>
		<author>
			<persName><forename type="first">O</forename><surname>Boissier</surname></persName>
		</author>
		<author>
			<persName><forename type="first">A</forename><surname>Ricci</surname></persName>
		</author>
		<author>
			<persName><forename type="first">A</forename><surname>Zimmermann</surname></persName>
		</author>
	</analytic>
	<monogr>
		<title level="m">Proceedings of the International Conference on Autonomous Agents and Multiagent Systems</title>
				<meeting>the International Conference on Autonomous Agents and Multiagent Systems</meeting>
		<imprint>
			<date type="published" when="2019">2019</date>
		</imprint>
	</monogr>
</biblStruct>

<biblStruct xml:id="b1">
	<analytic>
		<title level="a" type="main">4.4 merry hmas and happy new web: A wish for standardizing an ai-friendly web architecture for hypermedia multi-agent systems</title>
		<author>
			<persName><forename type="first">F</forename><surname>Gandon</surname></persName>
		</author>
	</analytic>
	<monogr>
		<title level="j">Autonomous Agents on the Web</title>
		<imprint>
			<biblScope unit="volume">11</biblScope>
			<biblScope unit="page">42</biblScope>
			<date type="published" when="2021">2021</date>
		</imprint>
	</monogr>
</biblStruct>

<biblStruct xml:id="b2">
	<analytic>
		<title level="a" type="main">Mams: Multi-agent microservices</title>
		<author>
			<persName><forename type="first">R</forename><surname>Collier</surname></persName>
		</author>
		<author>
			<persName><forename type="first">E</forename><surname>O'neill</surname></persName>
		</author>
		<author>
			<persName><forename type="first">D</forename><surname>Lillis</surname></persName>
		</author>
		<author>
			<persName><forename type="first">G</forename><surname>O'hare</surname></persName>
		</author>
	</analytic>
	<monogr>
		<title level="m">Companion Proceedings of The 2019 World Wide Web Conference</title>
				<imprint>
			<date type="published" when="2019">2019</date>
			<biblScope unit="page" from="655" to="662" />
		</imprint>
	</monogr>
</biblStruct>

<biblStruct xml:id="b3">
	<analytic>
		<title level="a" type="main">Delivering multi-agent microservices using cartago</title>
		<author>
			<persName><forename type="first">E</forename><surname>O'neill</surname></persName>
		</author>
		<author>
			<persName><forename type="first">D</forename><surname>Lillis</surname></persName>
		</author>
		<author>
			<persName><forename type="first">G</forename><forename type="middle">M</forename><surname>O'hare</surname></persName>
		</author>
		<author>
			<persName><forename type="first">R</forename><forename type="middle">W</forename><surname>Collier</surname></persName>
		</author>
	</analytic>
	<monogr>
		<title level="m">International Workshop on Engineering Multi-Agent Systems</title>
				<imprint>
			<publisher>Springer</publisher>
			<date type="published" when="2020">2020</date>
			<biblScope unit="page" from="1" to="20" />
		</imprint>
	</monogr>
</biblStruct>

<biblStruct xml:id="b4">
	<analytic>
		<title level="a" type="main">Explicit modelling of resources for multiagent microservices using the cartago framework</title>
		<author>
			<persName><forename type="first">E</forename><surname>O'neill</surname></persName>
		</author>
		<author>
			<persName><forename type="first">D</forename><surname>Lillis</surname></persName>
		</author>
		<author>
			<persName><forename type="first">G</forename><forename type="middle">M</forename><surname>O'hare</surname></persName>
		</author>
		<author>
			<persName><forename type="first">R</forename><forename type="middle">W</forename><surname>Collier</surname></persName>
		</author>
	</analytic>
	<monogr>
		<title level="m">Proceedings of the 19th International Conference on Autonomous Agents and MultiAgent Systems</title>
				<meeting>the 19th International Conference on Autonomous Agents and MultiAgent Systems</meeting>
		<imprint>
			<date type="published" when="2020">2020</date>
			<biblScope unit="page" from="1957" to="1959" />
		</imprint>
	</monogr>
</biblStruct>

<biblStruct xml:id="b5">
	<analytic>
		<title level="a" type="main">Incorporating learning in bdi agents</title>
		<author>
			<persName><forename type="first">S</forename><surname>Airiau</surname></persName>
		</author>
		<author>
			<persName><forename type="first">L</forename><surname>Padgham</surname></persName>
		</author>
		<author>
			<persName><forename type="first">S</forename><surname>Sardina</surname></persName>
		</author>
		<author>
			<persName><forename type="first">S</forename><surname>Sen</surname></persName>
		</author>
	</analytic>
	<monogr>
		<title level="m">Workshop AAMAS: adaptive and learning agents and MAS (ALAMAS+ ALAg), ACM Estoril</title>
				<imprint>
			<date type="published" when="2008">2008</date>
			<biblScope unit="page" from="49" to="56" />
		</imprint>
	</monogr>
</biblStruct>

<biblStruct xml:id="b6">
	<analytic>
		<title level="a" type="main">Agent programming in the cognitive era</title>
		<author>
			<persName><forename type="first">R</forename><forename type="middle">H</forename><surname>Bordini</surname></persName>
		</author>
		<author>
			<persName><forename type="first">A</forename><forename type="middle">El</forename><surname>Fallah Seghrouchni</surname></persName>
		</author>
		<author>
			<persName><forename type="first">K</forename><surname>Hindriks</surname></persName>
		</author>
		<author>
			<persName><forename type="first">B</forename><surname>Logan</surname></persName>
		</author>
		<author>
			<persName><forename type="first">A</forename><surname>Ricci</surname></persName>
		</author>
	</analytic>
	<monogr>
		<title level="j">Autonomous Agents and Multi-Agent Systems</title>
		<imprint>
			<biblScope unit="volume">34</biblScope>
			<biblScope unit="page" from="1" to="31" />
			<date type="published" when="2020">2020</date>
		</imprint>
	</monogr>
</biblStruct>

<biblStruct xml:id="b7">
	<analytic>
		<title level="a" type="main">Reflecting on agent programming with agentspeak (l)</title>
		<author>
			<persName><forename type="first">R</forename><forename type="middle">W</forename><surname>Collier</surname></persName>
		</author>
		<author>
			<persName><forename type="first">S</forename><surname>Russell</surname></persName>
		</author>
		<author>
			<persName><forename type="first">D</forename><surname>Lillis</surname></persName>
		</author>
	</analytic>
	<monogr>
		<title level="m">International Conference on Principles and Practice of Multi-Agent Systems</title>
				<imprint>
			<publisher>Springer</publisher>
			<date type="published" when="2015">2015</date>
			<biblScope unit="page" from="351" to="366" />
		</imprint>
	</monogr>
</biblStruct>

<biblStruct xml:id="b8">
	<monogr>
		<author>
			<persName><forename type="first">T</forename><forename type="middle">A S</forename><surname>Foundation</surname></persName>
		</author>
		<ptr target="https://jena.apache.org/" />
		<title level="m">Apache jena</title>
				<imprint>
			<date type="published" when="2021">2021</date>
		</imprint>
	</monogr>
</biblStruct>

<biblStruct xml:id="b9">
	<analytic>
		<title level="a" type="main">Jasdl: A practical programming approach combining agent and semantic web technologies</title>
		<author>
			<persName><forename type="first">T</forename><surname>Klapiscak</surname></persName>
		</author>
		<author>
			<persName><forename type="first">R</forename><forename type="middle">H</forename><surname>Bordini</surname></persName>
		</author>
	</analytic>
	<monogr>
		<title level="m">International Workshop on Declarative Agent Languages and Technologies</title>
				<imprint>
			<publisher>Springer</publisher>
			<date type="published" when="2008">2008</date>
			<biblScope unit="page" from="91" to="110" />
		</imprint>
	</monogr>
</biblStruct>

<biblStruct xml:id="b10">
	<monogr>
		<title level="m" type="main">From linked data knowledge graphs to linked intelligence intelligence graphs or the potential of the semantic web to break the walls between semantic networks and computational networks</title>
		<author>
			<persName><forename type="first">F</forename><surname>Gandon</surname></persName>
		</author>
		<ptr target="https://www.youtube.com/watch?v=b9GPOOu2PTM,iSWCVisionTrack" />
		<imprint>
			<date type="published" when="2020">2020</date>
		</imprint>
	</monogr>
</biblStruct>

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