Metadata-Version: 2.3
Name: deepbridge
Version: 0.1.2
Summary: 
Author: Team DeepBridge
Author-email: gustavo.haase@gmail.com
Requires-Python: >=3.12,<4.0
Classifier: Development Status :: 5 - Production/Stable
Classifier: Environment :: Console
Classifier: Natural Language :: Portuguese (Brazilian)
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
Requires-Dist: ipython (>=8.32.0,<9.0.0)
Requires-Dist: joblib (>=1.4.2,<2.0.0)
Requires-Dist: matplotlib (>=3.10.0,<4.0.0)
Requires-Dist: numpy (>=2.2.3,<3.0.0)
Requires-Dist: optuna (>=4.2.1,<5.0.0)
Requires-Dist: pandas (>=2.2.3,<3.0.0)
Requires-Dist: rich (>=13.9.4,<14.0.0)
Requires-Dist: scikit-learn (>=1.6.1,<2.0.0)
Requires-Dist: scipy (>=1.15.1,<2.0.0)
Requires-Dist: tabulate (>=0.9.0,<0.10.0)
Requires-Dist: typer[all] (>=0.15.1,<0.16.0)
Requires-Dist: xgboost (>=2.1.4,<3.0.0)
Project-URL: Código, https://github.com/DeepBridge-Validation/DeepBridge
Project-URL: Documentação, https://deepbridge.readthedocs.io/en/latest/
Description-Content-Type: text/markdown

# DeepBridge

[![Documentation Status](https://readthedocs.org/projects/deepbridge/badge/?version=latest)](https://deepbridge.readthedocs.io/en/latest/)
[![CI](https://github.com/DeepBridge-Validation/DeepBridge/actions/workflows/pipeline.yaml/badge.svg)](https://github.com/DeepBridge-Validation/DeepBridge/actions/workflows/pipeline.yaml)
[![PyPI version](https://badge.fury.io/py/deepbridge.svg)](https://badge.fury.io/py/deepbridge)

DeepBridge is a Python library for streamlining machine learning model validation and distillation processes. It provides tools to manage experiments, validate models, and create more efficient versions of complex models.

## Installation

You can install DeepBridge using pip:

```bash
pip install deepbridge
```

Or install from source:

```bash
git clone https://github.com/DeepBridge-Validation/DeepBridge.git
cd deepbridge
pip install -e .
```

## Quick Start

### Model Validation
```python
from deepbridge.model_validation import ModelValidation

# Create experiment
experiment = ModelValidation("my_experiment")

# Add data
experiment.add_data(X_train, y_train, X_test, y_test)

# Add and save model
experiment.add_model(model, "model_v1")
experiment.save_model("model_v1")
```

### Model Distillation
```python
from deepbridge.model_distiller import ModelDistiller

# Create and train distilled model
distiller = ModelDistiller(model_type="gbm")
distiller.fit(X=features, probas=predictions)

# Make predictions
predictions = distiller.predict(X_new)
```

### Using the CLI
```bash
# Create experiment
deepbridge validation create my_experiment --path ./experiments

# Train distilled model
deepbridge distill train gbm predictions.csv features.csv -s ./models
```

## Features

- **Model Validation**
  - Experiment management
  - Metric tracking
  - Model versioning
  - Surrogate model support

- **Model Distillation**
  - Multiple model types (GBM, XGBoost, MLP)
  - Performance metrics
  - Optimization options
  - Easy model persistence

- **Command Line Interface**
  - Intuitive commands
  - Rich output formatting
  - Multiple data format support

## Requirements

- Python 3.8+
- Dependencies:
  ```
  numpy>=1.24.0
  pandas>=2.0.0
  scikit-learn>=1.2.0
  xgboost>=1.7.0
  scipy>=1.10.0
  typer[all]>=0.9.0
  rich>=13.0.0
  ```

## Documentation

For detailed documentation, visit [our documentation page](https://deepbridge.readthedocs.io/).

### Example Notebooks

Check out our [example notebooks](examples/) for detailed usage scenarios:
- Basic Model Validation
- Model Distillation Techniques
- CLI Usage Examples

## Contributing

We welcome contributions! Here's how you can help:

1. Fork the repository
2. Create your feature branch (`git checkout -b feature/AmazingFeature`)
3. Commit your changes (`git commit -m 'Add some AmazingFeature'`)
4. Push to the branch (`git push origin feature/AmazingFeature`)
5. Open a Pull Request

## Development Setup

```bash
# Clone the repository
git clone https://github.com/DeepBridge-Validation/DeepBridge.git
cd deepbridge

# Create virtual environment
python -m venv venv
source venv/bin/activate  # Linux/Mac
# or
venv\Scripts\activate     # Windows

# Install development dependencies
pip install -r requirements-dev.txt
```

## Running Tests

```bash
pytest tests/
```

## License

This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.

## Citation

If you use DeepBridge in your research, please cite:

```bibtex
@software{deepbridge2024,
  title = {DeepBridge: A Python Library for Model Validation and Distillation},
  author = {Team DeepBridge},
  year = {2025},
  url = {https://github.com/DeepBridge-Validation/DeepBridge}
}
```

## Acknowledgments

- Thanks to all contributors
- Inspired by best practices in model optimization
- Built with modern Python tools and libraries

## Contact

- GitHub Issues: For bugs and feature requests
- Email: gustavo.haase@gmail.com
<!-- - Twitter: [@YourHandle](https://twitter.com/YourHandle) -->
