Introducing The Sweep: OX’s New Live Security Research Series
Register Now
Breaking: The 2026 Vulnpocalypse Hits PHP: Four Critical RCEs, but How Dangerous Are They?
Read the Report
Are you exposed? Connect your apps in minutes.
Scan your apps free

cluey

Latest version: v0.2.1

Overview

Last scanned
28 Nov 2026
Published
28 Nov 2026
PyPI package Publisher: rturnbull
1 Stars
0 Forks
2 Versions
32 Downloads
Python Repo language

Scan summary

cluey was last scanned on 28 Nov 2026 at version 0.2.1. Risk score 0 of 100. No malicious behavior was detected.

  • Releases: 2 versions, all published within 2 days (27 and 28 Nov 2026).
  • Findings: No rules fired in version 0.2.1.
  • Downloads: 32 downloads.

Versions

2 versions published
Versions and the rules that fired in each
VersionPublishedStatus
0.2.1 LATEST 28 Nov 2026 No rules fired
0.2.0 27 Nov 2026 No rules fired

No rules fired in 0.2.1

Findings

Findings for v0.2.1. The score is a capped sum of the weights of the rules that fired — not CVSS, not exploitability, and not a probability. It is not comparable across packages with different scan coverage.

The score describes 0.2.1; other versions have their own rules, not their own score.

README

The publisher’s own README, as collected from the registry.

========== cluey

.. start-badges

|pypi badge| |testing badge| |coverage badge| |docs badge| |black badge| |git3moji badge| |cluey badge|

.. |pypi badge| image:: https://img.shields.io/pypi/v/cluey?color=blue :alt: PyPI - Version :target: https://pypi.org/project/cluey/

.. |cluey badge| image:: https://img.shields.io/badge/cluey-B1230A.svg :target: https://rbturnbull.github.io/cluey/

.. |testing badge| image:: https://github.com/rbturnbull/cluey/actions/workflows/testing.yml/badge.svg :target: https://github.com/rbturnbull/cluey/actions

.. |docs badge| image:: https://github.com/rbturnbull/cluey/actions/workflows/docs.yml/badge.svg :target: https://rbturnbull.github.io/cluey

.. |black badge| image:: https://img.shields.io/badge/code%20style-black-000000.svg :target: https://github.com/psf/black

.. |coverage badge| image:: https://img.shields.io/endpoint?url=https://gist.githubusercontent.com/rbturnbull/b84e24e6b58498cfcdd7f19388e111ad/raw/coverage-badge.json :target: https://rbturnbull.github.io/cluey/coverage/

.. |git3moji badge| image:: https://img.shields.io/badge/git3moji-%E2%9A%A1%EF%B8%8F%F0%9F%90%9B%F0%9F%93%BA%F0%9F%91%AE%F0%9F%94%A4-fffad8.svg :target: https://robinpokorny.github.io/git3moji/

.. end-badges

Cluey - Command Line Utility for Engineers & You

Build clever, class-based command line apps with minimal boilerplate

Documentation at https://rbturnbull.github.io/cluey/

.. start-quickstart

Installation

The software can be installed using uv

.. code-block:: bash

uv add cluey

To install the latest version from the repository, you can use this command:

.. code-block:: bash

uv add git+https://github.com/rbturnbull/cluey.git

Documentation is available here: https://rbturnbull.github.io/cluey/

Your first Cluey CLI

Here is a minimal example of a Cluey CLI app:

.. code-block:: Python

import cluey

class GreetApp(cluey.Cluey):
    """A minimal Cluey CLI app"""

    @cluey.main
    def greet(self, name: str = cluey.Argument(..., help="")):
        """Greet a person by name"""
        print(f"Hello, {name}!")


if __name__ == "__main__":
    GreetApp().main()

Then you can run this:

.. code-block:: bash

python cluey/examples/greet.py --help

Which will display:

.. code-block:: bash

╭─ Arguments ─────────────────────────────────────────────────────────────────╮
│ *    name      TEXT  The name of the person to greet [required]             │
╰─────────────────────────────────────────────────────────────────────────────╯
╭─ Options ───────────────────────────────────────────────────────────────────╮
│ --version  -v        Show the version of this CLI                           │
│ --help               Show this message and exit.                            │
╰─────────────────────────────────────────────────────────────────────────────╯

To run the app,

.. code-block:: bash

python cluey/examples/cluey/examples/greet.py Alice

This will display:

.. code-block:: bash

Hello, Alice!

You can also run the command programatically:

.. code-block:: python

>>> app = GreetApp()
>>> app.greet("Alice")
Hello, Alice!

Adding a flag

.. code-block:: python

import cluey

class GreetApp(cluey.Cluey):
    """A minimal Cluey CLI app"""

    @cluey.main
    def greet(self, name: str = cluey.Argument(..., help="The name of the person to greet")):
        """Greet a person by name"""
        print(f"Hello, {name}!")

    @cluey.flag(shortcut="-v")
    def version(self) -> str:
        """Show the version of this CLI"""
        return "GreetApp version 0.1.0"


