semvec/pypi-packages huggingface dataset:
determinismus-kit 0.1.1
Kleines Determinismus-Kit für reproduzierbare Python-Läufe (Seeds, Threads, Snapshots, optional PyTorch/NumPy).
Requires Python: >=3.8

# Determinismus-Kit für Python

[![PyPI](https://img.shields.io/pypi/v/determinismus-kit.svg)](https://pypi.org/project/determinismus-kit/)
[![TestPyPI](https://img.shields.io/badge/TestPyPI-Link-blue)](https://test.pypi.org/project/determinismus-kit/)
[![GitHub](https://img.shields.io/badge/GitHub-Repo-black)](https://github.com/DrMabuseistda/determinismus-kit)
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](LICENSE)

Ein kleines Toolkit, das Python-Läufe reproduzierbarer macht:

- Seeds setzen (`random`, optional `numpy`, optional `torch`)
- Threads bändigen (OMP/BLAS/MKL)
- Umgebungs-Snapshot (Versionen/ENV)
- CLI: `python -m determinismus_kit run ...` oder `determinismus-kit`

---

## Installation

### Für Entwicklung
```bash
pip install -e .
```

### Von TestPyPI
Das Paket ist aktuell auf TestPyPI verfügbar:
```bash
pip install -i https://test.pypi.org/simple/ determinismus-kit
```

---

## Nutzung

### Als Bibliothek
```python
from determinismus_kit import deterministic

with deterministic(seed=123, threads=1):
    import random
    print([random.random() for _ in range(3)])
```

### Als CLI
```bash
python -m determinismus_kit run --seed 123 --threads 1 your_script.py
# oder
determinismus-kit run --seed 123 --threads 1 your_script.py
```

Argumente für das Zielskript kommen **nach `--`**:
```bash
determinismus-kit run --seed 123 your_script.py -- --foo bar
```

---

## Optionen

- `--seed` Seed für RNGs (Default: 123)  
- `--threads` Anzahl Threads für BLAS/OMP (Default: 1)  
- `--snapshot PATH` Umgebungssnapshot schreiben  
- `--no-cuda-determinism` CUDA-Deterministik nicht erzwingen  
- `-c/--code` Direkt Python-Code ausführen  

---

## Beispiele

### 1. Python-Skript deterministisch ausführen
```bash
determinismus-kit run --seed 123 --threads 1 examples/simple_random.py
```

### 2. Direkt Python-Code per `-c/--code` ausführen
```bash
determinismus-kit run --seed 42 --threads 1 -c "import random; print([random.random() for _ in range(3)])"
```

Mit gleichem Seed zweimal identisch:
```
[0.6394267984578837, 0.025010755222666936, 0.27502931836911926]
[0.6394267984578837, 0.025010755222666936, 0.27502931836911926]
```

Mit anderem Seed:
```
[0.32383276483316237, 0.15084917392450192, 0.6509344730398537]
```

---

## Hinweise

- NumPy/PyTorch werden automatisch unterstützt, wenn installiert.  
- Kleine Abweichungen auf verschiedener Hardware/OS sind möglich (Floating-Point).  
- Das Toolkit ist „best effort“ – für viele Praxisfälle ausreichend.  

---

## Lizenz

Dieses Projekt steht unter der [MIT License](LICENSE).
cartomancy 0.1.1
a tarot and minchiate TUI
Requires Python: <4.0,>=3.8
Keywords: tarot, cartomancy, divination, minchiate, fortunetelling

# cartomancy

a CLI for drawing tarot and minchiate cards, for quick, portable readings right in your terminal


## features

- supports two decks: **tarot** and **minchiate**
- draw any number of cards: 1-78 for tarot and 1-97 for minchiate
- optional reversals


## installation

cartomancy can be installed directly from [pypi](https://pypi.org/project/cartomancy).

```
# try without installing
uvx cartomancy

# install globally
uv tool insttall cartomancy

# or more traditionally
pip install --user cartomancy
pipx install cartomancy
```

## usage

```sh
usage: cards [-h] [-r] {tarot,minchiate} N

cartomancy in the terminal 🃏

positional arguments:
  {tarot,minchiate}  pick a deck
  N                  # of cards to draw

options:
  -h, --help         show this help message and exit
  -r, --reversals    allow reversals
```
prompt-refiner-cb 0.0.2
This package refines and optimizes prompts using a large language model (LLM) powered by https://www.aliyun.com/product/bailian
Requires Python: >=3.9

# Prompt Refiner 🗑️

[![Python](https://img.shields.io/badge/python-3.13-blue.svg)](https://www.python.org/)
[![License](https://img.shields.io/badge/license-MIT-green.svg)](LICENSE)

**Prompt Refiner** is a Python module to refine and optimize prompts for large language models (LLMs) using [Alibaba Cloud Bailian](https://www.aliyun.com/product/bailian). It helps improve clarity, specificity, and overall effectiveness of prompts effortlessly.

---

## Features

* **`PromptRefiner.refine(prompt)`** — Refine any user prompt.
* **`PromptRefiner.refine_system_prompt()`** — Refine the internal system prompt.

---

## Quick Install

```bash
pip install prompt_refiner_cb
```

> **Note:** Requires a valid LLM API key (Aliyun Bailian).

---

## Usage

```python
from prompt_refiner import PromptRefiner

# Initialize the refiner
refiner = PromptRefiner(api_key="YOUR_LLM_API_KEY")

# Refine a user prompt
user_prompt = "Write a story about a dragon and a princess."
refined_prompt = refiner.refine(user_prompt)
print(refined_prompt)

# Refine the system prompt itself
refined_system = refiner.refine_system_prompt()
print(refined_system)
```

---

## Environment Variables

Create a `.env` file in your project root:

```
LLM_API_KEY="your_api_key_here"
```

Pipenv or your environment will automatically load this variable.

---

## API Reference

### `PromptRefiner(api_key=None, model="deepseek-r1")`

Initialize the refiner. Uses the environment variable `LLM_API_KEY` if `api_key` is not provided.

**Parameters:**

| Parameter | Type | Default         | Description       |
| --------- | ---- | --------------- | ----------------- |
| `api_key` | str  | `None`          | LLM API key.      |
| `model`   | str  | `"deepseek-r1"` | LLM model to use. |

---

### `refine(prompt, system_prompt=None, temperature=0)`

Refine a user prompt.

**Parameters:**

| Parameter       | Type  | Default          | Description                                      |
| --------------- | ----- | ---------------- | ------------------------------------------------ |
| `prompt`        | str   | -                | The text to refine.                              |
| `system_prompt` | str   | `_SYSTEM_PROMPT` | Optional system instructions guiding refinement. |
| `temperature`   | float | 0                | Sampling temperature (controls creativity).      |

**Returns:** `str` — The refined prompt.

---

### `refine_system_prompt(temperature=0)`

Refines the internal system prompt itself.

**Parameters:**

| Parameter     | Type  | Default | Description                          |
| ------------- | ----- | ------- | ------------------------------------ |
| `temperature` | float | 0       | Sampling temperature for refinement. |

**Returns:** `str` — The refined system prompt.

---

## License

MIT License