<!DOCTYPE article PUBLIC "-//NLM//DTD JATS (Z39.96) Journal Archiving and Interchange DTD v1.0 20120330//EN" "JATS-archivearticle1.dtd">
<article xmlns:xlink="http://www.w3.org/1999/xlink">
  <front>
    <journal-meta>
      <journal-title-group>
        <journal-title>M. Färber);</journal-title>
      </journal-title-group>
    </journal-meta>
    <article-meta>
      <title-group>
        <article-title>Ontology for Modeling the Energy Consumption of AI Models</article-title>
      </title-group>
      <contrib-group>
        <contrib contrib-type="author">
          <string-name>Michael Färber</string-name>
          <email>michael.faerber@kit.edu</email>
          <xref ref-type="aff" rid="aff0">0</xref>
          <xref ref-type="aff" rid="aff1">1</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>David Lamprecht</string-name>
          <email>david.lamprecht@student.kit.edu</email>
          <xref ref-type="aff" rid="aff0">0</xref>
          <xref ref-type="aff" rid="aff1">1</xref>
        </contrib>
        <contrib contrib-type="editor">
          <string-name>Machine Learning, Green AI, Energy Consumption, Ontology Engineering</string-name>
        </contrib>
        <aff id="aff0">
          <label>0</label>
          <institution>Karlsruhe Institute of Technology (KIT), Institute AIFB</institution>
          ,
          <country country="DE">Germany</country>
        </aff>
        <aff id="aff1">
          <label>1</label>
          <institution>Ontology for Informatics</institution>
        </aff>
      </contrib-group>
      <pub-date>
        <year>2022</year>
      </pub-date>
      <volume>000</volume>
      <fpage>0</fpage>
      <lpage>0002</lpage>
      <abstract>
        <p>Modeling AI systems' characteristics of energy consumption and their sustainability level as an extension of the FAIR data principles has been considered only rudimentarily. In this paper, we propose the Green AI Ontology for modeling the energy consumption and other environmental aspects of AI models. We evaluate our ontology based on competency questions. Our ontology is available at https://w3id.org/ Green-AI-Ontology and can be used in a variety of scenarios, ranging from comprehensive research data management to strategic controlling of institutions and environmental eforts in politics.</p>
      </abstract>
    </article-meta>
  </front>
  <body>
    <sec id="sec-1">
      <title>1. Introduction</title>
      <p>CEUR
Workshop
Proceedings</p>
      <sec id="sec-1-1">
        <title>Package</title>
        <p>power draw</p>
        <p>energy
consumption</p>
        <p>Identifier
hasTeraFLOPS
hasIdentifier
hasPackagehPaoswEenreDrgraywConsumpthioansIdentifier hasFrequency
hasEnergyConsumption
hasPackagePowerDraw
hasCores</p>
      </sec>
      <sec id="sec-1-2">
        <title>Frequency in Hz</title>
      </sec>
      <sec id="sec-1-3">
        <title>Cores</title>
        <p>CPU
hasGPU
hasCPU
hasCPU
hasCPUCount
GPU
hasGPU</p>
      </sec>
      <sec id="sec-1-4">
        <title>GPU Count</title>
      </sec>
      <sec id="sec-1-5">
        <title>Provider/Cloud</title>
      </sec>
      <sec id="sec-1-6">
        <title>Service</title>
      </sec>
      <sec id="sec-1-7">
        <title>TeraFLOPS utilization count</title>
        <p>utilization
count</p>
      </sec>
      <sec id="sec-1-8">
        <title>Location</title>
      </sec>
      <sec id="sec-1-9">
        <title>Energy mix emission factor</title>
      </sec>
      <sec id="sec-1-10">
        <title>Version</title>
      </sec>
      <sec id="sec-1-11">
        <title>Name</title>
        <p>hasVersion name</p>
      </sec>
      <sec id="sec-1-12">
        <title>Energy</title>
      </sec>
      <sec id="sec-1-13">
        <title>Measurement</title>
      </sec>
      <sec id="sec-1-14">
        <title>Service</title>
        <p>hasUrl
FPO
hasFPO</p>
        <p>haskWh
