Friday, September 19, 2014

Convert Sinhala Word-Net to Text Files



There are 3 main projects you have to configure before create the word-net flat file system for Sinhala. 1) Sinhala-WordNet-MongoDBToText 2) Sinhala-WordNet-API 3) Sinhala-WordNet-CSS When getting the Sinhala-WordNet-CSS project from the git chose not the master branch the branch but the individual_commits It has 5 projects 1) Sinhala-WordNet-CSS-Common 2) Sinhala-WordNet-CSS-DAL 3) Sinhala-WordNet-CSS-JWNL 4) Sinhala-WordNet-CSS-Model 5) Sinhala-WordNet-CSS-Util 6) Sinhala-WordNet-CSS-Web But the important one is the "Sinhala-WordNet-CSS-DAL" Okay now to successfully generate the flat files (i.e. to do MongoDB to Text transformation) we need to configure the below 3 projects 1) Sinhala-WordNet-CSS-DAL 2) Sinhala-WordNet-API 3) Sinhala-WordNet-MongoDBToText First locate the file "file_properties.xml" in Sinhala-WordNet-API-master\SinhalaWordNetAPI\src\extjwnl\src\main\resources\net\sf\extjwnl In the XML file find the Replace the value "XXXXXXXX" with the full file path to "Sinhala-WordNet-API-master\SinhalaWordNetAPI\data\clean-file" Then go to Sinhala-WordNet-API-master\SinhalaWordNetAPI\src\utilities\src\main\java\net\sf\extjwnl\utilities and find the "shakshara.java" file. Find the below code block, String propsFile = "XXXXXX"; and replace the value "XXXXXX" with the full path to "file_properties.xml" file. Now Run the App.java in "Sinhala-WordNet-MongoDBToText" project (in Sinhala-WordNet-MongotoText\SinhalaWordNetMongotoText\src\main\java\org\sinhala\wordnet\DBconvert\core) If it prints "done" or else run successfully then check the folder "Sinhala-WordNet-API-master\SinhalaWordNetAPI\data\clean-file" . there will be the flat files. you can view them by clicking and open through an editor

0 comments:

Post a Comment