-
Notifications
You must be signed in to change notification settings - Fork 1
/
action.yml
36 lines (36 loc) · 1.1 KB
/
action.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
name: Finder
description: "Finding similar papers"
inputs:
pdf_path:
description: The path to the paper PDF file
required: true
openai_api_key:
description: The OpenAI API key required to create new embeddings
required: true
outputs:
recommendations:
description: "Output message with most similar paper recommendations"
value: ${{ steps.similar-papers-finder.outputs.recommendations }}
runs:
using: "composite"
steps:
- name: Install Python
uses: actions/setup-python@v5
with:
python-version: '3.9'
# cache: 'pip' # caching pip dependencies
- name: Install dependencies
shell: bash
working-directory: ${{ github.action_path }}
run: pip install numpy openai==0.28.1 pandas requests scikit-learn scipy tqdm PyPDF2==3.0.1 matplotlib plotly
- name: Find similar papers
id: similar-papers-finder
shell: bash
# working-directory: ${{ github.action_path }}
env:
PDF_PATH: ${{ inputs.pdf_path }}
run: |
python ${{ github.action_path }}/find-similar-papers.py
branding:
icon: upload
color: green