File size: 1,894 Bytes
c0aa211
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
37
38
39
40
41
42
43
44
45
46
47
.PHONY: install run

install:
	poetry install --no-root

run:
	poetry run streamlit run app.py

build-tree:
	poetry run python -c 'from main import build_tree_cache; build_tree_cache()'

test-search:
	poetry run python -c 'from main import test_search; test_search()'

test-semantic-search:
	poetry run python -c 'from main import test_semantic_search; test_semantic_search()'

fetch-data:
	mkdir -p data
	mkdir -p data/addendum
	mkdir -p data/code_descriptions
	mkdir -p data/poa_exempt_codes
	mkdir -p data/table_index

	@if [ ! -f data/code_descriptions/code_descriptions.zip ]; then \
	    wget https://ftp.cdc.gov/pub/Health_Statistics/NCHS/Publications/ICD10CM/2025/ICD10-CM%20Code%20Descriptions%202025.zip -O data/code_descriptions/code_descriptions.zip; \
	    unzip data/code_descriptions/code_descriptions.zip -d data/code_descriptions; \
	fi

	@if [ ! -f data/addendum/addendum.zip ]; then \
	    wget https://ftp.cdc.gov/pub/Health_Statistics/NCHS/Publications/ICD10CM/2025/ICD10cm-addendum-2025.zip -O data/addendum/addendum.zip; \
	    unzip data/addendum/addendum.zip -d data/addendum; \
	fi

	@if [ ! -f data/table_index/table_index.zip ]; then \
	    wget https://ftp.cdc.gov/pub/Health_Statistics/NCHS/Publications/ICD10CM/2025/icd10cm-table-index-2025.zip -O data/table_index/table_index.zip; \
	    unzip data/table_index/table_index.zip -d data/table_index; \
	fi

	@if [ ! -f data/poa_exempt_codes/poa_exempt_codes.zip ]; then \
	    wget https://ftp.cdc.gov/pub/Health_Statistics/NCHS/Publications/ICD10CM/2025/POAexemptCodesFY25.zip -O data/poa_exempt_codes/poa_exempt_codes.zip; \
	    unzip data/poa_exempt_codes/poa_exempt_codes.zip -d data/poa_exempt_codes; \
	fi

	@if [ ! -f data/guidelines.pdf ]; then \
	    wget https://ftp.cdc.gov/pub/Health_Statistics/NCHS/Publications/ICD10CM/2025/icd-10-cm-FY25-guidelines-october%20-2024.pdf -O data/guidelines.pdf; \
	fi