Title Back Colour Keyoti Title Line Title Curve
Blue Box Top

Modifying stop words list - SearchUnit - Forum

Welcome Guest Search | Active Topics | Log In | Register

Options
DMacy
#1 Posted : Wednesday, May 9, 2018 2:18:10 AM
Rank: Advanced Member

Groups: Registered

Joined: 9/1/2010
Posts: 133
I am generating my SearchUnit index programatically. Before indexing, I would like to modify the default list of stop words to remove one word. I can't figure out how to do it with LibConfig.StopWords. Here is the code to initialize the configuration and index:

Code:

        Dim LibConfig As New Configuration
        LibConfig.EventHandlerAssemblyPath = IndexPluginFilePath
        LibConfig.IndexDirectory = IndexFolderPath
        LibConfig.Logging = True

        Dim ConfigMgr As ConfigurationManager = New ConfigurationManager(IndexFolderPath)
        ConfigMgr.SaveSettings(LibConfig)

        Dim LibIndex As New Index.DocumentIndex(LibConfig)


Any help would be appreciated. Thanks!
Jim
#2 Posted : Wednesday, May 9, 2018 5:32:34 PM
Rank: Advanced Member

Groups: Administrators, Registered

Joined: 8/13/2004
Posts: 2,667
Location: Canada
You have to open the stoplist.txt file in the folder with path LibConfig.IndexDirectory, and remove it. Doing the usual StreamReader and StreamWriter to read each line and not write the word you don't want, is the way to go.

-your feedback is helpful to other users, thank you!


DMacy
#3 Posted : Wednesday, May 9, 2018 5:45:31 PM
Rank: Advanced Member

Groups: Registered

Joined: 9/1/2010
Posts: 133
Okay. Thanks, Jim! That's what I'll do.
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.




About | Contact | Site Map | Privacy Policy

Copyright © 2002- Keyoti Inc.