You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucene.apache.org by "Sujit Pal (JIRA)" <ji...@apache.org> on 2011/06/23 23:00:49 UTC
[jira] [Created] (LUCENE-3236) Make LowerCaseFilter and StopFilter
keyword aware, similar to PorterStemFilter
Make LowerCaseFilter and StopFilter keyword aware, similar to PorterStemFilter
------------------------------------------------------------------------------
Key: LUCENE-3236
URL: https://issues.apache.org/jira/browse/LUCENE-3236
Project: Lucene - Java
Issue Type: Improvement
Components: modules/analysis
Affects Versions: 4.0
Environment: N/A
Reporter: Sujit Pal
Priority: Minor
Fix For: 4.0
PorterStemFilter has functionality to detect if a term has been marked as a "keyword" by the KeywordMarkerFilter (KeywordAttribute.isKeyword() == true), and if so, skip stemming.
The suggestion is to have the same functionality in other filters where it is applicable. I think it may be particularly applicable to the LowerCaseFilter (ie if it is a keyword, don't mess with the case), and StopFilter (if it is a keyword, then don't filter it out even if it looks like a stop word).
Backward compatibility is maintained (in both cases) by adding a new constructor which takes an additional boolean parameter ignoreKeyword. The current constructor will call this new constructor with ignoreKeyword = false.
Patches are attached (for LowerCaseFilter and StopFilter).
I have verified that the analysis JUnit tests run against the updated code, ie, backward compatibility is maintained.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org
[jira] [Updated] (LUCENE-3236) Make LowerCaseFilter and StopFilter
keyword aware, similar to PorterStemFilter
Posted by "Sujit Pal (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/LUCENE-3236?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Sujit Pal updated LUCENE-3236:
------------------------------
Attachment: lucene-3236-patch.diff
Patch generated with svn diff from the top level Lucene/Solr trunk. Contains updates to LowerCaseFilter and StopFilter to recognize and NOT operate on terms marked with KeywordAttribute.isKeyword.
(NOTE: also contains changes to changes2html.pl which seem to have been generated automatically).
> Make LowerCaseFilter and StopFilter keyword aware, similar to PorterStemFilter
> ------------------------------------------------------------------------------
>
> Key: LUCENE-3236
> URL: https://issues.apache.org/jira/browse/LUCENE-3236
> Project: Lucene - Java
> Issue Type: Improvement
> Components: modules/analysis
> Affects Versions: 4.0
> Environment: N/A
> Reporter: Sujit Pal
> Priority: Minor
> Labels: analysis
> Fix For: 4.0
>
> Attachments: lucene-3236-patch.diff
>
>
> PorterStemFilter has functionality to detect if a term has been marked as a "keyword" by the KeywordMarkerFilter (KeywordAttribute.isKeyword() == true), and if so, skip stemming.
> The suggestion is to have the same functionality in other filters where it is applicable. I think it may be particularly applicable to the LowerCaseFilter (ie if it is a keyword, don't mess with the case), and StopFilter (if it is a keyword, then don't filter it out even if it looks like a stop word).
> Backward compatibility is maintained (in both cases) by adding a new constructor which takes an additional boolean parameter ignoreKeyword. The current constructor will call this new constructor with ignoreKeyword = false.
> Patches are attached (for LowerCaseFilter and StopFilter).
> I have verified that the analysis JUnit tests run against the updated code, ie, backward compatibility is maintained.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org