File size: 3,051 Bytes
9c0d2fa
 
4f87d5a
 
 
9c0d2fa
 
 
 
 
4f87d5a
 
5582456
 
 
4f87d5a
 
 
5582456
 
 
 
 
 
 
 
 
4f87d5a
 
5582456
 
 
 
 
 
 
 
4f87d5a
 
 
 
 
 
5582456
 
 
 
 
 
bc06d10
 
5582456
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
bc06d10
5582456
 
bc06d10
5582456
 
 
 
 
bc06d10
5582456
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
bc06d10
5582456
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
---
title: ARF Sandbox API
emoji: 🧪
colorFrom: blue
colorTo: indigo
sdk: docker
pinned: false
license: apache-2.0
---

# ARF Sandbox API – Mock Endpoint

🧪 **This is a fully simulated, mock API.**  
It does **not** use the protected Bayesian engine.  
No real data is processed – all responses are deterministic examples.

Use this endpoint to test integrations and see the expected request/response format.

---

## ⚡ Rate Limit

To ensure fair usage, the API enforces a limit of **10 requests per minute per IP address**.  
If you exceed this, you will receive a `429 Too Many Requests` response.

---

## 🔗 Endpoints

| Method | Endpoint | Description |
|--------|----------|-------------|
| `GET`  | `/health` | Health check – returns `{"status":"ok","timestamp":...}` |
| `POST` | `/v1/evaluate` | Simulate an incident evaluation (see request/response below) |
| `GET`  | `/docs` | Interactive Swagger UI (OpenAPI documentation) |
| `GET`  | `/redoc` | ReDoc alternative documentation |

---

## 📦 Example Request

```bash
curl -X POST https://A-R-F-ARF-Sandbox-API.hf.space/v1/evaluate \
  -H "Content-Type: application/json" \
  -d '{
    "service_name": "api",
    "event_type": "latency",
    "severity": "high",
    "metrics": {"latency_ms": 450}
  }'
```

### Response Model

| Field | Type | Description |
|-------|------|-------------|
| `status` | string | Always `"success"` for a valid request |
| `recommendation` | string | `"APPROVE"`, `"DENY"`, or `"ESCALATE"` |
| `risk_score` | float | Mock risk score between 0.0 and 1.0 (higher = more risk) |
| `confidence` | float | Mock confidence (0.0 – 1.0) |
| `justification` | string | Human‑readable explanation (always indicates mock) |
| `policy_violations` | list | Empty list (no real policy evaluation in sandbox) |

> 💡 **Note:** All responses are deterministic for the same input (except for the tiny pseudo‑random jitter). This makes integration tests predictable.

---

## 🔒 Real Engine

The actual ARF core engine is **access‑controlled** and available under outcome‑based pricing.  
👉 [Request pilot access](https://www.arf-ai.com/signup)

Pilot customers get:
- Real Bayesian risk fusion (online + offline HMC)
- Deterministic enforcement gates
- Complete audit trail and signed intents
- Outcome‑based pricing – pay for *verified risk reduction*

---

## 🧪 Try it Live

You can test the API interactively using the built‑in Swagger UI:  
**`/docs`** endpoint of this Space – or click the “App” tab above.

---

## 📚 See Also

- [ARF Official Specification](https://github.com/arf-foundation/arf-spec)
- [Public Demo UI](https://www.arf-ai.com)
- [Interactive Risk Dashboard](https://huggingface.co/spaces/A-R-F/Agentic-Reliability-Framework-v4)

---

## 🛟 Support

For questions about the sandbox or pilot access, please use the contact form on the [ARF website](https://www.arf-ai.com/contact).

---

*© ARF Foundation – Sandbox API is Apache 2.0. The real ARF engine is proprietary and access‑controlled.*