semvec/pypi-packages huggingface dataset:
mira-sdk 0.1.16
A Python SDK for the Mira API
License: MIT
Requires Python: >=3.10

# mira-sdk / mira-cli

## Prerequisites

- Python >= 3.10
- pip
- pdm

## Setup

```
pdm sync
```

## Usage

### CLI Commands

The mira-cli provides several commands for managing flows, prompts, and executing operations. Here's a brief overview of the available commands:

1. Initialize a flow:
   ```
   pdm run python -m src.mira.cli.mira_cli init --flow <flow_name> --template <template_name>
   ```
   - List available templates:
     ```
     pdm run python -m src.mira.cli.mira_cli init --list
     ```

2. Execute a flow: - #TODO - lets call this as local testing or local run
   ```
   pdm run python -m src.mira.cli.mira_cli execute --config <path_to_config_file> --input key1=value1 key2=value2
   ```

3. Manage prompts: - we have to start with prompts
   - List all prompts:
     ```
     pdm run python -m src.mira.cli.mira_cli prompts --lists
     ```
   - Show details of a specific prompt:
     ```
     pdm run python -m src.mira.cli.mira_cli prompts --show --prompt-name <author/prompt_name>
     ```

4. Deploy a flow:
   ```
   pdm run python -m src.mira.cli.mira_cli deploy --flow <path_to_yaml_config> --name <flow_name>
   ```

5. Execute a deployed flow:
   ```
   pdm run python -m src.mira.cli.mira_cli execute-flow --flow-name <flow_name> --input-data '{"key": "value"}'
   ```

For more detailed information on each command and its options, use the `--help` flag:

### SDK Usage

The Mira SDK provides a simple way to execute flows and build custom flows programmatically. Here are examples of how to use the SDK:

#### Executing a Flow

To execute a flow using the MiraClient:

```python
from mira_sdk.mira.client.mira_client import MiraClient

client = MiraClient("flows/person.yaml")
result = client.execute({"coin": "Solana"})
print(result)
```

This script loads a flow from a YAML file and executes it with the given input.

#### Building a Custom Flow
#TODO - lets skip this piece for now

To create a custom flow using the FlowBuilder:

```python
from mira_sdk.mira.builder.flow_builder import FlowBuilder

builder = FlowBuilder()

# Set flow name and description
builder.set_name("SimpleTextGenerator")
builder.set_description("Persona Impersonator")

# Add resources
builder.add_prompt([{"second_prompt": "Generate a short story about {person} at {club}", "type": "local"},
                    {"main_prompt": "@aroha-labs/klok/1.0.0", "type": "mira"}])
builder.add_resource("knowledge", "writing_tips", {"file": "writing_tips.txt"})
builder.add_resource("models", "story_generator", {"type": "gpt-3.5-turbo"})

# Add component
builder.add_component(
    "story_generator",
    "Generator",
    {
        "prompt": "{resources.prompts.main_prompt}",
        "models": "{resources.models.story_generator}",
    },
)

# Add flow step
builder.add_flow_step(
    "story_generator",
    inputs=[{"person": "request", "club": "request"}],
    outputs=[{"target": "response"}]
)

# Save the flow
builder.save("flows/person.yaml")
```
meerk40t-barcodes 0.2.8
MeerK40t Barcode Extension
License: MIT
Keywords: lasercutter, laser, vector, parser

# meerk40t-barcodes

MeerK40t 0.8+ Barcode extension.

## Barcode-Extension

* Registers the console command: `qrcode` which will generate a qrcode

Usage:    `qrcode x_pos y_pos dim code`

Arguments:
> x_pos          X-position of qr-code
> y_pos          Y-position of qr-code
> dim            Width/length of qr-code
> code           Text to create qr-code from

Options:
> --boxsize  (-x)      Boxsize (default 10)
> --border   (-b)      Border around qr-code (default 4)
> --version  (-v)      size (1..40)
> --errcorr  (-e)      error correction, one of L (7%), M (15%), Q (25%), H (30%)

* Registers the console command: `barcode` which will generate a barcode