if __name__ == "__main__":
    GreetApp().main()    

To display the version of the app, run:

.. code-block :: bash

python cluey/examples/greet.py --version
# OR
python cluey/examples/greet.py -v

Adding a second command

.. code-block:: python

import cluey

class ArithmeticApp(cluey.Cluey):
    """ Does basic arithmetic """

    @cluey.main
    def add(
        self, 
        a: float = cluey.Argument(..., help="A value to start with."),
        b: float = cluey.Argument(..., help="A value to add."),
    ):
        """ Sums two values """
        print(a+b)

    @cluey.main
    def subtract(
        self, 
        a: float = cluey.Argument(..., help="A value to start with."),
        b: float = cluey.Argument(..., help="A value to sub."),
    ):
        """ Subtracts one value from another """
        print(a-b)


if __name__ == "__main__":
    ArithmeticApp().main()

Then you can run the following:

.. code-block :: bash

python cluey/examples/arithmetic.py --help
python cluey/examples/arithmetic.py add --help
python cluey/examples/arithmetic.py subtract --help
python cluey/examples/arithmetic.py add 3 2
python cluey/examples/arithmetic.py subtract 3 2

Add options with defaults

.. code-block:: python

import unicodedata
import cluey


class StringTools(cluey.Cluey):
    """ Does simple string functions """
    @cluey.main
    def lowercase(
        self,
        string: str = cluey.Argument(..., help="The string to process."),
    ) -> str:
        """Converts the string to lowercase."""
        string = string.lower()
        print(string)
        return string

    @cluey.main
    def clean(
        self, 
        string: str = cluey.Argument(..., help="The string to process."),
        strip_accents:bool = cluey.Option(False, help="Whether or not to strip accents."),
        ascii:bool = cluey.Option(False, help="Whether or not to include only ascii characters."),
    ) -> str:
        """Cleans the given string."""
        if strip_accents:
            string = ''.join(
                character for character in unicodedata.normalize('NFKD', string)
                if not unicodedata.combining(character)
            )

        if ascii:
            string = ''.join(character for character in string if character.isascii())

        print(string)
        return string


if __name__ == "__main__":
    StringTools().main()    

Now the optional arguments can be set via the command line:

.. code-block:: bash

python cluey/examples/stringtools.py clean "Café ☕️" --strip-accents --ascii

Cafe

Call one method from another

So far, all of the above could have been done more easily with Typer, but with Cluey, you are able to call one method from another and the function arguments get passed to the command line.

.. code-block:: python

import unicodedata
import cluey


class StringTools(cluey.Cluey):
    """ Does simple string functions """

    @cluey.main
    def clean(
        self, 
        string: str = cluey.Argument(..., help="The string to process."),
        strip_accents:bool = cluey.Option(True, help="Whether or not to strip accents."),
        ascii:bool = cluey.Option(False, help="Whether or not to include only ascii characters."),
    ) -> str:
        """Cleans the given string."""
        if strip_accents:
            string = ''.join(
                character for character in unicodedata.normalize('NFKD', string)
                if not unicodedata.combining(character)
            )

        if ascii:
            string = ''.join(character for character in string if character.isascii())

        print(string)
        return string

    @cluey.main('clean')
    def count_vowels(self, string: str, **kwargs) -> int:
        """Counts the number of vowels in the string."""

        string = self.clean(string, **kwargs).lower()

        result = sum(1 for character in string if character in 'aeiou')
        print("Vowels:", result)
        return result


if __name__ == "__main__":
    StringTools().main()

Now I can see that all the options for the clean command are available with count_vowels:

.. code-block:: bash

python cluey/examples/stringtools.py count-vowels --help

.. code-block:: bash

Usage: stringtools.py count-vowels [OPTIONS] STRING               

Counts the number of vowels in the string.                        

╭─ Arguments ─────────────────────────────────────────────────────╮
│ *    string      TEXT  The string to process. [required]        │
╰─────────────────────────────────────────────────────────────────╯
╭─ Options ───────────────────────────────────────────────────────╮
│ --strip-accents    --no-strip-accents      Whether or not to    │
│                                            strip accents.       │
│                                            [default:            │
│                                            no-strip-accents]    │
│ --ascii            --no-ascii              Whether or not to    │
│                                            include only ascii   │
│                                            characters.          │
│                                            [default: no-ascii]  │
│ --help                                     Show this message    │
│                                            and exit.            │
╰─────────────────────────────────────────────────────────────────╯

.. code-block:: bash

python cluey/examples/stringtools.py count-vowels "Café ☕️" --strip-accents

.. code-block:: bash

Cafe
Vowels: 2

Methods that are not commands

Not all methods need to be exposed as commands to the command-line interface.

.. code-block:: python

import cluey

