uima-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Eddie Epstein <eaepst...@gmail.com>
Subject Re: Sofa mapping for a CM
Date Thu, 12 Jul 2012 15:31:00 GMT
I had no problem declaring sofa mapping for a CM in the
component descriptor editor, nor any problem during initialization.
I used the MeetingFinderAggregate from UIMA-AS, replacing
the CR with the SofaExampleAnnotator to create a new View
plus the SimpleTextSegmenter as a CM, and the following mapping:

  <sofaMappings>
    <sofaMapping>
      <componentKey>SofaExampleAnnotator</componentKey>
      <componentSofaName>EnglishDocument</componentSofaName>
      <aggregateSofaName>_InitialView</aggregateSofaName>
    </sofaMapping>
    <sofaMapping>
      <componentKey>SimpleTextSegmenter</componentKey>
      <aggregateSofaName>GermanDocument</aggregateSofaName>
    </sofaMapping>
    <sofaMapping>
      <componentKey>CasConsumer</componentKey>
      <aggregateSofaName>GermanDocument</aggregateSofaName>
    </sofaMapping>
    <sofaMapping>
      <componentKey>MeetingDetector</componentKey>
      <aggregateSofaName>GermanDocument</aggregateSofaName>
    </sofaMapping>
  </sofaMappings>

Can you reproduce the problem using SDK example components?

A view-unaware component uses a single view. So such a
CM should be creating new CASes with the same View as is
used in the CM's input CAS.

Fine with me to open a jira.
Eddie

On Wed, Jul 11, 2012 at 3:56 PM, Jörn Kottmann <kottmann@gmail.com> wrote:
> Yes, I see the problem described here, but was not
> sure if declaring a sofa mapping for a CM is allowed.
>
> We made the CM view aware instead of using the mapping,
> and that of course works well.
>
> Should we open a jira?
>
> I am not sure I can follow your proposed fix, why is the CM expected
> to create a new CAS with view v?
>
> I am getting the exception when the system is initialized
> (would take me a few minutes to reproduce this) and not when
> the CM gets its first CAS to process it.
>
> Jörn
>
>
> On 07/06/2012 09:38 PM, Eddie Epstein wrote:
>>
>> Looks like a problem here. Mapping a named view
>> to the CM input works correctly; that view is delivered
>> to the CM's process method. But there is an exception
>> when the CM calls getEmptyCAS() because the named view
>> does not yet exist.
>>
>> One solution would be for getEmptyCAS() to create the
>> specified view and then return it.
>>
>> Interestingly, just a few days ago I argued that the framework
>> should not create views.
>>     see http://markmail.org/message/bwzamfci2uo7wx4i
>> But this seems like a special case: a view-unaware CM
>> has received a CAS with view V, and is expected to create
>> new CASes with view V.
>>
>> Are you seeing the problem described here or another?
>> Any comments on proposed fix?
>>
>> Eddie
>>
>> On Wed, Jul 4, 2012 at 6:53 AM, Jörn Kottmann <kottmann@gmail.com> wrote:
>>>
>>> Hi all,
>>>
>>> are sofa mappings for CMs are supposed to work?
>>>
>>> Jörn
>
>
>

Mime
View raw message