<?xml version="1.0" encoding="UTF-8"?>
<rois:HRIComponentProfile
	gml:id="component_profile"
	xmlns:rois="http://www.omg.org/spec/RoIS/20240801"
    xmlns:ns2="http://www.w3.org/1999/xlink"
    xmlns:gml="http://www.opengis.net/gml/3.2"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">

    <gml:identifier codeSpace="urn:ietf:rfc:2141">urn:x-rois:def:component:OMG::SpeechRecognition</gml:identifier>
    <gml:name>speech_recognizer</gml:name>

    <!-- ===== Sub Component Profiles ===== -->
    <rois:SubComponentProfile>urn:x-rois:def:Component:OMG::RoISCommon</rois:SubComponentProfile>
    
    <!-- ===== Event Messages ===== -->
    <rois:MessageProfile rois:name="speech_input_started" xsi:type="rois:EventMessageProfileType">
        <rois:Results rois:description="time when speech input started" rois:name="timestamp">
            <rois:data_type_ref rois:code="DateTime"/>
        </rois:Results>
    </rois:MessageProfile>
    
    <rois:MessageProfile rois:name="speech_input_finished" xsi:type="rois:EventMessageProfileType">
        <rois:Results rois:description="time when speech nput ended" rois:name="timestamp">
            <rois:data_type_ref rois:code="DateTime"/>
        </rois:Results>
    </rois:MessageProfile>

    <rois:MessageProfile rois:name="speech_recognized" xsi:type="rois:EventMessageProfileType">
        <rois:Results rois:description="list of recognized sentence or word utterances" rois:name="recognized_text">
            <rois:data_type_ref rois:code="string[]"/>
        </rois:Results>
        <rois:Results rois:description="time when recognition completed" rois:name="timestamp">
            <rois:data_type_ref rois:code="DateTime"/>
        </rois:Results>
    </rois:MessageProfile>

    <!-- ===== Query Messages ===== -->
    <rois:MessageProfile rois:name="recognizable_languages" xsi:type="rois:QueryMessageProfileType">
        <rois:Results rois:description="ISO639-1 languages the speech recognizer can recognize" rois:name="languages">
            <rois:data_type_ref rois:code="string[]"/>
        </rois:Results>
    </rois:MessageProfile>

    <!-- ===== Parameter Profiles ===== -->
    <rois:ParameterProfile rois:default_value="default"
                           rois:description="Specifies active rule in the grammer"
                           rois:name="rule">
        <rois:data_type_ref rois:code="string"/>
    </rois:ParameterProfile>

    <rois:ParameterProfile rois:default_value="jp"
                           rois:description="ISO639-1 languages the speech recognizer will recognize"
                           rois:name="languages">
        <rois:data_type_ref rois:code="string[]"/>
    </rois:ParameterProfile>

    <rois:ParameterProfile rois:default_value="default"
                           rois:description="Specifies grammar for the speech recognizer"
                           rois:name="grammar">
        <rois:data_type_ref rois:code="string"/>
    </rois:ParameterProfile>

</rois:HRIComponentProfile>
