Metadata-Version: 2.4
Name: Ins-Pricing
Version: 0.1.2
Summary: Reusable modelling, pricing, governance, and reporting utilities.
Author: meishi125478
License: Proprietary
Keywords: pricing,insurance,bayesopt,ml
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3 :: Only
Classifier: Programming Language :: Python :: 3.9
Classifier: License :: Other/Proprietary License
Classifier: Operating System :: OS Independent
Classifier: Intended Audience :: Developers
Requires-Python: >=3.9
Description-Content-Type: text/markdown
Requires-Dist: numpy>=1.20
Requires-Dist: pandas>=1.4
Provides-Extra: ml
Requires-Dist: torch>=1.13; extra == "ml"
Requires-Dist: optuna>=3.0; extra == "ml"
Requires-Dist: xgboost>=1.6; extra == "ml"
Requires-Dist: scikit-learn>=1.1; extra == "ml"
Requires-Dist: statsmodels>=0.13; extra == "ml"
Requires-Dist: joblib>=1.2; extra == "ml"
Provides-Extra: plot
Requires-Dist: matplotlib>=3.5; extra == "plot"
Provides-Extra: explain
Requires-Dist: shap>=0.41; extra == "explain"
Provides-Extra: geo
Requires-Dist: contextily>=1.3; extra == "geo"
Provides-Extra: gnn
Requires-Dist: pynndescent>=0.5; extra == "gnn"
Requires-Dist: torch-geometric>=2.3; extra == "gnn"
Provides-Extra: all
Requires-Dist: torch>=1.13; extra == "all"
Requires-Dist: optuna>=3.0; extra == "all"
Requires-Dist: xgboost>=1.6; extra == "all"
Requires-Dist: scikit-learn>=1.1; extra == "all"
Requires-Dist: statsmodels>=0.13; extra == "all"
Requires-Dist: joblib>=1.2; extra == "all"
Requires-Dist: matplotlib>=3.5; extra == "all"
Requires-Dist: shap>=0.41; extra == "all"
Requires-Dist: contextily>=1.3; extra == "all"
Requires-Dist: pynndescent>=0.5; extra == "all"
Requires-Dist: torch-geometric>=2.3; extra == "all"

# Ins-Pricing Overview

This repository contains risk modeling and optimization notebooks, scripts, and a reusable training framework. The main module is `ins_pricing/modelling/bayesopt`.

## Top-level structure

- `Auto Info/`: vehicle info crawling, preprocessing, and embedding experiments
- `GLM and LGB/`: GLM/LightGBM modeling experiments
- `OpenAI/`: OpenAI notebook prototypes
- `Python Code/`: runnable scripts and utilities
- `others/`: temporary or miscellaneous notebooks
- `ins_pricing/`: reusable training framework and CLI tools (BayesOpt subpackage)
- `user_packages legacy/`: historical snapshot

Note: `ins_pricing/modelling/demo/` is kept in the repo only and is not shipped in the PyPI package.

## Quickstart

Run the following commands from the repo root:

```bash
python -m venv .venv
source .venv/bin/activate  # Windows: .\\.venv\\Scripts\\activate
pip install pandas scikit-learn lightgbm seaborn matplotlib
```

Start notebooks:

```bash
jupyter lab
```

## BayesOpt entry points

- CLI batch training: `python ins_pricing/modelling/BayesOpt_entry.py --config-json <path>`
- Incremental training: `python ins_pricing/modelling/BayesOpt_incremental.py --config-json <path>`
- Python API: `from ins_pricing.modelling import BayesOptModel`

## Tests

```bash
pytest -q
```

## Data and outputs

- Put shared data under `data/` (create it if needed).
- Training outputs are written to `plot/`, `Results/`, and `model/` by default.
- Keep secrets and large files outside the repo and use environment variables or `.env`.
