Skip to main content

Libère tes chaînes de mots — Bibliothèque pédagogique NLP pour la formation LCM

Project description

lcm-nlp — Libère tes chaînes de mots

Bibliothèque Python pédagogique pour le traitement automatique du langage naturel (NLP), conçue pour accompagner la formation Libère tes chaînes de mots.

Installation

pip install lcm-nlp

Modules

Module Description
regex_utils Expressions régulières et automates (DFA)
preprocessing Tokenisation, normalisation, stemming, distance d'édition
ngrams Modèles de langue N-grammes (lissage Laplace, interpolation)
classification Classification Naive Bayes, sac de mots, TF-IDF
evaluation Métriques d'évaluation (précision, rappel, F1, validation croisée)
ner Reconnaissance d'entités nommées (règles, IOB)
embeddings Plongements de mots (cooccurrence, SVD, similarité cosinus)
search Moteur de recherche textuelle avec TypeSense
corpus_loader Chargement du corpus Pleine Confiance (cybersécurité)
emoji_analysis Analyse d'emojis dans les textes
sentence_analysis Analyse de phrases (POS, lisibilité, complexité)
text_reuse Réutilisation de contenu, LDA, phrases clés
linkedin Chargement et analyse de données LinkedIn

Utilisation rapide

from lcm_nlp.preprocessing import tokenize, remove_stopwords
from lcm_nlp.classification import NaiveBayesClassifier

# Tokenisation
tokens = tokenize("Le traitement du langage naturel est fascinant.", method="words_only")
tokens = remove_stopwords(tokens)
print(tokens)
# → ['traitement', 'langage', 'naturel', 'fascinant']

# Classification
clf = NaiveBayesClassifier()
clf.train([
    (["excellent", "film"], "positif"),
    (["mauvais", "nul"], "négatif"),
])
print(clf.predict(["superbe", "film"]))  # → "positif"

Licence

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

lcm_nlp-1.2.0.tar.gz (48.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

lcm_nlp-1.2.0-py3-none-any.whl (57.2 kB view details)

Uploaded Python 3

File details

Details for the file lcm_nlp-1.2.0.tar.gz.

File metadata

  • Download URL: lcm_nlp-1.2.0.tar.gz
  • Upload date:
  • Size: 48.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.5

File hashes

Hashes for lcm_nlp-1.2.0.tar.gz
Algorithm Hash digest
SHA256 2d1357fd5c2f09bb1b8c6530a30b80ff5581005d148dfb901bd74981cc3797df
MD5 8549def84bebeda2ffef568e90dcb579
BLAKE2b-256 a091b508c836ef7f0da0c7efce5f700995bb5b23a98ba620f12a7d2fab4466cf

See more details on using hashes here.

File details

Details for the file lcm_nlp-1.2.0-py3-none-any.whl.

File metadata

  • Download URL: lcm_nlp-1.2.0-py3-none-any.whl
  • Upload date:
  • Size: 57.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.5

File hashes

Hashes for lcm_nlp-1.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 dee2e0eade34e48782f8c77b6650c0c6e529810cec444f388a1907b47fff3297
MD5 dae6904dccab52fa9bf0cdd88d4d07a7
BLAKE2b-256 cd2099d772be0a345b432ed460e29a78dbd86c71652c1162ec030cce52d7c29b

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page