Metadata-Version: 2.4
Name: belso
Version: 0.0.4
Summary: Better LLMs Structured Outputs
Home-page: https://github.com/MikiTwenty/belso
Author: Michele Ventimiglia
Author-email: michele.ventimiglia01@gmail.com
License: MIT
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python
Requires-Python: >=3.10
Description-Content-Type: text/markdown
License-File: LICENSE
License-File: AUTHORS
Requires-Dist: beartype
Requires-Dist: colorama
Requires-Dist: google-generativeai>=0.8.5
Requires-Dist: google.ai.generativelanguage>=0.6.15
Requires-Dist: pydantic
Requires-Dist: pytest
Requires-Dist: pyyaml
Requires-Dist: rich
Dynamic: author
Dynamic: author-email
Dynamic: classifier
Dynamic: description
Dynamic: description-content-type
Dynamic: home-page
Dynamic: license
Dynamic: license-file
Dynamic: requires-dist
Dynamic: requires-python
Dynamic: summary

# belso – Better LLMs Structured Outputs

[![Documentation](https://img.shields.io/badge/docs-GitHub%20Pages-blue)](https://MikiTwenty.github.io/belso/)
[![PyPI version](https://badge.fury.io/py/belso.svg)](https://badge.fury.io/py/belso)
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)

> **belso** is a developer-friendly Python toolkit for **defining, validating, and translating structured data** in Large Language Models (LLMs).
> Compatible with major providers. Designed for simplicity, power, and extensibility.

---

## 🚀 Overview

**belso (Better LLMs Structured Outputs)** streamlines how developers work with structured outputs from LLMs.
It offers a consistent API for schema definition, validation, and translation—helping you bridge the gap between **human language and structured data**, regardless of provider.

---

## 🔑 Key Features

- ✅ **Unified Schema Interface** – define once, use everywhere via Python dataclasses or Pydantic models
- 🔀 **Multi-Provider Compatibility** – seamless I/O with:
  - OpenAI
  - Anthropic
  - Google AI
  - Mistral AI
  - Hugging Face
  - Ollama
  - LangChain
- 🔁 **Bi-directional Format Translation** – convert schemas across LLM formats with a single call
- 🧱 **Supports Nesting & Arrays** – works with deeply nested fields and typed collections
- 🧪 **Validation & Inspection** – ensure schema integrity with built-in tools
- 📦 **Serialization** – import/export schemas via JSON, YAML, and XML
- ⚡ **Lightweight & Fast** – minimal dependencies, optimal for production use

---

## 📦 Installation

```bash
pip install belso
```

---

## 🧪 Quick Start

Explore the [examples](examples/) directory to see how belso can help you structure LLM outputs with ease.

---

## 📚 Documentation

Full documentation is available on the [official site](https://MikiTwenty.github.io/belso/).
Includes guides, API reference, and advanced usage examples.

---

## 📄 License

This project is distributed under the terms of the [MIT License](LICENSE).

---

## ☕ Support My Work

If you find belso useful, consider supporting the project:

[![Buy me a coffee](https://img.shields.io/badge/Buy_Me_A_Coffee-FFDD00?style=for-the-badge&logo=buy-me-a-coffee&logoColor=black)](https://www.buymeacoffee.com/mikitwenty)
