You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@bt2901
Ah, I missed to see that the parser already extracts categories, albeit only for English, to decide whether to include the page for extraction or not. I could have extended that bit for non-English categories and save them as well. So, yeah, I don't think the filtering of pages would work for non-English wikis. I should probably fix this.
Nevertheless, the current code (this pull request) as is, should work to extract and save the non-English categories as well, since the process is conducted during the actual extraction of pages.
I used the code for English, German, Russian, and Korean wiki dumps. But make sure to go into the each wiki page in edit mode, and check how the category is written in its surface form, and update the --category_surface accordingly.
This file contains hidden or 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
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
--extract_categoriesis given, page categories are extracted and saved along withtitleandtext.[[Category:Category name|Sortkey]]-> OnlyCategory nameis extracted.