Spaces:
Running
Running
Update README.md
Browse files
README.md
CHANGED
@@ -1,12 +1,35 @@
|
|
1 |
---
|
2 |
-
title:
|
3 |
-
emoji:
|
4 |
-
colorFrom:
|
5 |
-
colorTo:
|
6 |
sdk: docker
|
7 |
app_port: 7860
|
8 |
-
pinned: false
|
9 |
-
license: mit
|
10 |
---
|
11 |
|
12 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
---
|
2 |
+
title: NeuroBERT-Tiny API
|
3 |
+
emoji: 🤖
|
4 |
+
colorFrom: blue
|
5 |
+
colorTo: green
|
6 |
sdk: docker
|
7 |
app_port: 7860
|
|
|
|
|
8 |
---
|
9 |
|
10 |
+
# NeuroBERT-Tiny Masked Language Model API
|
11 |
+
|
12 |
+
This Space hosts a FastAPI application that performs Masked Language Modeling using the [boltuix/NeuroBERT-Tiny](https://huggingface.co/boltuix/NeuroBERT-Tiny) model.
|
13 |
+
|
14 |
+
## Endpoints:
|
15 |
+
|
16 |
+
* **Health Check (GET /health):**
|
17 |
+
Returns a simple message to confirm the API is running.
|
18 |
+
Example: `curl https://brendon-ai-faq.hf.space/health`
|
19 |
+
|
20 |
+
* **Predict (POST /):**
|
21 |
+
Accepts a JSON payload with a `text` field containing a sentence with `[MASK]` tokens.
|
22 |
+
Returns a list of top 5 predictions for each masked position.
|
23 |
+
|
24 |
+
Example `curl` request:
|
25 |
+
```bash
|
26 |
+
curl -X POST \
|
27 |
+
-H "Content-Type: application/json" \
|
28 |
+
-d '{"text": "The quick brown fox jumps over the [MASK] dog."}' \
|
29 |
+
[https://brendon-ai-faq.hf.space/](https://brendon-ai-faq.hf.space/)
|
30 |
+
```
|
31 |
+
|
32 |
+
## Interactive API Documentation:
|
33 |
+
You can find the full interactive API documentation at:
|
34 |
+
* [Swagger UI](https://brendon-ai-faq.hf.space/docs)
|
35 |
+
* [ReDoc](https://brendon-ai-faq.hf.space/redoc)
|