Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
225 commits
Select commit Hold shift + click to select a range
8dcf55d
Setting up GitHub Classroom Feedback
github-classroom[bot] Nov 9, 2024
184364a
feat: initalize project template
yeseoLee Nov 10, 2024
dfa7afc
chore: add gitignore
yeseoLee Nov 11, 2024
80783f9
chore: add gitignore
yeseoLee Nov 11, 2024
0cda47d
feat: add requirement
yeseoLee Nov 11, 2024
449ffbd
feat: ISSUE TEMPLATE 구성
yeseoLee Nov 11, 2024
4482083
feat: GPU 서버 setting script 추가
yeseoLee Nov 11, 2024
7a28f48
chore: add gitignore vscode
yeseoLee Nov 11, 2024
386a67f
Merge pull request #6 from boostcampaitech7/feat/baseline
yeseoLee Nov 11, 2024
7c1ec53
feat: baseline to Templatea
yeseoLee Nov 11, 2024
eb59063
fix: makefile을 위한 build-essential install 추가
yeseoLee Nov 11, 2024
4216528
fix: 내부 패키지 import 수정
yeseoLee Nov 12, 2024
ad3043c
fix: config 참조 에러 수정
yeseoLee Nov 12, 2024
712887b
chore: requirement 주석 추가
yeseoLee Nov 12, 2024
11c3c38
chore: add gitignore
yeseoLee Nov 12, 2024
b957ac6
style: inference 클래스명 변경
yeseoLee Nov 12, 2024
fe1f9f0
fix: config 누락추가 및 경로 수정
yeseoLee Nov 12, 2024
367e096
feat: 로그 추가
yeseoLee Nov 12, 2024
98dfb2a
chore: 주석 간소화
yeseoLee Nov 12, 2024
5dc2bef
Merge pull request #18 from boostcampaitech7/feat/baseline
yeseoLee Nov 12, 2024
5528a75
feat: wandb 기능 추가
Sujinkim-625 Nov 12, 2024
766ae56
feat: 파일명 생성 시 base_model의 "/"를 "_"로 변환
Sujinkim-625 Nov 12, 2024
6357578
feat: output.csv 파일명을 wandb 실험 이름과 동일하게 변경
Sujinkim-625 Nov 12, 2024
7eb1011
chore: pubao -> fubao
yeseoLee Nov 12, 2024
24daa38
Merge pull request #21 from boostcampaitech7/feat/wandb
Sujinkim-625 Nov 12, 2024
c96b967
fix: report_to as-is(None) to-be(wandb)
Sujinkim-625 Nov 12, 2024
f3afd7a
fix: logging strategy = epoch 추가
Sujinkim-625 Nov 13, 2024
b800f9c
feat:데이터 눈으로보는 페이지
koreannn Nov 13, 2024
4471645
fix:포매팅 적용
koreannn Nov 13, 2024
7da7895
fix:포매팅
koreannn Nov 13, 2024
7ebadbf
Merge pull request #25 from boostcampaitech7/feat/st_pages
koreannn Nov 13, 2024
11d53c4
feat: train 및 test파일의 pdf 시각화 코드 구현
nevertmr Nov 13, 2024
e95cc45
style: 파일명 변경
nevertmr Nov 13, 2024
1e13e0f
fix:폰트 저장방식 변경, data폴더에 저장
nevertmr Nov 13, 2024
0f1f0ce
Merge pull request #30 from boostcampaitech7/feat/eda_pdf-visualization
yeseoLee Nov 13, 2024
e85b58a
chore:스트림릿버전명시
koreannn Nov 13, 2024
f13a978
feat: config run_name 추가 및 config 로그 남김
yeseoLee Nov 13, 2024
128cd99
fix: log_config 인자 에러 수정
yeseoLee Nov 13, 2024
41a844a
feat: response_template config로 분리
yeseoLee Nov 13, 2024
2062f7c
feat : wandb에 에러는 기록 안함, config 로그 수정
yeseoLee Nov 13, 2024
1d5102a
feat : gradient checkpointing, accumulation 추가
yeseoLee Nov 13, 2024
1d4c622
fix : 누락된 streamlit 의존성 추가
yeseoLee Nov 13, 2024
1be1403
fix : wandb 오류 수정
yeseoLee Nov 14, 2024
4fe3a2e
Merge pull request #35 from boostcampaitech7/exp/gpu-efficiency
Sujinkim-625 Nov 14, 2024
f178829
feat:add labeling eda
Effyee Nov 14, 2024
1fd2c3b
feat:add labeling
Effyee Nov 14, 2024
75d1e62
Merge branch 'Develop' of https://github.com/boostcampaitech7/level2-…
Effyee Nov 14, 2024
4676f31
feat:add labeling code
Nov 14, 2024
4683322
feat: 의존성 추가
yeseoLee Nov 14, 2024
c16196e
feat: upload 유틸 구현(gdrive, hf_hub)
yeseoLee Nov 14, 2024
c300e57
feat: utils 패키지 분리
yeseoLee Nov 14, 2024
e21e2d5
chore: add gitignore
yeseoLee Nov 14, 2024
7dd3c65
chore: add gitignore
yeseoLee Nov 14, 2024
63c1d11
feat: 의존성 추가
yeseoLee Nov 14, 2024
b767ba3
feat: .env sample 추가
yeseoLee Nov 14, 2024
860fb74
fix: hf_upload arparse 추가
yeseoLee Nov 14, 2024
85a29e9
fix: 양자화 관련 누락된 의존성 추가
yeseoLee Nov 14, 2024
1974a66
fix: gdrive 토큰 로직 수정
yeseoLee Nov 14, 2024
f1889e2
fix: 상대경로 패키지 참조 수정
yeseoLee Nov 14, 2024
37a3791
refector: 코드 위치 변경
yeseoLee Nov 14, 2024
df05de3
fix: 허깅페이스 업로드 수정 argument to env
yeseoLee Nov 14, 2024
11cd3d6
fix: 오탈자 수정
yeseoLee Nov 14, 2024
58dcd9d
fix: 실행 경로 수정
yeseoLee Nov 14, 2024
dc60145
feat : inference 하지 않는 옵션 추가
yeseoLee Nov 15, 2024
8516d14
style : 스크립트 주석 추가
yeseoLee Nov 15, 2024
0732ae4
style : 변수 상수 순서 변경
yeseoLee Nov 15, 2024
d16ce2f
style : util.py -> common.py로 이름 변경
yeseoLee Nov 15, 2024
d1b0bd5
fix : env 및 config 관련 오류 수정
yeseoLee Nov 15, 2024
93295ec
feat : GDrive config.yaml 업로드 기능 추가
yeseoLee Nov 15, 2024
6a0541c
fix : load_env_file import error
yeseoLee Nov 15, 2024
c35ef18
fix : softmax 함수에서 dimension을 명시적으로 지정하도록 수정
yeseoLee Nov 15, 2024
06bcd6a
fix : config 및 env 버그 수정
yeseoLee Nov 15, 2024
2eb3376
Merge pull request #42 from boostcampaitech7/feat/util-uploader
hsmin9809 Nov 15, 2024
c84b87f
feat: peft version upgrade
yeseoLee Nov 15, 2024
e836dcb
feat: inference시 use_cache=True
yeseoLee Nov 15, 2024
db89d7a
feat: quantization 및 grad_norm config 추가
yeseoLee Nov 15, 2024
2c7634b
add config: logging & eval per step
yeseoLee Nov 16, 2024
e796a61
feat : add run script
yeseoLee Nov 16, 2024
dcc21f2
feat : timer (시간 측정 유틸 함수) 추가
yeseoLee Nov 16, 2024
7dd7e88
style : 주석 추가
yeseoLee Nov 16, 2024
fa8879a
style : 주석 추가
yeseoLee Nov 16, 2024
f83bf6a
feat: add requirement for rag
yeseoLee Nov 16, 2024
fb2994a
feat: wiki_dump 의존성 추가(wikiextractor)
yeseoLee Nov 16, 2024
3596adb
feat: add wiki_dump.py
yeseoLee Nov 16, 2024
93f85af
feat: RAG 구현: Wiki BM25
yeseoLee Nov 16, 2024
725ccb2
fix: timer 함수 내 print -> logger
yeseoLee Nov 16, 2024
0dcf750
feat: 파라미터 예시 추가
yeseoLee Nov 16, 2024
1fd42c8
fix: wiki data column 수정
yeseoLee Nov 16, 2024
5c3e1a8
feat: wiki retriever bm25s 구현
yeseoLee Nov 16, 2024
5c6dc03
fix: bm25 코드 리펙토링
yeseoLee Nov 17, 2024
e263422
fix: bm25 파일 이름 변경
yeseoLee Nov 17, 2024
22ab0bc
style: rename
yeseoLee Nov 17, 2024
0ec3f1f
fix: bm25s 제거 및 bm25 로직 개선
yeseoLee Nov 17, 2024
6722fae
fix: 8bit BitsAndBytesConfig quantization error
yeseoLee Nov 18, 2024
730f556
Merge pull request #48 from boostcampaitech7/feat/quantization
Sujinkim-625 Nov 18, 2024
93c918e
Merge branch 'Develop' into feat/rag
yeseoLee Nov 18, 2024
d41a595
feat: max_length 계산하는 ipynb 파일 추가.
Sujinkim-625 Nov 18, 2024
49fa44a
feat: scatter graph 추가
Sujinkim-625 Nov 18, 2024
1296b1f
fix: pickle에는 corpus 제외하고 embedding만 저장
yeseoLee Nov 17, 2024
4df1b22
Merge pull request #52 from boostcampaitech7/feat/check_length
hsmin9809 Nov 18, 2024
82cb533
fix: error log에 trace남도록 수정
yeseoLee Nov 18, 2024
860fc21
feat: retriever 연결
yeseoLee Nov 18, 2024
0f5ff79
refector: inference & dataloader간 코드 중복 제거 및 retriever config 분리
yeseoLee Nov 18, 2024
c6a67b5
fix: retrive 오류 수정(prompt, list comprehension)
yeseoLee Nov 18, 2024
d18cf82
style: 로그 레벨 조정 및 메세지 수정
yeseoLee Nov 18, 2024
ad18195
feat: requirement rank25s제거 및 elasticsearch 추가
yeseoLee Nov 18, 2024
1d3ff58
fix: InferenceModel 인자 오탈자 수정
yeseoLee Nov 18, 2024
86612d8
fix: inference 누락된 함수 추가
yeseoLee Nov 18, 2024
90b30d6
refector: retriever 적용을 위한 prompt 분리
yeseoLee Nov 18, 2024
cb2aee1
fix: retriever default tokenizer okt -> 띄어쓰기
yeseoLee Nov 19, 2024
a713699
Merge pull request #56 from boostcampaitech7/feat/rag
yeseoLee Nov 19, 2024
1f5d710
Resolve merge conflict in requirements.txt
Nov 19, 2024
9d2b704
feat: 사전 양자화 모델을 위한 옵션 및 의존성 추가
yeseoLee Nov 19, 2024
66cb739
fix: env 경로 오류 수정
yeseoLee Nov 19, 2024
e07cedb
feat: retriever 설정을위위한 데이터셋길길이 확인
yeseoLee Nov 19, 2024
259da66
feat:전전처리 데이터셋 저장 및 로드 기능, 리트리버 max_length 구현
yeseoLee Nov 19, 2024
c823b45
feat:elastic retriever
yeseoLee Nov 19, 2024
548dfd1
fix: config 추가 및 제거
yeseoLee Nov 19, 2024
906afda
fix: 불필요 config 제거
yeseoLee Nov 19, 2024
6d2789a
feat:rag
Nov 19, 2024
be5f612
fix: 권장 config update
yeseoLee Nov 19, 2024
aa4f3af
Merge pull request #60 from boostcampaitech7/feat/efficiency
Sujinkim-625 Nov 19, 2024
3d6491c
style: 폴더구조 및 파일명 변경
yeseoLee Nov 20, 2024
3175169
fix: wandb에 config 출력
yeseoLee Nov 20, 2024
0d9a177
refector: BM25Retriever 제거
yeseoLee Nov 20, 2024
7d03a22
Merge pull request #67 from boostcampaitech7/feat/log_and_directory
yeseoLee Nov 20, 2024
aa9d8ff
feat: reranker 구현
yeseoLee Nov 20, 2024
e9e155c
Merge pull request #69 from boostcampaitech7/feat/reranker
Effyee Nov 20, 2024
497ebc2
fix: 순환 참조 오류 수정
yeseoLee Nov 20, 2024
7220e53
Merge pull request #70 from boostcampaitech7/hotfix/rerank
yeseoLee Nov 20, 2024
1d5081c
fix: reranker 인스턴스 에러 수정
yeseoLee Nov 20, 2024
4664fcb
feat: retrieve visualization
yeseoLee Nov 20, 2024
3e7a32c
feat: 정답 선지 빨간색 표시
yeseoLee Nov 20, 2024
93e4e03
fix: retrieve 시각화
yeseoLee Nov 20, 2024
20cb17a
Merge pull request #72 from boostcampaitech7/feat/rag_viz
koreannn Nov 21, 2024
342f59d
feat:dense rag
Nov 21, 2024
be9ad79
Merge pull request #2 from gayeon7877/exp/compare-pretraining-kor-soc
Effyee Nov 21, 2024
6b68ec1
fix: 시각화 가로 세로 위치 개선
yeseoLee Nov 21, 2024
611600b
fix:dense rag
Nov 21, 2024
eadfdbb
Merge pull request #73 from boostcampaitech7/feat/rag_viz
yeseoLee Nov 21, 2024
292ff64
Merge pull request #3 from gayeon7877/exp/compare-pretraining-kor-soc
Effyee Nov 21, 2024
e14cded
Merge branch 'boostcampaitech7:Develop' into Develop
Effyee Nov 21, 2024
4779031
feat: earlystop 기능 추가
hsmin9809 Nov 21, 2024
4550afd
feat: config 파라미터 추가
hsmin9809 Nov 21, 2024
db343a6
feat: early stop threshold 추가
hsmin9809 Nov 21, 2024
4235ebe
feat: threshold config 파라미터 추가
hsmin9809 Nov 21, 2024
fd4c737
fix: dense
Nov 21, 2024
949da51
Merge pull request #4 from gayeon7877/feat/dense_rag
Effyee Nov 21, 2024
a4029fa
fix: dense
Nov 21, 2024
3464ed3
Merge pull request #5 from gayeon7877/feat/dense_rag
Effyee Nov 21, 2024
dac177b
fix:dense
Nov 21, 2024
90b5052
Merge pull request #6 from gayeon7877/feat/dense_rag
Effyee Nov 21, 2024
a659758
Merge pull request #75 from gayeon7877/Develop
Effyee Nov 21, 2024
5ca8a55
fix:style
Nov 21, 2024
5b5539d
Merge branch 'feat/dense_rag' of https://github.com/boostcampaitech7/…
Nov 21, 2024
a144748
docs:add README.md
Nov 21, 2024
2500adf
feat: data process for rag documents
yeseoLee Nov 21, 2024
27718ea
feat: process_json_file
yeseoLee Nov 21, 2024
05d6325
feat: optimizer quantization
yeseoLee Nov 21, 2024
65ff0d9
feat: preprocess_text 내용이 빈 괄호 제거
yeseoLee Nov 21, 2024
3c2fbe6
fix: process_text
yeseoLee Nov 21, 2024
6d5cce7
fix: retrieve load 로직 개선
yeseoLee Nov 22, 2024
00840b9
style: dense retriever 관련 코드 포메팅 수정
yeseoLee Nov 22, 2024
1f644ff
refector: print logger로 교체
yeseoLee Nov 22, 2024
71bd40e
Merge pull request #76 from boostcampaitech7/feat/dense_rag
yeseoLee Nov 22, 2024
f37bafe
Merge branch 'Develop' into feat/EarlyStop
yeseoLee Nov 22, 2024
4dea2d6
style: formatting
yeseoLee Nov 22, 2024
28f2d40
Merge pull request #77 from boostcampaitech7/feat/EarlyStop
yeseoLee Nov 22, 2024
b9a89ea
Merge branch 'Develop' into feat/rag_data_process
yeseoLee Nov 22, 2024
8ccffca
Merge branch 'Develop' into feat/optimizer_quantazation
yeseoLee Nov 22, 2024
53efe33
style: formatting
yeseoLee Nov 22, 2024
4d5de3c
Merge pull request #80 from boostcampaitech7/feat/rag_data_process
Effyee Nov 22, 2024
87aba37
refector: prepare datasets 중복 로직 제거
yeseoLee Nov 22, 2024
425dd5b
Merge pull request #81 from boostcampaitech7/feat/optimizer_quantazation
nevertmr Nov 22, 2024
a03df1f
fix: config 권장사양 업데이트
yeseoLee Nov 22, 2024
53088ba
feat: retrieve 결과 문서의 length 제한을 위한 기능 추가
yeseoLee Nov 22, 2024
6aa8442
feat: retrieve 시각화
yeseoLee Nov 22, 2024
3e4193d
fix: 의존성 에러 수정
yeseoLee Nov 22, 2024
0c11a31
fix: data_loader is_train value error
yeseoLee Nov 22, 2024
5a3dd04
fix: remove unused requirement
yeseoLee Nov 22, 2024
96b692a
Merge pull request #83 from boostcampaitech7/feat/max_seq_len
yeseoLee Nov 22, 2024
c15d131
feat: collect external data - sat, gaokao
yeseoLee Nov 23, 2024
6ba0d12
feat: collect external data - sat, gaokao
yeseoLee Nov 23, 2024
aaa6eb8
fix: optimizer-quantization 제거
yeseoLee Nov 23, 2024
bdb8356
feat: cache로 최적화된 번역api 구현(googletrans)
yeseoLee Nov 23, 2024
7a30f30
feat: collect external data - MuSR
yeseoLee Nov 23, 2024
9d0f71a
feat: balancing choices
yeseoLee Nov 23, 2024
2d8bd3e
feat: collection MuSR
yeseoLee Nov 23, 2024
36f6750
style: 외부데이터 수집 관련 파일명 변경
yeseoLee Nov 23, 2024
b2bc68e
feat: 외부데이터 formatting
yeseoLee Nov 23, 2024
5d606e2
fix: 외부데이터 이름 형식 변경
yeseoLee Nov 23, 2024
f60a955
fix: 외부데이터 이름 형식 변경
yeseoLee Nov 23, 2024
7cfd96e
fix: optimizer 양자화 사용/비사용 선택 가능하도록 수정
yeseoLee Nov 23, 2024
f041fab
Merge pull request #86 from boostcampaitech7/feat/external_data
hsmin9809 Nov 25, 2024
8e71030
Merge pull request #87 from boostcampaitech7/feat/no-optimizer-quanti…
hsmin9809 Nov 25, 2024
ef8d1f0
feat: 공무원시험 데이터 크롤링
yeseoLee Nov 25, 2024
f20b845
feat: 공무원시험 데이터 포매팅
yeseoLee Nov 25, 2024
a6e9d27
feat: 포매팅시 NaN 값 처리 추가
yeseoLee Nov 25, 2024
e6f284c
feat: 외부데이터 이용시 NaN 값 예외처리
yeseoLee Nov 25, 2024
60236b0
feat: 크롤링시 그림 또는 테이블이 포함된 문제 필터링
yeseoLee Nov 25, 2024
7168e95
feat: 회계, 헌법, 한국사 추가
yeseoLee Nov 25, 2024
98b0918
feat: hard voting
Nov 26, 2024
d41ef23
Merge pull request #92 from boostcampaitech7/feat/crawling
Sujinkim-625 Nov 26, 2024
ae35370
feat: hard voting
Nov 26, 2024
d500236
feat: hard voting
Nov 26, 2024
9460b10
feat: extracting information from PDF documents, create txt files
Sujinkim-625 Nov 26, 2024
2aebf5a
Merge pull request #96 from boostcampaitech7/feat/ensemble
Sujinkim-625 Nov 26, 2024
4dff386
fix: 공무원 시험 5지선다형 추가
yeseoLee Nov 26, 2024
ac1d65b
Merge pull request #98 from boostcampaitech7/feat/crawling
Sujinkim-625 Nov 26, 2024
7344a00
fix: style formatting
Sujinkim-625 Nov 26, 2024
bede380
hotfix: prompt 오류 수정
yeseoLee Nov 26, 2024
d33ed67
fix: style formatting
Sujinkim-625 Nov 26, 2024
9fbae97
feat: 외부데이터사용 시 대회 규칙 위배 여부 필터링
yeseoLee Nov 27, 2024
f5cfe23
Merge pull request #97 from boostcampaitech7/feat/pdf_edit
yeseoLee Nov 27, 2024
68cd48c
style:fix
Nov 28, 2024
955827a
Merge pull request #103 from boostcampaitech7/feat/race_aug
Effyee Nov 28, 2024
66e19fd
Merge pull request #102 from boostcampaitech7/feat/filtering
hsmin9809 Nov 28, 2024
252ff80
feat: 윤리와 사상 데이터 증강 prompt
Sujinkim-625 Nov 29, 2024
c29ba63
feat: CoT 칼럼 추가 prompt
Sujinkim-625 Nov 29, 2024
65b2e16
Merge pull request #104 from boostcampaitech7/feat/prompt
hsmin9809 Nov 29, 2024
2908d6f
feat: add README.md
Sujinkim-625 Dec 2, 2024
0bca25d
feat: add README.md
Sujinkim-625 Dec 2, 2024
cb7b090
Merge pull request #105 from boostcampaitech7/Develop
nevertmr Dec 3, 2024
0f312c5
Delete notebook/check_length.ipynb
yeseoLee Dec 19, 2024
998b624
fix: change team member ID
nevertmr Nov 16, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions .github/ISSUE_TEMPLATE/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
blank_issues_enabled: false
issue_templates:
- name: Feature Template
description: Suggest an feature for this project 👩‍💻
file: feature.md
- name: Experiment Template
description: Suggest an experiment for this project 🧑🏻‍🔬
file: experiment.md
- name: Research Template
description: Suggest an research to generate ideas 👨‍🏫
file: research.md
38 changes: 38 additions & 0 deletions .github/ISSUE_TEMPLATE/experiment.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
---
name: 📊 Experiment Request
about: Suggest an experiment for this project 🧑🏻‍🔬
title: "[EXP]"
labels: experiment
assignees:
---
# 📊 Experiment

