Source code for konlp.parse.api

# Copyright (C) 2017 - 0000 KoNLTK project
# Korean Natural Language Toolkit:
# Author: HyunYoung Lee <>
#         GyuHyeon Nam <>
#         Seungshik Kang <>
# URL: <>
# For license information, see LICENSE.TXT
# ============================================================
"""Korean Natural Language Toolkit parsing interface"""

from abc import ABCMeta, abstractmethod
from six import add_metaclass

[docs]@add_metaclass(ABCMeta) class ParserI(object): """Parser Interface"""
[docs] @abstractmethod def tag(self, tokens): """ Determine the most appropriate tag sequence for the given token sequence, and return a corresponding list of tagged tokens. A tagged token is encoded as a tuple ``(token, tag)``. :param tokens: The list of string token :type tokens: list(string) :raises: NotImplementedError """ raise NotImplementedError()