Files changed (4) hide show
  1. .gitignore +1 -0
  2. main.py +9 -0
  3. requirements.txt +34 -0
  4. setup.md +13 -1
.gitignore ADDED
@@ -0,0 +1 @@
 
 
1
+ venv
main.py ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
 
1
+ # hello_world.py
2
+ from transformers import pipeline
3
+
4
+ # Load a pre-trained sentiment-analysis pipeline
5
+ classifier = pipeline("sentiment-analysis")
6
+
7
+ # Test the classifier
8
+ result = classifier("I love Hugging Face!")
9
+ print(result)
requirements.txt ADDED
@@ -0,0 +1,34 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ aiohappyeyeballs==2.4.3
2
+ aiohttp==3.10.9
3
+ aiosignal==1.3.1
4
+ attrs==24.2.0
5
+ certifi==2024.8.30
6
+ charset-normalizer==3.3.2
7
+ datasets==3.0.1
8
+ dill==0.3.8
9
+ filelock==3.16.1
10
+ frozenlist==1.4.1
11
+ fsspec==2024.6.1
12
+ huggingface-hub==0.25.1
13
+ idna==3.10
14
+ multidict==6.1.0
15
+ multiprocess==0.70.16
16
+ numpy==2.1.2
17
+ packaging==24.1
18
+ pandas==2.2.3
19
+ pyarrow==17.0.0
20
+ python-dateutil==2.9.0.post0
21
+ pytz==2024.2
22
+ PyYAML==6.0.2
23
+ regex==2024.9.11
24
+ requests==2.32.3
25
+ safetensors==0.4.5
26
+ six==1.16.0
27
+ tokenizers==0.20.0
28
+ tqdm==4.66.5
29
+ transformers==4.45.1
30
+ typing_extensions==4.12.2
31
+ tzdata==2024.2
32
+ urllib3==2.2.3
33
+ xxhash==3.5.0
34
+ yarl==1.13.1
setup.md CHANGED
@@ -37,4 +37,16 @@ $: git remote set-url origin https://<user_name>:<token>@huggingface.co/<repo_pa
37
  ### Token Creation
38
 
39
  > Go to Settings > Access Tokens > Create new token >
40
- Choose Write Tab (3rd one) / go here https://huggingface.co/settings/tokens/new?tokenType=write
 
 
 
 
 
 
 
 
 
 
 
 
 
37
  ### Token Creation
38
 
39
  > Go to Settings > Access Tokens > Create new token >
40
+ Choose Write Tab (3rd one) / go here https://huggingface.co/settings/tokens/new?tokenType=write
41
+
42
+
43
+ ## Create Virtual Environment
44
+
45
+ ```
46
+ python3 -m venv venv
47
+ source venv/bin/activate
48
+ ```
49
+
50
+ ## FYI
51
+
52
+ > We initially started with `pip install transformers datasets`