Metadata-Version: 2.4
Name: pyquantity
Version: 0.1.15
Summary: A modern Python package for quantity calculations
Home-page: https://github.com/odysseu/pyquantity
Author: Odysseu
Author-email: Odysseu <uboucherie1@gmail.com>
License: MIT
Project-URL: Homepage, https://github.com/odysseu/pyquantity
Project-URL: Documentation, https://github.com/odysseu/pyquantity#readme
Project-URL: Repository, https://github.com/odysseu/pyquantity.git
Project-URL: Issues, https://github.com/odysseu/pyquantity/issues
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Programming Language :: Python :: 3.14
Requires-Python: >=3.10
Description-Content-Type: text/markdown
License-File: LICENSE
Provides-Extra: dev
Requires-Dist: black>=26.1.0; extra == "dev"
Requires-Dist: isort>=7.0.0; extra == "dev"
Requires-Dist: mypy>=1.19.1; extra == "dev"
Requires-Dist: pytest>=9.0.2; extra == "dev"
Requires-Dist: pytest-cov>=7.0.0; extra == "dev"
Requires-Dist: ruff>=0.15.1; extra == "dev"
Requires-Dist: build>=1.4.0; extra == "dev"
Requires-Dist: sphinx>=7.2.6; extra == "dev"
Requires-Dist: furo>=2025.12.19; extra == "dev"
Requires-Dist: myst-parser>=5.0.0; extra == "dev"
Dynamic: author
Dynamic: home-page
Dynamic: license-file
Dynamic: requires-python

# PyQuantity

[![CI](https://github.com/odysseu/pyquantity/actions/workflows/ci.yml/badge.svg)](https://github.com/odysseu/pyquantity/actions/workflows/ci.yml)
![Python 3.10](https://img.shields.io/badge/python-3.10-blue.svg)
![Python 3.11](https://img.shields.io/badge/python-3.11-blue.svg)
![Python 3.12](https://img.shields.io/badge/python-3.12-blue.svg)
![Python 3.13](https://img.shields.io/badge/python-3.13-blue.svg)
![Python 3.14](https://img.shields.io/badge/python-3.14-blue.svg)
![License](https://img.shields.io/badge/license-MIT-green)
[![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)

A Python package for quantity calculations with unit support and dimensional analysis.

**Test Coverage**: ![Coverage](coverage_badge.svg)

## Features

- Comprehensive unit systems with 60+ base dimensions
- 1000+ derived units including mechanical, electrical, and thermal units
- Full SI prefix support from yocto to yotta
- Contextual measurements with built-in database
- Natural language parsing for quantity extraction
- Advanced physics calculations
- Type hints and comprehensive documentation

## Installation

```bash
pip install pyquantity
```

**Requirements:**
- Python 3.10 or higher (following [Python's version support policy, mostly](https://devguide.python.org/versions/))

**For Developers:**
```bash
pip install -e ".[dev]"
python test_with_coverage.py
```

## Quick Start

```python
from pyquantity import Quantity, get_measurement, parse_quantity

# Basic quantity operations
length = Quantity(5.0, "meter")
width = Quantity(3.0, "meter")
area = length * width

# Unit conversion
distance = Quantity(1.5, "kilometer")
distance_m = distance.convert("meter")

# Contextual measurements
bath = get_measurement("normal bath")
cup = get_measurement("cup")
cups_in_bath = bath / cup

# Natural language parsing
text = "A car traveling at 120 km/h for 2.5 hours"
quantities = parse_quantity(text)
```

## Documentation

- [Usage Guide](docs/usage_guide.md)
- [Advanced Features](docs/advanced_features.md)
- [API Reference](docs/api_reference.md)
- [Examples](example_usage.py)

## License

MIT License - See [LICENSE](LICENSE) for details.

## Contributing

Contributions are welcome!
