Mooeypoo has uploaded a new change for review. ( https://gerrit.wikimedia.org/r/343783 )
Change subject: Add conflicts for category changes ...................................................................... Add conflicts for category changes Bug: T160803 Change-Id: Icdab6d3c2c45a9d4089d9fd09e5072589ac5e182 --- M i18n/en.json M i18n/qqq.json M includes/Hooks.php 3 files changed, 25 insertions(+), 6 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/ORES refs/changes/83/343783/1 diff --git a/i18n/en.json b/i18n/en.json index 058bd2a..f526051 100644 --- a/i18n/en.json +++ b/i18n/en.json @@ -16,12 +16,16 @@ "ores-hide-nondamaging-filter": "Hide probably good edits", "ores-pref-damaging": "ORES sensitivity", "ores-rcfilters-whats-this-link-text": "Learn more", - "ores-rcfilters-ores-conflicts-logactions-global": "The \"Logged actions\" filter conflicts with one or more Contribution Quality or User Intent filters. Quality and Intent predictions are not available for logged actions. The conflicting filters are marked in the Active Filters area, above.", "ores-rcfilters-logactions-conflicts-ores": "This filter conflicts with one or more Contribution Quality or User Intent filters. Quality and Intent predictions are not available for logged actions.", + "ores-rcfilters-ores-conflicts-logactions-global": "The \"Logged actions\" filter conflicts with one or more Contribution Quality or User Intent filters. Quality and Intent predictions are not available for logged actions. The conflicting filters are marked in the Active Filters area, above.", + + "ores-rcfilters-ores-conflicts-hidecategorization-global": "The \"Category changes\" filter is conflicting with one or more Contribution Quality or User Intent filters. Quality and Intent predictions are not available for category changes. The conflicting filters are marked in the Active Filters area, above.", + "ores-rcfilters-hidecategorization-conflicts-ores": "This filter conflicts with one or more Contribution Quality or User Intent filters. Quality and Intent predictions are not available for category changes.", + "ores-rcfilters-damaging-title": "Contribution quality predictions", "ores-rcfilters-damaging-whats-this-header": "About contribution quality predictions", "ores-rcfilters-damaging-whats-this-body": "These predictions are made by a machine-learning service trained on a large set of edits scored by human editors. Stricter, more accurate filters find fewer false positives but miss more of their target. Less accurate filters find more of their target, but they also find more false positives.", - "ores-rcfilters-damaging-conflicts-logactions": "Contribution Quality predictions are not available for certain types of change, so this filter conflicts with the following Type of Change {{PLURAL:$2|filter|filters}}: $1", + "ores-rcfilters-damaging-conflicts-typeofchange": "Contribution Quality predictions are not available for certain types of change, so this filter conflicts with the following Type of Change {{PLURAL:$2|filter|filters}}: $1", "ores-rcfilters-damaging-likelygood-label": "Very likely good", "ores-rcfilters-damaging-likelygood-desc": "Highly accurate at finding almost all problem-free edits.", "ores-rcfilters-damaging-maybebad-label": "May have problems", @@ -33,7 +37,7 @@ "ores-rcfilters-goodfaith-title": "User intent predictions", "ores-rcfilters-goodfaith-whats-this-header": "About user intent predictions", "ores-rcfilters-goodfaith-whats-this-body": "These predictions about users' good faith are made by a machine-learning service trained on a large set of edits scored by human editors. Stricter, more accurate filters find fewer false positives but miss more of their target. Less accurate filters find more of their target, but they also find more false positives.", - "ores-rcfilters-goodfaith-conflicts-logactions": "User Intent predictions are not available for certain types of change, so this filter conflicts with the following Type of Change {{PLURAL:$2|filter|filters}}: $1", + "ores-rcfilters-goodfaith-conflicts-typeofchange": "User Intent predictions are not available for certain types of change, so this filter conflicts with the following Type of Change {{PLURAL:$2|filter|filters}}: $1", "ores-rcfilters-goodfaith-good-label": "Very likely good faith", "ores-rcfilters-goodfaith-good-desc": "Highly accurate at finding almost all good-faith edits.", "ores-rcfilters-goodfaith-maybebad-label": "May be bad faith", diff --git a/i18n/qqq.json b/i18n/qqq.json index 1d6e097..876c2bd 100644 --- a/i18n/qqq.json +++ b/i18n/qqq.json @@ -23,7 +23,9 @@ "ores-pref-damaging": "Part asking for damaging threshold", "ores-rcfilters-whats-this-link-text": "Text of a link to more information about either Contribution Quality Predictions or User Intent Predictions\n{{Identical|Learn more}}", "ores-rcfilters-ores-conflicts-logactions-global": "Message shown in the result area when both an ORES filter and the 'Logged actions' filter are selected. This indicates that no results will be shown because log actions are never scored by ORES.\n\n* \"Logged actions\" is {{msg-mw|rcfilters-filter-logactions-label}}.\n* \"Contribution quality\" is based on {{msg-mw|Ores-rcfilters-damaging-title}}.\n* \"User intent\" is based on {{msg-mw|Ores-rcfilters-goodfaith-title}}.\n* \"Active Filters\" is based on {{msg-mw|rcfilters-activefilters}}.", - "ores-rcfilters-logactions-conflicts-ores": "Tooltip shown when hovering over a Logged actions filter tag, when a ORES filter is also selected.\n\n* \"Logged actions\" is {{msg-mw|rcfilters-filter-logactions-label}}.\n* \"Contribution quality\" is based on {{msg-mw|Ores-rcfilters-damaging-title}}.\n* \"User intent\" is based on {{msg-mw|Ores-rcfilters-goodfaith-title}}.", + "ores-rcfilters-logactions-conflicts-ores": "Tooltip shown when hovering over a Logged actions filter tag, when an ORES filter is also selected.\n\n* \"Logged actions\" is {{msg-mw|rcfilters-filter-logactions-label}}.\n* \"Contribution quality\" is based on {{msg-mw|Ores-rcfilters-damaging-title}}.\n* \"User intent\" is based on {{msg-mw|Ores-rcfilters-goodfaith-title}}.", + "ores-rcfilters-ores-conflicts-hidecategorization-global": "Message shown in the result area when both an ORES filter and the 'Category changes' filter are selected. This indicates that no results will be shown because categories are never scored by ORES.\n\n* \"Category changes\" is {{msg-mw|rcfilters-filter-categorization-label}}.\n* \"Contribution quality\" is based on {{msg-mw|Ores-rcfilters-damaging-title}}.\n* \"User intent\" is based on {{msg-mw|Ores-rcfilters-goodfaith-title}}.\n* \"Active Filters\" is based on {{msg-mw|rcfilters-activefilters}}.", + "ores-rcfilters-hidecategorization-conflicts-ores": "Tooltip shown when hovering over a Category changes filter tag, when an ORES filter is also selected.\n\n* \"Category changes\" is {{msg-mw|rcfilters-filter-categorization-label}}.\n* \"Contribution quality\" is based on {{msg-mw|Ores-rcfilters-damaging-title}}.\n* \"User intent\" is based on {{msg-mw|Ores-rcfilters-goodfaith-title}}.", "ores-rcfilters-damaging-title": "Title for the filter group for ORES damaging score.", "ores-rcfilters-damaging-whats-this-header": "Header of \"What's This\" popup for Contribution Quality group", "ores-rcfilters-damaging-whats-this-body": "Body of \"What's This\" popup for Contribution Quality group", diff --git a/includes/Hooks.php b/includes/Hooks.php index ec8d064..e85f9f6 100644 --- a/includes/Hooks.php +++ b/includes/Hooks.php @@ -94,6 +94,7 @@ $changeTypeGroup = $clsp->getFilterGroup( 'changeType' ); $logFilter = $changeTypeGroup->getFilter( 'hidelog' ); + $categoryFilter = $changeTypeGroup->getFilter( 'hidecategorization' ); if ( self::isModelEnabled( 'damaging' ) ) { $damagingLevels = $stats->getThresholds( 'damaging' ); @@ -166,8 +167,14 @@ $newDamagingGroup->conflictsWith( $logFilter, 'ores-rcfilters-ores-conflicts-logactions-global', - 'ores-rcfilters-damaging-conflicts-logactions', + 'ores-rcfilters-damaging-conflicts-typeofchange', 'ores-rcfilters-logactions-conflicts-ores' + ); + $newDamagingGroup->conflictsWith( + $categoryFilter, + 'ores-rcfilters-ores-conflicts-hidecategorization-global', + 'ores-rcfilters-damaging-conflicts-typeofchange', + 'ores-rcfilters-hidecategorization-conflicts-ores' ); $newDamagingGroup->getFilter( 'maybebad' )->setAsSupersetOf( @@ -281,9 +288,15 @@ $goodfaithGroup->conflictsWith( $logFilter, 'ores-rcfilters-ores-conflicts-logactions-global', - 'ores-rcfilters-goodfaith-conflicts-logactions', + 'ores-rcfilters-goodfaith-conflicts-typeofchange', 'ores-rcfilters-logactions-conflicts-ores' ); + $goodfaithGroup->conflictsWith( + $categoryFilter, + 'ores-rcfilters-ores-conflicts-hidecategorization-global', + 'ores-rcfilters-goodfaith-conflicts-typeofchange', + 'ores-rcfilters-hidecategorization-conflicts-ores' + ); $clsp->registerFilterGroup( $goodfaithGroup ); } -- To view, visit https://gerrit.wikimedia.org/r/343783 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Icdab6d3c2c45a9d4089d9fd09e5072589ac5e182 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/ORES Gerrit-Branch: master Gerrit-Owner: Mooeypoo <mor...@gmail.com> _______________________________________________ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits