Coder Social home page Coder Social logo

uwuipy's Introduction

uwuipy

uwuipy is an advanced uwuifier for Python, designed to transform regular text into a playful and expressive "uwu" style. This whimsical modification of text is often used in online communities for humorous or emotive communication.

Whether you're looking to add a fun twist to a chat application or simply want to explore text manipulation in a lighthearted manner, uwuipy offers an easy-to-use interface with customizable options to create unique text transformations.

The library provides control over various aspects of the uwuification process, including stuttering, facial expressions, actions, and exclamations. Whether you want subtle changes or dramatic transformations, uwuipy allows you to find the perfect balance through adjustable parameters.

Key Features:

  • Ease of Use: Quickly integrate uwuipy into your projects with a simple API.
  • Customizable: Tailor the uwuification process to your needs with adjustable parameters.
  • CLI Support: Use the tool directly from the command line or integrate it into Python applications.
  • Entertainment: A unique way to engage users with lively and animated text transformations.

Requirements

  • Python 3.10 or higher

Install

To install just use PyPI pip install uwuipy

Usage

As a library

Integrate uwuipy into your Python application to transform ordinary text into playful uwu-styled expressions. Here's a basic example of how to use it:

from uwuipy import uwuipy

uwu = uwuipy()
print(uwu.uwuify(input()))

Constructor parameters

The uwuipy constructor allows fine-tuning of the uwuification process through the following parameters:

  • seed: An integer seed for the random number generator. Defaults to current time if - not provided.
  • stutterchance: Probability of stuttering a word (0 to 1.0), default 0.1.
  • facechance: Probability of adding a face (0 to 1.0), default 0.05.
  • actionchance: Probability of adding an action (0 to 1.0), default 0.075.
  • exclamationchance: Probability of adding exclamations (0 to 1.0), default 1.
  • nsfw_actions: Enables more explicit actions if set to true; default is false.

Customized Example:

Adjust the parameters to create a customized uwuification process:

from uwuipy import uwuipy

uwu = uwuipy(None, 0.3, 0.3, 0.3, 1, False)
print(uwu.uwuify(input()))

This can produce output like:

The quick brown fox jumps over the lazy dog
The quick b-b-b-bwown (・\`ω\´・) ***screeches*** fox jumps uvw t-t-t-the OwO wazy dog

Time-Based Seeding:

Utilize time-based seeding for unique transformations:

from datetime import datetime
from uwuipy import uwuipy

message = "Hello this is a message posted in 2017."
seed = datetime(2017, 11, 28, 23, 55, 59, 342380).timestamp()
uwu = uwuipy(seed)
print(uwu.uwuify(message))

This method only uses the uwuify() function, accepting a string and returning an uwuified string based on the constructor parameters.

Directly in the terminal

CLI

Use uwuipy directly from the command line for quick uwuification:

python3 -m uwuipy The quick brown fox jumps over the lazy dog

Output:

The quick b-b-b-bwown (・\`ω・) ***screeches*** fox jumps uvw t-t-t-the OwO wazy dog

REPL

REPL Mode:

python3 -m uwuipy 
>>> The quick brown fox jumps over the lazy dog
The quick b-b-b-bwown (・\`ω・) ***screeches*** fox jumps uvw t-t-t-the OwO wazy dog

Help

Command Line Help:

python3 -m uwuipy --help

Contributing and Licence

Feel free contribute to the GitHub repo of the project.

Licenced under MIT

uwuipy's People

Contributors

cuprum77 avatar r2boyo25 avatar diminddl avatar thatredkite avatar pin-lee avatar badlywrittenstylesheet avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.