hccinfhir 0.1.1__tar.gz → 0.1.2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (52) hide show
  1. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/PKG-INFO +32 -3
  2. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/README.md +31 -2
  3. hccinfhir-0.1.2/hccinfhir/__init__.py +47 -0
  4. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/data/ra_eligible_cpt_hcpcs_2026.csv +5130 -5107
  5. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/data/ra_hierarchies_2026.csv +12 -0
  6. hccinfhir-0.1.2/hccinfhir/filter.py +39 -0
  7. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/hccinfhir.py +2 -1
  8. hccinfhir-0.1.2/hccinfhir/sample_utils.py +252 -0
  9. hccinfhir-0.1.2/hccinfhir/samples.py +252 -0
  10. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/pyproject.toml +1 -1
  11. hccinfhir-0.1.1/hccinfhir/__init__.py +0 -1
  12. hccinfhir-0.1.1/hccinfhir/filter.py +0 -41
  13. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/.gitignore +0 -0
  14. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/LICENSE +0 -0
  15. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/data/__init__.py +0 -0
  16. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/data/hcc_is_chronic.csv +0 -0
  17. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/data/ra_coefficients_2025.csv +0 -0
  18. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/data/ra_coefficients_2026.csv +0 -0
  19. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/data/ra_dx_to_cc_2025.csv +0 -0
  20. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/data/ra_dx_to_cc_2026.csv +0 -0
  21. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/data/ra_eligible_cpt_hcpcs_2023.csv +0 -0
  22. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/data/ra_eligible_cpt_hcpcs_2024.csv +0 -0
  23. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/data/ra_eligible_cpt_hcpcs_2025.csv +0 -0
  24. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/data/ra_hierarchies_2025.csv +0 -0
  25. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/datamodels.py +0 -0
  26. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/extractor.py +0 -0
  27. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/extractor_837.py +0 -0
  28. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/extractor_fhir.py +0 -0
  29. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/model_calculate.py +0 -0
  30. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/model_coefficients.py +0 -0
  31. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/model_demographics.py +0 -0
  32. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/model_dx_to_cc.py +0 -0
  33. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/model_hierarchies.py +0 -0
  34. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/model_interactions.py +0 -0
  35. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/samples/__init__.py +0 -0
  36. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/samples/sample_837_0.txt +0 -0
  37. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/samples/sample_837_1.txt +0 -0
  38. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/samples/sample_837_10.txt +0 -0
  39. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/samples/sample_837_11.txt +0 -0
  40. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/samples/sample_837_2.txt +0 -0
  41. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/samples/sample_837_3.txt +0 -0
  42. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/samples/sample_837_4.txt +0 -0
  43. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/samples/sample_837_5.txt +0 -0
  44. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/samples/sample_837_6.txt +0 -0
  45. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/samples/sample_837_7.txt +0 -0
  46. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/samples/sample_837_8.txt +0 -0
  47. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/samples/sample_837_9.txt +0 -0
  48. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/samples/sample_eob_1.json +0 -0
  49. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/samples/sample_eob_2.json +0 -0
  50. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/samples/sample_eob_200.ndjson +0 -0
  51. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/samples/sample_eob_3.json +0 -0
  52. {hccinfhir-0.1.1 → hccinfhir-0.1.2}/hccinfhir/utils.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: hccinfhir
3
- Version: 0.1.1
3
+ Version: 0.1.2
4
4
  Summary: HCC Algorithm for FHIR Resources
5
5
  Project-URL: Homepage, https://github.com/mimilabs/hccinfhir
6
6
  Project-URL: Issues, https://github.com/mimilabs/hccinfhir/issues