class MLApp(cluey.Cluey):
    """A simple machine learning style CLI"""

    @cluey.method
    def get_batches(
        self,
        items: list[str] = cluey.Argument(..., help="List of items to process"),
        batch_size: int = cluey.Option(
            2,
            help="Batch size for training and evaluation"
        ),
    ):
        """Split items into batches (not a command)."""
        batches = [
            items[i:i + batch_size]
            for i in range(0, len(items), batch_size)
        ]
        return batches

    @cluey.main("get_batches")
    def train(self, **kwargs):
        """Train a model in batches."""
        batches = self.get_batches(**kwargs)
        print(f"Training on {len(batches)} batches")
        for batch in batches:
            print(f"Training on batch: {batch}")

    @cluey.main("get_batches")
    def evaluate(self, **kwargs):
        """Evaluate a model in batches."""
        batches = self.get_batches(**kwargs)
        print(f"Evaluating {len(batches)} batches:")
        for batch in batches:
            print(f"Evaluating on batch: {batch}")


if __name__ == "__main__":
    MLApp().main()

Now all the arguments and options for get_batches are available with train and evaluate but get_batches isn't a command.

.. code-block:: bash

$ python cluey/examples/ml.py --help

Usage: ml.py [OPTIONS] COMMAND [ARGS]...                                              

╭─ Options ───────────────────────────────────────────────────────────────────────────╮
│ --help          Show this message and exit.                                         │
╰─────────────────────────────────────────────────────────────────────────────────────╯
╭─ Commands ──────────────────────────────────────────────────────────────────────────╮
│ evaluate   Evaluate a model in batches.                                             │
│ train      Train a model in batches.                                                │
╰─────────────────────────────────────────────────────────────────────────────────────╯    

$ python cluey/examples/ml.py train A B C D E
Training on 3 batches
Training on batch: ['A', 'B']
Training on batch: ['C', 'D']
Training on batch: ['E']

$ python cluey/examples/ml.py evaluate F G H I J K L M --batch-size 3
Evaluating 3 batches:
Evaluating on batch: ['F', 'G', 'H']
Evaluating on batch: ['I', 'J', 'K']
Evaluating on batch: ['L', 'M']

Inheritance

Cluey allows you to have base classes and inherit from them to build more complex CLIs.

.. code-block:: python

import cluey
from cluey.examples.ml import MLApp


class ExtendedMLApp(MLApp):
    """Extends MLApp with an extra command"""

    @cluey.main("get_batches")
    def stats(self, **kwargs):
        """Show batch statistics."""
        batches = self.get_batches(**kwargs)
        sizes = [len(b) for b in batches]
        total = sum(sizes)
        print(f"{len(batches)} batches; sizes={sizes}; total_items={total}")


if __name__ == "__main__":
    ExtendedMLApp().main()

This app contains all the commands of the base MLApp but it adds the extra stats command.

.. code-block:: bash

$ python cluey/examples/extendedml.py --help

Usage: extendedml.py [OPTIONS] COMMAND [ARGS]...                           

╭─ Options ────────────────────────────────────────────────────────────────╮
│ --help          Show this message and exit.                              │
╰──────────────────────────────────────────────────────────────────────────╯
╭─ Commands ───────────────────────────────────────────────────────────────╮
│ evaluate   Evaluate a model in batches.                                  │
│ stats      Show batch statistics.                                        │
│ train      Train a model in batches.                                     │
╰──────────────────────────────────────────────────────────────────────────╯    

$ python cluey/examples/extendedml.py stats A B C D E F G H I J K L M

7 batches; sizes=[2, 2, 2, 2, 2, 2, 1]; total_items=13

Calling Super

You can also override methods from the parent class and extend the arguments and options, without redefining the arguments from the super method.

.. code-block:: python

OX Radar and Response Center

Find threats in your stack.

OX Radar can check high-priority threats, like critical package CVEs, against your context.

Each incident is marked Detected or Not Detected with a remediation plan and proof all tracked in the Response Center.

Where it’s listed

The probe returned only these fields for this server — auth requirement, protocol and tool list weren’t observed, so they’re not shown (never guessed).

  • pypi-releases cluey

References

The publisher’s own links, as the registry reports them. These are not sources for the assessment on this page.

Powered by Read the latest findings

Scan your whole stack

Group 1261154050 1
Group 1261154050
 

From OX Research Newsroom

Plug and Pray: Your AI Agents Are Taking Orders From Strangers
Research

Plug and Pray: Your AI Agents Are Taking Orders From Strangers

PolinRider Returns
Research

PolinRider Returns: Hijacked npm Packages Use Ethereum Blockchain to Conceal Malware Infrastructure

The 2026 Vulnpocalypse Hits PHP: Four Critical RCEs, but How Dangerous Are They?
Vulnerability Insights

The 2026 Vulnpocalypse Hits PHP: Four Critical RCEs, but How Dangerous Are They?

Frame 2085668439 (1)
Group 1261154229