danielle2003 commited on
Commit
a040e14
·
1 Parent(s): 2b3de4f
Files changed (1) hide show
  1. .github/workflows/ci-cd.yml +36 -0
.github/workflows/ci-cd.yml CHANGED
@@ -0,0 +1,36 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ name: Sentiment Analysis Pipeline
2
+
3
+ on: [push, pull_request] # Runs on push or PR to any branch
4
+
5
+ jobs:
6
+ train_and_test:
7
+ runs-on: ubuntu-latest
8
+
9
+ steps:
10
+ - name: Checkout Repository
11
+ uses: actions/checkout@v3 # Clones repo
12
+
13
+ - name: Set Up Python
14
+ uses: actions/setup-python@v4
15
+ with:
16
+ python-version: "3.10"
17
+
18
+ - name: Install Dependencies
19
+ run: |
20
+ pip install --upgrade pip
21
+ pip install -r requirements.txt
22
+
23
+ - name: Train Model
24
+ run: python train.py
25
+
26
+ - name: Evaluate Model
27
+ run: python evaluate.py
28
+
29
+ - name: Run Tests
30
+ run: python test.py
31
+
32
+ - name: Upload Model Artifacts
33
+ uses: actions/upload-artifact@v3
34
+ with:
35
+ name: trained-model
36
+ path: models/