Spaces:
Sleeping
Sleeping
Akhilgautam30
commited on
Commit
·
9280371
1
Parent(s):
5a5ed00
fixing sync error
Browse files- .github/workflows/main.yml +4 -33
- .gitignore +0 -2
- main.py +1 -1
- weights-roberta-base.h5 +3 -0
.github/workflows/main.yml
CHANGED
@@ -5,7 +5,6 @@ on:
|
|
5 |
|
6 |
# to run this workflow manually from the Actions tab
|
7 |
workflow_dispatch:
|
8 |
-
|
9 |
jobs:
|
10 |
sync-to-hub:
|
11 |
runs-on: ubuntu-latest
|
@@ -14,35 +13,7 @@ jobs:
|
|
14 |
with:
|
15 |
fetch-depth: 0
|
16 |
lfs: true
|
17 |
-
- name:
|
18 |
-
|
19 |
-
|
20 |
-
run:
|
21 |
-
cd temp_repo
|
22 |
-
git init
|
23 |
-
git remote add origin https://akhilgautam2011%40gmail.com:${{ secrets.HF_TOKEN }}@huggingface.co/spaces/Akhilgautam30/personality_assesment
|
24 |
-
git config core.sparseCheckout true
|
25 |
-
echo "/*" > .git/info/sparse-checkout
|
26 |
-
echo "!weights-roberta-base.h5" >> .git/info/sparse-checkout
|
27 |
-
|
28 |
-
- name: Pull target repository contents except weights-base.h5
|
29 |
-
run: |
|
30 |
-
cd temp_repo
|
31 |
-
git pull origin main
|
32 |
-
|
33 |
-
- name: Copy changes from source repository to temp directory
|
34 |
-
run: |
|
35 |
-
rsync -av --exclude 'weights-roberta-base.h5' . temp_repo/
|
36 |
-
|
37 |
-
- name: Set Git user email and name
|
38 |
-
run: |
|
39 |
-
cd temp_repo
|
40 |
-
git config user.email "[email protected]"
|
41 |
-
git config user.name "Akhil Gautam"
|
42 |
-
|
43 |
-
- name: Commit and force push to target repository
|
44 |
-
run: |
|
45 |
-
cd temp_repo
|
46 |
-
git add .
|
47 |
-
git commit -m "Sync changes from source repository"
|
48 |
-
git push --force https://akhilgautam2011%40gmail.com:${{ secrets.HF_TOKEN }}@huggingface.co/spaces/Akhilgautam30/personality_assesment main
|
|
|
5 |
|
6 |
# to run this workflow manually from the Actions tab
|
7 |
workflow_dispatch:
|
|
|
8 |
jobs:
|
9 |
sync-to-hub:
|
10 |
runs-on: ubuntu-latest
|
|
|
13 |
with:
|
14 |
fetch-depth: 0
|
15 |
lfs: true
|
16 |
+
- name: Push to hub
|
17 |
+
env:
|
18 |
+
HF_TOKEN: ${{ secrets.HF_TOKEN }}
|
19 |
+
run: https://akhilgautam2011%40gmail.com:${{ secrets.HF_TOKEN }}@huggingface.co/spaces/Akhilgautam30/personality_assesment main
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
.gitignore
DELETED
@@ -1,2 +0,0 @@
|
|
1 |
-
# Ignore the weights-base.h5 file at the root level
|
2 |
-
/weights-roberta-base.h5
|
|
|
|
|
|
main.py
CHANGED
@@ -16,7 +16,7 @@ async def root():
|
|
16 |
@app.get("/predict")
|
17 |
async def predict_personality_get(text: str):
|
18 |
try:
|
19 |
-
print("
|
20 |
predictions = predict_personality(text)
|
21 |
return {"predictions": predictions}
|
22 |
except NameError:
|
|
|
16 |
@app.get("/predict")
|
17 |
async def predict_personality_get(text: str):
|
18 |
try:
|
19 |
+
print("--------------------------")
|
20 |
predictions = predict_personality(text)
|
21 |
return {"predictions": predictions}
|
22 |
except NameError:
|
weights-roberta-base.h5
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:692fd74f77f1db85f3e22987a68fb57109cd36c684f4b9b9f447fb4abb3c917d
|
3 |
+
size 498887488
|