semvec/pypi-packages huggingface dataset:
epub-optimizer 0.6.0
Optimize epub file size
License: MIT
Requires Python: >=3.9

# epub-optimizer

This CLI will optimize your epub file size, by performing the following operations:
- converting all PNG images to black and white JPGs
- removing any un-used fonts
- running `jpegoptim` on all jpgs, if it is installed and available

## Installation

```console
$ pip install epub-optimizer
```

## Usage

```console
$ epub-optimizer --help
usage: epub-optimizer [-h] -i INPUT [--verbose] output

Optimize epub file size

positional arguments:
  output                The output filepath

optional arguments:
  -h, --help            show this help message and exit
  -i INPUT, --input INPUT
                        The input filepath
  --verbose
```

Example:
```console
$ epub-optimizer -i ~/Downloads/Oathbringer\ \(The\ Stormlight\ Archive\ \#3\)\ -\ Brandon\ Sanderson.epub output.epub
The EPUB size was optimized from 32 MB to 11 MB
```
promptfold 1.0.15
Python client for PromptFold API - optimize prompts with PromptFold
License: MIT
Requires Python: >=3.8
Keywords: promptfold, optimization, api, client

# PromptFold Client Library

This package provides a simple Python client for the PromptFold API available on PyPI.

## Installation
```bash
pip install promptfold
```

## Usage

```python
import openai
from promptfold_client import PromptFold

# Initialize PromptFold client, compress your system prompt
pf_client = PromptFold(api_key="YOUR_PROMPTFOLD_API_KEY", system_prompt="Your system prompt.")

# Compress the original user prompt and system prompt
compressed = pf_client.compress_prompt(user_prompt="Input user prompt")

# Call OpenAI's GPT-4 with the compressed prompt
openai.api_key = "YOUR_OPENAI_API_KEY"
response = openai.ChatCompletion.create(
    model="gpt-4o",
    messages=[
        {"role": "system", "content": compressed.compressed_system_prompt},
        {"role": "user", "content": compressed.compressed_user_prompt}
    ]
)

# Print the response from GPT-4
print(response["choices"][0]["message"]["content"])

```

## Publishing a New Version (for Maintainers)

Publishing the client is handled by a script that automates the entire process.

**Prerequisites:**
1.  **PyPI Account:** You need an account on [PyPI](https://pypi.org) and an API token.
2.  **Twine Configuration:** Your local machine must be configured to authenticate with PyPI. You can do this by setting the `TWINE_USERNAME` and `TWINE_PASSWORD` environment variables.

**To publish a new version:**
1.  Navigate to the client directory: `cd promptfold_client`
2.  Run the publishing script. You have two options:
    *   **To automatically bump the patch version** (e.g., `1.0.1` -> `1.0.2`), run the script without arguments:
        ```bash
        ./publish_pypi.sh
        ```
    *   **To specify an exact version** (e.g., for a major release like `2.0.0`), provide it as an argument:
        ```bash
        ./publish_pypi.sh 2.0.0
        ```
3.  The script will handle everything else automatically.