Hi Gandhi, Thank you for your help. It's working now. In the customDictionary.xml, I changed org.apache.ctakes.dictionary.lookup2.dictionary.JdbcRareWordDictionary to org.apache.ctakes.dictionary.lookup2.dictionary.UmlsJdbcRareWordDictionary and org.apache.ctakes.dictionary.lookup2.concept.JdbcConceptFactory to org.apache.ctakes.dictionary.lookup2.concept.UmlsJdbcConceptFactory. For single word term, this worked without any change, but for a multi-word term, this was returning empty results. When I debugged, I found that the issue was coming at code below in DefaultJCasTermAnnotator class line 103- if ( hitTokens[ hit ].equals(allTokens.get( i ).getText() ) || hitTokens[ hit ].equals( allTokens.get( i ).getVariant() ) ); This was happening due to the difference in string case. The input string is converted to lowercase, but the string from MySQL database is not converted. Right now I have to put all terms in my database in lower case to make it work. Do you know any configuration so that I don't have to deal with the case issue without changing DefaultJCasTermAnnotator file? When using BSV file, I am getting lower case sting for both input and term.
Regards Chahal Arora Software Engineer Raxa On Tue, Dec 19, 2017 at 11:23 PM, Gandhi Rajan Natarajan < gandhi.natara...@arisglobal.com> wrote: > Hi Chahal, > > Looking at the error trace: > ‘javax.servlet.ServletException,java.io.IOException > 19 Dec 2017 17:56:01 INFO RequestMappingHandlerAdapter - Looking for > @ControllerAdvice: WebApplicationContext for namespace > 'ctakes-rest-service-servlet'’ > > It looks like you are trying to mix match codes from both > ctakes-rest-service and ctakes-web-rest module I guess. Ctakes-rest-service > module is obsolete now and request you to consider only ctakes-web-rest > module in https://github.com/GoTeamEpsilon/ctakes-rest- > service/tree/master/ctakes-web-rest > > Regards, > Gandhi > > From: Chahal Arora [mailto:chahal.ar...@raxa.com] > Sent: Tuesday, December 19, 2017 8:20 PM > To: dev@ctakes.apache.org > Subject: Re: Custom Dictionary connected to mysql > > Hi Gandhi, > > With updated customDictionary.xml all errors were gone. > > I am not sure about the schema of the tables used. I have taken reference > from JdbcRareWordDictionary.java - https://github.com/apache/ > ctakes/blob/trunk/ctakes-dictionary-lookup-fast/src/ > main/java/org/apache/ctakes/dictionary/lookup2/dictionary/ > JdbcRareWordDictionary.java and JdbcConceptFactory.java - > https://github.com/apache/ctakes/blob/trunk/ctakes- > dictionary-lookup-fast/src/main/java/org/apache/ctakes/ > dictionary/lookup2/concept/JdbcConceptFactory.java > > I am using the ctakes-rest-web server and getting all the annotation array > as empty in the result json. > > Attached tomcat logs again. > > Regards > Chahal Arora > Software Engineer > Raxa > > On Tue, Dec 19, 2017 at 6:44 PM, Gandhi Rajan Natarajan < > gandhi.natara...@arisglobal.com<mailto:gandhi.natara...@arisglobal.com>> > wrote: > Not able to see any tomcat logs attached. > > Do you see any errors in tomcat console? > > Regards, > Gandhi > > From: Chahal Arora [mailto:chahal.ar...@raxa.com<mailto: > chahal.ar...@raxa.com>] > Sent: Tuesday, December 19, 2017 6:09 PM > To: dev@ctakes.apache.org<mailto:dev@ctakes.apache.org> > Subject: Re: Custom Dictionary connected to mysql > > Hi, > > I have updated the customDictionary.xml and all the erros have gone but > still not getting any result. I am attaching the latest > customDictionary.xml and tomcat logs file. > > > > Regards > Chahal Arora > Software Engineer > Raxa > > On Tue, Dec 19, 2017 at 5:45 PM, Chahal Arora <chahal.ar...@raxa.com > <mailto:chahal.ar...@raxa.com><mailto:chahal.ar...@raxa.com<mailto:c > hahal.ar...@raxa.com>>> wrote: > Hi All, > > I was working on moving the terms from custom dictionary BSV file to MySQL > database in LabValueFinder. I am able to connect to the database but not > sure about the database schema. > > Is there an example available where the custom dictionary is connected to > mysql database instead of a bsv file or hsql database? > > Attached is the customDictionary.xml file that I am using. > > > Regards > Chahal Arora > Software Engineer > Raxa > > This email and any files transmitted with it are confidential and intended > solely for the use of the individual or entity to whom they are addressed. > If you are not the named addressee you should not disseminate, distribute > or copy this e-mail. Please notify the sender or system manager by email > immediately if you have received this e-mail by mistake and delete this > e-mail from your system. If you are not the intended recipient you are > notified that disclosing, copying, distributing or taking any action in > reliance on the contents of this information is strictly prohibited and > against the law. > > This email and any files transmitted with it are confidential and intended > solely for the use of the individual or entity to whom they are addressed. > If you are not the named addressee you should not disseminate, distribute > or copy this e-mail. Please notify the sender or system manager by email > immediately if you have received this e-mail by mistake and delete this > e-mail from your system. If you are not the intended recipient you are > notified that disclosing, copying, distributing or taking any action in > reliance on the contents of this information is strictly prohibited and > against the law. >