Created
January 20, 2016 17:42
-
-
Save filbertkm/5d6618f627481525beb4 to your computer and use it in GitHub Desktop.
cirrus config
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$wgSearchType = 'CirrusSearch'; | |
$wgCirrusSearchShowNowUsing = true; | |
$wgCirrusSearchMoreAccurateScoringMode = false; | |
$wgCirrusSearchRefreshInterval = 30; | |
$wgCirrusSearchSearchShardTimeout[ 'regex' ] = '20s'; | |
$wgCirrusSearchClientSideSearchTimeout[ 'regex' ] = 30; | |
$wgJobBackoffThrottling['cirrusSearchLinksUpdate'] = 5000; | |
$wgJobBackoffThrottling['cirrusSearchIncomingLinkCount'] = 1; | |
$wgCirrusSearchBannedPlugins[] = 'elasticsearch-analysis-hebrew'; | |
$wgCirrusSearchConnectionAttempts = 3; | |
$wgCirrusSearchServers = array( | |
'localhost', | |
); | |
$wgCirrusSearchWikimediaExtraPlugin = array( | |
'regex' => array( | |
'build', | |
'use', | |
), | |
'super_detect_noop' => true, | |
'field_value_factor_with_default' => false, | |
'id_hash_mod_filter' => true, | |
); | |
$wgCirrusSearchRescoreProfiles += array( | |
'wikidata' => array( | |
'supported_namespaces' => array( 0 ), | |
'fallback_profile' => 'default', | |
'rescore' => array( | |
array( | |
'window' => 8192, | |
'window_size_override' => 'CirrusSearchFunctionRescoreWindowSize', | |
'type' => 'function_score', | |
'function_chain' => 'simple_sum', | |
// 'query_weight' => 0.8, | |
'rescore_query_weight' => 0.8 | |
), | |
array( | |
'window' => 8192, | |
'window_size_override' => 'CirrusSearchFunctionRescoreWindowSize', | |
'type' => 'function_score', | |
'function_chain' => 'optional_chain' | |
) | |
) | |
) | |
); | |
$wgCirrusSearchRescoreFunctionScoreChains += array( | |
'simple_sum' => array( | |
'score_mode' => 'sum', | |
'functions' => array( | |
array( | |
'type' => 'custom_field', | |
'params' => array( | |
'field' => 'sitelink_count', | |
'missing' => 0, | |
) | |
), | |
array( | |
'type' => 'custom_field', | |
'params' => array( | |
'field' => 'label_count', | |
'missing' => 0 | |
) | |
), | |
array( | |
'type' => 'custom_field', | |
'params' => array( | |
'field' => 'statement_count', | |
'missing' => 0 | |
) | |
) | |
) | |
) | |
); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment