semvec/pypi-packages huggingface dataset:
pyproject2ebuild 0.0.4
Convert pyproject.toml to Gentoo ebuilds automatically.
Requires Python: >=3.9

# pyproject2ebuild

**pyproject2ebuild** is a tool to automatically convert Python `pyproject.toml` 
metadata into Gentoo ebuild files.
It can openrate on a local `pyproject.toml` or fetch it for you.

## Features
- Parses project name, version, description, license, homepage
- Converts Python dependencies to Gentoo dependency syntax
- Auto-maps version constraints
- Auto-generate metadata.xml
- Compatible with setuptools and setuptools_scm
- GPL-3.0-or-later licensed



## Example:

```
$ pyproject2ebuild https://raw.githubusercontent.com/pyupio/safety/refs/heads/main/pyproject.toml
Downloaded pyproject.toml from https://raw.githubusercontent.com/pyupio/safety/refs/heads/main/pyproject.toml
Ebuild written to ./safety-3.4.0.ebuild


$ cat safety-3.4.0.ebuild
# Copyright 2025
# Distributed under the terms of the GNU General Public License v2

EAPI=8

PYTHON_COMPAT=( python3_11 python3_12 )

inherit distutils-r1

DESCRIPTION="Scan dependencies for known vulnerabilities and licenses."
HOMEPAGE=""
SRC_URI="https://pypi.io/packages/source/s/safety/safety-3.4.0.tar.gz"

LICENSE="MIT"
SLOT="0"
KEYWORDS="~amd64"

DEPEND="
	>=dev-python/authlib-1.2.0[${PYTHON_USEDEP}]
	>=dev-python/click-8.0.2[${PYTHON_USEDEP}]
	>=dev-python/dparse-0.6.4[${PYTHON_USEDEP}]
	>=dev-python/filelock-3.16.1[${PYTHON_USEDEP}]
	>=dev-python/jinja2-3.1.0[${PYTHON_USEDEP}]
	>=dev-python/marshmallow-3.15.0[${PYTHON_USEDEP}]
	>=dev-python/packaging-21.0[${PYTHON_USEDEP}]
	>=dev-python/psutil-6.1.0[${PYTHON_USEDEP}]
	>=dev-python/pydantic-2.6.0[${PYTHON_USEDEP}]
	<dev-python/pydantic-2.10.0[${PYTHON_USEDEP}]
	dev-python/requests[${PYTHON_USEDEP}]
	dev-python/httpx[${PYTHON_USEDEP}]
	dev-python/tenacity[${PYTHON_USEDEP}]
	=dev-python/safety-schemas-0.0.14[${PYTHON_USEDEP}]
	>=dev-python/setuptools-65.5.1[${PYTHON_USEDEP}]
	>=dev-python/typer-0.12.1[${PYTHON_USEDEP}]
	>=dev-python/typing-extensions-4.7.1[${PYTHON_USEDEP}]
	>=dev-python/nltk-3.9[${PYTHON_USEDEP}]
	dev-python/tomlkit[${PYTHON_USEDEP}]
"
RDEPEND="${DEPEND}"
```
probability-chain 0.2.0
Simulate and optimize chained probability stages
Requires Python: >=3.7

# Probability Chain

🧮 **ProbabilityChain** is a Python class for simulating and optimizing chained probability systems — like upgrading systems in games, reliability paths, or multi-stage processes. It helps you allocate limited resources (probability boosts) to maximize the chance of reaching a final target stage.

---

## 🚀 Features

- Compute cumulative success probability up to any stage
- Optimize incremental probability allocations for best end-stage result
- Simulate and visualize how resource allocations affect outcomes
- Generate step-by-step summaries and allocation analysis

---

## 📦 Installation

Install from PyPI (once published):

```bash
pip install probability-chain
```

## 🧪 Example Usage

```python
from probability_chain import ProbabilityChain

# Define base probabilities for each stage (A through E)
chain = ProbabilityChain([0.5, 0.1, 0.5, 0.5, 0.5])

# Simulate how to optimally allocate a total of 1.5 "probability points"
steps = chain.simulate_optimal_allocation(total_budget=1.5, step=0.01, target_stage='E')

# Output a narrative summary of what happened
chain.summarize_allocation(steps)

```
Example Output:
```text
Step-by-Step Increment Allocation (Target Stage: E):
Step  1: Allocated 0.0100 to Stage B (New Value: 0.1100)
...

Final Allocation Summary (Total Budget: 1.5):
Stage A: +0.2200
Stage B: +0.6200
Stage C: +0.2200
Stage D: +0.2200
Stage E: +0.2200

Final Probability Values:
Stage A: 0.7200
Stage B: 0.7200
Stage C: 0.7200
Stage D: 0.7200
Stage E: 0.7200
```

## 📈 Output Visualization
After each simulation, a plot is shown:

X-axis: budget spent (in %)

Y-axis: total probability of reaching the target stage (in %)

The plot illustrates how probability grows with optimized allocation.

## 📚 API Overview
```python
ProbabilityChain(stages: List[float])
```
Create a new probability chain instance from a list of base probabilities for each stage (e.g., stages A through E).

Core Methods:
```python
compute_partial_probability(values=None, target_stage='E')
```
Returns the cumulative probability of reaching the given target stage by multiplying probabilities from the start.

```python
simulate_optimal_allocation(total_budget, step, target_stage)
```
Simulates how to distribute a fixed amount of budget (total_budget) in increments (step) across stages to maximize the probability of reaching target_stage.

Returns a list of steps detailing what was allocated where.
```python
summarize_allocation(steps)
```
Prints a narrative breakdown of the allocation history returned by simulate_optimal_allocation. Includes dominant stages, balance trends, and final values.

```python
compare(*adjustment_sets, target_stage)
```
Compare one or more manual adjustment strategies (e.g. increasing A by 0.1, B by 0.2, etc.) to see which leads to the best improvement in total probability.

Example Usage:
```python
chain.compare(
    [('B', 0.2)],
    [('A', 0.1), ('C', 0.1)],
    target_stage='E'
)
```
## 📝 License
This project is licensed under the MIT License.
See the [LICENSE](./LICENSE) file for more information.

## 👤 Author
Logan Diliberto
extra-input 1.0.6
Various functions to get input from the user

# Extra Input
A simple helper lib with a few extra ways to get input from the user

## How to use:
``` python
import extra_input

option = extra_input.selector(["Option [1]","Option [2]"])

print(f"you selected {option}")
```

## Functions:
 * `select(options:list[str], squareBrackets = True) -> str`
   Selects from a list of items, by defualt uses the items in the first square brackets of the list
 * `numbered_select(options:list[str], use_parens = False, roman_numerals = False) -> str`
   Selects from a list of items, selecting by using numbers not needed in the list
   Can use 1) or roman numerals
 * `intput(text:str) -> int`
   Gets input and only allows ints
 * `float_input(text:str) -> float`
   Gets input and only allows floats
 * `custom_input(text:str, allowed:str, tellAllowed = True) -> str`
   Gets input only allowing the charecters in allowed

## Ideas, Errors, or Helping
If you want to do any of the three please email me at lpowyt3@gmail.com

## Github
You can see the github here: [extra-input github](https://github.com/lpow100/extra-input)

## Changelog:
 * 1.0.5:
    - Fixed a bug where PyPI didn't show this whole readme
 * 1.0.4:
    - Fixed some misc bugs
    - Fixed selector using the wrong index
    - Fixed selector using its own charecter making it more error prone
 * 1.0.0 - 1.0.3:
    - Firguring out how to make this work
LngDetectoR 2025.5.81751
A tool to detect programming languages in a directory.
Requires Python: >=3.6

[![PyPI version](https://badge.fury.io/py/LngDetectoR.svg)](https://badge.fury.io/py/LngDetectoR)
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
[![Downloads](https://static.pepy.tech/badge/lngdetector)](https://pepy.tech/project/lngdetector)
[![LinkedIn](https://img.shields.io/badge/LinkedIn-blue)](https://www.linkedin.com/in/eugene-evstafev-716669181/)

# LngDetectoR

LngDetectoR is a Python tool designed to analyze directories and detect the programming languages used within files. It generates a comprehensive report detailing the count of files, lines of code, and the percentage of each language present.

## Installation

To install LngDetectoR, you can use pip:

```bash
pip install LngDetectoR
```

## Usage

### As a Command Line Tool

LngDetectoR can be utilized directly from the command line. Basic usage is as follows:

```bash
lngdetector --directory <path-to-directory>
```

- `--directory`: Specifies the directory to analyze. If not specified, it defaults to the current working directory.

### As a Python Module

LngDetectoR can also be used within your Python scripts.

Example:

```python
from lngdetector.detect import generate_report

# Generate a report for the specified directory
report = generate_report('/path/to/your/project')

# Display the report in a pretty table format
report.print_pretty_table()

# Retrieve data for a specific language
python_data = report.get_language_data('Python')
print(f"Python files: {python_data['count']}, lines of code: {python_data['lines']}")
```

## Output Example

When you run LngDetectoR, it generates a table with the detected languages, file counts, lines of code, and their percentage contributions. Here's an example of what the output might look like:

```
Total files: 50
Total lines of code: 1200
+------------+------------+---------------+------------+
|  Language  | File Count | Lines of Code | Percentage |
+------------+------------+---------------+------------+
| Python     |     20     |      500      |   41.67%   |
| JavaScript |     15     |      350      |   29.17%   |
| HTML       |     10     |      200      |   16.67%   |
| CSS        |      5     |      150      |   12.50%   |
+------------+------------+---------------+------------+
```

## Contributing

Contributions, issues, and feature requests are welcome! Feel free to check the [issues page](https://github.com/chigwell/langdetector/issues) for a list of proposed features (and known issues).

## License

This project is licensed under the [MIT License](https://choosealicense.com/licenses/mit/).
kalkon 0.6.0
Calculator with GUI
Requires Python: >=3.9
Keywords: calculator

![Python Version from PEP 621 TOML](https://img.shields.io/python/required-version-toml?tomlFilePath=https%3A%2F%2Fraw.githubusercontent.com%2Ffreand76%2Fkalkon%2Fmain%2Fpyproject.toml)
![PyPI - Version](https://img.shields.io/pypi/v/kalkon)
![PyPI - Downloads](https://img.shields.io/pypi/dm/kalkon)

# Kalkon - /kalˈkuːn/

*Swedish Noun*

*1. a turkey; a kind of large bird (colloquial)*

*2. a turkey; a failure*

*3. a python/asteval based calculator*

<p align="center">
  <img alt="Kalkon" src="https://raw.githubusercontent.com/freand76/kalkon/09cf8aa94aaf30b82a9e00e68c696bd3865af394/src/kalkon/images/kalkon.png" width=50%>
</p>

## Quickstart

### Install from PyPi
```
pip3 install kalkon
```

### Install from GitHub
```
> git clone https://github.com/freand76/kalkon.git
> cd kalkon
> python3 -m pip install .
```

### Start

Start using python.

```
> python3 -m kalkon
```

Start using shell script (if the pip3 bin-folder is in your path).

```
> kalkon
```

## Calculator

<p align="center">
  <img alt="Kalkon" src="https://raw.githubusercontent.com/freand76/kalkon/09cf8aa94aaf30b82a9e00e68c696bd3865af394/images/screenshot.png">
</p>

### Asteval

The calculator uses the [asteval](https://pypi.org/project/asteval) package to evaluate expressions.

Asteval handles python-like expression and will obey python rules for arithmetic and logic operators.

*Example*
```python
int(sin(pi/3)*log(5) + 0xfe) & 0x23
```

Asteval also handles variables, i.e. you can give variable a value and use it for later calculations.

*Example: Set variable*
```python
foo=3
```

*Example: Use variable*
```python
10 + foo * 5
```

### Commands

All commands start with a colon character
*Example:* **:hex**

**Output format commands**

The calculator can show the result of the expression in several different modes, enter one of the following commands to switch to the desired mode.

| Command | Description |
| :------ | :---------- |
| :float  | Show results as floating point |
| :f32    | Show results as 32-bit float / ieee-754 |
| :int    | Show results as integer, floats will be truncated |
| :i8"    | Show results as signed 8-bit integer |
| :i16    | Show results as signed 16-bit integer |
| :i32    | Show results as signed 32-bit integer |
| :i64    | Show results as signed 64-bit integer |
| :u8     | Show results as unsigned 8-bit integer |
| :u16    | Show results as unsigned 16-bit integer |
| :u32    | Show results as unsigned 32-bit integer |
| :u64    | Show results as unsigned 64-bit integer |
| :dec    | Show results as decimal values |
| :hex    | Show results as hexadecimal values |
| :bin    | Show results as binary values |


**Control commands**

The following command will clear the calculator stack.

| Command | Description |
| :------ | :---------- |
| :clear  | Clear the calculator stack |

### Shortcuts

| Shortcut | Description |
| :------- | :---------- |
| Shift+Enter | Drop stack item to editable field |