kWh of
electricity</p>
        <p>hasLocation
hasEnergyMixEmissionFactor
hasGPUCount
hasLocation
subClassOf</p>
        <p>usedEnergyMeasurementService
usedEnergyMeasurementServiceAllExperiments
hasEnergyMetrics
hasEnergyMetricsAllExperiments</p>
      </sec>
      <sec id="sec-1-15">
        <title>AI Model</title>
        <p>creates
URL</p>
      </sec>
      <sec id="sec-1-16">
        <title>Storage</title>
        <p>hasProvider
hasStorage</p>
      </sec>
      <sec id="sec-1-17">
        <title>FLOPS/W</title>
      </sec>
      <sec id="sec-1-18">
        <title>Hardware Settings</title>
      </sec>
      <sec id="sec-1-19">
        <title>Software Settings</title>
        <p>hasFLOPSperWatt hasSoftwareSettings
hasHardwareSettings
count
count</p>
      </sec>
      <sec id="sec-1-20">
        <title>Version</title>
      </sec>
      <sec id="sec-1-21">
        <title>CPU Count URL</title>
      </sec>
      <sec id="sec-1-22">
        <title>Hardware Type</title>
        <p>hasVersion
hasURL</p>
      </sec>
      <sec id="sec-1-23">
        <title>Name</title>
      </sec>
      <sec id="sec-1-24">
        <title>Memory</title>
        <p>hasName
hasHardwareType
hasMemory</p>
        <p>OS
hasOS</p>
      </sec>
      <sec id="sec-1-25">
        <title>Module/Package</title>
        <p>Programming
hasModule language
hasProgrammingLanguage
#Paramters
hasPrameters
allExperminentsRunTime
hasFinalRunTime
hasModelSize</p>
      </sec>
      <sec id="sec-1-26">
        <title>Time</title>
      </sec>
      <sec id="sec-1-27">
        <title>Time</title>
      </sec>
      <sec id="sec-1-28">
        <title>Model Size</title>
        <p>irao:hasAuthor
irao:Researcher
irao:Research</p>
      </sec>
      <sec id="sec-1-29">
        <title>Projekt</title>
        <p>subClassOf
subClassOf
foaf:Person
vivo:Project</p>
      </sec>
      <sec id="sec-1-30">
        <title>Energy Measure</title>
        <p>hasWatt
hasJoul</p>
      </sec>
      <sec id="sec-1-31">
        <title>Watt</title>
        <p>irao:hasPublication
trainedOn
hasResearchProjekt
hasSocialCosthasKgOfCO2eq</p>
      </sec>
      <sec id="sec-1-32">
        <title>Joul</title>
        <p>irao:Informatics</p>
      </sec>
      <sec id="sec-1-33">
        <title>Research Artifact</title>
        <p>subClassOf
irao:Dataset
social cost of
carbon in US$</p>
        <p>Kg of CO2eq
irao:hasPublication</p>
        <p>subClassOf
irao:Publication
irao:Software</p>
        <p>
          In this paper, we propose – to our knowledge – the first ontology for modeling the energy
consumption of AI models. It is available at https://w3id.org/Green-AI-Ontology (OWL file at
https://w3id.org/Green-AI-Ontology/ontology). We create a knowledge graph based on our
ontology and evaluate our ontology based on competency questions. Our ontology can be used
in various scenarios, ranging from improved research data management to strategic controlling
of institutions and implementation of standards.
2. The Green AI Ontology
Ontology Design. Figure 1 shows the main classes and properties of the ontology. The
corresponding documentation is linked in our repository. Overall, our ontology is designed to
model the following aspects:
1. Metrics and tools: This part addresses the metrics that are used to measure the energy
consumption of AI models. Apart from the pure values (Energy Measure), we consider the
online services (Energy Measurement Service) with which the values can be determined.
Energy Measurement Service is defined as a subclass of Energy Measurement so that all
relevant key figures are modeled in addition to information about the service.
2. Hardware settings, cloud service, and location: The property hasHardwareSettings shows
information about the hardware used. In addition to the modeling of private
infrastructures, services/cloud providers are represented here. The location of the hardware (e.g.,
city, country), which may have an impact on the environmental balance, can also be taken
into account.
3. Software settings: The property hasSoftwareSettings shows information about the software
used, including software packages and modules.
4. Linking to scholarly linked data: This part of the ontology is designed to integrate the
modeled energy consumption information into the modeling of the scientific landscape.
Since the AI models are closely linked to further computer science artifacts (e.g., datasets,
software), we reuse the Ontology for Informatics Research Artefacts [
          <xref ref-type="bibr" rid="ref3">3</xref>
          ] considering best
