Lingua::ZH::Keywords - Extract keywords from Chinese text


Lingua-ZH-Keywords documentation  | view source Contained in the Lingua-ZH-Keywords distribution.

Index


NAME

Top

Lingua::ZH::Keywords - Extract keywords from Chinese text

SYNOPSIS

Top

    # Exports keywords() by default
    use Lingua::ZH::Keywords;

    print join(",", keywords($text));	    # Prints five keywords
    print join(",", keywords($text, 10));   # Prints ten keywords

DESCRIPTION

Top

This is a very simple algorithm which removes stopwords from the text, and then counts up what it considers to be the most important keywords. The keywords subroutine returns a list of keywords in order of relevance.

The stopwords list is accessible as @Lingua::ZH::Keywords::StopWords.

If the input $text is an Unicode string, the returned keywords will also be Unicode strings; otherwise they are assumed to be Big5-encoded bytestrings.

SEE ALSO

Top

Lingua::ZH::TaBE, Lingua::EN::Keywords

ACKNOWLEDGEMENTS

Top

Algorithm adapted from the Lingua::EN::Keywords module by Simon Cozens, <simon@simon-cozens.org<gt>.

AUTHORS

Top

Autrijus Tang <autrijus@autrijus.org>

COPYRIGHT

Top


Lingua-ZH-Keywords documentation  | view source Contained in the Lingua-ZH-Keywords distribution.