noahsettersten's picture
chore: Address Credo messages
59fddbd
raw
history blame
3.65 kB
defmodule MedicalTranscriptionWeb.HomeLive.Index.SampleResults do
@moduledoc """
Contains sample data that can be displayed in HomeLive for prototyping UI.
To test the success UI, replace the status assignment with:
status: :success
And the `transcription_rows` stream with:
|> stream(:transcription_rows, MedicalTranscriptionWeb.HomeLive.Index.SampleResults.get_sample_results())
"""
alias AudioTagger.Structs.TagResult
def get_sample_results do
[
%{
id: 0,
start_mark: "00:00:00",
end_mark: "00:00:07",
text:
"This 55-year-old man with known coronary artery disease comes for a follow-up visit today.",
tags: [
%TagResult{
code: "74685",
label: "Coronary artery anomaly",
score: 0.892520010471344
},
%TagResult{
code: "41412",
label: "Dissection of coronary artery",
score: 0.8386646509170532
},
%TagResult{
code: "V717",
label: "Observation for suspected cardiovascular disease",
score: 0.8203237056732178
},
%TagResult{
code: "41400",
label: "Coronary atherosclerosis of unspecified type of vessel, native or graft",
score: 0.8200777173042297
},
%TagResult{
code: "V812",
label: "Screening for other and unspecified cardiovascular conditions",
score: 0.8076164722442627
}
]
},
%{
id: 1,
start_mark: "00:00:07",
end_mark: "00:00:11",
text: "Last month he was admitted to our hospital with unstable angina.",
tags: [
%TagResult{code: "4381", label: "Angiopathy in other dis", score: 0.8538626432418823},
%TagResult{code: "131", label: "Prinzmetal angina", score: 0.8411313891410828},
%TagResult{code: "130", label: "Angina decubitus", score: 0.8362892270088196},
%TagResult{code: "6985", label: "Angio intes w hmrhg", score: 0.8048261404037476},
%TagResult{code: "139", label: "Angina pectoris NEC/NOS", score: 0.7996218800544739}
]
},
%{
id: 2,
start_mark: "00:00:11",
end_mark: "00:00:15",
text: "He underwent heart catheterization on November 15th, 2007.",
tags: [
%TagResult{code: "8716", label: "FB post heart catheter", score: 0.8772457242012024},
%TagResult{code: "8705", label: "Acc cut/hem w catheteriz", score: 0.8552037477493286},
%TagResult{code: "5881", label: "Fit/adj vascular cathetr", score: 0.8404607772827148},
%TagResult{code: "6112", label: "Heart laceration-open", score: 0.834895133972168},
%TagResult{code: "6102", label: "Heart laceration-closed", score: 0.8253614902496338}
]
},
%{
id: 3,
start_mark: "00:00:15",
end_mark: "00:00:22",
text:
"At that time he was found to have a tight 99% proxmost enosis, total occlusion and collateralization",
tags: [
%TagResult{code: "641", label: "No proc/contraindication", score: 0.8215043544769287},
%TagResult{code: "643", label: "No proc for reasons NEC", score: 0.8145027160644531},
%TagResult{code: "416", label: "Proteus infection NOS", score: 0.8083868622779846},
%TagResult{code: "019", label: "Prostatitis NOS", score: 0.8061345815658569},
%TagResult{code: "5270", label: "Prolapsed arm-unspec", score: 0.8031538128852844}
]
}
]
end
end