@@ -69,6 +69,34 @@ result = calculate_raf(
69
69
 
70
70
  For more details on the SLD format, see the `datamodels.py` file.
71
71
 
72
+ ## Sample Data
73
+
74
+ The package includes comprehensive sample data for testing and demonstration purposes:
75
+
76
+ ```python
77
+ from hccinfhir import (
78
+ get_eob_sample,
79
+ get_eob_sample_list,
80
+ get_837_sample,
81
+ get_837_sample_list,
82
+ list_available_samples
83
+ )
84
+
85
+ # Get individual EOB samples (cases 1, 2, or 3)
86
+ eob_data = get_eob_sample(1)
87
+
88
+ # Get multiple EOB samples (up to 200 available)
89
+ eob_list = get_eob_sample_list(limit=10)
90
+
91
+ # Get 837 claim samples (cases 0 through 11)
92
+ claim_data = get_837_sample(0)
93
+
94
+ # Get information about available samples
95
+ info = list_available_samples()
96
+ ```
97
+
98
+ For detailed usage examples, see the `examples/sample_data_usage.py` file.
99
+
72
100
  ## Core Components
73
101
 
74
102
  ### 1. Extractor Module
@@ -352,9 +380,10 @@ WHERE is_included = 'yes' AND YEAR(mimi_src_file_date) = 2025;
352
380
  Join us at [mimilabs](https://mimilabs.ai/signup). Reference data available in MIMILabs data lakehouse.
353
381
 
354
382
  ## Publishing (only for those maintainers...)
383
+ Inside the hatch
355
384
  ```bash
356
- $ python3 -m hatch build
357
- $ python3 -m hatch publish
385
+ $ hatch build
386
+ $ hatch publish
358
387
  ```
359
388
 
360
389
  ## License
@@ -55,6 +55,34 @@ result = calculate_raf(
55
55
 
56
56
  For more details on the SLD format, see the `datamodels.py` file.
57
57
 
58
+ ## Sample Data
59
+
60
+ The package includes comprehensive sample data for testing and demonstration purposes:
61
+
62
+ ```python
63
+ from hccinfhir import (
64
+ get_eob_sample,
65
+ get_eob_sample_list,
66
+ get_837_sample,
67
+ get_837_sample_list,
68
+ list_available_samples
69
+ )
70
+
71
+ # Get individual EOB samples (cases 1, 2, or 3)
72
+ eob_data = get_eob_sample(1)
73
+
74
+ # Get multiple EOB samples (up to 200 available)
75
+ eob_list = get_eob_sample_list(limit=10)
76
+
77
+ # Get 837 claim samples (cases 0 through 11)
78
+ claim_data = get_837_sample(0)
79
+
80
+ # Get information about available samples
81
+ info = list_available_samples()
82
+ ```
83
+
84
+ For detailed usage examples, see the `examples/sample_data_usage.py` file.
85
+
58
86
  ## Core Components
59
87
 
60
88
  ### 1. Extractor Module
@@ -338,9 +366,10 @@ WHERE is_included = 'yes' AND YEAR(mimi_src_file_date) = 2025;
338
366
  Join us at [mimilabs](https://mimilabs.ai/signup). Reference data available in MIMILabs data lakehouse.
339
367
 
340
368
  ## Publishing (only for those maintainers...)
369
+ Inside the hatch
341
370
  ```bash
342
- $ python3 -m hatch build
343
- $ python3 -m hatch publish
371
+ $ hatch build
372
+ $ hatch publish
344
373
  ```
345
374
 
346
375
  ## License
@@ -0,0 +1,47 @@
1
+ """
2
+ HCCInFHIR - HCC Algorithm for FHIR Resources
3
+
4
+ A Python library for processing FHIR EOB resources and calculating HCC risk scores.
5
+ """
6
+
7
+ # Main classes
8
+ from .hccinfhir import HCCInFHIR
9
+ from .extractor import extract_sld, extract_sld_list
10
+ from .filter import apply_filter
11
+ from .model_calculate import calculate_raf
12
+ from .datamodels import Demographics, ServiceLevelData, RAFResult, ModelName
13
+
14
+ # Sample data functions
15
+ from .sample_utils import (
16
+ SampleData,
17
+ get_eob_sample,
18
+ get_eob_sample_list,
19
+ get_837_sample,
20
+ get_837_sample_list,
21
+ list_available_samples
22
+ )
23
+
24
+ __version__ = "0.1.2"
25
+ __author__ = "Yubin Park"
26
+ __email__ = "yubin.park@mimilabs.ai"
27
+
28
+ __all__ = [
29
+ # Main classes
30
+ "HCCInFHIR",
31
+ "extract_sld",
32
+ "extract_sld_list",
33
+ "apply_filter",
34
+ "calculate_raf",
35
+ "Demographics",
36
+ "ServiceLevelData",
37
+ "RAFResult",
38
+ "ModelName",
39
+
40
+ # Sample data
41
+ "SampleData",
42
+ "get_eob_sample",
43
+ "get_eob_sample_list",
44
+ "get_837_sample",
45
+ "get_837_sample_list",
46
+ "list_available_samples"
47
+ ]