BLKSerene/Wordless

View on GitHub
tests/tests_nlp/tests_stanza/test_stanza_got.py

Summary

Maintainability
A
0 mins
Test Coverage
# ----------------------------------------------------------------------
# Wordless: Tests - NLP - Stanza - Gothic
# Copyright (C) 2018-2024  Ye Lei (叢磊)
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program.  If not, see <http://www.gnu.org/licenses/>.
# ----------------------------------------------------------------------

from tests.tests_nlp.tests_stanza import test_stanza

def test_stanza_got():
    test_stanza.wl_test_stanza(
        lang = 'got',
        results_sentence_tokenize = ['πŒ²πŒΏπ„πŒ°π‚πŒ°πŒΆπŒ³πŒ°, πŒ²πŒΏπ„π‚πŒ°πŒΆπŒ³πŒ° 𐌰𐌹𐌸𐌸𐌰𐌿 πŒ²πŒΏπ„πŒΉπƒπŒΊπŒ° π‚πŒ°πŒΆπŒ³πŒ° πŒΉπƒπ„ πŒ²πŒ°πƒπ…πŒΏπŒ»π„πŒ°πŒ½πŒ° πŒ°πŒΏπƒπ„π‚πŒ°πŒ²πŒ°πŒΉπ‚πŒΌπŒ°πŒ½πŒΉπƒπŒΊπŒ° π‚πŒ°πŒΆπŒ³πŒ° π‚π‰πŒ³πŒΉπŒ³πŒ° π†π‚πŒ°πŒΌ πŒ²πŒΏπ„πŒ°πŒΌ. πƒπŒΉ πŒΉπƒπ„ πŒ°πŒΉπŒ½πŒ°πŒ·π‰ πŒ°πŒΏπƒπ„π‚πŒ°πŒ²πŒ°πŒΉπŒΌπŒ°πŒ½πŒΉπƒπŒΊπŒ° π‚πŒ°πŒΆπŒ³πŒ° πƒπ‰πŒ΄πŒΉ 𐌷𐌰𐌱𐌰𐌹𐌸 πŒ²πŒ°πŒΌπŒ΄πŒ»πŒ΄πŒΉπŒ½πŒΉπŒ½πƒ', '.'],
        results_word_tokenize = ['πŒ²πŒΏπ„πŒ°π‚πŒ°πŒΆπŒ³πŒ°,', 'πŒ²πŒΏπ„π‚πŒ°πŒΆπŒ³πŒ°', '𐌰𐌹𐌸𐌸𐌰𐌿', 'πŒ²πŒΏπ„πŒΉπƒπŒΊπŒ°', 'π‚πŒ°πŒΆπŒ³πŒ°', 'πŒΉπƒπ„', 'πŒ²πŒ°πƒπ…πŒΏπŒ»π„πŒ°πŒ½πŒ°', 'πŒ°πŒΏπƒπ„π‚πŒ°πŒ²πŒ°πŒΉπ‚πŒΌπŒ°πŒ½πŒΉπƒπŒΊπŒ°', 'π‚πŒ°πŒΆπŒ³πŒ°', 'π‚π‰πŒ³πŒΉπŒ³πŒ°', 'π†π‚πŒ°πŒΌ', 'πŒ²πŒΏπ„πŒ°πŒΌ', '.'],
        results_pos_tag = [('πŒ²πŒΏπ„πŒ°π‚πŒ°πŒΆπŒ³πŒ°,', 'Nb'), ('πŒ²πŒΏπ„π‚πŒ°πŒΆπŒ³πŒ°', 'Nb'), ('𐌰𐌹𐌸𐌸𐌰𐌿', 'Pd'), ('πŒ²πŒΏπ„πŒΉπƒπŒΊπŒ°', 'Pd'), ('π‚πŒ°πŒΆπŒ³πŒ°', 'Pd'), ('πŒΉπƒπ„', 'Pd'), ('πŒ²πŒ°πƒπ…πŒΏπŒ»π„πŒ°πŒ½πŒ°', 'Nb'), ('πŒ°πŒΏπƒπ„π‚πŒ°πŒ²πŒ°πŒΉπ‚πŒΌπŒ°πŒ½πŒΉπƒπŒΊπŒ°', 'Nb'), ('π‚πŒ°πŒΆπŒ³πŒ°', 'Pd'), ('π‚π‰πŒ³πŒΉπŒ³πŒ°', 'Pd'), ('π†π‚πŒ°πŒΌ', 'Pd'), ('πŒ²πŒΏπ„πŒ°πŒΌ', 'Nb'), ('.', 'Df')],
        results_pos_tag_universal = [('πŒ²πŒΏπ„πŒ°π‚πŒ°πŒΆπŒ³πŒ°,', 'NOUN'), ('πŒ²πŒΏπ„π‚πŒ°πŒΆπŒ³πŒ°', 'NOUN'), ('𐌰𐌹𐌸𐌸𐌰𐌿', 'DET'), ('πŒ²πŒΏπ„πŒΉπƒπŒΊπŒ°', 'DET'), ('π‚πŒ°πŒΆπŒ³πŒ°', 'DET'), ('πŒΉπƒπ„', 'DET'), ('πŒ²πŒ°πƒπ…πŒΏπŒ»π„πŒ°πŒ½πŒ°', 'NOUN'), ('πŒ°πŒΏπƒπ„π‚πŒ°πŒ²πŒ°πŒΉπ‚πŒΌπŒ°πŒ½πŒΉπƒπŒΊπŒ°', 'NOUN'), ('π‚πŒ°πŒΆπŒ³πŒ°', 'DET'), ('π‚π‰πŒ³πŒΉπŒ³πŒ°', 'DET'), ('π†π‚πŒ°πŒΌ', 'DET'), ('πŒ²πŒΏπ„πŒ°πŒΌ', 'NOUN'), ('.', 'ADV')],
        results_lemmatize = ['πŒ²πŒΏπ„πŒ°π‚πŒ°πŒΆπŒ³πŒ°,', 'πŒ²πŒΏπ„π‚πŒ°πŒΆπŒ³πŒ°', '𐌰𐌹𐌸𐌸𐌰𐌿', 'πŒ²πŒΏπ„πŒΉπƒπŒΊπŒ°', 'π‚πŒ°πŒΆπŒ³πŒ°', 'πŒΉπƒπ„', 'πŒ²πŒ°πƒπ…πŒΏπŒ»π„πŒ°πŒ½πŒ°', 'πŒ°πŒΏπƒπ„π‚πŒ°πŒ²πŒ°πŒΉπ‚πŒΌπŒ°πŒ½πŒΉπƒπŒΊπŒ°', 'π‚πŒ°πŒΆπŒ³πŒ°', 'π‚π‰πŒ³πŒΉπŒ³πŒ°', 'π†π‚πŒ°πŒΌ', 'πŒ²πŒΏπ„πŒ°πŒΌ', '-uh'],
        results_dependency_parse = [('πŒ²πŒΏπ„πŒ°π‚πŒ°πŒΆπŒ³πŒ°,', 'πŒ²πŒΏπ„π‚πŒ°πŒΆπŒ³πŒ°', 'vocative', 1), ('πŒ²πŒΏπ„π‚πŒ°πŒΆπŒ³πŒ°', 'πŒ²πŒΏπ„π‚πŒ°πŒΆπŒ³πŒ°', 'root', 0), ('𐌰𐌹𐌸𐌸𐌰𐌿', 'πŒ²πŒΏπ„π‚πŒ°πŒΆπŒ³πŒ°', 'det', -1), ('πŒ²πŒΏπ„πŒΉπƒπŒΊπŒ°', 'πŒ²πŒ°πƒπ…πŒΏπŒ»π„πŒ°πŒ½πŒ°', 'det', 3), ('π‚πŒ°πŒΆπŒ³πŒ°', 'πŒ²πŒ°πƒπ…πŒΏπŒ»π„πŒ°πŒ½πŒ°', 'det', 2), ('πŒΉπƒπ„', 'πŒ²πŒ°πƒπ…πŒΏπŒ»π„πŒ°πŒ½πŒ°', 'det', 1), ('πŒ²πŒ°πƒπ…πŒΏπŒ»π„πŒ°πŒ½πŒ°', 'πŒ²πŒΏπ„π‚πŒ°πŒΆπŒ³πŒ°', 'appos', -5), ('πŒ°πŒΏπƒπ„π‚πŒ°πŒ²πŒ°πŒΉπ‚πŒΌπŒ°πŒ½πŒΉπƒπŒΊπŒ°', 'πŒ²πŒ°πƒπ…πŒΏπŒ»π„πŒ°πŒ½πŒ°', 'nmod', -1), ('π‚πŒ°πŒΆπŒ³πŒ°', 'πŒ²πŒΏπ„πŒ°πŒΌ', 'det', 3), ('π‚π‰πŒ³πŒΉπŒ³πŒ°', 'πŒ²πŒΏπ„πŒ°πŒΌ', 'det', 2), ('π†π‚πŒ°πŒΌ', 'πŒ²πŒΏπ„πŒ°πŒΌ', 'det', 1), ('πŒ²πŒΏπ„πŒ°πŒΌ', 'πŒ°πŒΏπƒπ„π‚πŒ°πŒ²πŒ°πŒΉπ‚πŒΌπŒ°πŒ½πŒΉπƒπŒΊπŒ°', 'appos', -4), ('.', '.', 'root', 0)]
    )

if __name__ == '__main__':
    test_stanza_got()