Metadata-Version: 2.4
Name: crab-predict
Version: 1.0.0
Summary: 河蟹甘露运输存活时间预测工具
Author: 张昊
License: MIT
Requires-Python: >=3.9
Description-Content-Type: text/markdown
Requires-Dist: numpy>=1.24.0
Requires-Dist: pandas>=2.0.0
Requires-Dist: scikit-learn>=1.3.0
Requires-Dist: catboost>=1.2.0
Requires-Dist: joblib>=1.3.0
Requires-Dist: cryptography>=41.0.0

# 🦀 crab-predict

河蟹甘露运输存活时间预测工具。基于 450 组实验数据训练的 Stacking 集成学习模型。

## 安装

```bash
pip install crab-predict
```

## 使用

### 交互模式
```bash
crab-predict
```

### 命令行模式
```bash
# 基本用法
crab-predict -t 16 -H 90 -w 10 -f 58 -l 4.5

# JSON 输出（方便程序调用）
crab-predict -t 18 -H 80 --json
```

### Python 调用
```python
from crab_predict.core import predict

hours = predict(temp=16, humidity=90, weight=10, gender=1, fatness=58, loss_rate=4.5)
print(f"预计存活: {hours:.1f} 小时")
```

## 参数说明

| 参数 | 说明 | 范围 |
|------|------|------|
| -t | 运输温度 (°C) | 15-20 |
| -H | 环境湿度 (%) | 50-100 |
| -w | 体重 (g) | 1-15 |
| -g | 性别 (1=公, 2=母) | 1/2 |
| -f | 肥满度 (F指数) | 40-70 |
| -l | 12h体质量消耗率 (%) | 0-20 |
