-
Notifications
You must be signed in to change notification settings - Fork 70
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Moving from Old Language Metadata Structure to Support Sub-languages and Simplified JSON #402
Merged
andrewtavis
merged 37 commits into
scribe-org:main
from
OmarAI2003:refactor-languages_metadata.json-and-rework-references
Oct 18, 2024
Merged
Changes from all commits
Commits
Show all changes
37 commits
Select commit
Hold shift + click to select a range
624760d
Simplified language metadata JSON by removing unnecessary nesting and…
OmarAI2003 05ba79d
Refactored _load_json function to handle simplified JSON structure.
OmarAI2003 7be7005
Refactor language metadata structure: Include all languages with Norw…
OmarAI2003 e1ce1d8
Refactor _find function to handle languages with sub-languages
OmarAI2003 046c78d
Update get_scribe_languages to handle sub-languages in JSON structure
OmarAI2003 7c00873
Merge remote-tracking branch 'upstream/main' into refactor-languages_…
OmarAI2003 2233e44
Merge remote-tracking branch 'upstream/main' into refactor-languages_…
OmarAI2003 8f737cd
Remove get_language_words_to_remove and get_language_words_to_ignore …
OmarAI2003 9f75f54
Refactor language_map and language_to_qid generation to handle new JS…
OmarAI2003 6186be9
Fix: Update language extraction to match new JSON structure by removi…
OmarAI2003 1c959ec
Refactor language extraction to use direct keys from language_metadata.
OmarAI2003 458328e
Added format_sublanguage_name function to format sub-language names a…
OmarAI2003 e017760
Refactor: Apply format_sublanguage_name to handle sub-language
OmarAI2003 4705414
Removed dependency on the 'languages' key based on the old json struc…
OmarAI2003 ab7b6cf
Add function to list all languages from language metadata loaded json
OmarAI2003 8d8f8f5
Refactor to use list_all_languages function for language extraction
OmarAI2003 d9a649b
Enhance language handling by importing utility functions
OmarAI2003 30f97e9
Update get_language_iso function:
OmarAI2003 ceec187
Handle sub-languages in language table generation
OmarAI2003 5345c08
Merge remote-tracking branch 'upstream/main' into refactor-languages_…
OmarAI2003 540e9d2
adding new languages and their dialects to the language_metadata.json…
OmarAI2003 f389ab5
Modified the loop that searches languages in the list_data_types func…
OmarAI2003 09944ed
Capitalize the languages returned by the function 'format_sublanguage…
OmarAI2003 f602f17
Implemented minor fixes by utilizing the format_sublanguage_name func…
OmarAI2003 ba0ed9a
Updated the instance variable self.languages in ScribeDataConfig to u…
OmarAI2003 c77cb1f
adding mandarin as a sub language under chinese and updating some qids
OmarAI2003 87ec3b0
Update test_list_languages to match updated output format
OmarAI2003 84f8a4b
Merge remote-tracking branch 'upstream/main' into refactor-languages_…
OmarAI2003 881c055
removing .capitalize method since it's already implemented inside lag…
OmarAI2003 15a13fb
Merge remote-tracking branch 'upstream/main' into refactor-languages_…
OmarAI2003 fed80b3
Updating test cases in test_list.py file to match newly added languages
OmarAI2003 e6140e5
Update test cases to include sub-languages
OmarAI2003 22791ce
Updated the get_language_from_iso function to depend on the JSON file…
OmarAI2003 1416134
Add unit tests for language formatting and listing:
OmarAI2003 ca9edb4
Merge remote-tracking branch 'upstream/main' into refactor-languages_…
OmarAI2003 f3426f1
Merge branch 'scribe-org:main' into refactor-languages_metadata.json-…
OmarAI2003 661b131
Edits to language metadata and supporting functions + pr checklist
andrewtavis File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
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
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
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
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
Oops, something went wrong.
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You've made sorting and formatting more efficient by calling list_all_languages() and sorting the languages using get_language_iso() and get_language_qid(). This reduces redundancy and enhances readability. Thank you for this!!!