File size: 819 Bytes
21c7db9
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
# API

FastAPI endpoints cover environment lifecycle, orchestration, policy inference, evaluation, training metrics, case retrieval, and evidence queries.

## Product Inference

- `POST /policy/infer` selects one legal candidate using the active Transformers model when available, with deterministic safety-ranker fallback.
- `GET /policy/model_status` reports active-model configuration and load status.

The active model is controlled by `checkpoints/active/active_model_manifest.json`, generated by `scripts/activate_sweep_model.py`. The default production path prefers the GRPO adapter for `qwen-qwen2-5-0-5b-instruct`, then falls back to the merged Qwen 0.5B artifact or SFT adapter if required.

Example:

```bash
curl http://127.0.0.1:8200/policy/model_status
curl -X POST http://127.0.0.1:8200/policy/infer
```