Commit
·
5b97bd5
1
Parent(s):
1edfb59
(wip)modify repos
Browse files- .github/workflows/sync-to-hf.yaml +2 -2
- app.py +4 -4
.github/workflows/sync-to-hf.yaml
CHANGED
@@ -23,8 +23,8 @@ jobs:
|
|
23 |
HF_TOKEN: ${{ secrets.HF_TOKEN }}
|
24 |
run: |
|
25 |
# Replace these with your HF username and space name
|
26 |
-
HF_USERNAME="
|
27 |
-
SPACE_NAME="
|
28 |
|
29 |
# Clone the HF space repo
|
30 |
git clone https://$HF_USERNAME:$HF_TOKEN@huggingface.co/spaces/$HF_USERNAME/$SPACE_NAME hf-space
|
|
|
23 |
HF_TOKEN: ${{ secrets.HF_TOKEN }}
|
24 |
run: |
|
25 |
# Replace these with your HF username and space name
|
26 |
+
HF_USERNAME="kemuriririn"
|
27 |
+
SPACE_NAME="Voice Clone Arena"
|
28 |
|
29 |
# Clone the HF space repo
|
30 |
git clone https://$HF_USERNAME:$HF_TOKEN@huggingface.co/spaces/$HF_USERNAME/$SPACE_NAME hf-space
|
app.py
CHANGED
@@ -21,7 +21,7 @@ if os.getenv("SPACE_REPO_NAME"):
|
|
21 |
try:
|
22 |
print("Database not found, downloading from HF dataset...")
|
23 |
hf_hub_download(
|
24 |
-
repo_id="
|
25 |
filename="tts_arena.db",
|
26 |
repo_type="dataset",
|
27 |
local_dir="instance",
|
@@ -1111,8 +1111,8 @@ def setup_periodic_tasks():
|
|
1111 |
return
|
1112 |
|
1113 |
db_path = app.config["SQLALCHEMY_DATABASE_URI"].replace("sqlite:///", "instance/") # Get relative path
|
1114 |
-
preferences_repo_id = "
|
1115 |
-
database_repo_id = "
|
1116 |
votes_dir = "./votes"
|
1117 |
|
1118 |
def sync_database():
|
@@ -1404,7 +1404,7 @@ if __name__ == "__main__":
|
|
1404 |
try:
|
1405 |
print("Database not found, downloading from HF dataset...")
|
1406 |
hf_hub_download(
|
1407 |
-
repo_id="
|
1408 |
filename="tts_arena.db",
|
1409 |
repo_type="dataset",
|
1410 |
local_dir="instance", # download to instance/
|
|
|
21 |
try:
|
22 |
print("Database not found, downloading from HF dataset...")
|
23 |
hf_hub_download(
|
24 |
+
repo_id="kemuriririn/database-arena",
|
25 |
filename="tts_arena.db",
|
26 |
repo_type="dataset",
|
27 |
local_dir="instance",
|
|
|
1111 |
return
|
1112 |
|
1113 |
db_path = app.config["SQLALCHEMY_DATABASE_URI"].replace("sqlite:///", "instance/") # Get relative path
|
1114 |
+
preferences_repo_id = "kemuriririn/arena-preferences"
|
1115 |
+
database_repo_id = "kemuriririn/database-arena-v2"
|
1116 |
votes_dir = "./votes"
|
1117 |
|
1118 |
def sync_database():
|
|
|
1404 |
try:
|
1405 |
print("Database not found, downloading from HF dataset...")
|
1406 |
hf_hub_download(
|
1407 |
+
repo_id="kemuriririn/database-arena",
|
1408 |
filename="tts_arena.db",
|
1409 |
repo_type="dataset",
|
1410 |
local_dir="instance", # download to instance/
|