## 🥚 실험 근거

- 레퍼런스 (논문, 강의, 포스팅)
- 합리적 추론

## 📎 내용

- 실험에 대한 상세한 내용
- 실험 환경과 변인 통제 반드시 기입

## 🐣 예상 결과

- 반드시 이유와 함께 예상 결과 작성

## 🍳 실제 결과

- 예상 결과와 달랐다면 그 이유도 함께 작성

## 📝 실험 정보

- wandb 링크
- 제출 결과 노션 링크

## 📌 체크리스트

- [ ] todo 1
- [ ] todo 2

---
20 changes: 20 additions & 0 deletions .github/ISSUE_TEMPLATE/feature.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
---
name: 🚀 Feature Request
about: Suggest an feature for this project 👩‍💻
title: "[FEAT]"
labels: enhancement
assignees:
---
# 🚀 Feature

## 📎 내용

- context 1
- context 2

## 📌 체크리스트

- [ ] todo 1
- [ ] todo 2

---
25 changes: 25 additions & 0 deletions .github/ISSUE_TEMPLATE/research.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
---
name: 📚 Research Request
about: Suggest an research to generate ideas 👨‍🏫
title: "[RES]"
labels: research
assignees:
---
# 📚 Research

## 📎 내용

- context 1
- context 2