Usage:    `barcode x_pos y_pos dimx dimy btype code`

Arguments:
> x_pos     X-Position of barcode
> y_pos     Y-Position of barcode
> dim       Width of barcode, may be 'auto' to keep native width
> dimy      Height of barcode, may be 'auto' to keep native height
> btype     Barcode type
> code      The code to process

 Options:
> --notext  (-n)      suppress text display

* GUI-Support
The installation of this tool will register a new button in the Design section of MeerK40t:

<img width="639" alt="image" src="https://user-images.githubusercontent.com/2670784/232893108-c2f4293c-f084-4d5b-8900-b4cbd74f0e38.png">

If you click on it then a dialog will pop up allowing you to design a qr-code / a barcode:

<img width="258" alt="image" src="https://user-images.githubusercontent.com/2670784/232893402-88694837-370a-4b34-a0b7-e9e2ac83c0bc.png">

This will create an element in Meerk40t that can be treated like any other regular path, but which will allow post-creation change of the underlying code (ie the barcode will be regenerated based on the new input).

<img width="432" alt="image" src="https://user-images.githubusercontent.com/2670784/232892296-c3cbae13-53d8-4143-9667-94cdc31cb4a5.png">

## Installation

* `pip install meerk40t-barcodes`
Or
* Download into a directory:
* `$ pip install .`

## Development

* If you are developing your own extension for meerk40t you will want to use:
* `$ pip install -e .` this installs the python module in edit mode which allows you to easily see and experience your changes. Without reinstalling your module.

## Acknowledgements

* This MeerK40t extension uses the work of two great libraries to create barcodes & QR codes:

* The python-barcode library (https://github.com/WhyNotHugo/python-barcode)
* The qrcode library (https://github.com/lincolnloop/python-qrcode)
nomad-h5grove 2.5
Core utilities to serve HDF5 file contents
License: MIT
Requires Python: >=3.8

# h5grove, core utilities to serve HDF5 file contents

**h5grove** is a Python package that provides utilities to design backends serving HDF5 file content: attributes, metadata and data. HDF5 files are accessed with [h5py](https://github.com/h5py/).

## Documentation

The documentation of the latest release is available [here](https://silx-kit.github.io/h5grove/).

## Rationale

There are several packages out there that can serve HDF5 files. However, they are dedicated to their usecases and settle on one implementation, hampering reusability.

In addition, some problems arise constantly when designing HDF5 backends. To name a few:

- Resolving external links
- Dealing with compression and slicing of datasets
- Encoding data efficiently and consistently (looking at you, `NaN`, `Infinity` in JSON)

**h5grove** aims at providing building blocks that solve these common problems and can be reused in existing or new backends.

## Installation

```bash
pip install h5grove
```

You can use **h5grove** low-level utilities whatever the backend implementation you choose. Additional utilities are provided for several Python web frameworks but require additional packages that can be installed the following way:

- [FastAPI](https://fastapi.tiangolo.com/)

```bash
pip install h5grove[fastapi]
```

- [Flask](https://flask.palletsprojects.com/en/)

```bash
pip install h5grove[flask]
```

- [Tornado](https://www.tornadoweb.org/en/stable/)

```bash
pip install h5grove[tornado]
```
ai-prompt-manager 0.1.1
A small simple prompt manager for LLM prompts
License: MIT
Requires Python: >=3.6


# Prompt Manager

A small simple prompt manager for LLM prompts.

## Usage	

```python
from ai_prompt_manager import get_prompt, render_prompt

prompt = get_prompt("my-prompt.md")
print(prompt)

prompt = render_prompt(prompt, {"name": "John"})
print(prompt)
```

## Features

- Flexible variable substitution with render_prompt()

- Include files from the prompts directory, or from a url with get_prompt()

- Combine files, e.g. roleplay-prompt.txt + output-format-prompt.js

- Handle not-quite-json output from LLMs with parse_json()

## Contributing

Contributions are welcome! Please submit a pull request or open an issue for any bugs or feature requests.

## License

This project is licensed under the MIT License.

## Contact

For questions or comments, please contact the project maintainer, Daniel Winterstein.