Upload folder using huggingface_hub
Browse files- docs/quickstart.md +15 -20
docs/quickstart.md
CHANGED
|
@@ -28,35 +28,30 @@ It is designed for **public review** and **post-match verification**:
|
|
| 28 |
|
| 29 |
## 1-minute schema validation (Python)
|
| 30 |
|
| 31 |
-
|
| 32 |
-
|
| 33 |
```bash
|
| 34 |
python -m pip install jsonschema
|
| 35 |
-
python
|
| 36 |
-
|
| 37 |
-
|
| 38 |
-
|
| 39 |
-
|
| 40 |
-
|
| 41 |
-
|
| 42 |
-
|
| 43 |
-
# 2) Load sample log
|
| 44 |
-
with open("examples/sample_signal_log.json", "r", encoding="utf-8") as f:
|
| 45 |
-
data = json.load(f)
|
| 46 |
-
|
| 47 |
-
# 3) Validate
|
| 48 |
-
validate(instance=data, schema=schema)
|
| 49 |
-
print("OK: sample log matches schema")
|
| 50 |
-
PY
|
| 51 |
```
|
|
|
|
|
|
|
|
|
|
| 52 |
If validation fails, the JSON does not match required fields/types in the schema.
|
| 53 |
Update your log or adjust the schema accordingly.
|
| 54 |
|
| 55 |
-
(Windows
|
|
|
|
| 56 |
|
| 57 |
**Next:**
|
| 58 |
|
| 59 |
- Quickstart: [docs/quickstart.md](docs/quickstart.md)
|
| 60 |
- Examples: [examples/README.md](../examples/README.md)
|
| 61 |
- Sample log: [examples/sample_signal_log.json](../examples/sample_signal_log.json)
|
| 62 |
-
- Schema: [datasets/signal-log.schema.json](../datasets/signal-log.schema.json)
|
|
|
|
| 28 |
|
| 29 |
## 1-minute schema validation (Python)
|
| 30 |
|
| 31 |
+
### Local validation (cross-platform)
|
| 32 |
+
Python:
|
| 33 |
```bash
|
| 34 |
python -m pip install jsonschema
|
| 35 |
+
python scripts/validate.py
|
| 36 |
+
```
|
| 37 |
+
|
| 38 |
+
macOS/Linux (optional):
|
| 39 |
+
```
|
| 40 |
+
make install
|
| 41 |
+
make validate
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 42 |
```
|
| 43 |
+
|
| 44 |
+
|
| 45 |
+
|
| 46 |
If validation fails, the JSON does not match required fields/types in the schema.
|
| 47 |
Update your log or adjust the schema accordingly.
|
| 48 |
|
| 49 |
+
(Windows: run the Python commands above. `make` is optional and typically macOS/Linux.)
|
| 50 |
+
|
| 51 |
|
| 52 |
**Next:**
|
| 53 |
|
| 54 |
- Quickstart: [docs/quickstart.md](docs/quickstart.md)
|
| 55 |
- Examples: [examples/README.md](../examples/README.md)
|
| 56 |
- Sample log: [examples/sample_signal_log.json](../examples/sample_signal_log.json)
|
| 57 |
+
- Schema: [datasets/schema/signal-log.schema.json](../datasets/schema/signal-log.schema.json)
|