## 🧐 결론 및 실험 가능성

- conclusion 1
- conclusion 2

## 📌 체크리스트

- [ ] todo 1
- [ ] todo 2

---
11 changes: 11 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
## Description

- 이번 PR에서 작업한 내용을 간략히 설명

## Refer to the reviewer

- 리뷰어에게 필요한 설명이나 특별히 봐주었으면 하는 부분을 작성

## Related Issue

- #이슈번호
24 changes: 24 additions & 0 deletions .github/workflows/check-lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: check-lint

on: [pull_request]

jobs:
check-lint:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Set up Python 3.11
uses: actions/setup-python@v5
with:
python-version: "3.11"

- name: Install dependencies
run: |
python3 -m pip install --upgrade pip

- name: Check Lint
run: |
make quality
177 changes: 177 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,177 @@
# Custom
.idea/
**/data/
**/output/
**/outputs/
**/wandb/
**/*.out
config/*.yaml
config/token.json
config/credentials.json

# Byte-compiled / optimized / DLL files
__pycache__/
*.py[cod]
*$py.class

# C extensions
*.so

# Distribution / packaging
.Python
build/
develop-eggs/
dist/
downloads/
eggs/
.eggs/
lib/
lib64/
parts/
sdist/
var/
wheels/
share/python-wheels/
*.egg-info/
.installed.cfg
*.egg
MANIFEST

# PyInstaller
# Usually these files are written by a python script from a template
# before PyInstaller builds the exe, so as to inject date/other infos into it.
*.manifest
*.spec

# Installer logs
pip-log.txt
pip-delete-this-directory.txt

# Unit test / coverage reports
htmlcov/
.tox/
.nox/
.coverage
.coverage.*
.cache
nosetests.xml
coverage.xml
*.cover
*.py,cover
.hypothesis/
.pytest_cache/
cover/

# Translations
*.mo
*.pot

# Django stuff:
*.log
local_settings.py
db.sqlite3
db.sqlite3-journal

# Flask stuff:
instance/
.webassets-cache

# Scrapy stuff:
.scrapy

# Sphinx documentation
docs/_build/

# PyBuilder
.pybuilder/
target/

# Jupyter Notebook
.ipynb_checkpoints

# IPython
profile_default/
ipython_config.py

# pyenv
# For a library or package, you might want to ignore these files since the code is
# intended to run in multiple environments; otherwise, check them in:
# .python-version

# pipenv
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
# However, in case of collaboration, if having platform-specific dependencies or dependencies
# having no cross-platform support, pipenv may install dependencies that don't work, or not
# install all needed dependencies.
#Pipfile.lock

# poetry
# Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
# This is especially recommended for binary packages to ensure reproducibility, and is more
# commonly ignored for libraries.
# https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
#poetry.lock

# pdm
# Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
#pdm.lock
# pdm stores project-wide configurations in .pdm.toml, but it is recommended to not include it
# in version control.
# https://pdm.fming.dev/latest/usage/project/#working-with-version-control
.pdm.toml
.pdm-python
.pdm-build/

# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
__pypackages__/

# Celery stuff
celerybeat-schedule
celerybeat.pid

# SageMath parsed files
*.sage.py

# Environments
.env
.venv
env/
venv/
ENV/
env.bak/
venv.bak/

# Spyder project settings
.spyderproject
.spyproject

# Rope project settings
.ropeproject

# mkdocs documentation
/site

# mypy
.mypy_cache/
.dmypy.json
dmypy.json

# Pyre type checker
.pyre/

# pytype static type analyzer
.pytype/

# Cython debug symbols
cython_debug/

# PyCharm
# JetBrains specific template is maintained in a separate JetBrains.gitignore that can
# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
# and can be added to the global gitignore or merged into this file. For a more nuclear
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
#.idea/

# Mac
**/.DS_Store
.vscode/settings.json
25 changes: 25 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.5.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
- id: check-yaml
- id: check-added-large-files
- id: check-merge-conflict

- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.7.2
hooks:
- id: ruff
args: [--fix]
- id: ruff-format

- repo: local
hooks:
- id: pytest
name: pytest
entry: python3 -m pytest
language: system
pass_filenames: false
types: [python]
48 changes: 48 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
clean: clean-pyc clean-test
quality: set-style-dep check-quality
style: set-style-dep set-style
setup: set-precommit set-style-dep set-test-dep set-git set-dev
test: set-test-dep set-test


##### basic #####
set-git:
git config --local commit.template .gitmessage

set-style-dep:
pip3 install ruff==0.7.2

set-test-dep:
pip3 install pytest==8.3.2

set-precommit:
pip3 install pre-commit==4.0.1
pre-commit install

set-dev:
pip3 install -r ./requirements.txt

set-test:
python3 -m pytest tests/

set-style:
ruff check --fix .
ruff format .

check-quality:
ruff check .
ruff format --check .

##### clean #####
clean-pyc:
find . -name '*.pyc' -exec rm -f {} +
find . -name '*.pyo' -exec rm -f {} +
find . -name '*~' -exec rm -f {} +
find . -name '__pycache__' -exec rm -fr {} +

clean-test:
rm -f .coverage
rm -f .coverage.*
rm -rf .pytest_cache
rm -rf .mypy_cache
rm -rf .ruff_cache
Loading