Commit
Β·
8635ba1
1
Parent(s):
697ea59
Add initial data files and Streamlit app for CNO classification
Browse files- Created defaults_session_state.json to manage session state defaults.
- Added idxs.csv containing CNO labels and indices.
- Introduced metadata.json with demographic and educational metadata.
- Added problematic_cnos.json listing unreliable CNO codes.
- Included model.safetensors and sentencepiece.bpe.model for model loading.
- Created special_tokens_map.json for token management in the model.
- Developed streamlit_app.py for user interface and interaction.
- Added tokenizer.json and tokenizer_config.json for tokenizer settings.
- Included training_args.bin for model training arguments.
- Implemented utility functions in cno_utils.py for label and description mapping.
- src/config.json β config.json +0 -0
- {src/data β data}/cno11_notas.csv +0 -0
- {src/data β data}/defaults_session_state.json +0 -0
- {src/data β data}/idxs.csv +0 -0
- {src/data β data}/metadata.json +0 -0
- {src/data β data}/problematic_cnos.json +0 -0
- src/model.safetensors β model.safetensors +0 -0
- src/sentencepiece.bpe.model β sentencepiece.bpe.model +0 -0
- src/special_tokens_map.json β special_tokens_map.json +0 -0
- src/streamlit_app.py β streamlit_app.py +3 -3
- src/tokenizer.json β tokenizer.json +0 -0
- src/tokenizer_config.json β tokenizer_config.json +0 -0
- src/training_args.bin β training_args.bin +0 -0
- {src/utils β utils}/__init__.py +0 -0
- {src/utils β utils}/cno_utils.py +0 -0
src/config.json β config.json
RENAMED
|
File without changes
|
{src/data β data}/cno11_notas.csv
RENAMED
|
File without changes
|
{src/data β data}/defaults_session_state.json
RENAMED
|
File without changes
|
{src/data β data}/idxs.csv
RENAMED
|
File without changes
|
{src/data β data}/metadata.json
RENAMED
|
File without changes
|
{src/data β data}/problematic_cnos.json
RENAMED
|
File without changes
|
src/model.safetensors β model.safetensors
RENAMED
|
File without changes
|
src/sentencepiece.bpe.model β sentencepiece.bpe.model
RENAMED
|
File without changes
|
src/special_tokens_map.json β special_tokens_map.json
RENAMED
|
File without changes
|
src/streamlit_app.py β streamlit_app.py
RENAMED
|
@@ -73,8 +73,8 @@ def load_json_file(filename):
|
|
| 73 |
|
| 74 |
|
| 75 |
pipe = load_huggingface_model()
|
| 76 |
-
METADATA = load_json_file("
|
| 77 |
-
PROBLEMATIC_CNOS = load_json_file("
|
| 78 |
|
| 79 |
|
| 80 |
def run_inference(text_input):
|
|
@@ -117,7 +117,7 @@ st.sidebar.markdown(
|
|
| 117 |
|
| 118 |
|
| 119 |
def init_state() -> None:
|
| 120 |
-
defaults = load_json_file("
|
| 121 |
for k, v in defaults.items():
|
| 122 |
st.session_state.setdefault(k, v)
|
| 123 |
|
|
|
|
| 73 |
|
| 74 |
|
| 75 |
pipe = load_huggingface_model()
|
| 76 |
+
METADATA = load_json_file("data/metadata.json")
|
| 77 |
+
PROBLEMATIC_CNOS = load_json_file("data/problematic_cnos.json")
|
| 78 |
|
| 79 |
|
| 80 |
def run_inference(text_input):
|
|
|
|
| 117 |
|
| 118 |
|
| 119 |
def init_state() -> None:
|
| 120 |
+
defaults = load_json_file("data/defaults_session_state.json")
|
| 121 |
for k, v in defaults.items():
|
| 122 |
st.session_state.setdefault(k, v)
|
| 123 |
|
src/tokenizer.json β tokenizer.json
RENAMED
|
File without changes
|
src/tokenizer_config.json β tokenizer_config.json
RENAMED
|
File without changes
|
src/training_args.bin β training_args.bin
RENAMED
|
File without changes
|
{src/utils β utils}/__init__.py
RENAMED
|
File without changes
|
{src/utils β utils}/cno_utils.py
RENAMED
|
File without changes
|