Hi Anton,

The description of the applications in nerc.properties file are a CSV list of filenames whick exist in the %kim.context.dir%/resources/ directory. KIM tries to load them sequentially by creating a ConditionalSerialAnalyzerController from the description in the file. As ANNIE pipeline is a SerialAnalyserController this exception is thrown. Try to create a "Conditional Corpus Pipeline" application and load the resources you want in it. Then use the newly created application in the nerc.properties configuration file.

Greetings,
Philip

Anton Andreev wrote:
Hi,

I understand that I have to use this notation in order to add myapp.gapp:
com.ontotext.kim.KIMConstants.IE_APP=IE.gapp,myapp.gapp

But I get an exception. My application is modified ANNIE, is that the cause for the type mismatch?

Exception:
---------------------------------------------------
Using C:\Documents and Settings\toni\gate.xml as user configuration file
Using C:\Documents and Settings\toni\gate.session as user session file
CREOLE plugin loaded: file:/E:/anton_work/kim-platform-2.4-SNAPSHOT/bin/../plugins/ANNIE/
GATE is AWAKE.
Loading E:\anton_work\kim-platform-2.4-SNAPSHOT\context\default\resources\IE.gapp CREOLE plugin loaded: file:/E:/anton_work/kim-platform-2.4-SNAPSHOT/plugins/ANNIE/ CREOLE plugin loaded: file:/E:/anton_work/kim-platform-2.4-SNAPSHOT/plugins/Tools/ CREOLE plugin loaded: file:/E:/anton_work/kim-platform-2.4-SNAPSHOT/config/
initialize Instance Generator
Get EntityAPI.
Instance Generator initialization DONE
Loading E:\anton_work\kim-platform-2.4-SNAPSHOT\context\default\resources\myapp.gapp
Failed to load SemanticAnnotationAPI.
java.lang.ClassCastException: gate.creole.SerialAnalyserController cannot be cast to gate.creole.ConditionalSerialAnalyserController at com.ontotext.kim.semanticannotation.GateAdapter.load(GateAdapter.java:32) at com.ontotext.kim.semanticannotation.GateServiceFactory.loadSemanticAnnotationAPI(GateServiceFactory.java:72) at com.ontotext.kim.semanticannotation.GateServiceFactory.<init>(GateServiceFactory.java:41) at com.ontotext.kim.semanticannotation.OnDemandSemanticAnnotationFactory.initOnce(OnDemandSemanticAnnotationFactory.java:27) at com.ontotext.kim.semanticannotation.OnDemandSemanticAnnotationFactory.initNow(OnDemandSemanticAnnotationFactory.java:45) at com.ontotext.kim.KIMServiceImpl$ServerComponentStarter.run(KIMServiceImpl.java:102)
Server Starter thread failed!
com.ontotext.kim.client.KIMRuntimeException: java.lang.ClassCastException: gate.creole.SerialAnalyserController cannot be cast to gate.creole.ConditionalSerialAnalyserController at com.ontotext.kim.semanticannotation.GateServiceFactory.loadSemanticAnnotationAPI(GateServiceFactory.java:83) at com.ontotext.kim.semanticannotation.GateServiceFactory.<init>(GateServiceFactory.java:41) at com.ontotext.kim.semanticannotation.OnDemandSemanticAnnotationFactory.initOnce(OnDemandSemanticAnnotationFactory.java:27) at com.ontotext.kim.semanticannotation.OnDemandSemanticAnnotationFactory.initNow(OnDemandSemanticAnnotationFactory.java:45) at com.ontotext.kim.KIMServiceImpl$ServerComponentStarter.run(KIMServiceImpl.java:102) Caused by: java.lang.ClassCastException: gate.creole.SerialAnalyserController cannot be cast to gate.creole.ConditionalSerialAnalyserController at com.ontotext.kim.semanticannotation.GateAdapter.load(GateAdapter.java:32) at com.ontotext.kim.semanticannotation.GateServiceFactory.loadSemanticAnnotationAPI(GateServiceFactory.java:72)
    ... 4 more
Loading KIM ChannelIfaceInvocation replacement ...
Shutting down SemanticRepositoryAPI for the MAIN repository.
1416823 statement(s) in repository overall.
Repository shuted down!
It is now safe to close the KIM Server.
KIMService unregistered from port 1099
KIM Server shutdown.
KIM shut down at localhost

Cheers,
Anton

2009/5/27 Anton Andreev <[email protected] <mailto:[email protected]>>

    Hi,

    I am trying to use a GATE application from KIM. I have saved my
    GATE application in
    \kim-platform-2.4-SNAPSHOT\context\default\resources\myapp.gapp.
    I am trying to modify
    \kim-platform-2.4-SNAPSHOT\config\nerc.properties.

    1. What is the correct configuration?
    com.ontotext.kim.KIMConstants.IE_APP=IE.gapp
    com.ontotext.kim.KIMConstants.IE_APP=myapp.gapp

    or

    com.ontotext.kim.KIMConstants.IE_APP=IE.gapp myapp.gapp

    Either way it does not seem to work.

    2. What is the correct calling syntax:

    KIMService serviceKim = GetService.from();
    SemanticAnnotationAPI apiSemAnn1 =
    serviceKim.getSemanticAnnotationAPI("myapp.gapp");

    What is the correct syntax of the getSemanticAnnotationAPI
    parameter? Is it only "myapp" or "myapp.gapp"?

    I get that apiSemAnn1 is null.

    Thanks,
    Anton


------------------------------------------------------------------------

_______________________________________________
Kim-discussion mailing list
[email protected]
http://ontotext.com/mailman/listinfo/kim-discussion

_______________________________________________
Kim-discussion mailing list
[email protected]
http://ontotext.com/mailman/listinfo/kim-discussion

Reply via email to