Processamento Linguagem Natural com Python e NLTK

  • Upload
    pugpe

  • View
    6.919

  • Download
    0

Embed Size (px)

Citation preview

NLTK(Processamento de Linguagem Natural Com Python)

Bruno J. M. Melo ([email protected])

Processamento de Linguagem Natural (PLN)

PLN = Computao + Lingustica

Tpicos: Traduo, Minerao de Texto, Minerao de Opinio, Extrao de Informao... etc...

Tarefas: stemming, POS tagging, chunking, parsing

NLTK

Projeto (open source) para trabalhar com Processamento de Linguagem Natural usando Python.

No voltado para uso em ambiente de Produo.*

Foco em: Simplicidade, Consistncia e Modularidade.

Instalao

$ easy_install NLTK>>> import nltk>>> nltk.download()

Funes/Mdulos

nltk.chunk

nltk.classify

nltk.cluster

nltk.collocations

nltk.corpus

nltk.draw

nltk.grammar

nltk.inference

nltk.metrics

nltk.stem

nltk.tag

nltk.tokenize

Corpora em Portugus

mac_morpho: MacMorpho POS-Tagged Corpus

floresta: Floresta Treebank

machado: Obras de Machado de Assis

Corpora em Portugus

>>> nltk.corpus.mac_morpho.words()>>> nltk.corpus.floresta.words()(palavras com tags)>>> nltk.corpus.floresta.tagged_words()

POS tagging

# postag_pt.py

http://khnt.hit.uib.no/icame/manuals/brown/INDEX.HTM

Classificao

# classify_en.py

Etc.

# concordance_pt.py# etc_pt.py

?