rhoitjadhav commited on
Commit
d5caedb
·
1 Parent(s): 6159a0f

update dockerfile

Browse files
Files changed (2) hide show
  1. load_data.py +4 -2
  2. start.sh +1 -1
load_data.py CHANGED
@@ -1,3 +1,5 @@
 
 
1
  import requests
2
  import time
3
  import pandas as pd
@@ -9,8 +11,8 @@ from argilla.labeling.text_classification import Rule, add_rules
9
  def load_datasets():
10
  # This is the code that you want to execute when the endpoint is available
11
  print("Argilla is available! Loading datasets")
12
-
13
- rg.init(api_key="UPLOAD_API_KEY", workspace="huggingface")
14
 
15
  # load dataset from json
16
  my_dataframe = pd.read_json(
 
1
+ import os
2
+
3
  import requests
4
  import time
5
  import pandas as pd
 
11
  def load_datasets():
12
  # This is the code that you want to execute when the endpoint is available
13
  print("Argilla is available! Loading datasets")
14
+ api_key = os.getenv("API_KEY" )
15
+ rg.init(api_key=api_key, workspace="admin")
16
 
17
  # load dataset from json
18
  my_dataframe = pd.read_json(
start.sh CHANGED
@@ -26,7 +26,7 @@ sudo systemctl daemon-reload
26
  echo "enable"
27
  sudo systemctl enable elasticsearch
28
  echo "start"
29
- sudo systemctl start elasticsearch
30
 
31
  # Load data
32
  echo "Loading data"
 
26
  echo "enable"
27
  sudo systemctl enable elasticsearch
28
  echo "start"
29
+ #sudo systemctl start elasticsearch
30
 
31
  # Load data
32
  echo "Loading data"