Spaces:
Runtime error
Runtime error
Commit
ยท
2079b17
1
Parent(s):
1134ee9
add example on magpie pre-query enforcement
Browse files
examples/enforce_mapgie_template copy.py
ADDED
|
@@ -0,0 +1,10 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# pip install synthetic-dataset-generator
|
| 2 |
+
import os
|
| 3 |
+
|
| 4 |
+
from synthetic_dataset_generator.app import demo
|
| 5 |
+
|
| 6 |
+
# Follow https://docs.argilla.io/latest/getting_started/quickstart/ to get your Argilla API key and URL
|
| 7 |
+
os.environ["ARGILLA_API_URL"] = "https://[your-owner-name]-[your_space_name].hf.space"
|
| 8 |
+
os.environ["ARGILLA_API_KEY"] = "my_api_key"
|
| 9 |
+
|
| 10 |
+
demo.launch()
|