Skip to content

Commit

Permalink
feat: using space secret
Browse files Browse the repository at this point in the history
  • Loading branch information
vancauwe committed Dec 21, 2024
1 parent 3b7d130 commit 8c2fa3e
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,9 @@ def push_observation(tab_log:DeltaGenerator=None):
tab_log.info(f"Uploading observation: {metadata_str}")

# get huggingface api
api = HfApi()
import os
token = os.getenv("HF_TOKEN")
api = HfApi(token=token)

f = tempfile.NamedTemporaryFile(mode="w", suffix=".json", delete=False)
f.write(metadata_str)
Expand Down

0 comments on commit 8c2fa3e

Please sign in to comment.