Skip to main content

A powerful dictionary for common internet and text slang (Lychee Language Core).

Project description

Lychee: Language Core Lychee is a lightweight Python package designed to quickly look up the meanings of common internet abbreviations, text slang, and acronyms in a case-insensitive manner. It is the core utility for cleaning and analyzing user-generated text.

Installation pip install lychee

Lychee Core Features (SlangDictionary Class) The core SlangDictionary class provides robust lookups and replacement functionality:

Method

Description

Example

replace_slang_in_text()

Crucial for Data Cleaning. Replaces all recognized slang terms in a string with their full meanings.

slang.replace_slang_in_text(text)

get_meaning()

Finds the meaning of a given slang term (case-insensitive).

slang.get_meaning('BRB')

reverse_lookup()

Finds slang terms based on a keyword in the meaning.

slang.reverse_lookup('laugh')

search_slang()

Searches terms or meanings containing a specific keyword.

slang.search_slang('friend')

Quick Start: Slang Replacement You can easily apply this function to a single string or a pandas Series/Column.

from lychee import SlangDictionary

Initialize the Lychee Core Slang Dictionary

slang_lookup = SlangDictionary()

input_text = "TBH, the new game slaps! I'm AFK now, BRB. No cap, it was fire."

Clean the text using the replacement function

cleaned_text = slang_lookup.replace_slang_in_text(input_text)

print(cleaned_text)

Output: To be honest, the new game Describing something as good (e.g. This song slaps)! I'm Away from keyboard now, Be right back. No lie, it was A word to describe something positive (e.g. That game is fire).

Upcoming Text Processing Utilities (Future Release) The TextCleaner class is a structural placeholder for future feature development, including:

to_lowercase()

remove_html_tags()

remove_urls()

remove_punctuation()

Contributing We welcome contributions! Feel free to fork the repository on GitHub and submit a pull request.

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

him_lychee-0.1.1.tar.gz (8.0 kB view details)

Uploaded Source

Built Distribution

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

him_lychee-0.1.1-py3-none-any.whl (8.5 kB view details)

Uploaded Python 3

File details

Details for the file him_lychee-0.1.1.tar.gz.

File metadata

  • Download URL: him_lychee-0.1.1.tar.gz
  • Upload date:
  • Size: 8.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.7

File hashes

Hashes for him_lychee-0.1.1.tar.gz
Algorithm Hash digest
SHA256 3d8971e221aa9b32ac082989469a695f0b962b784924ad46fe37c25aec1e4f2b
MD5 de770fc2b767d91645292710dbe37c88
BLAKE2b-256 86b7c13f6a3071348fe9007ae109ce30341bb8996af9bf4d5ffa876a1ef6ad78

See more details on using hashes here.

File details

Details for the file him_lychee-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: him_lychee-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 8.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.7

File hashes

Hashes for him_lychee-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 a37bc3462588177f82497e79af448b5ac0c245316e6a5bac115ccf14c2e31254
MD5 37112ec41f5ed9bdc0c8d7ec72574144
BLAKE2b-256 4a691568ff3e9e94fea891e5b644a6e53ac2f737aadb326906fde4cfc8de5064

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