practice for reusing existing ontologies. As a result, the modeled information is not a silo
but is closely linked to papers, data sets, and researchers. In this way, novel queries and
strategic controlling are possible (e.g., answering: What is the average energy consumption
of AI models developed and trained at my institution over the last five years? ).
        </p>
        <p>
          Knowledge Graph Construction. To create a knowledge graph based on our ontology,
we first applied 10 regex patterns (an extension of [
          <xref ref-type="bibr" rid="ref6">6</xref>
          ]) on all 217,000 arXive computer science
papers as of July 31, 2020 (from http://unarxive.org). In this way, we obtained 3,016 energy
information units. However, we noticed that the accuracy of the matched patterns is insuficient
due to the low precision of the information extraction approach. For instance, a large portion
of the extracted energy information refers to non-AI models, such as mobile phones and e-cars.
        </p>
        <p>Thus, we refrained from this approach and instead asked AI researchers via a questionnaire
to report the energy consumption of AI models published in papers. In this way, we obtained a
proof-of-concept knowledge graph, modeling 40 AI models and 1,975 statements.</p>
        <p>Ontology Evaluation. Following the best practices of ontology engineering (e.g., the NeOn
ontology engineering methodology), we identified 15 competency questions (see our repository;
based on 79 Green AI-related papers that are listed in our repository) that our ontology should
be able to answer. Based on our created knowledge graph and created SPARQL queries (see our
repository and Listing 1), we were able to answer all competence questions.</p>
        <p>Use Cases. In the following, we outline several potential use cases of our ontology.</p>
        <p>
          Research Data Management. The FAIR principles [
          <xref ref-type="bibr" rid="ref1">1</xref>
          ] have been proposed to ensure that
resources are findable, accessible, interoperable, and reusable. Our ontology can be considered
SELECT * WHERE { ?AIModel a gai:AIModel .
        </p>
        <p>?AIModel gai:hasEnergyMetrics ?EnergyMetrics .</p>
        <p>?EnergyMetrics gai:hasFPO ?FloatingPointOperations . }
Listing 1: SPARQL query answering “How many floating point operations (FPO) do the AI
models have?”
an extension of these principles, allowing the modeling of usage information next to existing
ontologies and knowledge graphs.</p>
        <p>
          AI Systems. Engineers training and deploying AI models as well as end users may be
increasingly interested in knowing the environmental background of given AI models [
          <xref ref-type="bibr" rid="ref5">5</xref>
          ] in order to
assess them more thoroughly than merely for their efectiveness. Our modeling of the energy
consumption of AI models is not restricted to one metric (e.g., CO2, run time); instead, our
ontology allows the modeling of several measurements for each AI model.
        </p>
        <p>Society. From the perspective of popular sciences and politicians, our ontology complies
with the rising public awareness of Green AI and environmental studies. The ontology enables
energy consumption to be put into perspective (e.g., comparing energy consumption of language
models and bitcoin mining).</p>
      </sec>
    </sec>
    <sec id="sec-2">
      <title>3. Conclusion</title>
      <p>In this paper, we proposed the Green AI Ontology for modeling the energy consumption of
AI models. It can be used to extend academic knowledge graphs, to encourage researchers to
provide information on the energy consumption of their AI models, and to ensure that the
community appreciates this information.</p>
    </sec>
  </body>
  <back>
    <ref-list>
      <ref id="ref1">
        <mixed-citation>
          [1]
          <string-name>
            <given-names>M. D.</given-names>
            <surname>Wilkinson</surname>
          </string-name>
          , et al.,
          <article-title>The FAIR Guiding Principles for scientific data management and stewardship</article-title>
          , Scientific
          <string-name>
            <surname>Data</surname>
          </string-name>
          (
          <year>2016</year>
          )
          <fpage>2052</fpage>
          -
          <lpage>4463</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref2">
        <mixed-citation>
          [2]
          <string-name>
            <given-names>V. B.</given-names>
            <surname>Nguyen</surname>
          </string-name>
          ,
          <string-name>
            <given-names>V.</given-names>
            <surname>Svátek</surname>
          </string-name>
          , G. Rabby, Ó. Corcho,
          <article-title>Ontologies Supporting Research-Related Information Foraging Using Knowledge Graphs: Literature Survey and Holistic Model Mapping</article-title>
          ,
          <source>in: Proc. of EKAW</source>
          ,
          <year>2020</year>
          , pp.
          <fpage>88</fpage>
          -
          <lpage>103</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref3">
        <mixed-citation>
          [3]
          <string-name>
            <given-names>V. B.</given-names>
            <surname>Nguyen</surname>
          </string-name>
          ,
          <string-name>
            <given-names>V.</given-names>
            <surname>Svátek</surname>
          </string-name>
          ,
          <article-title>Ontology for informatics research artifacts</article-title>
          ,
          <source>in: Proceedings of the 18th Extended Semantic Web Conference, ESWC'21</source>
          ,
          <year>2021</year>
          , pp.
          <fpage>126</fpage>
          -
          <lpage>130</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref4">
        <mixed-citation>
          [4]
          <string-name>
            <given-names>A.</given-names>
            <surname>Nguyen</surname>
          </string-name>
          ,
          <string-name>
            <given-names>T.</given-names>
            <surname>Weller</surname>
          </string-name>
          ,
          <string-name>
            <given-names>M.</given-names>
            <surname>Färber</surname>
          </string-name>
          ,
          <string-name>
            <given-names>Y.</given-names>
            <surname>Sure-Vetter</surname>
          </string-name>
          ,
          <article-title>Making neural networks FAIR</article-title>
          ,
          <source>in: Proceedings of the Second Iberoamerican Conference and First Indo-American Conference on Knowledge Graphs and Semantic Web</source>
          ,
          <source>KGSWC'20</source>
          ,
          <year>2020</year>
          , pp.
          <fpage>29</fpage>
          -
          <lpage>44</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref5">
        <mixed-citation>
          [5]
          <string-name>
            <given-names>A.</given-names>
            <surname>Lacoste</surname>
          </string-name>
          ,
          <string-name>
            <given-names>A.</given-names>
            <surname>Luccioni</surname>
          </string-name>
          ,
          <string-name>
            <given-names>V.</given-names>
            <surname>Schmidt</surname>
          </string-name>
          , T. Dandres,
          <article-title>Quantifying the Carbon Emissions of Machine Learning</article-title>
          , CoRR abs/
          <year>1910</year>
          .09700 (
          <year>2019</year>
          ).
        </mixed-citation>
      </ref>
      <ref id="ref6">
        <mixed-citation>
          [6]
          <string-name>
            <given-names>P.</given-names>
            <surname>Henderson</surname>
          </string-name>
          ,
          <string-name>
            <given-names>J.</given-names>
            <surname>Hu</surname>
          </string-name>
          ,
          <string-name>
            <given-names>J.</given-names>
            <surname>Romof</surname>
          </string-name>
          ,
          <string-name>
            <given-names>E.</given-names>
            <surname>Brunskill</surname>
          </string-name>
          ,
          <string-name>
            <given-names>D.</given-names>
            <surname>Jurafsky</surname>
          </string-name>
          ,
          <string-name>
            <given-names>J.</given-names>
            <surname>Pineau</surname>
          </string-name>
          ,
          <article-title>Towards the systematic reporting of the energy and carbon footprints of machine learning</article-title>
          ,
          <source>CoRR abs/2002</source>
          .05651 (
          <year>2020</year>
          ).
        </mixed-citation>
      </ref>
    </ref-list>
  </back>
</article>