diff --git a/sleep_assessment/cases/case1/case1_01.json b/sleep_assessment/cases/case1/case1_01.json new file mode 100644 index 0000000000000000000000000000000000000000..856c183d8a167f648bbcbdb9e7c1b99b607acbf2 --- /dev/null +++ b/sleep_assessment/cases/case1/case1_01.json @@ -0,0 +1,27 @@ +{ + "meta_info": { + "case_id": "ISRUC_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "ISRUC" + }, + "agent_input": { + "instruction": "Please use the provided sleep-stage label file to calculate the Sleep Onset Latency (SOL) for the provided sleep EEG/PSG recording. SOL is defined as the time in minutes from the first scored 30-second epoch to the first sleep epoch (N1, N2, N3, or REM). Please clearly state the final SOL value in minutes in your response.", + "label_path": "data/sleep/ISRUC_01.npy" + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the Sleep Onset Latency (SOL) value in minutes from the agent's report. SOL is defined in this benchmark as the time from the first scored 30-second epoch to the first sleep epoch.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key in the JSON must be EXACTLY \"sleep_onset_latency_min\".\n5. The value must be a FLOAT in minutes.\n6. If the value is missing or cannot be found, return {\"sleep_onset_latency_min\": null}.\n\n### OUTPUT TEMPLATE\n{\"sleep_onset_latency_min\": }", + "metrics": [ + { + "metric_id": "sleep_onset_latency_accuracy", + "type": "numeric_check", + "target_key": "sleep_onset_latency_min", + "weight": 100, + "params": { + "gt_value": 5.5, + "tolerance": 2.0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case1/case1_02.json b/sleep_assessment/cases/case1/case1_02.json new file mode 100644 index 0000000000000000000000000000000000000000..551aa4180a58609764e0fe9653a8b20c3f911a8d --- /dev/null +++ b/sleep_assessment/cases/case1/case1_02.json @@ -0,0 +1,27 @@ +{ + "meta_info": { + "case_id": "ISRUC_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "ISRUC" + }, + "agent_input": { + "instruction": "Please use the provided sleep-stage label file to calculate the Sleep Onset Latency (SOL) for the provided sleep EEG/PSG recording. SOL is defined as the time in minutes from the first scored 30-second epoch to the first sleep epoch (N1, N2, N3, or REM). Please clearly state the final SOL value in minutes in your response.", + "label_path": "data/sleep/ISRUC_02.npy" + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the Sleep Onset Latency (SOL) value in minutes from the agent's report. SOL is defined in this benchmark as the time from the first scored 30-second epoch to the first sleep epoch.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key in the JSON must be EXACTLY \"sleep_onset_latency_min\".\n5. The value must be a FLOAT in minutes.\n6. If the value is missing or cannot be found, return {\"sleep_onset_latency_min\": null}.\n\n### OUTPUT TEMPLATE\n{\"sleep_onset_latency_min\": }", + "metrics": [ + { + "metric_id": "sleep_onset_latency_accuracy", + "type": "numeric_check", + "target_key": "sleep_onset_latency_min", + "weight": 100, + "params": { + "gt_value": 55.0, + "tolerance": 2.0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case1/case1_03.json b/sleep_assessment/cases/case1/case1_03.json new file mode 100644 index 0000000000000000000000000000000000000000..31701d7d40f4be49f88af9141b7b94eab4195bc5 --- /dev/null +++ b/sleep_assessment/cases/case1/case1_03.json @@ -0,0 +1,27 @@ +{ + "meta_info": { + "case_id": "ISRUC_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "ISRUC" + }, + "agent_input": { + "instruction": "Please use the provided sleep-stage label file to calculate the Sleep Onset Latency (SOL) for the provided sleep EEG/PSG recording. SOL is defined as the time in minutes from the first scored 30-second epoch to the first sleep epoch (N1, N2, N3, or REM). Please clearly state the final SOL value in minutes in your response.", + "label_path": "data/sleep/ISRUC_03.npy" + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the Sleep Onset Latency (SOL) value in minutes from the agent's report. SOL is defined in this benchmark as the time from the first scored 30-second epoch to the first sleep epoch.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key in the JSON must be EXACTLY \"sleep_onset_latency_min\".\n5. The value must be a FLOAT in minutes.\n6. If the value is missing or cannot be found, return {\"sleep_onset_latency_min\": null}.\n\n### OUTPUT TEMPLATE\n{\"sleep_onset_latency_min\": }", + "metrics": [ + { + "metric_id": "sleep_onset_latency_accuracy", + "type": "numeric_check", + "target_key": "sleep_onset_latency_min", + "weight": 100, + "params": { + "gt_value": 3.5, + "tolerance": 2.0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case1/case1_04.json b/sleep_assessment/cases/case1/case1_04.json new file mode 100644 index 0000000000000000000000000000000000000000..29aa3f6515b3e377c17e6647a369f64e6ce9475f --- /dev/null +++ b/sleep_assessment/cases/case1/case1_04.json @@ -0,0 +1,27 @@ +{ + "meta_info": { + "case_id": "ISRUC_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "ISRUC" + }, + "agent_input": { + "instruction": "Please use the provided sleep-stage label file to calculate the Sleep Onset Latency (SOL) for the provided sleep EEG/PSG recording. SOL is defined as the time in minutes from the first scored 30-second epoch to the first sleep epoch (N1, N2, N3, or REM). Please clearly state the final SOL value in minutes in your response.", + "label_path": "data/sleep/ISRUC_04.npy" + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the Sleep Onset Latency (SOL) value in minutes from the agent's report. SOL is defined in this benchmark as the time from the first scored 30-second epoch to the first sleep epoch.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key in the JSON must be EXACTLY \"sleep_onset_latency_min\".\n5. The value must be a FLOAT in minutes.\n6. If the value is missing or cannot be found, return {\"sleep_onset_latency_min\": null}.\n\n### OUTPUT TEMPLATE\n{\"sleep_onset_latency_min\": }", + "metrics": [ + { + "metric_id": "sleep_onset_latency_accuracy", + "type": "numeric_check", + "target_key": "sleep_onset_latency_min", + "weight": 100, + "params": { + "gt_value": 1.0, + "tolerance": 2.0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case1/case1_05.json b/sleep_assessment/cases/case1/case1_05.json new file mode 100644 index 0000000000000000000000000000000000000000..d77500a4e69e7acf2c0d9995972d5ea4fc3b8458 --- /dev/null +++ b/sleep_assessment/cases/case1/case1_05.json @@ -0,0 +1,27 @@ +{ + "meta_info": { + "case_id": "ISRUC_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "ISRUC" + }, + "agent_input": { + "instruction": "Please use the provided sleep-stage label file to calculate the Sleep Onset Latency (SOL) for the provided sleep EEG/PSG recording. SOL is defined as the time in minutes from the first scored 30-second epoch to the first sleep epoch (N1, N2, N3, or REM). Please clearly state the final SOL value in minutes in your response.", + "label_path": "data/sleep/ISRUC_05.npy" + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the Sleep Onset Latency (SOL) value in minutes from the agent's report. SOL is defined in this benchmark as the time from the first scored 30-second epoch to the first sleep epoch.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key in the JSON must be EXACTLY \"sleep_onset_latency_min\".\n5. The value must be a FLOAT in minutes.\n6. If the value is missing or cannot be found, return {\"sleep_onset_latency_min\": null}.\n\n### OUTPUT TEMPLATE\n{\"sleep_onset_latency_min\": }", + "metrics": [ + { + "metric_id": "sleep_onset_latency_accuracy", + "type": "numeric_check", + "target_key": "sleep_onset_latency_min", + "weight": 100, + "params": { + "gt_value": 75.0, + "tolerance": 2.0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case1/case1_06.json b/sleep_assessment/cases/case1/case1_06.json new file mode 100644 index 0000000000000000000000000000000000000000..af6e9a26287715c29787f5a3c56f8742ff1642ed --- /dev/null +++ b/sleep_assessment/cases/case1/case1_06.json @@ -0,0 +1,27 @@ +{ + "meta_info": { + "case_id": "HMC_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "HMC" + }, + "agent_input": { + "instruction": "Please use the provided sleep-stage label file to calculate the Sleep Onset Latency (SOL) for the provided sleep EEG/PSG recording. SOL is defined as the time in minutes from the first scored 30-second epoch to the first sleep epoch (N1, N2, N3, or REM). Please clearly state the final SOL value in minutes in your response.", + "label_path": "data/sleep/HMC_01.npy" + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the Sleep Onset Latency (SOL) value in minutes from the agent's report. SOL is defined in this benchmark as the time from the first scored 30-second epoch to the first sleep epoch.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key in the JSON must be EXACTLY \"sleep_onset_latency_min\".\n5. The value must be a FLOAT in minutes.\n6. If the value is missing or cannot be found, return {\"sleep_onset_latency_min\": null}.\n\n### OUTPUT TEMPLATE\n{\"sleep_onset_latency_min\": }", + "metrics": [ + { + "metric_id": "sleep_onset_latency_accuracy", + "type": "numeric_check", + "target_key": "sleep_onset_latency_min", + "weight": 100, + "params": { + "gt_value": 4.0, + "tolerance": 2.0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case1/case1_07.json b/sleep_assessment/cases/case1/case1_07.json new file mode 100644 index 0000000000000000000000000000000000000000..f118ded3d54196df439a1c314d6c83ab42e0f9df --- /dev/null +++ b/sleep_assessment/cases/case1/case1_07.json @@ -0,0 +1,27 @@ +{ + "meta_info": { + "case_id": "HMC_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "HMC" + }, + "agent_input": { + "instruction": "Please use the provided sleep-stage label file to calculate the Sleep Onset Latency (SOL) for the provided sleep EEG/PSG recording. SOL is defined as the time in minutes from the first scored 30-second epoch to the first sleep epoch (N1, N2, N3, or REM). Please clearly state the final SOL value in minutes in your response.", + "label_path": "data/sleep/HMC_02.npy" + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the Sleep Onset Latency (SOL) value in minutes from the agent's report. SOL is defined in this benchmark as the time from the first scored 30-second epoch to the first sleep epoch.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key in the JSON must be EXACTLY \"sleep_onset_latency_min\".\n5. The value must be a FLOAT in minutes.\n6. If the value is missing or cannot be found, return {\"sleep_onset_latency_min\": null}.\n\n### OUTPUT TEMPLATE\n{\"sleep_onset_latency_min\": }", + "metrics": [ + { + "metric_id": "sleep_onset_latency_accuracy", + "type": "numeric_check", + "target_key": "sleep_onset_latency_min", + "weight": 100, + "params": { + "gt_value": 3.0, + "tolerance": 2.0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case1/case1_08.json b/sleep_assessment/cases/case1/case1_08.json new file mode 100644 index 0000000000000000000000000000000000000000..11b3292f117ef35620028d0944fedba60f6024ae --- /dev/null +++ b/sleep_assessment/cases/case1/case1_08.json @@ -0,0 +1,27 @@ +{ + "meta_info": { + "case_id": "HMC_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "HMC" + }, + "agent_input": { + "instruction": "Please use the provided sleep-stage label file to calculate the Sleep Onset Latency (SOL) for the provided sleep EEG/PSG recording. SOL is defined as the time in minutes from the first scored 30-second epoch to the first sleep epoch (N1, N2, N3, or REM). Please clearly state the final SOL value in minutes in your response.", + "label_path": "data/sleep/HMC_03.npy" + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the Sleep Onset Latency (SOL) value in minutes from the agent's report. SOL is defined in this benchmark as the time from the first scored 30-second epoch to the first sleep epoch.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key in the JSON must be EXACTLY \"sleep_onset_latency_min\".\n5. The value must be a FLOAT in minutes.\n6. If the value is missing or cannot be found, return {\"sleep_onset_latency_min\": null}.\n\n### OUTPUT TEMPLATE\n{\"sleep_onset_latency_min\": }", + "metrics": [ + { + "metric_id": "sleep_onset_latency_accuracy", + "type": "numeric_check", + "target_key": "sleep_onset_latency_min", + "weight": 100, + "params": { + "gt_value": 1.5, + "tolerance": 2.0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case1/case1_09.json b/sleep_assessment/cases/case1/case1_09.json new file mode 100644 index 0000000000000000000000000000000000000000..30dfc6dbd3346fd16caa203f62f7dcff1f941f99 --- /dev/null +++ b/sleep_assessment/cases/case1/case1_09.json @@ -0,0 +1,27 @@ +{ + "meta_info": { + "case_id": "HMC_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "HMC" + }, + "agent_input": { + "instruction": "Please use the provided sleep-stage label file to calculate the Sleep Onset Latency (SOL) for the provided sleep EEG/PSG recording. SOL is defined as the time in minutes from the first scored 30-second epoch to the first sleep epoch (N1, N2, N3, or REM). Please clearly state the final SOL value in minutes in your response.", + "label_path": "data/sleep/HMC_04.npy" + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the Sleep Onset Latency (SOL) value in minutes from the agent's report. SOL is defined in this benchmark as the time from the first scored 30-second epoch to the first sleep epoch.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key in the JSON must be EXACTLY \"sleep_onset_latency_min\".\n5. The value must be a FLOAT in minutes.\n6. If the value is missing or cannot be found, return {\"sleep_onset_latency_min\": null}.\n\n### OUTPUT TEMPLATE\n{\"sleep_onset_latency_min\": }", + "metrics": [ + { + "metric_id": "sleep_onset_latency_accuracy", + "type": "numeric_check", + "target_key": "sleep_onset_latency_min", + "weight": 100, + "params": { + "gt_value": 3.0, + "tolerance": 2.0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case1/case1_10.json b/sleep_assessment/cases/case1/case1_10.json new file mode 100644 index 0000000000000000000000000000000000000000..bdaca0ec5a138f750040457d96afa6f68bfdd44c --- /dev/null +++ b/sleep_assessment/cases/case1/case1_10.json @@ -0,0 +1,27 @@ +{ + "meta_info": { + "case_id": "HMC_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "HMC" + }, + "agent_input": { + "instruction": "Please use the provided sleep-stage label file to calculate the Sleep Onset Latency (SOL) for the provided sleep EEG/PSG recording. SOL is defined as the time in minutes from the first scored 30-second epoch to the first sleep epoch (N1, N2, N3, or REM). Please clearly state the final SOL value in minutes in your response.", + "label_path": "data/sleep/HMC_05.npy" + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the Sleep Onset Latency (SOL) value in minutes from the agent's report. SOL is defined in this benchmark as the time from the first scored 30-second epoch to the first sleep epoch.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key in the JSON must be EXACTLY \"sleep_onset_latency_min\".\n5. The value must be a FLOAT in minutes.\n6. If the value is missing or cannot be found, return {\"sleep_onset_latency_min\": null}.\n\n### OUTPUT TEMPLATE\n{\"sleep_onset_latency_min\": }", + "metrics": [ + { + "metric_id": "sleep_onset_latency_accuracy", + "type": "numeric_check", + "target_key": "sleep_onset_latency_min", + "weight": 100, + "params": { + "gt_value": 22.0, + "tolerance": 2.0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case1/case1_11.json b/sleep_assessment/cases/case1/case1_11.json new file mode 100644 index 0000000000000000000000000000000000000000..a72386ed162819b9ea58d5fd15c0c363837d4b6f --- /dev/null +++ b/sleep_assessment/cases/case1/case1_11.json @@ -0,0 +1,27 @@ +{ + "meta_info": { + "case_id": "SHHS1_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "SHHS1" + }, + "agent_input": { + "instruction": "Please use the provided sleep-stage label file to calculate the Sleep Onset Latency (SOL) for the provided sleep EEG/PSG recording. SOL is defined as the time in minutes from the first scored 30-second epoch to the first sleep epoch (N1, N2, N3, or REM). Please clearly state the final SOL value in minutes in your response.", + "label_path": "data/sleep/SHHS1_01.npy" + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the Sleep Onset Latency (SOL) value in minutes from the agent's report. SOL is defined in this benchmark as the time from the first scored 30-second epoch to the first sleep epoch.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key in the JSON must be EXACTLY \"sleep_onset_latency_min\".\n5. The value must be a FLOAT in minutes.\n6. If the value is missing or cannot be found, return {\"sleep_onset_latency_min\": null}.\n\n### OUTPUT TEMPLATE\n{\"sleep_onset_latency_min\": }", + "metrics": [ + { + "metric_id": "sleep_onset_latency_accuracy", + "type": "numeric_check", + "target_key": "sleep_onset_latency_min", + "weight": 100, + "params": { + "gt_value": 14.0, + "tolerance": 2.0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case1/case1_12.json b/sleep_assessment/cases/case1/case1_12.json new file mode 100644 index 0000000000000000000000000000000000000000..a4f57e20ac397906a8b668055ea2339bc29d1743 --- /dev/null +++ b/sleep_assessment/cases/case1/case1_12.json @@ -0,0 +1,27 @@ +{ + "meta_info": { + "case_id": "SHHS1_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "SHHS1" + }, + "agent_input": { + "instruction": "Please use the provided sleep-stage label file to calculate the Sleep Onset Latency (SOL) for the provided sleep EEG/PSG recording. SOL is defined as the time in minutes from the first scored 30-second epoch to the first sleep epoch (N1, N2, N3, or REM). Please clearly state the final SOL value in minutes in your response.", + "label_path": "data/sleep/SHHS1_02.npy" + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the Sleep Onset Latency (SOL) value in minutes from the agent's report. SOL is defined in this benchmark as the time from the first scored 30-second epoch to the first sleep epoch.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key in the JSON must be EXACTLY \"sleep_onset_latency_min\".\n5. The value must be a FLOAT in minutes.\n6. If the value is missing or cannot be found, return {\"sleep_onset_latency_min\": null}.\n\n### OUTPUT TEMPLATE\n{\"sleep_onset_latency_min\": }", + "metrics": [ + { + "metric_id": "sleep_onset_latency_accuracy", + "type": "numeric_check", + "target_key": "sleep_onset_latency_min", + "weight": 100, + "params": { + "gt_value": 0.0, + "tolerance": 2.0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case1/case1_13.json b/sleep_assessment/cases/case1/case1_13.json new file mode 100644 index 0000000000000000000000000000000000000000..099c3452496c2ba86ba8aa249e19fb049373e509 --- /dev/null +++ b/sleep_assessment/cases/case1/case1_13.json @@ -0,0 +1,27 @@ +{ + "meta_info": { + "case_id": "SHHS1_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "SHHS1" + }, + "agent_input": { + "instruction": "Please use the provided sleep-stage label file to calculate the Sleep Onset Latency (SOL) for the provided sleep EEG/PSG recording. SOL is defined as the time in minutes from the first scored 30-second epoch to the first sleep epoch (N1, N2, N3, or REM). Please clearly state the final SOL value in minutes in your response.", + "label_path": "data/sleep/SHHS1_03.npy" + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the Sleep Onset Latency (SOL) value in minutes from the agent's report. SOL is defined in this benchmark as the time from the first scored 30-second epoch to the first sleep epoch.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key in the JSON must be EXACTLY \"sleep_onset_latency_min\".\n5. The value must be a FLOAT in minutes.\n6. If the value is missing or cannot be found, return {\"sleep_onset_latency_min\": null}.\n\n### OUTPUT TEMPLATE\n{\"sleep_onset_latency_min\": }", + "metrics": [ + { + "metric_id": "sleep_onset_latency_accuracy", + "type": "numeric_check", + "target_key": "sleep_onset_latency_min", + "weight": 100, + "params": { + "gt_value": 83.5, + "tolerance": 2.0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case1/case1_14.json b/sleep_assessment/cases/case1/case1_14.json new file mode 100644 index 0000000000000000000000000000000000000000..e9e52dbfb67f74f9073632a0994b00b9aa3ef7cc --- /dev/null +++ b/sleep_assessment/cases/case1/case1_14.json @@ -0,0 +1,27 @@ +{ + "meta_info": { + "case_id": "SHHS1_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "SHHS1" + }, + "agent_input": { + "instruction": "Please use the provided sleep-stage label file to calculate the Sleep Onset Latency (SOL) for the provided sleep EEG/PSG recording. SOL is defined as the time in minutes from the first scored 30-second epoch to the first sleep epoch (N1, N2, N3, or REM). Please clearly state the final SOL value in minutes in your response.", + "label_path": "data/sleep/SHHS1_04.npy" + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the Sleep Onset Latency (SOL) value in minutes from the agent's report. SOL is defined in this benchmark as the time from the first scored 30-second epoch to the first sleep epoch.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key in the JSON must be EXACTLY \"sleep_onset_latency_min\".\n5. The value must be a FLOAT in minutes.\n6. If the value is missing or cannot be found, return {\"sleep_onset_latency_min\": null}.\n\n### OUTPUT TEMPLATE\n{\"sleep_onset_latency_min\": }", + "metrics": [ + { + "metric_id": "sleep_onset_latency_accuracy", + "type": "numeric_check", + "target_key": "sleep_onset_latency_min", + "weight": 100, + "params": { + "gt_value": 41.0, + "tolerance": 2.0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case1/case1_15.json b/sleep_assessment/cases/case1/case1_15.json new file mode 100644 index 0000000000000000000000000000000000000000..d5c91122d07c521a0530d4112a360e2791b91c83 --- /dev/null +++ b/sleep_assessment/cases/case1/case1_15.json @@ -0,0 +1,27 @@ +{ + "meta_info": { + "case_id": "SHHS1_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "SHHS1" + }, + "agent_input": { + "instruction": "Please use the provided sleep-stage label file to calculate the Sleep Onset Latency (SOL) for the provided sleep EEG/PSG recording. SOL is defined as the time in minutes from the first scored 30-second epoch to the first sleep epoch (N1, N2, N3, or REM). Please clearly state the final SOL value in minutes in your response.", + "label_path": "data/sleep/SHHS1_05.npy" + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the Sleep Onset Latency (SOL) value in minutes from the agent's report. SOL is defined in this benchmark as the time from the first scored 30-second epoch to the first sleep epoch.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key in the JSON must be EXACTLY \"sleep_onset_latency_min\".\n5. The value must be a FLOAT in minutes.\n6. If the value is missing or cannot be found, return {\"sleep_onset_latency_min\": null}.\n\n### OUTPUT TEMPLATE\n{\"sleep_onset_latency_min\": }", + "metrics": [ + { + "metric_id": "sleep_onset_latency_accuracy", + "type": "numeric_check", + "target_key": "sleep_onset_latency_min", + "weight": 100, + "params": { + "gt_value": 10.0, + "tolerance": 2.0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case1/case1_16.json b/sleep_assessment/cases/case1/case1_16.json new file mode 100644 index 0000000000000000000000000000000000000000..442ab0c15c811b5bbd8a75d556b53d1c9c5bb247 --- /dev/null +++ b/sleep_assessment/cases/case1/case1_16.json @@ -0,0 +1,27 @@ +{ + "meta_info": { + "case_id": "MASSSS3_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "instruction": "Please use the provided sleep-stage label file to calculate the Sleep Onset Latency (SOL) for the provided sleep EEG/PSG recording. SOL is defined as the time in minutes from the first scored 30-second epoch to the first sleep epoch (N1, N2, N3, or REM). Please clearly state the final SOL value in minutes in your response.", + "label_path": "data/sleep/MASSSS3_01.npy" + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the Sleep Onset Latency (SOL) value in minutes from the agent's report. SOL is defined in this benchmark as the time from the first scored 30-second epoch to the first sleep epoch.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key in the JSON must be EXACTLY \"sleep_onset_latency_min\".\n5. The value must be a FLOAT in minutes.\n6. If the value is missing or cannot be found, return {\"sleep_onset_latency_min\": null}.\n\n### OUTPUT TEMPLATE\n{\"sleep_onset_latency_min\": }", + "metrics": [ + { + "metric_id": "sleep_onset_latency_accuracy", + "type": "numeric_check", + "target_key": "sleep_onset_latency_min", + "weight": 100, + "params": { + "gt_value": 3.5, + "tolerance": 2.0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case1/case1_17.json b/sleep_assessment/cases/case1/case1_17.json new file mode 100644 index 0000000000000000000000000000000000000000..f758c7471e724d71fc66d9457afde45399dbd27f --- /dev/null +++ b/sleep_assessment/cases/case1/case1_17.json @@ -0,0 +1,27 @@ +{ + "meta_info": { + "case_id": "MASSSS3_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "instruction": "Please use the provided sleep-stage label file to calculate the Sleep Onset Latency (SOL) for the provided sleep EEG/PSG recording. SOL is defined as the time in minutes from the first scored 30-second epoch to the first sleep epoch (N1, N2, N3, or REM). Please clearly state the final SOL value in minutes in your response.", + "label_path": "data/sleep/MASSSS3_02.npy" + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the Sleep Onset Latency (SOL) value in minutes from the agent's report. SOL is defined in this benchmark as the time from the first scored 30-second epoch to the first sleep epoch.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key in the JSON must be EXACTLY \"sleep_onset_latency_min\".\n5. The value must be a FLOAT in minutes.\n6. If the value is missing or cannot be found, return {\"sleep_onset_latency_min\": null}.\n\n### OUTPUT TEMPLATE\n{\"sleep_onset_latency_min\": }", + "metrics": [ + { + "metric_id": "sleep_onset_latency_accuracy", + "type": "numeric_check", + "target_key": "sleep_onset_latency_min", + "weight": 100, + "params": { + "gt_value": 21.0, + "tolerance": 2.0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case1/case1_18.json b/sleep_assessment/cases/case1/case1_18.json new file mode 100644 index 0000000000000000000000000000000000000000..647b67fdfd0c53f080eb1ecd9afb1ebf64138818 --- /dev/null +++ b/sleep_assessment/cases/case1/case1_18.json @@ -0,0 +1,27 @@ +{ + "meta_info": { + "case_id": "MASSSS3_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "instruction": "Please use the provided sleep-stage label file to calculate the Sleep Onset Latency (SOL) for the provided sleep EEG/PSG recording. SOL is defined as the time in minutes from the first scored 30-second epoch to the first sleep epoch (N1, N2, N3, or REM). Please clearly state the final SOL value in minutes in your response.", + "label_path": "data/sleep/MASSSS3_03.npy" + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the Sleep Onset Latency (SOL) value in minutes from the agent's report. SOL is defined in this benchmark as the time from the first scored 30-second epoch to the first sleep epoch.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key in the JSON must be EXACTLY \"sleep_onset_latency_min\".\n5. The value must be a FLOAT in minutes.\n6. If the value is missing or cannot be found, return {\"sleep_onset_latency_min\": null}.\n\n### OUTPUT TEMPLATE\n{\"sleep_onset_latency_min\": }", + "metrics": [ + { + "metric_id": "sleep_onset_latency_accuracy", + "type": "numeric_check", + "target_key": "sleep_onset_latency_min", + "weight": 100, + "params": { + "gt_value": 7.0, + "tolerance": 2.0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case1/case1_19.json b/sleep_assessment/cases/case1/case1_19.json new file mode 100644 index 0000000000000000000000000000000000000000..df74312d3659193edc99990903b0d5aa0e4de81d --- /dev/null +++ b/sleep_assessment/cases/case1/case1_19.json @@ -0,0 +1,27 @@ +{ + "meta_info": { + "case_id": "MASSSS3_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "instruction": "Please use the provided sleep-stage label file to calculate the Sleep Onset Latency (SOL) for the provided sleep EEG/PSG recording. SOL is defined as the time in minutes from the first scored 30-second epoch to the first sleep epoch (N1, N2, N3, or REM). Please clearly state the final SOL value in minutes in your response.", + "label_path": "data/sleep/MASSSS3_04.npy" + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the Sleep Onset Latency (SOL) value in minutes from the agent's report. SOL is defined in this benchmark as the time from the first scored 30-second epoch to the first sleep epoch.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key in the JSON must be EXACTLY \"sleep_onset_latency_min\".\n5. The value must be a FLOAT in minutes.\n6. If the value is missing or cannot be found, return {\"sleep_onset_latency_min\": null}.\n\n### OUTPUT TEMPLATE\n{\"sleep_onset_latency_min\": }", + "metrics": [ + { + "metric_id": "sleep_onset_latency_accuracy", + "type": "numeric_check", + "target_key": "sleep_onset_latency_min", + "weight": 100, + "params": { + "gt_value": 2.0, + "tolerance": 2.0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case1/case1_20.json b/sleep_assessment/cases/case1/case1_20.json new file mode 100644 index 0000000000000000000000000000000000000000..67ab17e447a33f00346166f61f7476c9ade492f3 --- /dev/null +++ b/sleep_assessment/cases/case1/case1_20.json @@ -0,0 +1,27 @@ +{ + "meta_info": { + "case_id": "MASSSS3_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "instruction": "Please use the provided sleep-stage label file to calculate the Sleep Onset Latency (SOL) for the provided sleep EEG/PSG recording. SOL is defined as the time in minutes from the first scored 30-second epoch to the first sleep epoch (N1, N2, N3, or REM). Please clearly state the final SOL value in minutes in your response.", + "label_path": "data/sleep/MASSSS3_05.npy" + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the Sleep Onset Latency (SOL) value in minutes from the agent's report. SOL is defined in this benchmark as the time from the first scored 30-second epoch to the first sleep epoch.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key in the JSON must be EXACTLY \"sleep_onset_latency_min\".\n5. The value must be a FLOAT in minutes.\n6. If the value is missing or cannot be found, return {\"sleep_onset_latency_min\": null}.\n\n### OUTPUT TEMPLATE\n{\"sleep_onset_latency_min\": }", + "metrics": [ + { + "metric_id": "sleep_onset_latency_accuracy", + "type": "numeric_check", + "target_key": "sleep_onset_latency_min", + "weight": 100, + "params": { + "gt_value": 7.0, + "tolerance": 2.0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case1/case1_21.json b/sleep_assessment/cases/case1/case1_21.json new file mode 100644 index 0000000000000000000000000000000000000000..e1cd3431b7f3749c7673ada0f4105d8f27f9a15c --- /dev/null +++ b/sleep_assessment/cases/case1/case1_21.json @@ -0,0 +1,27 @@ +{ + "meta_info": { + "case_id": "Physionet2018_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "instruction": "Please use the provided sleep-stage label file to calculate the Sleep Onset Latency (SOL) for the provided sleep EEG/PSG recording. SOL is defined as the time in minutes from the first scored 30-second epoch to the first sleep epoch (N1, N2, N3, or REM). Please clearly state the final SOL value in minutes in your response.", + "label_path": "data/sleep/Physionet2018_01.npy" + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the Sleep Onset Latency (SOL) value in minutes from the agent's report. SOL is defined in this benchmark as the time from the first scored 30-second epoch to the first sleep epoch.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key in the JSON must be EXACTLY \"sleep_onset_latency_min\".\n5. The value must be a FLOAT in minutes.\n6. If the value is missing or cannot be found, return {\"sleep_onset_latency_min\": null}.\n\n### OUTPUT TEMPLATE\n{\"sleep_onset_latency_min\": }", + "metrics": [ + { + "metric_id": "sleep_onset_latency_accuracy", + "type": "numeric_check", + "target_key": "sleep_onset_latency_min", + "weight": 100, + "params": { + "gt_value": 4.0, + "tolerance": 2.0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case1/case1_22.json b/sleep_assessment/cases/case1/case1_22.json new file mode 100644 index 0000000000000000000000000000000000000000..507c040797260415ce3a91f64a26ff5718e3afea --- /dev/null +++ b/sleep_assessment/cases/case1/case1_22.json @@ -0,0 +1,27 @@ +{ + "meta_info": { + "case_id": "Physionet2018_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "instruction": "Please use the provided sleep-stage label file to calculate the Sleep Onset Latency (SOL) for the provided sleep EEG/PSG recording. SOL is defined as the time in minutes from the first scored 30-second epoch to the first sleep epoch (N1, N2, N3, or REM). Please clearly state the final SOL value in minutes in your response.", + "label_path": "data/sleep/Physionet2018_02.npy" + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the Sleep Onset Latency (SOL) value in minutes from the agent's report. SOL is defined in this benchmark as the time from the first scored 30-second epoch to the first sleep epoch.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key in the JSON must be EXACTLY \"sleep_onset_latency_min\".\n5. The value must be a FLOAT in minutes.\n6. If the value is missing or cannot be found, return {\"sleep_onset_latency_min\": null}.\n\n### OUTPUT TEMPLATE\n{\"sleep_onset_latency_min\": }", + "metrics": [ + { + "metric_id": "sleep_onset_latency_accuracy", + "type": "numeric_check", + "target_key": "sleep_onset_latency_min", + "weight": 100, + "params": { + "gt_value": 10.5, + "tolerance": 2.0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case1/case1_23.json b/sleep_assessment/cases/case1/case1_23.json new file mode 100644 index 0000000000000000000000000000000000000000..e9f3c90211d7dcafab0eb7588085a115324b01c3 --- /dev/null +++ b/sleep_assessment/cases/case1/case1_23.json @@ -0,0 +1,27 @@ +{ + "meta_info": { + "case_id": "Physionet2018_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "instruction": "Please use the provided sleep-stage label file to calculate the Sleep Onset Latency (SOL) for the provided sleep EEG/PSG recording. SOL is defined as the time in minutes from the first scored 30-second epoch to the first sleep epoch (N1, N2, N3, or REM). Please clearly state the final SOL value in minutes in your response.", + "label_path": "data/sleep/Physionet2018_03.npy" + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the Sleep Onset Latency (SOL) value in minutes from the agent's report. SOL is defined in this benchmark as the time from the first scored 30-second epoch to the first sleep epoch.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key in the JSON must be EXACTLY \"sleep_onset_latency_min\".\n5. The value must be a FLOAT in minutes.\n6. If the value is missing or cannot be found, return {\"sleep_onset_latency_min\": null}.\n\n### OUTPUT TEMPLATE\n{\"sleep_onset_latency_min\": }", + "metrics": [ + { + "metric_id": "sleep_onset_latency_accuracy", + "type": "numeric_check", + "target_key": "sleep_onset_latency_min", + "weight": 100, + "params": { + "gt_value": 4.0, + "tolerance": 2.0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case1/case1_24.json b/sleep_assessment/cases/case1/case1_24.json new file mode 100644 index 0000000000000000000000000000000000000000..66c036c7472a64580859297774f77d570dedcc74 --- /dev/null +++ b/sleep_assessment/cases/case1/case1_24.json @@ -0,0 +1,27 @@ +{ + "meta_info": { + "case_id": "Physionet2018_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "instruction": "Please use the provided sleep-stage label file to calculate the Sleep Onset Latency (SOL) for the provided sleep EEG/PSG recording. SOL is defined as the time in minutes from the first scored 30-second epoch to the first sleep epoch (N1, N2, N3, or REM). Please clearly state the final SOL value in minutes in your response.", + "label_path": "data/sleep/Physionet2018_04.npy" + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the Sleep Onset Latency (SOL) value in minutes from the agent's report. SOL is defined in this benchmark as the time from the first scored 30-second epoch to the first sleep epoch.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key in the JSON must be EXACTLY \"sleep_onset_latency_min\".\n5. The value must be a FLOAT in minutes.\n6. If the value is missing or cannot be found, return {\"sleep_onset_latency_min\": null}.\n\n### OUTPUT TEMPLATE\n{\"sleep_onset_latency_min\": }", + "metrics": [ + { + "metric_id": "sleep_onset_latency_accuracy", + "type": "numeric_check", + "target_key": "sleep_onset_latency_min", + "weight": 100, + "params": { + "gt_value": 0.5, + "tolerance": 2.0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case1/case1_25.json b/sleep_assessment/cases/case1/case1_25.json new file mode 100644 index 0000000000000000000000000000000000000000..124296a400b0b16b8848bd54f4c2c21704b894fb --- /dev/null +++ b/sleep_assessment/cases/case1/case1_25.json @@ -0,0 +1,27 @@ +{ + "meta_info": { + "case_id": "Physionet2018_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "instruction": "Please use the provided sleep-stage label file to calculate the Sleep Onset Latency (SOL) for the provided sleep EEG/PSG recording. SOL is defined as the time in minutes from the first scored 30-second epoch to the first sleep epoch (N1, N2, N3, or REM). Please clearly state the final SOL value in minutes in your response.", + "label_path": "data/sleep/Physionet2018_05.npy" + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the Sleep Onset Latency (SOL) value in minutes from the agent's report. SOL is defined in this benchmark as the time from the first scored 30-second epoch to the first sleep epoch.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key in the JSON must be EXACTLY \"sleep_onset_latency_min\".\n5. The value must be a FLOAT in minutes.\n6. If the value is missing or cannot be found, return {\"sleep_onset_latency_min\": null}.\n\n### OUTPUT TEMPLATE\n{\"sleep_onset_latency_min\": }", + "metrics": [ + { + "metric_id": "sleep_onset_latency_accuracy", + "type": "numeric_check", + "target_key": "sleep_onset_latency_min", + "weight": 100, + "params": { + "gt_value": 1.0, + "tolerance": 2.0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case2/case2_01.json b/sleep_assessment/cases/case2/case2_01.json new file mode 100644 index 0000000000000000000000000000000000000000..089b69cb9e979a552d32606fc1f13a198b86c6f5 --- /dev/null +++ b/sleep_assessment/cases/case2/case2_01.json @@ -0,0 +1,44 @@ +{ + "meta_info": { + "case_id": "ISRUC_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "ISRUC" + }, + "agent_input": { + "data_path": "data/sleep/ISRUC_01.edf", + "instruction": "Please inspect the provided raw sleep EEG/PSG file. Report the total number of channels in the file, and list all EEG channels that can be used for sleep analysis. Use the original channel names exactly as they appear in the raw file. Do not include EOG, EMG, ECG, respiratory, SpO2/SaO2, light, position, or other auxiliary channels in the EEG channel list." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep EEG/PSG reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two outputs from the agent report:\n1) the total number of channels in the raw file\n2) the list of all EEG channels using original raw-file channel names\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text or explanations.\n4. The keys must be EXACTLY \"channel_count\" and \"eeg_channels\".\n5. \"channel_count\" must be an INTEGER or null.\n6. \"eeg_channels\" must be a JSON array of strings or null.\n7. Preserve original EEG channel names exactly as written in the raw file.\n8. Do NOT normalize references, casing, spacing, parentheses, hyphens, or symbols.\n9. Do NOT include EOG, EMG, ECG, respiratory, SpO2/SaO2, light, position, or auxiliary channels in \"eeg_channels\".\n10. For SHHS1 reports, only \"EEG(sec)\" and \"EEG\" count as EEG channels; \"THOR RES\", \"POSITION\", and \"OX stat\" are not EEG channels.\n11. Remove duplicate EEG channel names if the report repeats them.\n12. If one value is missing or unclear, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"channel_count\": , \"eeg_channels\": }", + "metrics": [ + { + "metric_id": "channel_count_accuracy", + "type": "numeric_check", + "target_key": "channel_count", + "weight": 30, + "params": { + "gt_value": 19, + "tolerance": 0.1 + } + }, + { + "metric_id": "eeg_channel_set_match", + "type": "set_match_check", + "target_key": "eeg_channels", + "weight": 70, + "params": { + "gt_value": [ + "F3-A2", + "C3-A2", + "O1-A2", + "F4-A1", + "C4-A1", + "O2-A1" + ], + "match_mode": "exact" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case2/case2_02.json b/sleep_assessment/cases/case2/case2_02.json new file mode 100644 index 0000000000000000000000000000000000000000..50e05304ebf2e686cdaa1835c2a829ce2fbd1172 --- /dev/null +++ b/sleep_assessment/cases/case2/case2_02.json @@ -0,0 +1,44 @@ +{ + "meta_info": { + "case_id": "ISRUC_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "ISRUC" + }, + "agent_input": { + "data_path": "data/sleep/ISRUC_02.edf", + "instruction": "Please inspect the provided raw sleep EEG/PSG file. Report the total number of channels in the file, and list all EEG channels that can be used for sleep analysis. Use the original channel names exactly as they appear in the raw file. Do not include EOG, EMG, ECG, respiratory, SpO2/SaO2, light, position, or other auxiliary channels in the EEG channel list." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep EEG/PSG reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two outputs from the agent report:\n1) the total number of channels in the raw file\n2) the list of all EEG channels using original raw-file channel names\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text or explanations.\n4. The keys must be EXACTLY \"channel_count\" and \"eeg_channels\".\n5. \"channel_count\" must be an INTEGER or null.\n6. \"eeg_channels\" must be a JSON array of strings or null.\n7. Preserve original EEG channel names exactly as written in the raw file.\n8. Do NOT normalize references, casing, spacing, parentheses, hyphens, or symbols.\n9. Do NOT include EOG, EMG, ECG, respiratory, SpO2/SaO2, light, position, or auxiliary channels in \"eeg_channels\".\n10. For SHHS1 reports, only \"EEG(sec)\" and \"EEG\" count as EEG channels; \"THOR RES\", \"POSITION\", and \"OX stat\" are not EEG channels.\n11. Remove duplicate EEG channel names if the report repeats them.\n12. If one value is missing or unclear, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"channel_count\": , \"eeg_channels\": }", + "metrics": [ + { + "metric_id": "channel_count_accuracy", + "type": "numeric_check", + "target_key": "channel_count", + "weight": 30, + "params": { + "gt_value": 19, + "tolerance": 0.1 + } + }, + { + "metric_id": "eeg_channel_set_match", + "type": "set_match_check", + "target_key": "eeg_channels", + "weight": 70, + "params": { + "gt_value": [ + "F3-A2", + "C3-A2", + "O1-A2", + "F4-A1", + "C4-A1", + "O2-A1" + ], + "match_mode": "exact" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case2/case2_03.json b/sleep_assessment/cases/case2/case2_03.json new file mode 100644 index 0000000000000000000000000000000000000000..e39db6d9606a333646c2ff980b544064eac8ae99 --- /dev/null +++ b/sleep_assessment/cases/case2/case2_03.json @@ -0,0 +1,44 @@ +{ + "meta_info": { + "case_id": "ISRUC_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "ISRUC" + }, + "agent_input": { + "data_path": "data/sleep/ISRUC_03.edf", + "instruction": "Please inspect the provided raw sleep EEG/PSG file. Report the total number of channels in the file, and list all EEG channels that can be used for sleep analysis. Use the original channel names exactly as they appear in the raw file. Do not include EOG, EMG, ECG, respiratory, SpO2/SaO2, light, position, or other auxiliary channels in the EEG channel list." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep EEG/PSG reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two outputs from the agent report:\n1) the total number of channels in the raw file\n2) the list of all EEG channels using original raw-file channel names\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text or explanations.\n4. The keys must be EXACTLY \"channel_count\" and \"eeg_channels\".\n5. \"channel_count\" must be an INTEGER or null.\n6. \"eeg_channels\" must be a JSON array of strings or null.\n7. Preserve original EEG channel names exactly as written in the raw file.\n8. Do NOT normalize references, casing, spacing, parentheses, hyphens, or symbols.\n9. Do NOT include EOG, EMG, ECG, respiratory, SpO2/SaO2, light, position, or auxiliary channels in \"eeg_channels\".\n10. For SHHS1 reports, only \"EEG(sec)\" and \"EEG\" count as EEG channels; \"THOR RES\", \"POSITION\", and \"OX stat\" are not EEG channels.\n11. Remove duplicate EEG channel names if the report repeats them.\n12. If one value is missing or unclear, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"channel_count\": , \"eeg_channels\": }", + "metrics": [ + { + "metric_id": "channel_count_accuracy", + "type": "numeric_check", + "target_key": "channel_count", + "weight": 30, + "params": { + "gt_value": 19, + "tolerance": 0.1 + } + }, + { + "metric_id": "eeg_channel_set_match", + "type": "set_match_check", + "target_key": "eeg_channels", + "weight": 70, + "params": { + "gt_value": [ + "F3-A2", + "C3-A2", + "O1-A2", + "F4-A1", + "C4-A1", + "O2-A1" + ], + "match_mode": "exact" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case2/case2_04.json b/sleep_assessment/cases/case2/case2_04.json new file mode 100644 index 0000000000000000000000000000000000000000..405f399610e52fe8738cbd15c52cb9767b0fa5d6 --- /dev/null +++ b/sleep_assessment/cases/case2/case2_04.json @@ -0,0 +1,42 @@ +{ + "meta_info": { + "case_id": "HMC_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "HMC" + }, + "agent_input": { + "data_path": "data/sleep/HMC_01.edf", + "instruction": "Please inspect the provided raw sleep EEG/PSG file. Report the total number of channels in the file, and list all EEG channels that can be used for sleep analysis. Use the original channel names exactly as they appear in the raw file. Do not include EOG, EMG, ECG, respiratory, SpO2/SaO2, light, position, or other auxiliary channels in the EEG channel list." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep EEG/PSG reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two outputs from the agent report:\n1) the total number of channels in the raw file\n2) the list of all EEG channels using original raw-file channel names\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text or explanations.\n4. The keys must be EXACTLY \"channel_count\" and \"eeg_channels\".\n5. \"channel_count\" must be an INTEGER or null.\n6. \"eeg_channels\" must be a JSON array of strings or null.\n7. Preserve original EEG channel names exactly as written in the raw file.\n8. Do NOT normalize references, casing, spacing, parentheses, hyphens, or symbols.\n9. Do NOT include EOG, EMG, ECG, respiratory, SpO2/SaO2, light, position, or auxiliary channels in \"eeg_channels\".\n10. For SHHS1 reports, only \"EEG(sec)\" and \"EEG\" count as EEG channels; \"THOR RES\", \"POSITION\", and \"OX stat\" are not EEG channels.\n11. Remove duplicate EEG channel names if the report repeats them.\n12. If one value is missing or unclear, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"channel_count\": , \"eeg_channels\": }", + "metrics": [ + { + "metric_id": "channel_count_accuracy", + "type": "numeric_check", + "target_key": "channel_count", + "weight": 30, + "params": { + "gt_value": 8, + "tolerance": 0.1 + } + }, + { + "metric_id": "eeg_channel_set_match", + "type": "set_match_check", + "target_key": "eeg_channels", + "weight": 70, + "params": { + "gt_value": [ + "EEG F4-M1", + "EEG C4-M1", + "EEG O2-M1", + "EEG C3-M2" + ], + "match_mode": "exact" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case2/case2_05.json b/sleep_assessment/cases/case2/case2_05.json new file mode 100644 index 0000000000000000000000000000000000000000..107feb18f89abc8743790b233d0d8f8b4e9ab2c4 --- /dev/null +++ b/sleep_assessment/cases/case2/case2_05.json @@ -0,0 +1,42 @@ +{ + "meta_info": { + "case_id": "HMC_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "HMC" + }, + "agent_input": { + "data_path": "data/sleep/HMC_02.edf", + "instruction": "Please inspect the provided raw sleep EEG/PSG file. Report the total number of channels in the file, and list all EEG channels that can be used for sleep analysis. Use the original channel names exactly as they appear in the raw file. Do not include EOG, EMG, ECG, respiratory, SpO2/SaO2, light, position, or other auxiliary channels in the EEG channel list." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep EEG/PSG reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two outputs from the agent report:\n1) the total number of channels in the raw file\n2) the list of all EEG channels using original raw-file channel names\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text or explanations.\n4. The keys must be EXACTLY \"channel_count\" and \"eeg_channels\".\n5. \"channel_count\" must be an INTEGER or null.\n6. \"eeg_channels\" must be a JSON array of strings or null.\n7. Preserve original EEG channel names exactly as written in the raw file.\n8. Do NOT normalize references, casing, spacing, parentheses, hyphens, or symbols.\n9. Do NOT include EOG, EMG, ECG, respiratory, SpO2/SaO2, light, position, or auxiliary channels in \"eeg_channels\".\n10. For SHHS1 reports, only \"EEG(sec)\" and \"EEG\" count as EEG channels; \"THOR RES\", \"POSITION\", and \"OX stat\" are not EEG channels.\n11. Remove duplicate EEG channel names if the report repeats them.\n12. If one value is missing or unclear, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"channel_count\": , \"eeg_channels\": }", + "metrics": [ + { + "metric_id": "channel_count_accuracy", + "type": "numeric_check", + "target_key": "channel_count", + "weight": 30, + "params": { + "gt_value": 8, + "tolerance": 0.1 + } + }, + { + "metric_id": "eeg_channel_set_match", + "type": "set_match_check", + "target_key": "eeg_channels", + "weight": 70, + "params": { + "gt_value": [ + "EEG F4-M1", + "EEG C4-M1", + "EEG O2-M1", + "EEG C3-M2" + ], + "match_mode": "exact" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case2/case2_06.json b/sleep_assessment/cases/case2/case2_06.json new file mode 100644 index 0000000000000000000000000000000000000000..b28cf34a76adaeb467ca06e8e686b3d27e862986 --- /dev/null +++ b/sleep_assessment/cases/case2/case2_06.json @@ -0,0 +1,42 @@ +{ + "meta_info": { + "case_id": "HMC_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "HMC" + }, + "agent_input": { + "data_path": "data/sleep/HMC_03.edf", + "instruction": "Please inspect the provided raw sleep EEG/PSG file. Report the total number of channels in the file, and list all EEG channels that can be used for sleep analysis. Use the original channel names exactly as they appear in the raw file. Do not include EOG, EMG, ECG, respiratory, SpO2/SaO2, light, position, or other auxiliary channels in the EEG channel list." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep EEG/PSG reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two outputs from the agent report:\n1) the total number of channels in the raw file\n2) the list of all EEG channels using original raw-file channel names\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text or explanations.\n4. The keys must be EXACTLY \"channel_count\" and \"eeg_channels\".\n5. \"channel_count\" must be an INTEGER or null.\n6. \"eeg_channels\" must be a JSON array of strings or null.\n7. Preserve original EEG channel names exactly as written in the raw file.\n8. Do NOT normalize references, casing, spacing, parentheses, hyphens, or symbols.\n9. Do NOT include EOG, EMG, ECG, respiratory, SpO2/SaO2, light, position, or auxiliary channels in \"eeg_channels\".\n10. For SHHS1 reports, only \"EEG(sec)\" and \"EEG\" count as EEG channels; \"THOR RES\", \"POSITION\", and \"OX stat\" are not EEG channels.\n11. Remove duplicate EEG channel names if the report repeats them.\n12. If one value is missing or unclear, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"channel_count\": , \"eeg_channels\": }", + "metrics": [ + { + "metric_id": "channel_count_accuracy", + "type": "numeric_check", + "target_key": "channel_count", + "weight": 30, + "params": { + "gt_value": 8, + "tolerance": 0.1 + } + }, + { + "metric_id": "eeg_channel_set_match", + "type": "set_match_check", + "target_key": "eeg_channels", + "weight": 70, + "params": { + "gt_value": [ + "EEG F4-M1", + "EEG C4-M1", + "EEG O2-M1", + "EEG C3-M2" + ], + "match_mode": "exact" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case2/case2_07.json b/sleep_assessment/cases/case2/case2_07.json new file mode 100644 index 0000000000000000000000000000000000000000..48694927a80fe89b227a4e3afc3c3ec276ea3a98 --- /dev/null +++ b/sleep_assessment/cases/case2/case2_07.json @@ -0,0 +1,40 @@ +{ + "meta_info": { + "case_id": "SHHS1_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "SHHS1" + }, + "agent_input": { + "data_path": "data/sleep/SHHS1_01.edf", + "instruction": "Please inspect the provided raw sleep EEG/PSG file. Report the total number of channels in the file, and list all EEG channels that can be used for sleep analysis. Use the original channel names exactly as they appear in the raw file. Do not include EOG, EMG, ECG, respiratory, SpO2/SaO2, light, position, or other auxiliary channels in the EEG channel list." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep EEG/PSG reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two outputs from the agent report:\n1) the total number of channels in the raw file\n2) the list of all EEG channels using original raw-file channel names\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text or explanations.\n4. The keys must be EXACTLY \"channel_count\" and \"eeg_channels\".\n5. \"channel_count\" must be an INTEGER or null.\n6. \"eeg_channels\" must be a JSON array of strings or null.\n7. Preserve original EEG channel names exactly as written in the raw file.\n8. Do NOT normalize references, casing, spacing, parentheses, hyphens, or symbols.\n9. Do NOT include EOG, EMG, ECG, respiratory, SpO2/SaO2, light, position, or auxiliary channels in \"eeg_channels\".\n10. For SHHS1 reports, only \"EEG(sec)\" and \"EEG\" count as EEG channels; \"THOR RES\", \"POSITION\", and \"OX stat\" are not EEG channels.\n11. Remove duplicate EEG channel names if the report repeats them.\n12. If one value is missing or unclear, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"channel_count\": , \"eeg_channels\": }", + "metrics": [ + { + "metric_id": "channel_count_accuracy", + "type": "numeric_check", + "target_key": "channel_count", + "weight": 30, + "params": { + "gt_value": 14, + "tolerance": 0.1 + } + }, + { + "metric_id": "eeg_channel_set_match", + "type": "set_match_check", + "target_key": "eeg_channels", + "weight": 70, + "params": { + "gt_value": [ + "EEG(sec)", + "EEG" + ], + "match_mode": "exact" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case2/case2_08.json b/sleep_assessment/cases/case2/case2_08.json new file mode 100644 index 0000000000000000000000000000000000000000..9c728acbdc4a842016487b97444bce028561ca80 --- /dev/null +++ b/sleep_assessment/cases/case2/case2_08.json @@ -0,0 +1,40 @@ +{ + "meta_info": { + "case_id": "SHHS1_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "SHHS1" + }, + "agent_input": { + "data_path": "data/sleep/SHHS1_02.edf", + "instruction": "Please inspect the provided raw sleep EEG/PSG file. Report the total number of channels in the file, and list all EEG channels that can be used for sleep analysis. Use the original channel names exactly as they appear in the raw file. Do not include EOG, EMG, ECG, respiratory, SpO2/SaO2, light, position, or other auxiliary channels in the EEG channel list." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep EEG/PSG reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two outputs from the agent report:\n1) the total number of channels in the raw file\n2) the list of all EEG channels using original raw-file channel names\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text or explanations.\n4. The keys must be EXACTLY \"channel_count\" and \"eeg_channels\".\n5. \"channel_count\" must be an INTEGER or null.\n6. \"eeg_channels\" must be a JSON array of strings or null.\n7. Preserve original EEG channel names exactly as written in the raw file.\n8. Do NOT normalize references, casing, spacing, parentheses, hyphens, or symbols.\n9. Do NOT include EOG, EMG, ECG, respiratory, SpO2/SaO2, light, position, or auxiliary channels in \"eeg_channels\".\n10. For SHHS1 reports, only \"EEG(sec)\" and \"EEG\" count as EEG channels; \"THOR RES\", \"POSITION\", and \"OX stat\" are not EEG channels.\n11. Remove duplicate EEG channel names if the report repeats them.\n12. If one value is missing or unclear, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"channel_count\": , \"eeg_channels\": }", + "metrics": [ + { + "metric_id": "channel_count_accuracy", + "type": "numeric_check", + "target_key": "channel_count", + "weight": 30, + "params": { + "gt_value": 14, + "tolerance": 0.1 + } + }, + { + "metric_id": "eeg_channel_set_match", + "type": "set_match_check", + "target_key": "eeg_channels", + "weight": 70, + "params": { + "gt_value": [ + "EEG(sec)", + "EEG" + ], + "match_mode": "exact" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case2/case2_09.json b/sleep_assessment/cases/case2/case2_09.json new file mode 100644 index 0000000000000000000000000000000000000000..8d70cc6b07a509ca4d7264d8fdd57ec2021511db --- /dev/null +++ b/sleep_assessment/cases/case2/case2_09.json @@ -0,0 +1,40 @@ +{ + "meta_info": { + "case_id": "SHHS1_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "SHHS1" + }, + "agent_input": { + "data_path": "data/sleep/SHHS1_03.edf", + "instruction": "Please inspect the provided raw sleep EEG/PSG file. Report the total number of channels in the file, and list all EEG channels that can be used for sleep analysis. Use the original channel names exactly as they appear in the raw file. Do not include EOG, EMG, ECG, respiratory, SpO2/SaO2, light, position, or other auxiliary channels in the EEG channel list." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep EEG/PSG reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two outputs from the agent report:\n1) the total number of channels in the raw file\n2) the list of all EEG channels using original raw-file channel names\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text or explanations.\n4. The keys must be EXACTLY \"channel_count\" and \"eeg_channels\".\n5. \"channel_count\" must be an INTEGER or null.\n6. \"eeg_channels\" must be a JSON array of strings or null.\n7. Preserve original EEG channel names exactly as written in the raw file.\n8. Do NOT normalize references, casing, spacing, parentheses, hyphens, or symbols.\n9. Do NOT include EOG, EMG, ECG, respiratory, SpO2/SaO2, light, position, or auxiliary channels in \"eeg_channels\".\n10. For SHHS1 reports, only \"EEG(sec)\" and \"EEG\" count as EEG channels; \"THOR RES\", \"POSITION\", and \"OX stat\" are not EEG channels.\n11. Remove duplicate EEG channel names if the report repeats them.\n12. If one value is missing or unclear, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"channel_count\": , \"eeg_channels\": }", + "metrics": [ + { + "metric_id": "channel_count_accuracy", + "type": "numeric_check", + "target_key": "channel_count", + "weight": 30, + "params": { + "gt_value": 14, + "tolerance": 0.1 + } + }, + { + "metric_id": "eeg_channel_set_match", + "type": "set_match_check", + "target_key": "eeg_channels", + "weight": 70, + "params": { + "gt_value": [ + "EEG(sec)", + "EEG" + ], + "match_mode": "exact" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case2/case2_10.json b/sleep_assessment/cases/case2/case2_10.json new file mode 100644 index 0000000000000000000000000000000000000000..590819106e05397d56f17c237399f9faaa34a027 --- /dev/null +++ b/sleep_assessment/cases/case2/case2_10.json @@ -0,0 +1,58 @@ +{ + "meta_info": { + "case_id": "MASSSS3_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "data_path": "data/sleep/MASSSS3_01.edf", + "instruction": "Please inspect the provided raw sleep EEG/PSG file. Report the total number of channels in the file, and list all EEG channels that can be used for sleep analysis. Use the original channel names exactly as they appear in the raw file. Do not include EOG, EMG, ECG, respiratory, SpO2/SaO2, light, position, or other auxiliary channels in the EEG channel list." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep EEG/PSG reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two outputs from the agent report:\n1) the total number of channels in the raw file\n2) the list of all EEG channels using original raw-file channel names\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text or explanations.\n4. The keys must be EXACTLY \"channel_count\" and \"eeg_channels\".\n5. \"channel_count\" must be an INTEGER or null.\n6. \"eeg_channels\" must be a JSON array of strings or null.\n7. Preserve original EEG channel names exactly as written in the raw file.\n8. Do NOT normalize references, casing, spacing, parentheses, hyphens, or symbols.\n9. Do NOT include EOG, EMG, ECG, respiratory, SpO2/SaO2, light, position, or auxiliary channels in \"eeg_channels\".\n10. For SHHS1 reports, only \"EEG(sec)\" and \"EEG\" count as EEG channels; \"THOR RES\", \"POSITION\", and \"OX stat\" are not EEG channels.\n11. Remove duplicate EEG channel names if the report repeats them.\n12. If one value is missing or unclear, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"channel_count\": , \"eeg_channels\": }", + "metrics": [ + { + "metric_id": "channel_count_accuracy", + "type": "numeric_check", + "target_key": "channel_count", + "weight": 30, + "params": { + "gt_value": 27, + "tolerance": 0.1 + } + }, + { + "metric_id": "eeg_channel_set_match", + "type": "set_match_check", + "target_key": "eeg_channels", + "weight": 70, + "params": { + "gt_value": [ + "EEG Fp1-LER", + "EEG Fp2-LER", + "EEG F7-LER", + "EEG F8-LER", + "EEG F3-LER", + "EEG F4-LER", + "EEG T3-LER", + "EEG T4-LER", + "EEG C3-LER", + "EEG C4-LER", + "EEG T5-LER", + "EEG T6-LER", + "EEG P3-LER", + "EEG P4-LER", + "EEG O1-LER", + "EEG O2-LER", + "EEG Fz-LER", + "EEG Cz-LER", + "EEG Pz-LER", + "EEG Oz-LER" + ], + "match_mode": "exact" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case2/case2_11.json b/sleep_assessment/cases/case2/case2_11.json new file mode 100644 index 0000000000000000000000000000000000000000..9231bbe0cc5344b0afd39f401db752ddf1cd7077 --- /dev/null +++ b/sleep_assessment/cases/case2/case2_11.json @@ -0,0 +1,58 @@ +{ + "meta_info": { + "case_id": "MASSSS3_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "data_path": "data/sleep/MASSSS3_02.edf", + "instruction": "Please inspect the provided raw sleep EEG/PSG file. Report the total number of channels in the file, and list all EEG channels that can be used for sleep analysis. Use the original channel names exactly as they appear in the raw file. Do not include EOG, EMG, ECG, respiratory, SpO2/SaO2, light, position, or other auxiliary channels in the EEG channel list." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep EEG/PSG reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two outputs from the agent report:\n1) the total number of channels in the raw file\n2) the list of all EEG channels using original raw-file channel names\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text or explanations.\n4. The keys must be EXACTLY \"channel_count\" and \"eeg_channels\".\n5. \"channel_count\" must be an INTEGER or null.\n6. \"eeg_channels\" must be a JSON array of strings or null.\n7. Preserve original EEG channel names exactly as written in the raw file.\n8. Do NOT normalize references, casing, spacing, parentheses, hyphens, or symbols.\n9. Do NOT include EOG, EMG, ECG, respiratory, SpO2/SaO2, light, position, or auxiliary channels in \"eeg_channels\".\n10. For SHHS1 reports, only \"EEG(sec)\" and \"EEG\" count as EEG channels; \"THOR RES\", \"POSITION\", and \"OX stat\" are not EEG channels.\n11. Remove duplicate EEG channel names if the report repeats them.\n12. If one value is missing or unclear, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"channel_count\": , \"eeg_channels\": }", + "metrics": [ + { + "metric_id": "channel_count_accuracy", + "type": "numeric_check", + "target_key": "channel_count", + "weight": 30, + "params": { + "gt_value": 27, + "tolerance": 0.1 + } + }, + { + "metric_id": "eeg_channel_set_match", + "type": "set_match_check", + "target_key": "eeg_channels", + "weight": 70, + "params": { + "gt_value": [ + "EEG Fp1-LER", + "EEG Fp2-LER", + "EEG F7-LER", + "EEG F8-LER", + "EEG F3-LER", + "EEG F4-LER", + "EEG T3-LER", + "EEG T4-LER", + "EEG C3-LER", + "EEG C4-LER", + "EEG T5-LER", + "EEG T6-LER", + "EEG P3-LER", + "EEG P4-LER", + "EEG O1-LER", + "EEG O2-LER", + "EEG Fz-LER", + "EEG Cz-LER", + "EEG Pz-LER", + "EEG Oz-LER" + ], + "match_mode": "exact" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case2/case2_12.json b/sleep_assessment/cases/case2/case2_12.json new file mode 100644 index 0000000000000000000000000000000000000000..b34c2c889557f9c91565f7b3c365a38d51796dc1 --- /dev/null +++ b/sleep_assessment/cases/case2/case2_12.json @@ -0,0 +1,58 @@ +{ + "meta_info": { + "case_id": "MASSSS3_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "data_path": "data/sleep/MASSSS3_03.edf", + "instruction": "Please inspect the provided raw sleep EEG/PSG file. Report the total number of channels in the file, and list all EEG channels that can be used for sleep analysis. Use the original channel names exactly as they appear in the raw file. Do not include EOG, EMG, ECG, respiratory, SpO2/SaO2, light, position, or other auxiliary channels in the EEG channel list." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep EEG/PSG reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two outputs from the agent report:\n1) the total number of channels in the raw file\n2) the list of all EEG channels using original raw-file channel names\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text or explanations.\n4. The keys must be EXACTLY \"channel_count\" and \"eeg_channels\".\n5. \"channel_count\" must be an INTEGER or null.\n6. \"eeg_channels\" must be a JSON array of strings or null.\n7. Preserve original EEG channel names exactly as written in the raw file.\n8. Do NOT normalize references, casing, spacing, parentheses, hyphens, or symbols.\n9. Do NOT include EOG, EMG, ECG, respiratory, SpO2/SaO2, light, position, or auxiliary channels in \"eeg_channels\".\n10. For SHHS1 reports, only \"EEG(sec)\" and \"EEG\" count as EEG channels; \"THOR RES\", \"POSITION\", and \"OX stat\" are not EEG channels.\n11. Remove duplicate EEG channel names if the report repeats them.\n12. If one value is missing or unclear, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"channel_count\": , \"eeg_channels\": }", + "metrics": [ + { + "metric_id": "channel_count_accuracy", + "type": "numeric_check", + "target_key": "channel_count", + "weight": 30, + "params": { + "gt_value": 27, + "tolerance": 0.1 + } + }, + { + "metric_id": "eeg_channel_set_match", + "type": "set_match_check", + "target_key": "eeg_channels", + "weight": 70, + "params": { + "gt_value": [ + "EEG Fp1-LER", + "EEG Fp2-LER", + "EEG F7-LER", + "EEG F8-LER", + "EEG F3-LER", + "EEG F4-LER", + "EEG T3-LER", + "EEG T4-LER", + "EEG C3-LER", + "EEG C4-LER", + "EEG T5-LER", + "EEG T6-LER", + "EEG P3-LER", + "EEG P4-LER", + "EEG O1-LER", + "EEG O2-LER", + "EEG Fz-LER", + "EEG Cz-LER", + "EEG Pz-LER", + "EEG Oz-LER" + ], + "match_mode": "exact" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case2/case2_13.json b/sleep_assessment/cases/case2/case2_13.json new file mode 100644 index 0000000000000000000000000000000000000000..0aee35f9954abcc0f68fb49182dd1b9a47875d5d --- /dev/null +++ b/sleep_assessment/cases/case2/case2_13.json @@ -0,0 +1,44 @@ +{ + "meta_info": { + "case_id": "Physionet2018_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "data_path": "data/sleep/Physionet2018_01.edf", + "instruction": "Please inspect the provided raw sleep EEG/PSG file. Report the total number of channels in the file, and list all EEG channels that can be used for sleep analysis. Use the original channel names exactly as they appear in the raw file. Do not include EOG, EMG, ECG, respiratory, SpO2/SaO2, light, position, or other auxiliary channels in the EEG channel list." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep EEG/PSG reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two outputs from the agent report:\n1) the total number of channels in the raw file\n2) the list of all EEG channels using original raw-file channel names\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text or explanations.\n4. The keys must be EXACTLY \"channel_count\" and \"eeg_channels\".\n5. \"channel_count\" must be an INTEGER or null.\n6. \"eeg_channels\" must be a JSON array of strings or null.\n7. Preserve original EEG channel names exactly as written in the raw file.\n8. Do NOT normalize references, casing, spacing, parentheses, hyphens, or symbols.\n9. Do NOT include EOG, EMG, ECG, respiratory, SpO2/SaO2, light, position, or auxiliary channels in \"eeg_channels\".\n10. For SHHS1 reports, only \"EEG(sec)\" and \"EEG\" count as EEG channels; \"THOR RES\", \"POSITION\", and \"OX stat\" are not EEG channels.\n11. Remove duplicate EEG channel names if the report repeats them.\n12. If one value is missing or unclear, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"channel_count\": , \"eeg_channels\": }", + "metrics": [ + { + "metric_id": "channel_count_accuracy", + "type": "numeric_check", + "target_key": "channel_count", + "weight": 30, + "params": { + "gt_value": 13, + "tolerance": 0.1 + } + }, + { + "metric_id": "eeg_channel_set_match", + "type": "set_match_check", + "target_key": "eeg_channels", + "weight": 70, + "params": { + "gt_value": [ + "F3-M2", + "F4-M1", + "C3-M2", + "C4-M1", + "O1-M2", + "O2-M1" + ], + "match_mode": "exact" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case2/case2_14.json b/sleep_assessment/cases/case2/case2_14.json new file mode 100644 index 0000000000000000000000000000000000000000..cf1009b5f78313510f2226924251ea81e9cda991 --- /dev/null +++ b/sleep_assessment/cases/case2/case2_14.json @@ -0,0 +1,44 @@ +{ + "meta_info": { + "case_id": "Physionet2018_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "data_path": "data/sleep/Physionet2018_02.edf", + "instruction": "Please inspect the provided raw sleep EEG/PSG file. Report the total number of channels in the file, and list all EEG channels that can be used for sleep analysis. Use the original channel names exactly as they appear in the raw file. Do not include EOG, EMG, ECG, respiratory, SpO2/SaO2, light, position, or other auxiliary channels in the EEG channel list." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep EEG/PSG reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two outputs from the agent report:\n1) the total number of channels in the raw file\n2) the list of all EEG channels using original raw-file channel names\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text or explanations.\n4. The keys must be EXACTLY \"channel_count\" and \"eeg_channels\".\n5. \"channel_count\" must be an INTEGER or null.\n6. \"eeg_channels\" must be a JSON array of strings or null.\n7. Preserve original EEG channel names exactly as written in the raw file.\n8. Do NOT normalize references, casing, spacing, parentheses, hyphens, or symbols.\n9. Do NOT include EOG, EMG, ECG, respiratory, SpO2/SaO2, light, position, or auxiliary channels in \"eeg_channels\".\n10. For SHHS1 reports, only \"EEG(sec)\" and \"EEG\" count as EEG channels; \"THOR RES\", \"POSITION\", and \"OX stat\" are not EEG channels.\n11. Remove duplicate EEG channel names if the report repeats them.\n12. If one value is missing or unclear, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"channel_count\": , \"eeg_channels\": }", + "metrics": [ + { + "metric_id": "channel_count_accuracy", + "type": "numeric_check", + "target_key": "channel_count", + "weight": 30, + "params": { + "gt_value": 13, + "tolerance": 0.1 + } + }, + { + "metric_id": "eeg_channel_set_match", + "type": "set_match_check", + "target_key": "eeg_channels", + "weight": 70, + "params": { + "gt_value": [ + "F3-M2", + "F4-M1", + "C3-M2", + "C4-M1", + "O1-M2", + "O2-M1" + ], + "match_mode": "exact" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case2/case2_15.json b/sleep_assessment/cases/case2/case2_15.json new file mode 100644 index 0000000000000000000000000000000000000000..3c1c503132eb2cff1271dab40074e773c4f28f3a --- /dev/null +++ b/sleep_assessment/cases/case2/case2_15.json @@ -0,0 +1,44 @@ +{ + "meta_info": { + "case_id": "Physionet2018_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "data_path": "data/sleep/Physionet2018_03.edf", + "instruction": "Please inspect the provided raw sleep EEG/PSG file. Report the total number of channels in the file, and list all EEG channels that can be used for sleep analysis. Use the original channel names exactly as they appear in the raw file. Do not include EOG, EMG, ECG, respiratory, SpO2/SaO2, light, position, or other auxiliary channels in the EEG channel list." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep EEG/PSG reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two outputs from the agent report:\n1) the total number of channels in the raw file\n2) the list of all EEG channels using original raw-file channel names\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text or explanations.\n4. The keys must be EXACTLY \"channel_count\" and \"eeg_channels\".\n5. \"channel_count\" must be an INTEGER or null.\n6. \"eeg_channels\" must be a JSON array of strings or null.\n7. Preserve original EEG channel names exactly as written in the raw file.\n8. Do NOT normalize references, casing, spacing, parentheses, hyphens, or symbols.\n9. Do NOT include EOG, EMG, ECG, respiratory, SpO2/SaO2, light, position, or auxiliary channels in \"eeg_channels\".\n10. For SHHS1 reports, only \"EEG(sec)\" and \"EEG\" count as EEG channels; \"THOR RES\", \"POSITION\", and \"OX stat\" are not EEG channels.\n11. Remove duplicate EEG channel names if the report repeats them.\n12. If one value is missing or unclear, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"channel_count\": , \"eeg_channels\": }", + "metrics": [ + { + "metric_id": "channel_count_accuracy", + "type": "numeric_check", + "target_key": "channel_count", + "weight": 30, + "params": { + "gt_value": 13, + "tolerance": 0.1 + } + }, + { + "metric_id": "eeg_channel_set_match", + "type": "set_match_check", + "target_key": "eeg_channels", + "weight": 70, + "params": { + "gt_value": [ + "F3-M2", + "F4-M1", + "C3-M2", + "C4-M1", + "O1-M2", + "O2-M1" + ], + "match_mode": "exact" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case3/case3_01.json b/sleep_assessment/cases/case3/case3_01.json new file mode 100644 index 0000000000000000000000000000000000000000..ecbda64beb7db99bfa5daa2ba88e5c8f419f2345 --- /dev/null +++ b/sleep_assessment/cases/case3/case3_01.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "ISRUC_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_01.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three values for the recording: Total Sleep Time (TST) in minutes, Total In Bed Time (TIB) in minutes, and Sleep Efficiency (SE) as a percentage. TIB must be computed from the label file duration. Please clearly report all three final values in your response." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) Total Sleep Time (TST) in minutes\n2) Total In Bed Time (TIB) in minutes\n3) Sleep Efficiency (SE) as a percentage\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys in the JSON must be EXACTLY \"tst_min\", \"tib_min\", and \"se_percent\".\n5. \"tst_min\" and \"tib_min\" must be FLOAT values in minutes or null.\n6. \"se_percent\" must be a FLOAT percentage value or null.\n7. If a value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"tst_min\": , \"tib_min\": , \"se_percent\": }", + "metrics": [ + { + "metric_id": "tst_accuracy", + "type": "numeric_check", + "target_key": "tst_min", + "weight": 30, + "params": { + "gt_value": 308.0, + "tolerance": 9.24 + } + }, + { + "metric_id": "tib_accuracy", + "type": "numeric_check", + "target_key": "tib_min", + "weight": 30, + "params": { + "gt_value": 440.0, + "tolerance": 13.2 + } + }, + { + "metric_id": "se_accuracy", + "type": "numeric_check", + "target_key": "se_percent", + "weight": 40, + "params": { + "gt_value": 70.0, + "tolerance": 2.1 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case3/case3_02.json b/sleep_assessment/cases/case3/case3_02.json new file mode 100644 index 0000000000000000000000000000000000000000..be3ccd63143bfc55e34995dd6324b21f958eb42f --- /dev/null +++ b/sleep_assessment/cases/case3/case3_02.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "ISRUC_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_02.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three values for the recording: Total Sleep Time (TST) in minutes, Total In Bed Time (TIB) in minutes, and Sleep Efficiency (SE) as a percentage. TIB must be computed from the label file duration. Please clearly report all three final values in your response." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) Total Sleep Time (TST) in minutes\n2) Total In Bed Time (TIB) in minutes\n3) Sleep Efficiency (SE) as a percentage\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys in the JSON must be EXACTLY \"tst_min\", \"tib_min\", and \"se_percent\".\n5. \"tst_min\" and \"tib_min\" must be FLOAT values in minutes or null.\n6. \"se_percent\" must be a FLOAT percentage value or null.\n7. If a value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"tst_min\": , \"tib_min\": , \"se_percent\": }", + "metrics": [ + { + "metric_id": "tst_accuracy", + "type": "numeric_check", + "target_key": "tst_min", + "weight": 30, + "params": { + "gt_value": 359.5, + "tolerance": 10.785 + } + }, + { + "metric_id": "tib_accuracy", + "type": "numeric_check", + "target_key": "tib_min", + "weight": 30, + "params": { + "gt_value": 482.0, + "tolerance": 14.459999999999999 + } + }, + { + "metric_id": "se_accuracy", + "type": "numeric_check", + "target_key": "se_percent", + "weight": 40, + "params": { + "gt_value": 74.5850622406639, + "tolerance": 2.237551867219917 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case3/case3_03.json b/sleep_assessment/cases/case3/case3_03.json new file mode 100644 index 0000000000000000000000000000000000000000..8fd9ea099fbae464fb0a785d21fe9f0ae817c81f --- /dev/null +++ b/sleep_assessment/cases/case3/case3_03.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "ISRUC_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_03.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three values for the recording: Total Sleep Time (TST) in minutes, Total In Bed Time (TIB) in minutes, and Sleep Efficiency (SE) as a percentage. TIB must be computed from the label file duration. Please clearly report all three final values in your response." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) Total Sleep Time (TST) in minutes\n2) Total In Bed Time (TIB) in minutes\n3) Sleep Efficiency (SE) as a percentage\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys in the JSON must be EXACTLY \"tst_min\", \"tib_min\", and \"se_percent\".\n5. \"tst_min\" and \"tib_min\" must be FLOAT values in minutes or null.\n6. \"se_percent\" must be a FLOAT percentage value or null.\n7. If a value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"tst_min\": , \"tib_min\": , \"se_percent\": }", + "metrics": [ + { + "metric_id": "tst_accuracy", + "type": "numeric_check", + "target_key": "tst_min", + "weight": 30, + "params": { + "gt_value": 405.5, + "tolerance": 12.165 + } + }, + { + "metric_id": "tib_accuracy", + "type": "numeric_check", + "target_key": "tib_min", + "weight": 30, + "params": { + "gt_value": 471.5, + "tolerance": 14.145 + } + }, + { + "metric_id": "se_accuracy", + "type": "numeric_check", + "target_key": "se_percent", + "weight": 40, + "params": { + "gt_value": 86.00212089077412, + "tolerance": 2.5800636267232235 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case3/case3_04.json b/sleep_assessment/cases/case3/case3_04.json new file mode 100644 index 0000000000000000000000000000000000000000..bdc7c36f2047d0f3257a69249f9c34d43e656b32 --- /dev/null +++ b/sleep_assessment/cases/case3/case3_04.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "ISRUC_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_04.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three values for the recording: Total Sleep Time (TST) in minutes, Total In Bed Time (TIB) in minutes, and Sleep Efficiency (SE) as a percentage. TIB must be computed from the label file duration. Please clearly report all three final values in your response." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) Total Sleep Time (TST) in minutes\n2) Total In Bed Time (TIB) in minutes\n3) Sleep Efficiency (SE) as a percentage\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys in the JSON must be EXACTLY \"tst_min\", \"tib_min\", and \"se_percent\".\n5. \"tst_min\" and \"tib_min\" must be FLOAT values in minutes or null.\n6. \"se_percent\" must be a FLOAT percentage value or null.\n7. If a value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"tst_min\": , \"tib_min\": , \"se_percent\": }", + "metrics": [ + { + "metric_id": "tst_accuracy", + "type": "numeric_check", + "target_key": "tst_min", + "weight": 30, + "params": { + "gt_value": 467.5, + "tolerance": 14.025 + } + }, + { + "metric_id": "tib_accuracy", + "type": "numeric_check", + "target_key": "tib_min", + "weight": 30, + "params": { + "gt_value": 481.5, + "tolerance": 14.445 + } + }, + { + "metric_id": "se_accuracy", + "type": "numeric_check", + "target_key": "se_percent", + "weight": 40, + "params": { + "gt_value": 97.09241952232607, + "tolerance": 2.912772585669782 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case3/case3_05.json b/sleep_assessment/cases/case3/case3_05.json new file mode 100644 index 0000000000000000000000000000000000000000..ac969ce28d0d104a53c879b57b754de684318222 --- /dev/null +++ b/sleep_assessment/cases/case3/case3_05.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "ISRUC_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_05.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three values for the recording: Total Sleep Time (TST) in minutes, Total In Bed Time (TIB) in minutes, and Sleep Efficiency (SE) as a percentage. TIB must be computed from the label file duration. Please clearly report all three final values in your response." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) Total Sleep Time (TST) in minutes\n2) Total In Bed Time (TIB) in minutes\n3) Sleep Efficiency (SE) as a percentage\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys in the JSON must be EXACTLY \"tst_min\", \"tib_min\", and \"se_percent\".\n5. \"tst_min\" and \"tib_min\" must be FLOAT values in minutes or null.\n6. \"se_percent\" must be a FLOAT percentage value or null.\n7. If a value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"tst_min\": , \"tib_min\": , \"se_percent\": }", + "metrics": [ + { + "metric_id": "tst_accuracy", + "type": "numeric_check", + "target_key": "tst_min", + "weight": 30, + "params": { + "gt_value": 289.5, + "tolerance": 8.685 + } + }, + { + "metric_id": "tib_accuracy", + "type": "numeric_check", + "target_key": "tib_min", + "weight": 30, + "params": { + "gt_value": 437.5, + "tolerance": 13.125 + } + }, + { + "metric_id": "se_accuracy", + "type": "numeric_check", + "target_key": "se_percent", + "weight": 40, + "params": { + "gt_value": 66.17142857142856, + "tolerance": 1.9851428571428569 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case3/case3_06.json b/sleep_assessment/cases/case3/case3_06.json new file mode 100644 index 0000000000000000000000000000000000000000..82998aa1873ceb5a25ebc406e4ff66eb8ea59135 --- /dev/null +++ b/sleep_assessment/cases/case3/case3_06.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "HMC_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_01.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three values for the recording: Total Sleep Time (TST) in minutes, Total In Bed Time (TIB) in minutes, and Sleep Efficiency (SE) as a percentage. TIB must be computed from the label file duration. Please clearly report all three final values in your response." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) Total Sleep Time (TST) in minutes\n2) Total In Bed Time (TIB) in minutes\n3) Sleep Efficiency (SE) as a percentage\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys in the JSON must be EXACTLY \"tst_min\", \"tib_min\", and \"se_percent\".\n5. \"tst_min\" and \"tib_min\" must be FLOAT values in minutes or null.\n6. \"se_percent\" must be a FLOAT percentage value or null.\n7. If a value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"tst_min\": , \"tib_min\": , \"se_percent\": }", + "metrics": [ + { + "metric_id": "tst_accuracy", + "type": "numeric_check", + "target_key": "tst_min", + "weight": 30, + "params": { + "gt_value": 351.5, + "tolerance": 10.545 + } + }, + { + "metric_id": "tib_accuracy", + "type": "numeric_check", + "target_key": "tib_min", + "weight": 30, + "params": { + "gt_value": 427.0, + "tolerance": 12.809999999999999 + } + }, + { + "metric_id": "se_accuracy", + "type": "numeric_check", + "target_key": "se_percent", + "weight": 40, + "params": { + "gt_value": 82.31850117096019, + "tolerance": 2.469555035128806 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case3/case3_07.json b/sleep_assessment/cases/case3/case3_07.json new file mode 100644 index 0000000000000000000000000000000000000000..61a74522dfd4e188245b5086d018a68d5cb1df78 --- /dev/null +++ b/sleep_assessment/cases/case3/case3_07.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "HMC_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_02.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three values for the recording: Total Sleep Time (TST) in minutes, Total In Bed Time (TIB) in minutes, and Sleep Efficiency (SE) as a percentage. TIB must be computed from the label file duration. Please clearly report all three final values in your response." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) Total Sleep Time (TST) in minutes\n2) Total In Bed Time (TIB) in minutes\n3) Sleep Efficiency (SE) as a percentage\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys in the JSON must be EXACTLY \"tst_min\", \"tib_min\", and \"se_percent\".\n5. \"tst_min\" and \"tib_min\" must be FLOAT values in minutes or null.\n6. \"se_percent\" must be a FLOAT percentage value or null.\n7. If a value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"tst_min\": , \"tib_min\": , \"se_percent\": }", + "metrics": [ + { + "metric_id": "tst_accuracy", + "type": "numeric_check", + "target_key": "tst_min", + "weight": 30, + "params": { + "gt_value": 387.0, + "tolerance": 11.61 + } + }, + { + "metric_id": "tib_accuracy", + "type": "numeric_check", + "target_key": "tib_min", + "weight": 30, + "params": { + "gt_value": 428.0, + "tolerance": 12.84 + } + }, + { + "metric_id": "se_accuracy", + "type": "numeric_check", + "target_key": "se_percent", + "weight": 40, + "params": { + "gt_value": 90.42056074766354, + "tolerance": 2.712616822429906 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case3/case3_08.json b/sleep_assessment/cases/case3/case3_08.json new file mode 100644 index 0000000000000000000000000000000000000000..c16f03a94da896bf0612bfc8d49e6c6bf5df18ad --- /dev/null +++ b/sleep_assessment/cases/case3/case3_08.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "HMC_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_03.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three values for the recording: Total Sleep Time (TST) in minutes, Total In Bed Time (TIB) in minutes, and Sleep Efficiency (SE) as a percentage. TIB must be computed from the label file duration. Please clearly report all three final values in your response." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) Total Sleep Time (TST) in minutes\n2) Total In Bed Time (TIB) in minutes\n3) Sleep Efficiency (SE) as a percentage\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys in the JSON must be EXACTLY \"tst_min\", \"tib_min\", and \"se_percent\".\n5. \"tst_min\" and \"tib_min\" must be FLOAT values in minutes or null.\n6. \"se_percent\" must be a FLOAT percentage value or null.\n7. If a value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"tst_min\": , \"tib_min\": , \"se_percent\": }", + "metrics": [ + { + "metric_id": "tst_accuracy", + "type": "numeric_check", + "target_key": "tst_min", + "weight": 30, + "params": { + "gt_value": 275.5, + "tolerance": 8.265 + } + }, + { + "metric_id": "tib_accuracy", + "type": "numeric_check", + "target_key": "tib_min", + "weight": 30, + "params": { + "gt_value": 477.0, + "tolerance": 14.309999999999999 + } + }, + { + "metric_id": "se_accuracy", + "type": "numeric_check", + "target_key": "se_percent", + "weight": 40, + "params": { + "gt_value": 57.75681341719078, + "tolerance": 1.7327044025157232 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case3/case3_09.json b/sleep_assessment/cases/case3/case3_09.json new file mode 100644 index 0000000000000000000000000000000000000000..de8af8acac3fab1a4652fa580bc3827e9e127304 --- /dev/null +++ b/sleep_assessment/cases/case3/case3_09.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "HMC_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_04.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three values for the recording: Total Sleep Time (TST) in minutes, Total In Bed Time (TIB) in minutes, and Sleep Efficiency (SE) as a percentage. TIB must be computed from the label file duration. Please clearly report all three final values in your response." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) Total Sleep Time (TST) in minutes\n2) Total In Bed Time (TIB) in minutes\n3) Sleep Efficiency (SE) as a percentage\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys in the JSON must be EXACTLY \"tst_min\", \"tib_min\", and \"se_percent\".\n5. \"tst_min\" and \"tib_min\" must be FLOAT values in minutes or null.\n6. \"se_percent\" must be a FLOAT percentage value or null.\n7. If a value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"tst_min\": , \"tib_min\": , \"se_percent\": }", + "metrics": [ + { + "metric_id": "tst_accuracy", + "type": "numeric_check", + "target_key": "tst_min", + "weight": 30, + "params": { + "gt_value": 468.0, + "tolerance": 14.04 + } + }, + { + "metric_id": "tib_accuracy", + "type": "numeric_check", + "target_key": "tib_min", + "weight": 30, + "params": { + "gt_value": 508.0, + "tolerance": 15.24 + } + }, + { + "metric_id": "se_accuracy", + "type": "numeric_check", + "target_key": "se_percent", + "weight": 40, + "params": { + "gt_value": 92.1259842519685, + "tolerance": 2.763779527559055 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case3/case3_10.json b/sleep_assessment/cases/case3/case3_10.json new file mode 100644 index 0000000000000000000000000000000000000000..17915d328d9fac960796e9d09cb13cba37a50b20 --- /dev/null +++ b/sleep_assessment/cases/case3/case3_10.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "HMC_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_05.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three values for the recording: Total Sleep Time (TST) in minutes, Total In Bed Time (TIB) in minutes, and Sleep Efficiency (SE) as a percentage. TIB must be computed from the label file duration. Please clearly report all three final values in your response." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) Total Sleep Time (TST) in minutes\n2) Total In Bed Time (TIB) in minutes\n3) Sleep Efficiency (SE) as a percentage\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys in the JSON must be EXACTLY \"tst_min\", \"tib_min\", and \"se_percent\".\n5. \"tst_min\" and \"tib_min\" must be FLOAT values in minutes or null.\n6. \"se_percent\" must be a FLOAT percentage value or null.\n7. If a value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"tst_min\": , \"tib_min\": , \"se_percent\": }", + "metrics": [ + { + "metric_id": "tst_accuracy", + "type": "numeric_check", + "target_key": "tst_min", + "weight": 30, + "params": { + "gt_value": 379.0, + "tolerance": 11.37 + } + }, + { + "metric_id": "tib_accuracy", + "type": "numeric_check", + "target_key": "tib_min", + "weight": 30, + "params": { + "gt_value": 479.5, + "tolerance": 14.385 + } + }, + { + "metric_id": "se_accuracy", + "type": "numeric_check", + "target_key": "se_percent", + "weight": 40, + "params": { + "gt_value": 79.04066736183525, + "tolerance": 2.3712200208550573 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case3/case3_11.json b/sleep_assessment/cases/case3/case3_11.json new file mode 100644 index 0000000000000000000000000000000000000000..19dae0da2f64a95f19e8a64ec99ca88abcfe82e8 --- /dev/null +++ b/sleep_assessment/cases/case3/case3_11.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "SHHS1_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_01.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three values for the recording: Total Sleep Time (TST) in minutes, Total In Bed Time (TIB) in minutes, and Sleep Efficiency (SE) as a percentage. TIB must be computed from the label file duration. Please clearly report all three final values in your response." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) Total Sleep Time (TST) in minutes\n2) Total In Bed Time (TIB) in minutes\n3) Sleep Efficiency (SE) as a percentage\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys in the JSON must be EXACTLY \"tst_min\", \"tib_min\", and \"se_percent\".\n5. \"tst_min\" and \"tib_min\" must be FLOAT values in minutes or null.\n6. \"se_percent\" must be a FLOAT percentage value or null.\n7. If a value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"tst_min\": , \"tib_min\": , \"se_percent\": }", + "metrics": [ + { + "metric_id": "tst_accuracy", + "type": "numeric_check", + "target_key": "tst_min", + "weight": 30, + "params": { + "gt_value": 375.5, + "tolerance": 11.264999999999999 + } + }, + { + "metric_id": "tib_accuracy", + "type": "numeric_check", + "target_key": "tib_min", + "weight": 30, + "params": { + "gt_value": 542.0, + "tolerance": 16.259999999999998 + } + }, + { + "metric_id": "se_accuracy", + "type": "numeric_check", + "target_key": "se_percent", + "weight": 40, + "params": { + "gt_value": 69.28044280442805, + "tolerance": 2.0784132841328415 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case3/case3_12.json b/sleep_assessment/cases/case3/case3_12.json new file mode 100644 index 0000000000000000000000000000000000000000..481a41a4c46a260c7db5cbf971f7d1f4bd02de90 --- /dev/null +++ b/sleep_assessment/cases/case3/case3_12.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "SHHS1_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_02.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three values for the recording: Total Sleep Time (TST) in minutes, Total In Bed Time (TIB) in minutes, and Sleep Efficiency (SE) as a percentage. TIB must be computed from the label file duration. Please clearly report all three final values in your response." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) Total Sleep Time (TST) in minutes\n2) Total In Bed Time (TIB) in minutes\n3) Sleep Efficiency (SE) as a percentage\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys in the JSON must be EXACTLY \"tst_min\", \"tib_min\", and \"se_percent\".\n5. \"tst_min\" and \"tib_min\" must be FLOAT values in minutes or null.\n6. \"se_percent\" must be a FLOAT percentage value or null.\n7. If a value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"tst_min\": , \"tib_min\": , \"se_percent\": }", + "metrics": [ + { + "metric_id": "tst_accuracy", + "type": "numeric_check", + "target_key": "tst_min", + "weight": 30, + "params": { + "gt_value": 182.0, + "tolerance": 5.46 + } + }, + { + "metric_id": "tib_accuracy", + "type": "numeric_check", + "target_key": "tib_min", + "weight": 30, + "params": { + "gt_value": 539.5, + "tolerance": 16.185 + } + }, + { + "metric_id": "se_accuracy", + "type": "numeric_check", + "target_key": "se_percent", + "weight": 40, + "params": { + "gt_value": 33.734939759036145, + "tolerance": 1.0120481927710843 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case3/case3_13.json b/sleep_assessment/cases/case3/case3_13.json new file mode 100644 index 0000000000000000000000000000000000000000..3dea68ed8fb9f912731c5e6c19e46ce997cad466 --- /dev/null +++ b/sleep_assessment/cases/case3/case3_13.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "SHHS1_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_03.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three values for the recording: Total Sleep Time (TST) in minutes, Total In Bed Time (TIB) in minutes, and Sleep Efficiency (SE) as a percentage. TIB must be computed from the label file duration. Please clearly report all three final values in your response." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) Total Sleep Time (TST) in minutes\n2) Total In Bed Time (TIB) in minutes\n3) Sleep Efficiency (SE) as a percentage\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys in the JSON must be EXACTLY \"tst_min\", \"tib_min\", and \"se_percent\".\n5. \"tst_min\" and \"tib_min\" must be FLOAT values in minutes or null.\n6. \"se_percent\" must be a FLOAT percentage value or null.\n7. If a value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"tst_min\": , \"tib_min\": , \"se_percent\": }", + "metrics": [ + { + "metric_id": "tst_accuracy", + "type": "numeric_check", + "target_key": "tst_min", + "weight": 30, + "params": { + "gt_value": 358.5, + "tolerance": 10.754999999999999 + } + }, + { + "metric_id": "tib_accuracy", + "type": "numeric_check", + "target_key": "tib_min", + "weight": 30, + "params": { + "gt_value": 524.5, + "tolerance": 15.735 + } + }, + { + "metric_id": "se_accuracy", + "type": "numeric_check", + "target_key": "se_percent", + "weight": 40, + "params": { + "gt_value": 68.35081029551954, + "tolerance": 2.0505243088655862 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case3/case3_14.json b/sleep_assessment/cases/case3/case3_14.json new file mode 100644 index 0000000000000000000000000000000000000000..41424c1e83657fe5bf367b48e30fd9f73c533f9f --- /dev/null +++ b/sleep_assessment/cases/case3/case3_14.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "SHHS1_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_04.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three values for the recording: Total Sleep Time (TST) in minutes, Total In Bed Time (TIB) in minutes, and Sleep Efficiency (SE) as a percentage. TIB must be computed from the label file duration. Please clearly report all three final values in your response." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) Total Sleep Time (TST) in minutes\n2) Total In Bed Time (TIB) in minutes\n3) Sleep Efficiency (SE) as a percentage\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys in the JSON must be EXACTLY \"tst_min\", \"tib_min\", and \"se_percent\".\n5. \"tst_min\" and \"tib_min\" must be FLOAT values in minutes or null.\n6. \"se_percent\" must be a FLOAT percentage value or null.\n7. If a value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"tst_min\": , \"tib_min\": , \"se_percent\": }", + "metrics": [ + { + "metric_id": "tst_accuracy", + "type": "numeric_check", + "target_key": "tst_min", + "weight": 30, + "params": { + "gt_value": 301.0, + "tolerance": 9.03 + } + }, + { + "metric_id": "tib_accuracy", + "type": "numeric_check", + "target_key": "tib_min", + "weight": 30, + "params": { + "gt_value": 437.5, + "tolerance": 13.125 + } + }, + { + "metric_id": "se_accuracy", + "type": "numeric_check", + "target_key": "se_percent", + "weight": 40, + "params": { + "gt_value": 68.8, + "tolerance": 2.064 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case3/case3_15.json b/sleep_assessment/cases/case3/case3_15.json new file mode 100644 index 0000000000000000000000000000000000000000..24c468bda69cb2bd6310bbf9f7b8199e8e9fe243 --- /dev/null +++ b/sleep_assessment/cases/case3/case3_15.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "SHHS1_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_05.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three values for the recording: Total Sleep Time (TST) in minutes, Total In Bed Time (TIB) in minutes, and Sleep Efficiency (SE) as a percentage. TIB must be computed from the label file duration. Please clearly report all three final values in your response." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) Total Sleep Time (TST) in minutes\n2) Total In Bed Time (TIB) in minutes\n3) Sleep Efficiency (SE) as a percentage\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys in the JSON must be EXACTLY \"tst_min\", \"tib_min\", and \"se_percent\".\n5. \"tst_min\" and \"tib_min\" must be FLOAT values in minutes or null.\n6. \"se_percent\" must be a FLOAT percentage value or null.\n7. If a value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"tst_min\": , \"tib_min\": , \"se_percent\": }", + "metrics": [ + { + "metric_id": "tst_accuracy", + "type": "numeric_check", + "target_key": "tst_min", + "weight": 30, + "params": { + "gt_value": 370.0, + "tolerance": 11.1 + } + }, + { + "metric_id": "tib_accuracy", + "type": "numeric_check", + "target_key": "tib_min", + "weight": 30, + "params": { + "gt_value": 542.0, + "tolerance": 16.259999999999998 + } + }, + { + "metric_id": "se_accuracy", + "type": "numeric_check", + "target_key": "se_percent", + "weight": 40, + "params": { + "gt_value": 68.26568265682657, + "tolerance": 2.047970479704797 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case3/case3_16.json b/sleep_assessment/cases/case3/case3_16.json new file mode 100644 index 0000000000000000000000000000000000000000..564edfe983c7d9b05c7b2b15c161a3d05c76e951 --- /dev/null +++ b/sleep_assessment/cases/case3/case3_16.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "MASSSS3_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_01.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three values for the recording: Total Sleep Time (TST) in minutes, Total In Bed Time (TIB) in minutes, and Sleep Efficiency (SE) as a percentage. TIB must be computed from the label file duration. Please clearly report all three final values in your response." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) Total Sleep Time (TST) in minutes\n2) Total In Bed Time (TIB) in minutes\n3) Sleep Efficiency (SE) as a percentage\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys in the JSON must be EXACTLY \"tst_min\", \"tib_min\", and \"se_percent\".\n5. \"tst_min\" and \"tib_min\" must be FLOAT values in minutes or null.\n6. \"se_percent\" must be a FLOAT percentage value or null.\n7. If a value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"tst_min\": , \"tib_min\": , \"se_percent\": }", + "metrics": [ + { + "metric_id": "tst_accuracy", + "type": "numeric_check", + "target_key": "tst_min", + "weight": 30, + "params": { + "gt_value": 469.5, + "tolerance": 14.084999999999999 + } + }, + { + "metric_id": "tib_accuracy", + "type": "numeric_check", + "target_key": "tib_min", + "weight": 30, + "params": { + "gt_value": 504.0, + "tolerance": 15.12 + } + }, + { + "metric_id": "se_accuracy", + "type": "numeric_check", + "target_key": "se_percent", + "weight": 40, + "params": { + "gt_value": 93.15476190476191, + "tolerance": 2.794642857142857 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case3/case3_17.json b/sleep_assessment/cases/case3/case3_17.json new file mode 100644 index 0000000000000000000000000000000000000000..ac4a79820cb874674b5dee59efeddca070853fa7 --- /dev/null +++ b/sleep_assessment/cases/case3/case3_17.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "MASSSS3_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_02.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three values for the recording: Total Sleep Time (TST) in minutes, Total In Bed Time (TIB) in minutes, and Sleep Efficiency (SE) as a percentage. TIB must be computed from the label file duration. Please clearly report all three final values in your response." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) Total Sleep Time (TST) in minutes\n2) Total In Bed Time (TIB) in minutes\n3) Sleep Efficiency (SE) as a percentage\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys in the JSON must be EXACTLY \"tst_min\", \"tib_min\", and \"se_percent\".\n5. \"tst_min\" and \"tib_min\" must be FLOAT values in minutes or null.\n6. \"se_percent\" must be a FLOAT percentage value or null.\n7. If a value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"tst_min\": , \"tib_min\": , \"se_percent\": }", + "metrics": [ + { + "metric_id": "tst_accuracy", + "type": "numeric_check", + "target_key": "tst_min", + "weight": 30, + "params": { + "gt_value": 477.5, + "tolerance": 14.325 + } + }, + { + "metric_id": "tib_accuracy", + "type": "numeric_check", + "target_key": "tib_min", + "weight": 30, + "params": { + "gt_value": 536.0, + "tolerance": 16.08 + } + }, + { + "metric_id": "se_accuracy", + "type": "numeric_check", + "target_key": "se_percent", + "weight": 40, + "params": { + "gt_value": 89.08582089552239, + "tolerance": 2.6725746268656714 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case3/case3_18.json b/sleep_assessment/cases/case3/case3_18.json new file mode 100644 index 0000000000000000000000000000000000000000..470d6eddbcaf3b1675f365762096cdcd423d881f --- /dev/null +++ b/sleep_assessment/cases/case3/case3_18.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "MASSSS3_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_03.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three values for the recording: Total Sleep Time (TST) in minutes, Total In Bed Time (TIB) in minutes, and Sleep Efficiency (SE) as a percentage. TIB must be computed from the label file duration. Please clearly report all three final values in your response." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) Total Sleep Time (TST) in minutes\n2) Total In Bed Time (TIB) in minutes\n3) Sleep Efficiency (SE) as a percentage\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys in the JSON must be EXACTLY \"tst_min\", \"tib_min\", and \"se_percent\".\n5. \"tst_min\" and \"tib_min\" must be FLOAT values in minutes or null.\n6. \"se_percent\" must be a FLOAT percentage value or null.\n7. If a value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"tst_min\": , \"tib_min\": , \"se_percent\": }", + "metrics": [ + { + "metric_id": "tst_accuracy", + "type": "numeric_check", + "target_key": "tst_min", + "weight": 30, + "params": { + "gt_value": 451.5, + "tolerance": 13.545 + } + }, + { + "metric_id": "tib_accuracy", + "type": "numeric_check", + "target_key": "tib_min", + "weight": 30, + "params": { + "gt_value": 477.5, + "tolerance": 14.325 + } + }, + { + "metric_id": "se_accuracy", + "type": "numeric_check", + "target_key": "se_percent", + "weight": 40, + "params": { + "gt_value": 94.55497382198953, + "tolerance": 2.836649214659686 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case3/case3_19.json b/sleep_assessment/cases/case3/case3_19.json new file mode 100644 index 0000000000000000000000000000000000000000..f69cd06329b6f305eb5271caceb333f09655f00c --- /dev/null +++ b/sleep_assessment/cases/case3/case3_19.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "MASSSS3_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_04.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three values for the recording: Total Sleep Time (TST) in minutes, Total In Bed Time (TIB) in minutes, and Sleep Efficiency (SE) as a percentage. TIB must be computed from the label file duration. Please clearly report all three final values in your response." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) Total Sleep Time (TST) in minutes\n2) Total In Bed Time (TIB) in minutes\n3) Sleep Efficiency (SE) as a percentage\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys in the JSON must be EXACTLY \"tst_min\", \"tib_min\", and \"se_percent\".\n5. \"tst_min\" and \"tib_min\" must be FLOAT values in minutes or null.\n6. \"se_percent\" must be a FLOAT percentage value or null.\n7. If a value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"tst_min\": , \"tib_min\": , \"se_percent\": }", + "metrics": [ + { + "metric_id": "tst_accuracy", + "type": "numeric_check", + "target_key": "tst_min", + "weight": 30, + "params": { + "gt_value": 450.5, + "tolerance": 13.514999999999999 + } + }, + { + "metric_id": "tib_accuracy", + "type": "numeric_check", + "target_key": "tib_min", + "weight": 30, + "params": { + "gt_value": 456.0, + "tolerance": 13.68 + } + }, + { + "metric_id": "se_accuracy", + "type": "numeric_check", + "target_key": "se_percent", + "weight": 40, + "params": { + "gt_value": 98.79385964912281, + "tolerance": 2.963815789473684 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case3/case3_20.json b/sleep_assessment/cases/case3/case3_20.json new file mode 100644 index 0000000000000000000000000000000000000000..c21a7324b4f77f1c61787e2314c56e01b6fa62e5 --- /dev/null +++ b/sleep_assessment/cases/case3/case3_20.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "MASSSS3_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_05.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three values for the recording: Total Sleep Time (TST) in minutes, Total In Bed Time (TIB) in minutes, and Sleep Efficiency (SE) as a percentage. TIB must be computed from the label file duration. Please clearly report all three final values in your response." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) Total Sleep Time (TST) in minutes\n2) Total In Bed Time (TIB) in minutes\n3) Sleep Efficiency (SE) as a percentage\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys in the JSON must be EXACTLY \"tst_min\", \"tib_min\", and \"se_percent\".\n5. \"tst_min\" and \"tib_min\" must be FLOAT values in minutes or null.\n6. \"se_percent\" must be a FLOAT percentage value or null.\n7. If a value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"tst_min\": , \"tib_min\": , \"se_percent\": }", + "metrics": [ + { + "metric_id": "tst_accuracy", + "type": "numeric_check", + "target_key": "tst_min", + "weight": 30, + "params": { + "gt_value": 508.0, + "tolerance": 15.24 + } + }, + { + "metric_id": "tib_accuracy", + "type": "numeric_check", + "target_key": "tib_min", + "weight": 30, + "params": { + "gt_value": 534.5, + "tolerance": 16.035 + } + }, + { + "metric_id": "se_accuracy", + "type": "numeric_check", + "target_key": "se_percent", + "weight": 40, + "params": { + "gt_value": 95.0420954162769, + "tolerance": 2.8512628624883067 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case3/case3_21.json b/sleep_assessment/cases/case3/case3_21.json new file mode 100644 index 0000000000000000000000000000000000000000..44cf9102a0c6892c1b78bfcfb83ff3cd2ca699d0 --- /dev/null +++ b/sleep_assessment/cases/case3/case3_21.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "Physionet2018_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_01.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three values for the recording: Total Sleep Time (TST) in minutes, Total In Bed Time (TIB) in minutes, and Sleep Efficiency (SE) as a percentage. TIB must be computed from the label file duration. Please clearly report all three final values in your response." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) Total Sleep Time (TST) in minutes\n2) Total In Bed Time (TIB) in minutes\n3) Sleep Efficiency (SE) as a percentage\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys in the JSON must be EXACTLY \"tst_min\", \"tib_min\", and \"se_percent\".\n5. \"tst_min\" and \"tib_min\" must be FLOAT values in minutes or null.\n6. \"se_percent\" must be a FLOAT percentage value or null.\n7. If a value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"tst_min\": , \"tib_min\": , \"se_percent\": }", + "metrics": [ + { + "metric_id": "tst_accuracy", + "type": "numeric_check", + "target_key": "tst_min", + "weight": 30, + "params": { + "gt_value": 239.0, + "tolerance": 7.17 + } + }, + { + "metric_id": "tib_accuracy", + "type": "numeric_check", + "target_key": "tib_min", + "weight": 30, + "params": { + "gt_value": 422.5, + "tolerance": 12.674999999999999 + } + }, + { + "metric_id": "se_accuracy", + "type": "numeric_check", + "target_key": "se_percent", + "weight": 40, + "params": { + "gt_value": 56.5680473372781, + "tolerance": 1.697041420118343 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case3/case3_22.json b/sleep_assessment/cases/case3/case3_22.json new file mode 100644 index 0000000000000000000000000000000000000000..a07fa9d2eb50c470624fdd42bba369d12fbf42ba --- /dev/null +++ b/sleep_assessment/cases/case3/case3_22.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "Physionet2018_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_02.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three values for the recording: Total Sleep Time (TST) in minutes, Total In Bed Time (TIB) in minutes, and Sleep Efficiency (SE) as a percentage. TIB must be computed from the label file duration. Please clearly report all three final values in your response." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) Total Sleep Time (TST) in minutes\n2) Total In Bed Time (TIB) in minutes\n3) Sleep Efficiency (SE) as a percentage\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys in the JSON must be EXACTLY \"tst_min\", \"tib_min\", and \"se_percent\".\n5. \"tst_min\" and \"tib_min\" must be FLOAT values in minutes or null.\n6. \"se_percent\" must be a FLOAT percentage value or null.\n7. If a value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"tst_min\": , \"tib_min\": , \"se_percent\": }", + "metrics": [ + { + "metric_id": "tst_accuracy", + "type": "numeric_check", + "target_key": "tst_min", + "weight": 30, + "params": { + "gt_value": 230.0, + "tolerance": 6.8999999999999995 + } + }, + { + "metric_id": "tib_accuracy", + "type": "numeric_check", + "target_key": "tib_min", + "weight": 30, + "params": { + "gt_value": 388.5, + "tolerance": 11.655 + } + }, + { + "metric_id": "se_accuracy", + "type": "numeric_check", + "target_key": "se_percent", + "weight": 40, + "params": { + "gt_value": 59.202059202059196, + "tolerance": 1.7760617760617758 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case3/case3_23.json b/sleep_assessment/cases/case3/case3_23.json new file mode 100644 index 0000000000000000000000000000000000000000..0ada6b2af0ec0fb9fdf5434d633c01665432eb22 --- /dev/null +++ b/sleep_assessment/cases/case3/case3_23.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "Physionet2018_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_03.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three values for the recording: Total Sleep Time (TST) in minutes, Total In Bed Time (TIB) in minutes, and Sleep Efficiency (SE) as a percentage. TIB must be computed from the label file duration. Please clearly report all three final values in your response." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) Total Sleep Time (TST) in minutes\n2) Total In Bed Time (TIB) in minutes\n3) Sleep Efficiency (SE) as a percentage\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys in the JSON must be EXACTLY \"tst_min\", \"tib_min\", and \"se_percent\".\n5. \"tst_min\" and \"tib_min\" must be FLOAT values in minutes or null.\n6. \"se_percent\" must be a FLOAT percentage value or null.\n7. If a value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"tst_min\": , \"tib_min\": , \"se_percent\": }", + "metrics": [ + { + "metric_id": "tst_accuracy", + "type": "numeric_check", + "target_key": "tst_min", + "weight": 30, + "params": { + "gt_value": 226.0, + "tolerance": 6.779999999999999 + } + }, + { + "metric_id": "tib_accuracy", + "type": "numeric_check", + "target_key": "tib_min", + "weight": 30, + "params": { + "gt_value": 489.0, + "tolerance": 14.67 + } + }, + { + "metric_id": "se_accuracy", + "type": "numeric_check", + "target_key": "se_percent", + "weight": 40, + "params": { + "gt_value": 46.216768916155424, + "tolerance": 1.3865030674846626 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case3/case3_24.json b/sleep_assessment/cases/case3/case3_24.json new file mode 100644 index 0000000000000000000000000000000000000000..850058f023b3a77c2bbaeb321d2996e27b00d6d6 --- /dev/null +++ b/sleep_assessment/cases/case3/case3_24.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "Physionet2018_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_04.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three values for the recording: Total Sleep Time (TST) in minutes, Total In Bed Time (TIB) in minutes, and Sleep Efficiency (SE) as a percentage. TIB must be computed from the label file duration. Please clearly report all three final values in your response." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) Total Sleep Time (TST) in minutes\n2) Total In Bed Time (TIB) in minutes\n3) Sleep Efficiency (SE) as a percentage\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys in the JSON must be EXACTLY \"tst_min\", \"tib_min\", and \"se_percent\".\n5. \"tst_min\" and \"tib_min\" must be FLOAT values in minutes or null.\n6. \"se_percent\" must be a FLOAT percentage value or null.\n7. If a value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"tst_min\": , \"tib_min\": , \"se_percent\": }", + "metrics": [ + { + "metric_id": "tst_accuracy", + "type": "numeric_check", + "target_key": "tst_min", + "weight": 30, + "params": { + "gt_value": 381.5, + "tolerance": 11.445 + } + }, + { + "metric_id": "tib_accuracy", + "type": "numeric_check", + "target_key": "tib_min", + "weight": 30, + "params": { + "gt_value": 422.0, + "tolerance": 12.66 + } + }, + { + "metric_id": "se_accuracy", + "type": "numeric_check", + "target_key": "se_percent", + "weight": 40, + "params": { + "gt_value": 90.40284360189574, + "tolerance": 2.712085308056872 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case3/case3_25.json b/sleep_assessment/cases/case3/case3_25.json new file mode 100644 index 0000000000000000000000000000000000000000..67a12fb96300c0e839f51ab4ed5264625ac4eacc --- /dev/null +++ b/sleep_assessment/cases/case3/case3_25.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "Physionet2018_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_05.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three values for the recording: Total Sleep Time (TST) in minutes, Total In Bed Time (TIB) in minutes, and Sleep Efficiency (SE) as a percentage. TIB must be computed from the label file duration. Please clearly report all three final values in your response." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) Total Sleep Time (TST) in minutes\n2) Total In Bed Time (TIB) in minutes\n3) Sleep Efficiency (SE) as a percentage\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys in the JSON must be EXACTLY \"tst_min\", \"tib_min\", and \"se_percent\".\n5. \"tst_min\" and \"tib_min\" must be FLOAT values in minutes or null.\n6. \"se_percent\" must be a FLOAT percentage value or null.\n7. If a value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"tst_min\": , \"tib_min\": , \"se_percent\": }", + "metrics": [ + { + "metric_id": "tst_accuracy", + "type": "numeric_check", + "target_key": "tst_min", + "weight": 30, + "params": { + "gt_value": 450.0, + "tolerance": 13.5 + } + }, + { + "metric_id": "tib_accuracy", + "type": "numeric_check", + "target_key": "tib_min", + "weight": 30, + "params": { + "gt_value": 479.5, + "tolerance": 14.385 + } + }, + { + "metric_id": "se_accuracy", + "type": "numeric_check", + "target_key": "se_percent", + "weight": 40, + "params": { + "gt_value": 93.84775808133472, + "tolerance": 2.8154327424400414 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case4/case4_01.json b/sleep_assessment/cases/case4/case4_01.json new file mode 100644 index 0000000000000000000000000000000000000000..d90ff7eedda29fa72d5d5d2ff02cb13d72c6358f --- /dev/null +++ b/sleep_assessment/cases/case4/case4_01.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "ISRUC_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_01.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two sleep continuity metrics for the recording: Wake After Sleep Onset (WASO) in minutes, and the number of awakenings after sleep onset. Define the analysis interval from the first sleep epoch to the last sleep epoch, and count awakenings as contiguous Wake segments within that interval. Please clearly report both final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two values from the agent's report:\n1) Wake After Sleep Onset (WASO) in minutes\n2) the number of awakenings after sleep onset\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"waso_min\" and \"awakening_count\".\n5. \"waso_min\" must be a FLOAT in minutes or null.\n6. \"awakening_count\" must be an INTEGER or null.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"waso_min\": , \"awakening_count\": }", + "metrics": [ + { + "metric_id": "waso_accuracy", + "type": "numeric_check", + "target_key": "waso_min", + "weight": 50, + "params": { + "gt_value": 126.5, + "tolerance": 6.325 + } + }, + { + "metric_id": "awakening_count_accuracy", + "type": "numeric_check", + "target_key": "awakening_count", + "weight": 50, + "params": { + "gt_value": 27, + "tolerance": 1 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case4/case4_02.json b/sleep_assessment/cases/case4/case4_02.json new file mode 100644 index 0000000000000000000000000000000000000000..26098a718a854fd6c92d84c0177359b84dbf16fc --- /dev/null +++ b/sleep_assessment/cases/case4/case4_02.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "ISRUC_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_02.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two sleep continuity metrics for the recording: Wake After Sleep Onset (WASO) in minutes, and the number of awakenings after sleep onset. Define the analysis interval from the first sleep epoch to the last sleep epoch, and count awakenings as contiguous Wake segments within that interval. Please clearly report both final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two values from the agent's report:\n1) Wake After Sleep Onset (WASO) in minutes\n2) the number of awakenings after sleep onset\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"waso_min\" and \"awakening_count\".\n5. \"waso_min\" must be a FLOAT in minutes or null.\n6. \"awakening_count\" must be an INTEGER or null.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"waso_min\": , \"awakening_count\": }", + "metrics": [ + { + "metric_id": "waso_accuracy", + "type": "numeric_check", + "target_key": "waso_min", + "weight": 50, + "params": { + "gt_value": 67.5, + "tolerance": 3.375 + } + }, + { + "metric_id": "awakening_count_accuracy", + "type": "numeric_check", + "target_key": "awakening_count", + "weight": 50, + "params": { + "gt_value": 30, + "tolerance": 1 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case4/case4_03.json b/sleep_assessment/cases/case4/case4_03.json new file mode 100644 index 0000000000000000000000000000000000000000..66d21af5fb38b1bf972d978995fc863243c5a9af --- /dev/null +++ b/sleep_assessment/cases/case4/case4_03.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "ISRUC_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_03.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two sleep continuity metrics for the recording: Wake After Sleep Onset (WASO) in minutes, and the number of awakenings after sleep onset. Define the analysis interval from the first sleep epoch to the last sleep epoch, and count awakenings as contiguous Wake segments within that interval. Please clearly report both final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two values from the agent's report:\n1) Wake After Sleep Onset (WASO) in minutes\n2) the number of awakenings after sleep onset\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"waso_min\" and \"awakening_count\".\n5. \"waso_min\" must be a FLOAT in minutes or null.\n6. \"awakening_count\" must be an INTEGER or null.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"waso_min\": , \"awakening_count\": }", + "metrics": [ + { + "metric_id": "waso_accuracy", + "type": "numeric_check", + "target_key": "waso_min", + "weight": 50, + "params": { + "gt_value": 62.5, + "tolerance": 3.125 + } + }, + { + "metric_id": "awakening_count_accuracy", + "type": "numeric_check", + "target_key": "awakening_count", + "weight": 50, + "params": { + "gt_value": 49, + "tolerance": 2 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case4/case4_04.json b/sleep_assessment/cases/case4/case4_04.json new file mode 100644 index 0000000000000000000000000000000000000000..93b47abfc9638fcb38d91e57cdee1a48130510c0 --- /dev/null +++ b/sleep_assessment/cases/case4/case4_04.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "ISRUC_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_04.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two sleep continuity metrics for the recording: Wake After Sleep Onset (WASO) in minutes, and the number of awakenings after sleep onset. Define the analysis interval from the first sleep epoch to the last sleep epoch, and count awakenings as contiguous Wake segments within that interval. Please clearly report both final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two values from the agent's report:\n1) Wake After Sleep Onset (WASO) in minutes\n2) the number of awakenings after sleep onset\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"waso_min\" and \"awakening_count\".\n5. \"waso_min\" must be a FLOAT in minutes or null.\n6. \"awakening_count\" must be an INTEGER or null.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"waso_min\": , \"awakening_count\": }", + "metrics": [ + { + "metric_id": "waso_accuracy", + "type": "numeric_check", + "target_key": "waso_min", + "weight": 50, + "params": { + "gt_value": 13.0, + "tolerance": 0.65 + } + }, + { + "metric_id": "awakening_count_accuracy", + "type": "numeric_check", + "target_key": "awakening_count", + "weight": 50, + "params": { + "gt_value": 22, + "tolerance": 1 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case4/case4_05.json b/sleep_assessment/cases/case4/case4_05.json new file mode 100644 index 0000000000000000000000000000000000000000..5e928f8ac3b622452384b8f511da4deb8c26c716 --- /dev/null +++ b/sleep_assessment/cases/case4/case4_05.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "ISRUC_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_05.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two sleep continuity metrics for the recording: Wake After Sleep Onset (WASO) in minutes, and the number of awakenings after sleep onset. Define the analysis interval from the first sleep epoch to the last sleep epoch, and count awakenings as contiguous Wake segments within that interval. Please clearly report both final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two values from the agent's report:\n1) Wake After Sleep Onset (WASO) in minutes\n2) the number of awakenings after sleep onset\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"waso_min\" and \"awakening_count\".\n5. \"waso_min\" must be a FLOAT in minutes or null.\n6. \"awakening_count\" must be an INTEGER or null.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"waso_min\": , \"awakening_count\": }", + "metrics": [ + { + "metric_id": "waso_accuracy", + "type": "numeric_check", + "target_key": "waso_min", + "weight": 50, + "params": { + "gt_value": 47.5, + "tolerance": 2.375 + } + }, + { + "metric_id": "awakening_count_accuracy", + "type": "numeric_check", + "target_key": "awakening_count", + "weight": 50, + "params": { + "gt_value": 20, + "tolerance": 1 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case4/case4_06.json b/sleep_assessment/cases/case4/case4_06.json new file mode 100644 index 0000000000000000000000000000000000000000..5dff3457c273c5568e10467a0cd120c9c7a2d608 --- /dev/null +++ b/sleep_assessment/cases/case4/case4_06.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "HMC_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_01.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two sleep continuity metrics for the recording: Wake After Sleep Onset (WASO) in minutes, and the number of awakenings after sleep onset. Define the analysis interval from the first sleep epoch to the last sleep epoch, and count awakenings as contiguous Wake segments within that interval. Please clearly report both final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two values from the agent's report:\n1) Wake After Sleep Onset (WASO) in minutes\n2) the number of awakenings after sleep onset\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"waso_min\" and \"awakening_count\".\n5. \"waso_min\" must be a FLOAT in minutes or null.\n6. \"awakening_count\" must be an INTEGER or null.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"waso_min\": , \"awakening_count\": }", + "metrics": [ + { + "metric_id": "waso_accuracy", + "type": "numeric_check", + "target_key": "waso_min", + "weight": 50, + "params": { + "gt_value": 66.5, + "tolerance": 3.325 + } + }, + { + "metric_id": "awakening_count_accuracy", + "type": "numeric_check", + "target_key": "awakening_count", + "weight": 50, + "params": { + "gt_value": 12, + "tolerance": 0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case4/case4_07.json b/sleep_assessment/cases/case4/case4_07.json new file mode 100644 index 0000000000000000000000000000000000000000..82caa58a61c2a01a8c9a0c18ebdcfea965d9c02c --- /dev/null +++ b/sleep_assessment/cases/case4/case4_07.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "HMC_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_02.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two sleep continuity metrics for the recording: Wake After Sleep Onset (WASO) in minutes, and the number of awakenings after sleep onset. Define the analysis interval from the first sleep epoch to the last sleep epoch, and count awakenings as contiguous Wake segments within that interval. Please clearly report both final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two values from the agent's report:\n1) Wake After Sleep Onset (WASO) in minutes\n2) the number of awakenings after sleep onset\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"waso_min\" and \"awakening_count\".\n5. \"waso_min\" must be a FLOAT in minutes or null.\n6. \"awakening_count\" must be an INTEGER or null.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"waso_min\": , \"awakening_count\": }", + "metrics": [ + { + "metric_id": "waso_accuracy", + "type": "numeric_check", + "target_key": "waso_min", + "weight": 50, + "params": { + "gt_value": 37.0, + "tolerance": 1.85 + } + }, + { + "metric_id": "awakening_count_accuracy", + "type": "numeric_check", + "target_key": "awakening_count", + "weight": 50, + "params": { + "gt_value": 20, + "tolerance": 1 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case4/case4_08.json b/sleep_assessment/cases/case4/case4_08.json new file mode 100644 index 0000000000000000000000000000000000000000..92c226c906bdcfde0bcc923cfffd089277f0bc9a --- /dev/null +++ b/sleep_assessment/cases/case4/case4_08.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "HMC_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_03.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two sleep continuity metrics for the recording: Wake After Sleep Onset (WASO) in minutes, and the number of awakenings after sleep onset. Define the analysis interval from the first sleep epoch to the last sleep epoch, and count awakenings as contiguous Wake segments within that interval. Please clearly report both final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two values from the agent's report:\n1) Wake After Sleep Onset (WASO) in minutes\n2) the number of awakenings after sleep onset\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"waso_min\" and \"awakening_count\".\n5. \"waso_min\" must be a FLOAT in minutes or null.\n6. \"awakening_count\" must be an INTEGER or null.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"waso_min\": , \"awakening_count\": }", + "metrics": [ + { + "metric_id": "waso_accuracy", + "type": "numeric_check", + "target_key": "waso_min", + "weight": 50, + "params": { + "gt_value": 195.5, + "tolerance": 9.775 + } + }, + { + "metric_id": "awakening_count_accuracy", + "type": "numeric_check", + "target_key": "awakening_count", + "weight": 50, + "params": { + "gt_value": 33, + "tolerance": 1 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case4/case4_09.json b/sleep_assessment/cases/case4/case4_09.json new file mode 100644 index 0000000000000000000000000000000000000000..ae40268e67b63974b0f6bf64ea1189b63c4473d5 --- /dev/null +++ b/sleep_assessment/cases/case4/case4_09.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "HMC_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_04.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two sleep continuity metrics for the recording: Wake After Sleep Onset (WASO) in minutes, and the number of awakenings after sleep onset. Define the analysis interval from the first sleep epoch to the last sleep epoch, and count awakenings as contiguous Wake segments within that interval. Please clearly report both final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two values from the agent's report:\n1) Wake After Sleep Onset (WASO) in minutes\n2) the number of awakenings after sleep onset\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"waso_min\" and \"awakening_count\".\n5. \"waso_min\" must be a FLOAT in minutes or null.\n6. \"awakening_count\" must be an INTEGER or null.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"waso_min\": , \"awakening_count\": }", + "metrics": [ + { + "metric_id": "waso_accuracy", + "type": "numeric_check", + "target_key": "waso_min", + "weight": 50, + "params": { + "gt_value": 33.5, + "tolerance": 1.675 + } + }, + { + "metric_id": "awakening_count_accuracy", + "type": "numeric_check", + "target_key": "awakening_count", + "weight": 50, + "params": { + "gt_value": 28, + "tolerance": 1 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case4/case4_10.json b/sleep_assessment/cases/case4/case4_10.json new file mode 100644 index 0000000000000000000000000000000000000000..9b8cda3d8e9a2eba45750092e46264d1c36e5a72 --- /dev/null +++ b/sleep_assessment/cases/case4/case4_10.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "HMC_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_05.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two sleep continuity metrics for the recording: Wake After Sleep Onset (WASO) in minutes, and the number of awakenings after sleep onset. Define the analysis interval from the first sleep epoch to the last sleep epoch, and count awakenings as contiguous Wake segments within that interval. Please clearly report both final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two values from the agent's report:\n1) Wake After Sleep Onset (WASO) in minutes\n2) the number of awakenings after sleep onset\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"waso_min\" and \"awakening_count\".\n5. \"waso_min\" must be a FLOAT in minutes or null.\n6. \"awakening_count\" must be an INTEGER or null.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"waso_min\": , \"awakening_count\": }", + "metrics": [ + { + "metric_id": "waso_accuracy", + "type": "numeric_check", + "target_key": "waso_min", + "weight": 50, + "params": { + "gt_value": 76.5, + "tolerance": 3.825 + } + }, + { + "metric_id": "awakening_count_accuracy", + "type": "numeric_check", + "target_key": "awakening_count", + "weight": 50, + "params": { + "gt_value": 44, + "tolerance": 2 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case4/case4_11.json b/sleep_assessment/cases/case4/case4_11.json new file mode 100644 index 0000000000000000000000000000000000000000..13970e1a6a78a9700d2d7e7c624ee923c8778437 --- /dev/null +++ b/sleep_assessment/cases/case4/case4_11.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "SHHS1_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_01.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two sleep continuity metrics for the recording: Wake After Sleep Onset (WASO) in minutes, and the number of awakenings after sleep onset. Define the analysis interval from the first sleep epoch to the last sleep epoch, and count awakenings as contiguous Wake segments within that interval. Please clearly report both final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two values from the agent's report:\n1) Wake After Sleep Onset (WASO) in minutes\n2) the number of awakenings after sleep onset\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"waso_min\" and \"awakening_count\".\n5. \"waso_min\" must be a FLOAT in minutes or null.\n6. \"awakening_count\" must be an INTEGER or null.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"waso_min\": , \"awakening_count\": }", + "metrics": [ + { + "metric_id": "waso_accuracy", + "type": "numeric_check", + "target_key": "waso_min", + "weight": 50, + "params": { + "gt_value": 65.0, + "tolerance": 3.25 + } + }, + { + "metric_id": "awakening_count_accuracy", + "type": "numeric_check", + "target_key": "awakening_count", + "weight": 50, + "params": { + "gt_value": 46, + "tolerance": 2 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case4/case4_12.json b/sleep_assessment/cases/case4/case4_12.json new file mode 100644 index 0000000000000000000000000000000000000000..8e8ee87ce2273eb294eef47811a3f8e93e55b751 --- /dev/null +++ b/sleep_assessment/cases/case4/case4_12.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "SHHS1_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_02.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two sleep continuity metrics for the recording: Wake After Sleep Onset (WASO) in minutes, and the number of awakenings after sleep onset. Define the analysis interval from the first sleep epoch to the last sleep epoch, and count awakenings as contiguous Wake segments within that interval. Please clearly report both final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two values from the agent's report:\n1) Wake After Sleep Onset (WASO) in minutes\n2) the number of awakenings after sleep onset\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"waso_min\" and \"awakening_count\".\n5. \"waso_min\" must be a FLOAT in minutes or null.\n6. \"awakening_count\" must be an INTEGER or null.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"waso_min\": , \"awakening_count\": }", + "metrics": [ + { + "metric_id": "waso_accuracy", + "type": "numeric_check", + "target_key": "waso_min", + "weight": 50, + "params": { + "gt_value": 43.0, + "tolerance": 2.15 + } + }, + { + "metric_id": "awakening_count_accuracy", + "type": "numeric_check", + "target_key": "awakening_count", + "weight": 50, + "params": { + "gt_value": 14, + "tolerance": 0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case4/case4_13.json b/sleep_assessment/cases/case4/case4_13.json new file mode 100644 index 0000000000000000000000000000000000000000..651961cadcb5d946da3743c04c0e20279ce940d9 --- /dev/null +++ b/sleep_assessment/cases/case4/case4_13.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "SHHS1_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_03.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two sleep continuity metrics for the recording: Wake After Sleep Onset (WASO) in minutes, and the number of awakenings after sleep onset. Define the analysis interval from the first sleep epoch to the last sleep epoch, and count awakenings as contiguous Wake segments within that interval. Please clearly report both final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two values from the agent's report:\n1) Wake After Sleep Onset (WASO) in minutes\n2) the number of awakenings after sleep onset\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"waso_min\" and \"awakening_count\".\n5. \"waso_min\" must be a FLOAT in minutes or null.\n6. \"awakening_count\" must be an INTEGER or null.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"waso_min\": , \"awakening_count\": }", + "metrics": [ + { + "metric_id": "waso_accuracy", + "type": "numeric_check", + "target_key": "waso_min", + "weight": 50, + "params": { + "gt_value": 73.0, + "tolerance": 3.6500000000000004 + } + }, + { + "metric_id": "awakening_count_accuracy", + "type": "numeric_check", + "target_key": "awakening_count", + "weight": 50, + "params": { + "gt_value": 31, + "tolerance": 1 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case4/case4_14.json b/sleep_assessment/cases/case4/case4_14.json new file mode 100644 index 0000000000000000000000000000000000000000..b6381e2880dbfdc096dab091e1f19850ea827270 --- /dev/null +++ b/sleep_assessment/cases/case4/case4_14.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "SHHS1_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_04.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two sleep continuity metrics for the recording: Wake After Sleep Onset (WASO) in minutes, and the number of awakenings after sleep onset. Define the analysis interval from the first sleep epoch to the last sleep epoch, and count awakenings as contiguous Wake segments within that interval. Please clearly report both final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two values from the agent's report:\n1) Wake After Sleep Onset (WASO) in minutes\n2) the number of awakenings after sleep onset\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"waso_min\" and \"awakening_count\".\n5. \"waso_min\" must be a FLOAT in minutes or null.\n6. \"awakening_count\" must be an INTEGER or null.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"waso_min\": , \"awakening_count\": }", + "metrics": [ + { + "metric_id": "waso_accuracy", + "type": "numeric_check", + "target_key": "waso_min", + "weight": 50, + "params": { + "gt_value": 43.5, + "tolerance": 2.1750000000000003 + } + }, + { + "metric_id": "awakening_count_accuracy", + "type": "numeric_check", + "target_key": "awakening_count", + "weight": 50, + "params": { + "gt_value": 23, + "tolerance": 1 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case4/case4_15.json b/sleep_assessment/cases/case4/case4_15.json new file mode 100644 index 0000000000000000000000000000000000000000..8407cbb4dd6563b432ac4ed7acdd091384212303 --- /dev/null +++ b/sleep_assessment/cases/case4/case4_15.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "SHHS1_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_05.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two sleep continuity metrics for the recording: Wake After Sleep Onset (WASO) in minutes, and the number of awakenings after sleep onset. Define the analysis interval from the first sleep epoch to the last sleep epoch, and count awakenings as contiguous Wake segments within that interval. Please clearly report both final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two values from the agent's report:\n1) Wake After Sleep Onset (WASO) in minutes\n2) the number of awakenings after sleep onset\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"waso_min\" and \"awakening_count\".\n5. \"waso_min\" must be a FLOAT in minutes or null.\n6. \"awakening_count\" must be an INTEGER or null.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"waso_min\": , \"awakening_count\": }", + "metrics": [ + { + "metric_id": "waso_accuracy", + "type": "numeric_check", + "target_key": "waso_min", + "weight": 50, + "params": { + "gt_value": 100.0, + "tolerance": 5.0 + } + }, + { + "metric_id": "awakening_count_accuracy", + "type": "numeric_check", + "target_key": "awakening_count", + "weight": 50, + "params": { + "gt_value": 35, + "tolerance": 1 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case4/case4_16.json b/sleep_assessment/cases/case4/case4_16.json new file mode 100644 index 0000000000000000000000000000000000000000..2cc4545dbd539063b887e8ad0b5b530b43829c7e --- /dev/null +++ b/sleep_assessment/cases/case4/case4_16.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "MASSSS3_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_01.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two sleep continuity metrics for the recording: Wake After Sleep Onset (WASO) in minutes, and the number of awakenings after sleep onset. Define the analysis interval from the first sleep epoch to the last sleep epoch, and count awakenings as contiguous Wake segments within that interval. Please clearly report both final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two values from the agent's report:\n1) Wake After Sleep Onset (WASO) in minutes\n2) the number of awakenings after sleep onset\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"waso_min\" and \"awakening_count\".\n5. \"waso_min\" must be a FLOAT in minutes or null.\n6. \"awakening_count\" must be an INTEGER or null.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"waso_min\": , \"awakening_count\": }", + "metrics": [ + { + "metric_id": "waso_accuracy", + "type": "numeric_check", + "target_key": "waso_min", + "weight": 50, + "params": { + "gt_value": 30.5, + "tolerance": 1.5250000000000001 + } + }, + { + "metric_id": "awakening_count_accuracy", + "type": "numeric_check", + "target_key": "awakening_count", + "weight": 50, + "params": { + "gt_value": 22, + "tolerance": 1 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case4/case4_17.json b/sleep_assessment/cases/case4/case4_17.json new file mode 100644 index 0000000000000000000000000000000000000000..10e6deb7cb514337843354317d0038389e3172b5 --- /dev/null +++ b/sleep_assessment/cases/case4/case4_17.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "MASSSS3_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_02.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two sleep continuity metrics for the recording: Wake After Sleep Onset (WASO) in minutes, and the number of awakenings after sleep onset. Define the analysis interval from the first sleep epoch to the last sleep epoch, and count awakenings as contiguous Wake segments within that interval. Please clearly report both final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two values from the agent's report:\n1) Wake After Sleep Onset (WASO) in minutes\n2) the number of awakenings after sleep onset\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"waso_min\" and \"awakening_count\".\n5. \"waso_min\" must be a FLOAT in minutes or null.\n6. \"awakening_count\" must be an INTEGER or null.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"waso_min\": , \"awakening_count\": }", + "metrics": [ + { + "metric_id": "waso_accuracy", + "type": "numeric_check", + "target_key": "waso_min", + "weight": 50, + "params": { + "gt_value": 37.5, + "tolerance": 1.875 + } + }, + { + "metric_id": "awakening_count_accuracy", + "type": "numeric_check", + "target_key": "awakening_count", + "weight": 50, + "params": { + "gt_value": 31, + "tolerance": 1 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case4/case4_18.json b/sleep_assessment/cases/case4/case4_18.json new file mode 100644 index 0000000000000000000000000000000000000000..91c1d1d75f5e6540313b001bf4efbea6037521d8 --- /dev/null +++ b/sleep_assessment/cases/case4/case4_18.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "MASSSS3_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_03.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two sleep continuity metrics for the recording: Wake After Sleep Onset (WASO) in minutes, and the number of awakenings after sleep onset. Define the analysis interval from the first sleep epoch to the last sleep epoch, and count awakenings as contiguous Wake segments within that interval. Please clearly report both final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two values from the agent's report:\n1) Wake After Sleep Onset (WASO) in minutes\n2) the number of awakenings after sleep onset\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"waso_min\" and \"awakening_count\".\n5. \"waso_min\" must be a FLOAT in minutes or null.\n6. \"awakening_count\" must be an INTEGER or null.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"waso_min\": , \"awakening_count\": }", + "metrics": [ + { + "metric_id": "waso_accuracy", + "type": "numeric_check", + "target_key": "waso_min", + "weight": 50, + "params": { + "gt_value": 19.0, + "tolerance": 0.9500000000000001 + } + }, + { + "metric_id": "awakening_count_accuracy", + "type": "numeric_check", + "target_key": "awakening_count", + "weight": 50, + "params": { + "gt_value": 19, + "tolerance": 0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case4/case4_19.json b/sleep_assessment/cases/case4/case4_19.json new file mode 100644 index 0000000000000000000000000000000000000000..914a9ed923e6bc05a6b59fbac48035cf4d62f666 --- /dev/null +++ b/sleep_assessment/cases/case4/case4_19.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "MASSSS3_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_04.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two sleep continuity metrics for the recording: Wake After Sleep Onset (WASO) in minutes, and the number of awakenings after sleep onset. Define the analysis interval from the first sleep epoch to the last sleep epoch, and count awakenings as contiguous Wake segments within that interval. Please clearly report both final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two values from the agent's report:\n1) Wake After Sleep Onset (WASO) in minutes\n2) the number of awakenings after sleep onset\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"waso_min\" and \"awakening_count\".\n5. \"waso_min\" must be a FLOAT in minutes or null.\n6. \"awakening_count\" must be an INTEGER or null.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"waso_min\": , \"awakening_count\": }", + "metrics": [ + { + "metric_id": "waso_accuracy", + "type": "numeric_check", + "target_key": "waso_min", + "weight": 50, + "params": { + "gt_value": 3.5, + "tolerance": 0.5 + } + }, + { + "metric_id": "awakening_count_accuracy", + "type": "numeric_check", + "target_key": "awakening_count", + "weight": 50, + "params": { + "gt_value": 7, + "tolerance": 0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case4/case4_20.json b/sleep_assessment/cases/case4/case4_20.json new file mode 100644 index 0000000000000000000000000000000000000000..36c530f0df5d8ab8a1674ed62919a1bf2b3e22f8 --- /dev/null +++ b/sleep_assessment/cases/case4/case4_20.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "MASSSS3_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_05.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two sleep continuity metrics for the recording: Wake After Sleep Onset (WASO) in minutes, and the number of awakenings after sleep onset. Define the analysis interval from the first sleep epoch to the last sleep epoch, and count awakenings as contiguous Wake segments within that interval. Please clearly report both final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two values from the agent's report:\n1) Wake After Sleep Onset (WASO) in minutes\n2) the number of awakenings after sleep onset\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"waso_min\" and \"awakening_count\".\n5. \"waso_min\" must be a FLOAT in minutes or null.\n6. \"awakening_count\" must be an INTEGER or null.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"waso_min\": , \"awakening_count\": }", + "metrics": [ + { + "metric_id": "waso_accuracy", + "type": "numeric_check", + "target_key": "waso_min", + "weight": 50, + "params": { + "gt_value": 19.5, + "tolerance": 0.9750000000000001 + } + }, + { + "metric_id": "awakening_count_accuracy", + "type": "numeric_check", + "target_key": "awakening_count", + "weight": 50, + "params": { + "gt_value": 23, + "tolerance": 1 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case4/case4_21.json b/sleep_assessment/cases/case4/case4_21.json new file mode 100644 index 0000000000000000000000000000000000000000..b72b7f8afa232806b3ab94b3790c264ffc3752d5 --- /dev/null +++ b/sleep_assessment/cases/case4/case4_21.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "Physionet2018_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_01.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two sleep continuity metrics for the recording: Wake After Sleep Onset (WASO) in minutes, and the number of awakenings after sleep onset. Define the analysis interval from the first sleep epoch to the last sleep epoch, and count awakenings as contiguous Wake segments within that interval. Please clearly report both final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two values from the agent's report:\n1) Wake After Sleep Onset (WASO) in minutes\n2) the number of awakenings after sleep onset\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"waso_min\" and \"awakening_count\".\n5. \"waso_min\" must be a FLOAT in minutes or null.\n6. \"awakening_count\" must be an INTEGER or null.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"waso_min\": , \"awakening_count\": }", + "metrics": [ + { + "metric_id": "waso_accuracy", + "type": "numeric_check", + "target_key": "waso_min", + "weight": 50, + "params": { + "gt_value": 151.5, + "tolerance": 7.575 + } + }, + { + "metric_id": "awakening_count_accuracy", + "type": "numeric_check", + "target_key": "awakening_count", + "weight": 50, + "params": { + "gt_value": 27, + "tolerance": 1 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case4/case4_22.json b/sleep_assessment/cases/case4/case4_22.json new file mode 100644 index 0000000000000000000000000000000000000000..72abb7dac0a0f9fbe0025a1346607eefa530d469 --- /dev/null +++ b/sleep_assessment/cases/case4/case4_22.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "Physionet2018_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_02.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two sleep continuity metrics for the recording: Wake After Sleep Onset (WASO) in minutes, and the number of awakenings after sleep onset. Define the analysis interval from the first sleep epoch to the last sleep epoch, and count awakenings as contiguous Wake segments within that interval. Please clearly report both final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two values from the agent's report:\n1) Wake After Sleep Onset (WASO) in minutes\n2) the number of awakenings after sleep onset\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"waso_min\" and \"awakening_count\".\n5. \"waso_min\" must be a FLOAT in minutes or null.\n6. \"awakening_count\" must be an INTEGER or null.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"waso_min\": , \"awakening_count\": }", + "metrics": [ + { + "metric_id": "waso_accuracy", + "type": "numeric_check", + "target_key": "waso_min", + "weight": 50, + "params": { + "gt_value": 148.0, + "tolerance": 7.4 + } + }, + { + "metric_id": "awakening_count_accuracy", + "type": "numeric_check", + "target_key": "awakening_count", + "weight": 50, + "params": { + "gt_value": 31, + "tolerance": 1 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case4/case4_23.json b/sleep_assessment/cases/case4/case4_23.json new file mode 100644 index 0000000000000000000000000000000000000000..75ad85b5409176c22cf181f0a52321ff16234eec --- /dev/null +++ b/sleep_assessment/cases/case4/case4_23.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "Physionet2018_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_03.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two sleep continuity metrics for the recording: Wake After Sleep Onset (WASO) in minutes, and the number of awakenings after sleep onset. Define the analysis interval from the first sleep epoch to the last sleep epoch, and count awakenings as contiguous Wake segments within that interval. Please clearly report both final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two values from the agent's report:\n1) Wake After Sleep Onset (WASO) in minutes\n2) the number of awakenings after sleep onset\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"waso_min\" and \"awakening_count\".\n5. \"waso_min\" must be a FLOAT in minutes or null.\n6. \"awakening_count\" must be an INTEGER or null.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"waso_min\": , \"awakening_count\": }", + "metrics": [ + { + "metric_id": "waso_accuracy", + "type": "numeric_check", + "target_key": "waso_min", + "weight": 50, + "params": { + "gt_value": 168.5, + "tolerance": 8.425 + } + }, + { + "metric_id": "awakening_count_accuracy", + "type": "numeric_check", + "target_key": "awakening_count", + "weight": 50, + "params": { + "gt_value": 11, + "tolerance": 0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case4/case4_24.json b/sleep_assessment/cases/case4/case4_24.json new file mode 100644 index 0000000000000000000000000000000000000000..1ab15c16d149299833a7f2a037e6f2160c7182b8 --- /dev/null +++ b/sleep_assessment/cases/case4/case4_24.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "Physionet2018_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_04.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two sleep continuity metrics for the recording: Wake After Sleep Onset (WASO) in minutes, and the number of awakenings after sleep onset. Define the analysis interval from the first sleep epoch to the last sleep epoch, and count awakenings as contiguous Wake segments within that interval. Please clearly report both final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two values from the agent's report:\n1) Wake After Sleep Onset (WASO) in minutes\n2) the number of awakenings after sleep onset\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"waso_min\" and \"awakening_count\".\n5. \"waso_min\" must be a FLOAT in minutes or null.\n6. \"awakening_count\" must be an INTEGER or null.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"waso_min\": , \"awakening_count\": }", + "metrics": [ + { + "metric_id": "waso_accuracy", + "type": "numeric_check", + "target_key": "waso_min", + "weight": 50, + "params": { + "gt_value": 40.0, + "tolerance": 2.0 + } + }, + { + "metric_id": "awakening_count_accuracy", + "type": "numeric_check", + "target_key": "awakening_count", + "weight": 50, + "params": { + "gt_value": 21, + "tolerance": 1 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case4/case4_25.json b/sleep_assessment/cases/case4/case4_25.json new file mode 100644 index 0000000000000000000000000000000000000000..7b45ecbede8b069ded756bc47e18b68dba357a08 --- /dev/null +++ b/sleep_assessment/cases/case4/case4_25.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "Physionet2018_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_05.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two sleep continuity metrics for the recording: Wake After Sleep Onset (WASO) in minutes, and the number of awakenings after sleep onset. Define the analysis interval from the first sleep epoch to the last sleep epoch, and count awakenings as contiguous Wake segments within that interval. Please clearly report both final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two values from the agent's report:\n1) Wake After Sleep Onset (WASO) in minutes\n2) the number of awakenings after sleep onset\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"waso_min\" and \"awakening_count\".\n5. \"waso_min\" must be a FLOAT in minutes or null.\n6. \"awakening_count\" must be an INTEGER or null.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"waso_min\": , \"awakening_count\": }", + "metrics": [ + { + "metric_id": "waso_accuracy", + "type": "numeric_check", + "target_key": "waso_min", + "weight": 50, + "params": { + "gt_value": 28.5, + "tolerance": 1.425 + } + }, + { + "metric_id": "awakening_count_accuracy", + "type": "numeric_check", + "target_key": "awakening_count", + "weight": 50, + "params": { + "gt_value": 4, + "tolerance": 0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case5/case5_01.json b/sleep_assessment/cases/case5/case5_01.json new file mode 100644 index 0000000000000000000000000000000000000000..a29814c7cabc476bdf5fa6e3b433f22ca85b63d2 --- /dev/null +++ b/sleep_assessment/cases/case5/case5_01.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "ISRUC_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_01.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three sleep-stage metrics for the recording: NREM duration in minutes, REM sleep ratio as a percentage of total sleep time, and REM latency in minutes. Define REM latency as the time from the first sleep epoch to the first REM epoch. Please clearly report all three final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) NREM duration in minutes\n2) REM sleep ratio as a percentage of total sleep time\n3) REM latency in minutes\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"nrem_duration_min\", \"rem_sleep_ratio_percent\", and \"rem_latency_min\".\n5. All values must be FLOATS or null.\n6. \"nrem_duration_min\" and \"rem_latency_min\" are measured in minutes.\n7. \"rem_sleep_ratio_percent\" is a percentage value; if the report says 18.5%, output 18.5.\n8. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"nrem_duration_min\": , \"rem_sleep_ratio_percent\": , \"rem_latency_min\": }", + "metrics": [ + { + "metric_id": "nrem_duration_accuracy", + "type": "numeric_check", + "target_key": "nrem_duration_min", + "weight": 34, + "params": { + "gt_value": 249.0, + "tolerance": 12.450000000000001 + } + }, + { + "metric_id": "rem_sleep_ratio_accuracy", + "type": "numeric_check", + "target_key": "rem_sleep_ratio_percent", + "weight": 33, + "params": { + "gt_value": 19.155844155844157, + "tolerance": 0.9577922077922079 + } + }, + { + "metric_id": "rem_latency_accuracy", + "type": "numeric_check", + "target_key": "rem_latency_min", + "weight": 33, + "params": { + "gt_value": 165.5, + "tolerance": 8.275 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case5/case5_02.json b/sleep_assessment/cases/case5/case5_02.json new file mode 100644 index 0000000000000000000000000000000000000000..0392f3c3ccc0be1a424de09c498c9de82b5fb9b7 --- /dev/null +++ b/sleep_assessment/cases/case5/case5_02.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "ISRUC_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_02.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three sleep-stage metrics for the recording: NREM duration in minutes, REM sleep ratio as a percentage of total sleep time, and REM latency in minutes. Define REM latency as the time from the first sleep epoch to the first REM epoch. Please clearly report all three final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) NREM duration in minutes\n2) REM sleep ratio as a percentage of total sleep time\n3) REM latency in minutes\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"nrem_duration_min\", \"rem_sleep_ratio_percent\", and \"rem_latency_min\".\n5. All values must be FLOATS or null.\n6. \"nrem_duration_min\" and \"rem_latency_min\" are measured in minutes.\n7. \"rem_sleep_ratio_percent\" is a percentage value; if the report says 18.5%, output 18.5.\n8. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"nrem_duration_min\": , \"rem_sleep_ratio_percent\": , \"rem_latency_min\": }", + "metrics": [ + { + "metric_id": "nrem_duration_accuracy", + "type": "numeric_check", + "target_key": "nrem_duration_min", + "weight": 34, + "params": { + "gt_value": 308.5, + "tolerance": 15.425 + } + }, + { + "metric_id": "rem_sleep_ratio_accuracy", + "type": "numeric_check", + "target_key": "rem_sleep_ratio_percent", + "weight": 33, + "params": { + "gt_value": 14.186369958275382, + "tolerance": 0.7093184979137691 + } + }, + { + "metric_id": "rem_latency_accuracy", + "type": "numeric_check", + "target_key": "rem_latency_min", + "weight": 33, + "params": { + "gt_value": 105.5, + "tolerance": 5.275 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case5/case5_03.json b/sleep_assessment/cases/case5/case5_03.json new file mode 100644 index 0000000000000000000000000000000000000000..5bdd267cf7bb2cdedb5292c31b4ae365da93b028 --- /dev/null +++ b/sleep_assessment/cases/case5/case5_03.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "ISRUC_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_03.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three sleep-stage metrics for the recording: NREM duration in minutes, REM sleep ratio as a percentage of total sleep time, and REM latency in minutes. Define REM latency as the time from the first sleep epoch to the first REM epoch. Please clearly report all three final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) NREM duration in minutes\n2) REM sleep ratio as a percentage of total sleep time\n3) REM latency in minutes\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"nrem_duration_min\", \"rem_sleep_ratio_percent\", and \"rem_latency_min\".\n5. All values must be FLOATS or null.\n6. \"nrem_duration_min\" and \"rem_latency_min\" are measured in minutes.\n7. \"rem_sleep_ratio_percent\" is a percentage value; if the report says 18.5%, output 18.5.\n8. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"nrem_duration_min\": , \"rem_sleep_ratio_percent\": , \"rem_latency_min\": }", + "metrics": [ + { + "metric_id": "nrem_duration_accuracy", + "type": "numeric_check", + "target_key": "nrem_duration_min", + "weight": 34, + "params": { + "gt_value": 292.0, + "tolerance": 14.600000000000001 + } + }, + { + "metric_id": "rem_sleep_ratio_accuracy", + "type": "numeric_check", + "target_key": "rem_sleep_ratio_percent", + "weight": 33, + "params": { + "gt_value": 27.990135635018497, + "tolerance": 1.399506781750925 + } + }, + { + "metric_id": "rem_latency_accuracy", + "type": "numeric_check", + "target_key": "rem_latency_min", + "weight": 33, + "params": { + "gt_value": 158.0, + "tolerance": 7.9 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case5/case5_04.json b/sleep_assessment/cases/case5/case5_04.json new file mode 100644 index 0000000000000000000000000000000000000000..875737dd2c8cad491054385ad84582ab7a84efcd --- /dev/null +++ b/sleep_assessment/cases/case5/case5_04.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "ISRUC_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_04.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three sleep-stage metrics for the recording: NREM duration in minutes, REM sleep ratio as a percentage of total sleep time, and REM latency in minutes. Define REM latency as the time from the first sleep epoch to the first REM epoch. Please clearly report all three final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) NREM duration in minutes\n2) REM sleep ratio as a percentage of total sleep time\n3) REM latency in minutes\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"nrem_duration_min\", \"rem_sleep_ratio_percent\", and \"rem_latency_min\".\n5. All values must be FLOATS or null.\n6. \"nrem_duration_min\" and \"rem_latency_min\" are measured in minutes.\n7. \"rem_sleep_ratio_percent\" is a percentage value; if the report says 18.5%, output 18.5.\n8. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"nrem_duration_min\": , \"rem_sleep_ratio_percent\": , \"rem_latency_min\": }", + "metrics": [ + { + "metric_id": "nrem_duration_accuracy", + "type": "numeric_check", + "target_key": "nrem_duration_min", + "weight": 34, + "params": { + "gt_value": 352.5, + "tolerance": 17.625 + } + }, + { + "metric_id": "rem_sleep_ratio_accuracy", + "type": "numeric_check", + "target_key": "rem_sleep_ratio_percent", + "weight": 33, + "params": { + "gt_value": 24.59893048128342, + "tolerance": 1.2299465240641712 + } + }, + { + "metric_id": "rem_latency_accuracy", + "type": "numeric_check", + "target_key": "rem_latency_min", + "weight": 33, + "params": { + "gt_value": 79.5, + "tolerance": 3.975 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case5/case5_05.json b/sleep_assessment/cases/case5/case5_05.json new file mode 100644 index 0000000000000000000000000000000000000000..b4db5ed151d06b04de92419665aae0bb432c8815 --- /dev/null +++ b/sleep_assessment/cases/case5/case5_05.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "ISRUC_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_05.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three sleep-stage metrics for the recording: NREM duration in minutes, REM sleep ratio as a percentage of total sleep time, and REM latency in minutes. Define REM latency as the time from the first sleep epoch to the first REM epoch. Please clearly report all three final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) NREM duration in minutes\n2) REM sleep ratio as a percentage of total sleep time\n3) REM latency in minutes\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"nrem_duration_min\", \"rem_sleep_ratio_percent\", and \"rem_latency_min\".\n5. All values must be FLOATS or null.\n6. \"nrem_duration_min\" and \"rem_latency_min\" are measured in minutes.\n7. \"rem_sleep_ratio_percent\" is a percentage value; if the report says 18.5%, output 18.5.\n8. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"nrem_duration_min\": , \"rem_sleep_ratio_percent\": , \"rem_latency_min\": }", + "metrics": [ + { + "metric_id": "nrem_duration_accuracy", + "type": "numeric_check", + "target_key": "nrem_duration_min", + "weight": 34, + "params": { + "gt_value": 268.5, + "tolerance": 13.425 + } + }, + { + "metric_id": "rem_sleep_ratio_accuracy", + "type": "numeric_check", + "target_key": "rem_sleep_ratio_percent", + "weight": 33, + "params": { + "gt_value": 7.253886010362694, + "tolerance": 0.3626943005181347 + } + }, + { + "metric_id": "rem_latency_accuracy", + "type": "numeric_check", + "target_key": "rem_latency_min", + "weight": 33, + "params": { + "gt_value": 126.5, + "tolerance": 6.325 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case5/case5_06.json b/sleep_assessment/cases/case5/case5_06.json new file mode 100644 index 0000000000000000000000000000000000000000..03cc5c38e9a316590637b54047f27f1e10cf457b --- /dev/null +++ b/sleep_assessment/cases/case5/case5_06.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "HMC_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_01.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three sleep-stage metrics for the recording: NREM duration in minutes, REM sleep ratio as a percentage of total sleep time, and REM latency in minutes. Define REM latency as the time from the first sleep epoch to the first REM epoch. Please clearly report all three final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) NREM duration in minutes\n2) REM sleep ratio as a percentage of total sleep time\n3) REM latency in minutes\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"nrem_duration_min\", \"rem_sleep_ratio_percent\", and \"rem_latency_min\".\n5. All values must be FLOATS or null.\n6. \"nrem_duration_min\" and \"rem_latency_min\" are measured in minutes.\n7. \"rem_sleep_ratio_percent\" is a percentage value; if the report says 18.5%, output 18.5.\n8. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"nrem_duration_min\": , \"rem_sleep_ratio_percent\": , \"rem_latency_min\": }", + "metrics": [ + { + "metric_id": "nrem_duration_accuracy", + "type": "numeric_check", + "target_key": "nrem_duration_min", + "weight": 34, + "params": { + "gt_value": 281.0, + "tolerance": 14.05 + } + }, + { + "metric_id": "rem_sleep_ratio_accuracy", + "type": "numeric_check", + "target_key": "rem_sleep_ratio_percent", + "weight": 33, + "params": { + "gt_value": 20.056899004267425, + "tolerance": 1.0028449502133714 + } + }, + { + "metric_id": "rem_latency_accuracy", + "type": "numeric_check", + "target_key": "rem_latency_min", + "weight": 33, + "params": { + "gt_value": 73.5, + "tolerance": 3.6750000000000003 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case5/case5_07.json b/sleep_assessment/cases/case5/case5_07.json new file mode 100644 index 0000000000000000000000000000000000000000..6d2f09936dafd09c8a233c9490307708d7d20464 --- /dev/null +++ b/sleep_assessment/cases/case5/case5_07.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "HMC_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_02.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three sleep-stage metrics for the recording: NREM duration in minutes, REM sleep ratio as a percentage of total sleep time, and REM latency in minutes. Define REM latency as the time from the first sleep epoch to the first REM epoch. Please clearly report all three final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) NREM duration in minutes\n2) REM sleep ratio as a percentage of total sleep time\n3) REM latency in minutes\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"nrem_duration_min\", \"rem_sleep_ratio_percent\", and \"rem_latency_min\".\n5. All values must be FLOATS or null.\n6. \"nrem_duration_min\" and \"rem_latency_min\" are measured in minutes.\n7. \"rem_sleep_ratio_percent\" is a percentage value; if the report says 18.5%, output 18.5.\n8. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"nrem_duration_min\": , \"rem_sleep_ratio_percent\": , \"rem_latency_min\": }", + "metrics": [ + { + "metric_id": "nrem_duration_accuracy", + "type": "numeric_check", + "target_key": "nrem_duration_min", + "weight": 34, + "params": { + "gt_value": 300.0, + "tolerance": 15.0 + } + }, + { + "metric_id": "rem_sleep_ratio_accuracy", + "type": "numeric_check", + "target_key": "rem_sleep_ratio_percent", + "weight": 33, + "params": { + "gt_value": 22.48062015503876, + "tolerance": 1.124031007751938 + } + }, + { + "metric_id": "rem_latency_accuracy", + "type": "numeric_check", + "target_key": "rem_latency_min", + "weight": 33, + "params": { + "gt_value": 109.5, + "tolerance": 5.4750000000000005 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case5/case5_08.json b/sleep_assessment/cases/case5/case5_08.json new file mode 100644 index 0000000000000000000000000000000000000000..1a0a18a3369d9c6f23d333a61cf85b0c1178c842 --- /dev/null +++ b/sleep_assessment/cases/case5/case5_08.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "HMC_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_03.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three sleep-stage metrics for the recording: NREM duration in minutes, REM sleep ratio as a percentage of total sleep time, and REM latency in minutes. Define REM latency as the time from the first sleep epoch to the first REM epoch. Please clearly report all three final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) NREM duration in minutes\n2) REM sleep ratio as a percentage of total sleep time\n3) REM latency in minutes\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"nrem_duration_min\", \"rem_sleep_ratio_percent\", and \"rem_latency_min\".\n5. All values must be FLOATS or null.\n6. \"nrem_duration_min\" and \"rem_latency_min\" are measured in minutes.\n7. \"rem_sleep_ratio_percent\" is a percentage value; if the report says 18.5%, output 18.5.\n8. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"nrem_duration_min\": , \"rem_sleep_ratio_percent\": , \"rem_latency_min\": }", + "metrics": [ + { + "metric_id": "nrem_duration_accuracy", + "type": "numeric_check", + "target_key": "nrem_duration_min", + "weight": 34, + "params": { + "gt_value": 199.5, + "tolerance": 9.975000000000001 + } + }, + { + "metric_id": "rem_sleep_ratio_accuracy", + "type": "numeric_check", + "target_key": "rem_sleep_ratio_percent", + "weight": 33, + "params": { + "gt_value": 27.586206896551722, + "tolerance": 1.3793103448275863 + } + }, + { + "metric_id": "rem_latency_accuracy", + "type": "numeric_check", + "target_key": "rem_latency_min", + "weight": 33, + "params": { + "gt_value": 263.0, + "tolerance": 13.15 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case5/case5_09.json b/sleep_assessment/cases/case5/case5_09.json new file mode 100644 index 0000000000000000000000000000000000000000..7700045b33eb9ed105fbcd5ee0f0154d85ffee0b --- /dev/null +++ b/sleep_assessment/cases/case5/case5_09.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "HMC_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_04.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three sleep-stage metrics for the recording: NREM duration in minutes, REM sleep ratio as a percentage of total sleep time, and REM latency in minutes. Define REM latency as the time from the first sleep epoch to the first REM epoch. Please clearly report all three final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) NREM duration in minutes\n2) REM sleep ratio as a percentage of total sleep time\n3) REM latency in minutes\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"nrem_duration_min\", \"rem_sleep_ratio_percent\", and \"rem_latency_min\".\n5. All values must be FLOATS or null.\n6. \"nrem_duration_min\" and \"rem_latency_min\" are measured in minutes.\n7. \"rem_sleep_ratio_percent\" is a percentage value; if the report says 18.5%, output 18.5.\n8. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"nrem_duration_min\": , \"rem_sleep_ratio_percent\": , \"rem_latency_min\": }", + "metrics": [ + { + "metric_id": "nrem_duration_accuracy", + "type": "numeric_check", + "target_key": "nrem_duration_min", + "weight": 34, + "params": { + "gt_value": 344.5, + "tolerance": 17.225 + } + }, + { + "metric_id": "rem_sleep_ratio_accuracy", + "type": "numeric_check", + "target_key": "rem_sleep_ratio_percent", + "weight": 33, + "params": { + "gt_value": 26.38888888888889, + "tolerance": 1.3194444444444446 + } + }, + { + "metric_id": "rem_latency_accuracy", + "type": "numeric_check", + "target_key": "rem_latency_min", + "weight": 33, + "params": { + "gt_value": 46.0, + "tolerance": 2.3000000000000003 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case5/case5_10.json b/sleep_assessment/cases/case5/case5_10.json new file mode 100644 index 0000000000000000000000000000000000000000..4f63ce1edbe16cb81b0dec4eb6ffd5cbec8decfa --- /dev/null +++ b/sleep_assessment/cases/case5/case5_10.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "HMC_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_05.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three sleep-stage metrics for the recording: NREM duration in minutes, REM sleep ratio as a percentage of total sleep time, and REM latency in minutes. Define REM latency as the time from the first sleep epoch to the first REM epoch. Please clearly report all three final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) NREM duration in minutes\n2) REM sleep ratio as a percentage of total sleep time\n3) REM latency in minutes\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"nrem_duration_min\", \"rem_sleep_ratio_percent\", and \"rem_latency_min\".\n5. All values must be FLOATS or null.\n6. \"nrem_duration_min\" and \"rem_latency_min\" are measured in minutes.\n7. \"rem_sleep_ratio_percent\" is a percentage value; if the report says 18.5%, output 18.5.\n8. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"nrem_duration_min\": , \"rem_sleep_ratio_percent\": , \"rem_latency_min\": }", + "metrics": [ + { + "metric_id": "nrem_duration_accuracy", + "type": "numeric_check", + "target_key": "nrem_duration_min", + "weight": 34, + "params": { + "gt_value": 315.5, + "tolerance": 15.775 + } + }, + { + "metric_id": "rem_sleep_ratio_accuracy", + "type": "numeric_check", + "target_key": "rem_sleep_ratio_percent", + "weight": 33, + "params": { + "gt_value": 16.75461741424802, + "tolerance": 0.837730870712401 + } + }, + { + "metric_id": "rem_latency_accuracy", + "type": "numeric_check", + "target_key": "rem_latency_min", + "weight": 33, + "params": { + "gt_value": 186.0, + "tolerance": 9.3 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case5/case5_11.json b/sleep_assessment/cases/case5/case5_11.json new file mode 100644 index 0000000000000000000000000000000000000000..9508480bc551c5f0f27f9b8599cf79893c91b03d --- /dev/null +++ b/sleep_assessment/cases/case5/case5_11.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "SHHS1_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_01.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three sleep-stage metrics for the recording: NREM duration in minutes, REM sleep ratio as a percentage of total sleep time, and REM latency in minutes. Define REM latency as the time from the first sleep epoch to the first REM epoch. Please clearly report all three final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) NREM duration in minutes\n2) REM sleep ratio as a percentage of total sleep time\n3) REM latency in minutes\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"nrem_duration_min\", \"rem_sleep_ratio_percent\", and \"rem_latency_min\".\n5. All values must be FLOATS or null.\n6. \"nrem_duration_min\" and \"rem_latency_min\" are measured in minutes.\n7. \"rem_sleep_ratio_percent\" is a percentage value; if the report says 18.5%, output 18.5.\n8. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"nrem_duration_min\": , \"rem_sleep_ratio_percent\": , \"rem_latency_min\": }", + "metrics": [ + { + "metric_id": "nrem_duration_accuracy", + "type": "numeric_check", + "target_key": "nrem_duration_min", + "weight": 34, + "params": { + "gt_value": 324.5, + "tolerance": 16.225 + } + }, + { + "metric_id": "rem_sleep_ratio_accuracy", + "type": "numeric_check", + "target_key": "rem_sleep_ratio_percent", + "weight": 33, + "params": { + "gt_value": 13.581890812250332, + "tolerance": 0.6790945406125166 + } + }, + { + "metric_id": "rem_latency_accuracy", + "type": "numeric_check", + "target_key": "rem_latency_min", + "weight": 33, + "params": { + "gt_value": 114.0, + "tolerance": 5.7 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case5/case5_12.json b/sleep_assessment/cases/case5/case5_12.json new file mode 100644 index 0000000000000000000000000000000000000000..a5cba3e672226688fd202c041e56b415e61c6588 --- /dev/null +++ b/sleep_assessment/cases/case5/case5_12.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "SHHS1_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_02.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three sleep-stage metrics for the recording: NREM duration in minutes, REM sleep ratio as a percentage of total sleep time, and REM latency in minutes. Define REM latency as the time from the first sleep epoch to the first REM epoch. Please clearly report all three final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) NREM duration in minutes\n2) REM sleep ratio as a percentage of total sleep time\n3) REM latency in minutes\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"nrem_duration_min\", \"rem_sleep_ratio_percent\", and \"rem_latency_min\".\n5. All values must be FLOATS or null.\n6. \"nrem_duration_min\" and \"rem_latency_min\" are measured in minutes.\n7. \"rem_sleep_ratio_percent\" is a percentage value; if the report says 18.5%, output 18.5.\n8. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"nrem_duration_min\": , \"rem_sleep_ratio_percent\": , \"rem_latency_min\": }", + "metrics": [ + { + "metric_id": "nrem_duration_accuracy", + "type": "numeric_check", + "target_key": "nrem_duration_min", + "weight": 34, + "params": { + "gt_value": 151.5, + "tolerance": 7.575 + } + }, + { + "metric_id": "rem_sleep_ratio_accuracy", + "type": "numeric_check", + "target_key": "rem_sleep_ratio_percent", + "weight": 33, + "params": { + "gt_value": 16.75824175824176, + "tolerance": 0.837912087912088 + } + }, + { + "metric_id": "rem_latency_accuracy", + "type": "numeric_check", + "target_key": "rem_latency_min", + "weight": 33, + "params": { + "gt_value": 37.5, + "tolerance": 1.875 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case5/case5_13.json b/sleep_assessment/cases/case5/case5_13.json new file mode 100644 index 0000000000000000000000000000000000000000..a543d4c898195cf47eeb849a5060dab681f52133 --- /dev/null +++ b/sleep_assessment/cases/case5/case5_13.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "SHHS1_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_03.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three sleep-stage metrics for the recording: NREM duration in minutes, REM sleep ratio as a percentage of total sleep time, and REM latency in minutes. Define REM latency as the time from the first sleep epoch to the first REM epoch. Please clearly report all three final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) NREM duration in minutes\n2) REM sleep ratio as a percentage of total sleep time\n3) REM latency in minutes\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"nrem_duration_min\", \"rem_sleep_ratio_percent\", and \"rem_latency_min\".\n5. All values must be FLOATS or null.\n6. \"nrem_duration_min\" and \"rem_latency_min\" are measured in minutes.\n7. \"rem_sleep_ratio_percent\" is a percentage value; if the report says 18.5%, output 18.5.\n8. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"nrem_duration_min\": , \"rem_sleep_ratio_percent\": , \"rem_latency_min\": }", + "metrics": [ + { + "metric_id": "nrem_duration_accuracy", + "type": "numeric_check", + "target_key": "nrem_duration_min", + "weight": 34, + "params": { + "gt_value": 315.5, + "tolerance": 15.775 + } + }, + { + "metric_id": "rem_sleep_ratio_accuracy", + "type": "numeric_check", + "target_key": "rem_sleep_ratio_percent", + "weight": 33, + "params": { + "gt_value": 11.99442119944212, + "tolerance": 0.599721059972106 + } + }, + { + "metric_id": "rem_latency_accuracy", + "type": "numeric_check", + "target_key": "rem_latency_min", + "weight": 33, + "params": { + "gt_value": 142.0, + "tolerance": 7.1000000000000005 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case5/case5_14.json b/sleep_assessment/cases/case5/case5_14.json new file mode 100644 index 0000000000000000000000000000000000000000..290b077e2c658a932d61825df7870536a3a3dea8 --- /dev/null +++ b/sleep_assessment/cases/case5/case5_14.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "SHHS1_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_04.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three sleep-stage metrics for the recording: NREM duration in minutes, REM sleep ratio as a percentage of total sleep time, and REM latency in minutes. Define REM latency as the time from the first sleep epoch to the first REM epoch. Please clearly report all three final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) NREM duration in minutes\n2) REM sleep ratio as a percentage of total sleep time\n3) REM latency in minutes\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"nrem_duration_min\", \"rem_sleep_ratio_percent\", and \"rem_latency_min\".\n5. All values must be FLOATS or null.\n6. \"nrem_duration_min\" and \"rem_latency_min\" are measured in minutes.\n7. \"rem_sleep_ratio_percent\" is a percentage value; if the report says 18.5%, output 18.5.\n8. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"nrem_duration_min\": , \"rem_sleep_ratio_percent\": , \"rem_latency_min\": }", + "metrics": [ + { + "metric_id": "nrem_duration_accuracy", + "type": "numeric_check", + "target_key": "nrem_duration_min", + "weight": 34, + "params": { + "gt_value": 255.0, + "tolerance": 12.75 + } + }, + { + "metric_id": "rem_sleep_ratio_accuracy", + "type": "numeric_check", + "target_key": "rem_sleep_ratio_percent", + "weight": 33, + "params": { + "gt_value": 15.282392026578073, + "tolerance": 0.7641196013289037 + } + }, + { + "metric_id": "rem_latency_accuracy", + "type": "numeric_check", + "target_key": "rem_latency_min", + "weight": 33, + "params": { + "gt_value": 45.0, + "tolerance": 2.25 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case5/case5_15.json b/sleep_assessment/cases/case5/case5_15.json new file mode 100644 index 0000000000000000000000000000000000000000..8c6d1a50d5e074d180355abc81651b8ff4c1dd11 --- /dev/null +++ b/sleep_assessment/cases/case5/case5_15.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "SHHS1_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_05.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three sleep-stage metrics for the recording: NREM duration in minutes, REM sleep ratio as a percentage of total sleep time, and REM latency in minutes. Define REM latency as the time from the first sleep epoch to the first REM epoch. Please clearly report all three final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) NREM duration in minutes\n2) REM sleep ratio as a percentage of total sleep time\n3) REM latency in minutes\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"nrem_duration_min\", \"rem_sleep_ratio_percent\", and \"rem_latency_min\".\n5. All values must be FLOATS or null.\n6. \"nrem_duration_min\" and \"rem_latency_min\" are measured in minutes.\n7. \"rem_sleep_ratio_percent\" is a percentage value; if the report says 18.5%, output 18.5.\n8. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"nrem_duration_min\": , \"rem_sleep_ratio_percent\": , \"rem_latency_min\": }", + "metrics": [ + { + "metric_id": "nrem_duration_accuracy", + "type": "numeric_check", + "target_key": "nrem_duration_min", + "weight": 34, + "params": { + "gt_value": 324.5, + "tolerance": 16.225 + } + }, + { + "metric_id": "rem_sleep_ratio_accuracy", + "type": "numeric_check", + "target_key": "rem_sleep_ratio_percent", + "weight": 33, + "params": { + "gt_value": 12.297297297297296, + "tolerance": 0.6148648648648649 + } + }, + { + "metric_id": "rem_latency_accuracy", + "type": "numeric_check", + "target_key": "rem_latency_min", + "weight": 33, + "params": { + "gt_value": 126.5, + "tolerance": 6.325 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case5/case5_16.json b/sleep_assessment/cases/case5/case5_16.json new file mode 100644 index 0000000000000000000000000000000000000000..9ed3a9944509829edca1adfca480727aa15911ec --- /dev/null +++ b/sleep_assessment/cases/case5/case5_16.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "MASSSS3_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_01.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three sleep-stage metrics for the recording: NREM duration in minutes, REM sleep ratio as a percentage of total sleep time, and REM latency in minutes. Define REM latency as the time from the first sleep epoch to the first REM epoch. Please clearly report all three final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) NREM duration in minutes\n2) REM sleep ratio as a percentage of total sleep time\n3) REM latency in minutes\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"nrem_duration_min\", \"rem_sleep_ratio_percent\", and \"rem_latency_min\".\n5. All values must be FLOATS or null.\n6. \"nrem_duration_min\" and \"rem_latency_min\" are measured in minutes.\n7. \"rem_sleep_ratio_percent\" is a percentage value; if the report says 18.5%, output 18.5.\n8. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"nrem_duration_min\": , \"rem_sleep_ratio_percent\": , \"rem_latency_min\": }", + "metrics": [ + { + "metric_id": "nrem_duration_accuracy", + "type": "numeric_check", + "target_key": "nrem_duration_min", + "weight": 34, + "params": { + "gt_value": 379.0, + "tolerance": 18.95 + } + }, + { + "metric_id": "rem_sleep_ratio_accuracy", + "type": "numeric_check", + "target_key": "rem_sleep_ratio_percent", + "weight": 33, + "params": { + "gt_value": 19.275825346112885, + "tolerance": 0.9637912673056444 + } + }, + { + "metric_id": "rem_latency_accuracy", + "type": "numeric_check", + "target_key": "rem_latency_min", + "weight": 33, + "params": { + "gt_value": 53.5, + "tolerance": 2.6750000000000003 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case5/case5_17.json b/sleep_assessment/cases/case5/case5_17.json new file mode 100644 index 0000000000000000000000000000000000000000..77b59b092bd09672ab890c8f19b394f9883bee97 --- /dev/null +++ b/sleep_assessment/cases/case5/case5_17.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "MASSSS3_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_02.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three sleep-stage metrics for the recording: NREM duration in minutes, REM sleep ratio as a percentage of total sleep time, and REM latency in minutes. Define REM latency as the time from the first sleep epoch to the first REM epoch. Please clearly report all three final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) NREM duration in minutes\n2) REM sleep ratio as a percentage of total sleep time\n3) REM latency in minutes\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"nrem_duration_min\", \"rem_sleep_ratio_percent\", and \"rem_latency_min\".\n5. All values must be FLOATS or null.\n6. \"nrem_duration_min\" and \"rem_latency_min\" are measured in minutes.\n7. \"rem_sleep_ratio_percent\" is a percentage value; if the report says 18.5%, output 18.5.\n8. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"nrem_duration_min\": , \"rem_sleep_ratio_percent\": , \"rem_latency_min\": }", + "metrics": [ + { + "metric_id": "nrem_duration_accuracy", + "type": "numeric_check", + "target_key": "nrem_duration_min", + "weight": 34, + "params": { + "gt_value": 356.5, + "tolerance": 17.825 + } + }, + { + "metric_id": "rem_sleep_ratio_accuracy", + "type": "numeric_check", + "target_key": "rem_sleep_ratio_percent", + "weight": 33, + "params": { + "gt_value": 25.340314136125656, + "tolerance": 1.2670157068062828 + } + }, + { + "metric_id": "rem_latency_accuracy", + "type": "numeric_check", + "target_key": "rem_latency_min", + "weight": 33, + "params": { + "gt_value": 42.0, + "tolerance": 2.1 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case5/case5_18.json b/sleep_assessment/cases/case5/case5_18.json new file mode 100644 index 0000000000000000000000000000000000000000..0e647f060b47557ac0981dc3500dc94f73871672 --- /dev/null +++ b/sleep_assessment/cases/case5/case5_18.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "MASSSS3_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_03.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three sleep-stage metrics for the recording: NREM duration in minutes, REM sleep ratio as a percentage of total sleep time, and REM latency in minutes. Define REM latency as the time from the first sleep epoch to the first REM epoch. Please clearly report all three final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) NREM duration in minutes\n2) REM sleep ratio as a percentage of total sleep time\n3) REM latency in minutes\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"nrem_duration_min\", \"rem_sleep_ratio_percent\", and \"rem_latency_min\".\n5. All values must be FLOATS or null.\n6. \"nrem_duration_min\" and \"rem_latency_min\" are measured in minutes.\n7. \"rem_sleep_ratio_percent\" is a percentage value; if the report says 18.5%, output 18.5.\n8. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"nrem_duration_min\": , \"rem_sleep_ratio_percent\": , \"rem_latency_min\": }", + "metrics": [ + { + "metric_id": "nrem_duration_accuracy", + "type": "numeric_check", + "target_key": "nrem_duration_min", + "weight": 34, + "params": { + "gt_value": 317.5, + "tolerance": 15.875 + } + }, + { + "metric_id": "rem_sleep_ratio_accuracy", + "type": "numeric_check", + "target_key": "rem_sleep_ratio_percent", + "weight": 33, + "params": { + "gt_value": 29.678848283499445, + "tolerance": 1.4839424141749724 + } + }, + { + "metric_id": "rem_latency_accuracy", + "type": "numeric_check", + "target_key": "rem_latency_min", + "weight": 33, + "params": { + "gt_value": 81.5, + "tolerance": 4.075 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case5/case5_19.json b/sleep_assessment/cases/case5/case5_19.json new file mode 100644 index 0000000000000000000000000000000000000000..1e02702db3dc9174b67fe4ba954d4e10d3c56d1b --- /dev/null +++ b/sleep_assessment/cases/case5/case5_19.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "MASSSS3_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_04.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three sleep-stage metrics for the recording: NREM duration in minutes, REM sleep ratio as a percentage of total sleep time, and REM latency in minutes. Define REM latency as the time from the first sleep epoch to the first REM epoch. Please clearly report all three final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) NREM duration in minutes\n2) REM sleep ratio as a percentage of total sleep time\n3) REM latency in minutes\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"nrem_duration_min\", \"rem_sleep_ratio_percent\", and \"rem_latency_min\".\n5. All values must be FLOATS or null.\n6. \"nrem_duration_min\" and \"rem_latency_min\" are measured in minutes.\n7. \"rem_sleep_ratio_percent\" is a percentage value; if the report says 18.5%, output 18.5.\n8. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"nrem_duration_min\": , \"rem_sleep_ratio_percent\": , \"rem_latency_min\": }", + "metrics": [ + { + "metric_id": "nrem_duration_accuracy", + "type": "numeric_check", + "target_key": "nrem_duration_min", + "weight": 34, + "params": { + "gt_value": 328.0, + "tolerance": 16.400000000000002 + } + }, + { + "metric_id": "rem_sleep_ratio_accuracy", + "type": "numeric_check", + "target_key": "rem_sleep_ratio_percent", + "weight": 33, + "params": { + "gt_value": 27.19200887902331, + "tolerance": 1.3596004439511655 + } + }, + { + "metric_id": "rem_latency_accuracy", + "type": "numeric_check", + "target_key": "rem_latency_min", + "weight": 33, + "params": { + "gt_value": 71.5, + "tolerance": 3.575 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case5/case5_20.json b/sleep_assessment/cases/case5/case5_20.json new file mode 100644 index 0000000000000000000000000000000000000000..862d280070a4bc88b12bf62408cf291ef076e1e2 --- /dev/null +++ b/sleep_assessment/cases/case5/case5_20.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "MASSSS3_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_05.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three sleep-stage metrics for the recording: NREM duration in minutes, REM sleep ratio as a percentage of total sleep time, and REM latency in minutes. Define REM latency as the time from the first sleep epoch to the first REM epoch. Please clearly report all three final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) NREM duration in minutes\n2) REM sleep ratio as a percentage of total sleep time\n3) REM latency in minutes\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"nrem_duration_min\", \"rem_sleep_ratio_percent\", and \"rem_latency_min\".\n5. All values must be FLOATS or null.\n6. \"nrem_duration_min\" and \"rem_latency_min\" are measured in minutes.\n7. \"rem_sleep_ratio_percent\" is a percentage value; if the report says 18.5%, output 18.5.\n8. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"nrem_duration_min\": , \"rem_sleep_ratio_percent\": , \"rem_latency_min\": }", + "metrics": [ + { + "metric_id": "nrem_duration_accuracy", + "type": "numeric_check", + "target_key": "nrem_duration_min", + "weight": 34, + "params": { + "gt_value": 369.5, + "tolerance": 18.475 + } + }, + { + "metric_id": "rem_sleep_ratio_accuracy", + "type": "numeric_check", + "target_key": "rem_sleep_ratio_percent", + "weight": 33, + "params": { + "gt_value": 27.263779527559056, + "tolerance": 1.3631889763779528 + } + }, + { + "metric_id": "rem_latency_accuracy", + "type": "numeric_check", + "target_key": "rem_latency_min", + "weight": 33, + "params": { + "gt_value": 85.0, + "tolerance": 4.25 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case5/case5_21.json b/sleep_assessment/cases/case5/case5_21.json new file mode 100644 index 0000000000000000000000000000000000000000..9d6a8940ace2dbe0cf9ce19f2b0f7b4843d0bc7f --- /dev/null +++ b/sleep_assessment/cases/case5/case5_21.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "Physionet2018_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_01.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three sleep-stage metrics for the recording: NREM duration in minutes, REM sleep ratio as a percentage of total sleep time, and REM latency in minutes. Define REM latency as the time from the first sleep epoch to the first REM epoch. Please clearly report all three final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) NREM duration in minutes\n2) REM sleep ratio as a percentage of total sleep time\n3) REM latency in minutes\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"nrem_duration_min\", \"rem_sleep_ratio_percent\", and \"rem_latency_min\".\n5. All values must be FLOATS or null.\n6. \"nrem_duration_min\" and \"rem_latency_min\" are measured in minutes.\n7. \"rem_sleep_ratio_percent\" is a percentage value; if the report says 18.5%, output 18.5.\n8. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"nrem_duration_min\": , \"rem_sleep_ratio_percent\": , \"rem_latency_min\": }", + "metrics": [ + { + "metric_id": "nrem_duration_accuracy", + "type": "numeric_check", + "target_key": "nrem_duration_min", + "weight": 34, + "params": { + "gt_value": 198.5, + "tolerance": 9.925 + } + }, + { + "metric_id": "rem_sleep_ratio_accuracy", + "type": "numeric_check", + "target_key": "rem_sleep_ratio_percent", + "weight": 33, + "params": { + "gt_value": 16.94560669456067, + "tolerance": 0.8472803347280335 + } + }, + { + "metric_id": "rem_latency_accuracy", + "type": "numeric_check", + "target_key": "rem_latency_min", + "weight": 33, + "params": { + "gt_value": 82.0, + "tolerance": 4.1000000000000005 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case5/case5_22.json b/sleep_assessment/cases/case5/case5_22.json new file mode 100644 index 0000000000000000000000000000000000000000..60ec1bb068247eebdf742b25411f89e9f86a3207 --- /dev/null +++ b/sleep_assessment/cases/case5/case5_22.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "Physionet2018_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_02.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three sleep-stage metrics for the recording: NREM duration in minutes, REM sleep ratio as a percentage of total sleep time, and REM latency in minutes. Define REM latency as the time from the first sleep epoch to the first REM epoch. Please clearly report all three final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) NREM duration in minutes\n2) REM sleep ratio as a percentage of total sleep time\n3) REM latency in minutes\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"nrem_duration_min\", \"rem_sleep_ratio_percent\", and \"rem_latency_min\".\n5. All values must be FLOATS or null.\n6. \"nrem_duration_min\" and \"rem_latency_min\" are measured in minutes.\n7. \"rem_sleep_ratio_percent\" is a percentage value; if the report says 18.5%, output 18.5.\n8. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"nrem_duration_min\": , \"rem_sleep_ratio_percent\": , \"rem_latency_min\": }", + "metrics": [ + { + "metric_id": "nrem_duration_accuracy", + "type": "numeric_check", + "target_key": "nrem_duration_min", + "weight": 34, + "params": { + "gt_value": 229.5, + "tolerance": 11.475000000000001 + } + }, + { + "metric_id": "rem_sleep_ratio_accuracy", + "type": "numeric_check", + "target_key": "rem_sleep_ratio_percent", + "weight": 33, + "params": { + "gt_value": 0.21739130434782608, + "tolerance": 0.010869565217391304 + } + }, + { + "metric_id": "rem_latency_accuracy", + "type": "numeric_check", + "target_key": "rem_latency_min", + "weight": 33, + "params": { + "gt_value": 352.0, + "tolerance": 17.6 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case5/case5_23.json b/sleep_assessment/cases/case5/case5_23.json new file mode 100644 index 0000000000000000000000000000000000000000..11de5ed67be603fd0b49fb4f1e7d0b29b71d5d76 --- /dev/null +++ b/sleep_assessment/cases/case5/case5_23.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "Physionet2018_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_03.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three sleep-stage metrics for the recording: NREM duration in minutes, REM sleep ratio as a percentage of total sleep time, and REM latency in minutes. Define REM latency as the time from the first sleep epoch to the first REM epoch. Please clearly report all three final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) NREM duration in minutes\n2) REM sleep ratio as a percentage of total sleep time\n3) REM latency in minutes\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"nrem_duration_min\", \"rem_sleep_ratio_percent\", and \"rem_latency_min\".\n5. All values must be FLOATS or null.\n6. \"nrem_duration_min\" and \"rem_latency_min\" are measured in minutes.\n7. \"rem_sleep_ratio_percent\" is a percentage value; if the report says 18.5%, output 18.5.\n8. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"nrem_duration_min\": , \"rem_sleep_ratio_percent\": , \"rem_latency_min\": }", + "metrics": [ + { + "metric_id": "nrem_duration_accuracy", + "type": "numeric_check", + "target_key": "nrem_duration_min", + "weight": 34, + "params": { + "gt_value": 225.5, + "tolerance": 11.275 + } + }, + { + "metric_id": "rem_sleep_ratio_accuracy", + "type": "numeric_check", + "target_key": "rem_sleep_ratio_percent", + "weight": 33, + "params": { + "gt_value": 0.22123893805309736, + "tolerance": 0.011061946902654869 + } + }, + { + "metric_id": "rem_latency_accuracy", + "type": "numeric_check", + "target_key": "rem_latency_min", + "weight": 33, + "params": { + "gt_value": 101.0, + "tolerance": 5.050000000000001 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case5/case5_24.json b/sleep_assessment/cases/case5/case5_24.json new file mode 100644 index 0000000000000000000000000000000000000000..75f1a6e599153b3430891aa0d9c7d08aff462e10 --- /dev/null +++ b/sleep_assessment/cases/case5/case5_24.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "Physionet2018_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_04.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three sleep-stage metrics for the recording: NREM duration in minutes, REM sleep ratio as a percentage of total sleep time, and REM latency in minutes. Define REM latency as the time from the first sleep epoch to the first REM epoch. Please clearly report all three final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) NREM duration in minutes\n2) REM sleep ratio as a percentage of total sleep time\n3) REM latency in minutes\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"nrem_duration_min\", \"rem_sleep_ratio_percent\", and \"rem_latency_min\".\n5. All values must be FLOATS or null.\n6. \"nrem_duration_min\" and \"rem_latency_min\" are measured in minutes.\n7. \"rem_sleep_ratio_percent\" is a percentage value; if the report says 18.5%, output 18.5.\n8. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"nrem_duration_min\": , \"rem_sleep_ratio_percent\": , \"rem_latency_min\": }", + "metrics": [ + { + "metric_id": "nrem_duration_accuracy", + "type": "numeric_check", + "target_key": "nrem_duration_min", + "weight": 34, + "params": { + "gt_value": 336.5, + "tolerance": 16.825 + } + }, + { + "metric_id": "rem_sleep_ratio_accuracy", + "type": "numeric_check", + "target_key": "rem_sleep_ratio_percent", + "weight": 33, + "params": { + "gt_value": 11.795543905635649, + "tolerance": 0.5897771952817824 + } + }, + { + "metric_id": "rem_latency_accuracy", + "type": "numeric_check", + "target_key": "rem_latency_min", + "weight": 33, + "params": { + "gt_value": 55.0, + "tolerance": 2.75 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case5/case5_25.json b/sleep_assessment/cases/case5/case5_25.json new file mode 100644 index 0000000000000000000000000000000000000000..d28faeb56b404fac441d82656072af03aa64186d --- /dev/null +++ b/sleep_assessment/cases/case5/case5_25.json @@ -0,0 +1,47 @@ +{ + "meta_info": { + "case_id": "Physionet2018_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_05.npy", + "instruction": "Please use the provided sleep-stage label file to calculate three sleep-stage metrics for the recording: NREM duration in minutes, REM sleep ratio as a percentage of total sleep time, and REM latency in minutes. Define REM latency as the time from the first sleep epoch to the first REM epoch. Please clearly report all three final values." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract three values from the agent's report:\n1) NREM duration in minutes\n2) REM sleep ratio as a percentage of total sleep time\n3) REM latency in minutes\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"nrem_duration_min\", \"rem_sleep_ratio_percent\", and \"rem_latency_min\".\n5. All values must be FLOATS or null.\n6. \"nrem_duration_min\" and \"rem_latency_min\" are measured in minutes.\n7. \"rem_sleep_ratio_percent\" is a percentage value; if the report says 18.5%, output 18.5.\n8. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"nrem_duration_min\": , \"rem_sleep_ratio_percent\": , \"rem_latency_min\": }", + "metrics": [ + { + "metric_id": "nrem_duration_accuracy", + "type": "numeric_check", + "target_key": "nrem_duration_min", + "weight": 34, + "params": { + "gt_value": 399.0, + "tolerance": 19.950000000000003 + } + }, + { + "metric_id": "rem_sleep_ratio_accuracy", + "type": "numeric_check", + "target_key": "rem_sleep_ratio_percent", + "weight": 33, + "params": { + "gt_value": 11.333333333333334, + "tolerance": 0.5666666666666668 + } + }, + { + "metric_id": "rem_latency_accuracy", + "type": "numeric_check", + "target_key": "rem_latency_min", + "weight": 33, + "params": { + "gt_value": 105.0, + "tolerance": 5.25 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case6/case6_01.json b/sleep_assessment/cases/case6/case6_01.json new file mode 100644 index 0000000000000000000000000000000000000000..3ea82f1f81b7895d3f11dd7ab2212ac171b5d56f --- /dev/null +++ b/sleep_assessment/cases/case6/case6_01.json @@ -0,0 +1,35 @@ +{ + "meta_info": { + "case_id": "ISRUC_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_01.npy", + "instruction": "Please use the provided sleep-stage label file to analyze the whole-night stage distribution. Determine the dominant sleep stage and the secondary sleep stage across the entire recording, and report both using the fixed stage labels W, N1, N2, N3, and R." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two stage labels from the agent's report:\n1) the dominant sleep stage across the whole night\n2) the secondary sleep stage across the whole night\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"dominant_sleep_stage\" and \"secondary_sleep_stage\".\n5. Each value must be exactly one of: \"W\", \"N1\", \"N2\", \"N3\", \"R\", or null.\n6. Normalize any synonyms to the fixed field set above. For example: Wake -> W, REM -> R.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"dominant_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>, \"secondary_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>}", + "metrics": [ + { + "metric_id": "dominant_stage_accuracy", + "type": "categorical_check", + "target_key": "dominant_sleep_stage", + "weight": 60, + "params": { + "gt_value": "W" + } + }, + { + "metric_id": "secondary_stage_accuracy", + "type": "categorical_check", + "target_key": "secondary_sleep_stage", + "weight": 40, + "params": { + "gt_value": "N3" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case6/case6_02.json b/sleep_assessment/cases/case6/case6_02.json new file mode 100644 index 0000000000000000000000000000000000000000..42fa7318ce63a9673887f1a6400b35aa92c56596 --- /dev/null +++ b/sleep_assessment/cases/case6/case6_02.json @@ -0,0 +1,35 @@ +{ + "meta_info": { + "case_id": "ISRUC_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_02.npy", + "instruction": "Please use the provided sleep-stage label file to analyze the whole-night stage distribution. Determine the dominant sleep stage and the secondary sleep stage across the entire recording, and report both using the fixed stage labels W, N1, N2, N3, and R." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two stage labels from the agent's report:\n1) the dominant sleep stage across the whole night\n2) the secondary sleep stage across the whole night\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"dominant_sleep_stage\" and \"secondary_sleep_stage\".\n5. Each value must be exactly one of: \"W\", \"N1\", \"N2\", \"N3\", \"R\", or null.\n6. Normalize any synonyms to the fixed field set above. For example: Wake -> W, REM -> R.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"dominant_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>, \"secondary_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>}", + "metrics": [ + { + "metric_id": "dominant_stage_accuracy", + "type": "categorical_check", + "target_key": "dominant_sleep_stage", + "weight": 60, + "params": { + "gt_value": "N2" + } + }, + { + "metric_id": "secondary_stage_accuracy", + "type": "categorical_check", + "target_key": "secondary_sleep_stage", + "weight": 40, + "params": { + "gt_value": "W" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case6/case6_03.json b/sleep_assessment/cases/case6/case6_03.json new file mode 100644 index 0000000000000000000000000000000000000000..45987926f2af7a397518599dfb41a5124aea4b67 --- /dev/null +++ b/sleep_assessment/cases/case6/case6_03.json @@ -0,0 +1,35 @@ +{ + "meta_info": { + "case_id": "ISRUC_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_03.npy", + "instruction": "Please use the provided sleep-stage label file to analyze the whole-night stage distribution. Determine the dominant sleep stage and the secondary sleep stage across the entire recording, and report both using the fixed stage labels W, N1, N2, N3, and R." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two stage labels from the agent's report:\n1) the dominant sleep stage across the whole night\n2) the secondary sleep stage across the whole night\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"dominant_sleep_stage\" and \"secondary_sleep_stage\".\n5. Each value must be exactly one of: \"W\", \"N1\", \"N2\", \"N3\", \"R\", or null.\n6. Normalize any synonyms to the fixed field set above. For example: Wake -> W, REM -> R.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"dominant_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>, \"secondary_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>}", + "metrics": [ + { + "metric_id": "dominant_stage_accuracy", + "type": "categorical_check", + "target_key": "dominant_sleep_stage", + "weight": 60, + "params": { + "gt_value": "N2" + } + }, + { + "metric_id": "secondary_stage_accuracy", + "type": "categorical_check", + "target_key": "secondary_sleep_stage", + "weight": 40, + "params": { + "gt_value": "R" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case6/case6_04.json b/sleep_assessment/cases/case6/case6_04.json new file mode 100644 index 0000000000000000000000000000000000000000..56759bcbf357f1511c333dff6e42d92b8d126a84 --- /dev/null +++ b/sleep_assessment/cases/case6/case6_04.json @@ -0,0 +1,35 @@ +{ + "meta_info": { + "case_id": "ISRUC_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_04.npy", + "instruction": "Please use the provided sleep-stage label file to analyze the whole-night stage distribution. Determine the dominant sleep stage and the secondary sleep stage across the entire recording, and report both using the fixed stage labels W, N1, N2, N3, and R." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two stage labels from the agent's report:\n1) the dominant sleep stage across the whole night\n2) the secondary sleep stage across the whole night\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"dominant_sleep_stage\" and \"secondary_sleep_stage\".\n5. Each value must be exactly one of: \"W\", \"N1\", \"N2\", \"N3\", \"R\", or null.\n6. Normalize any synonyms to the fixed field set above. For example: Wake -> W, REM -> R.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"dominant_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>, \"secondary_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>}", + "metrics": [ + { + "metric_id": "dominant_stage_accuracy", + "type": "categorical_check", + "target_key": "dominant_sleep_stage", + "weight": 60, + "params": { + "gt_value": "N2" + } + }, + { + "metric_id": "secondary_stage_accuracy", + "type": "categorical_check", + "target_key": "secondary_sleep_stage", + "weight": 40, + "params": { + "gt_value": "R" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case6/case6_05.json b/sleep_assessment/cases/case6/case6_05.json new file mode 100644 index 0000000000000000000000000000000000000000..44be1a3c6acf83af094de64869299dfb81d6e62b --- /dev/null +++ b/sleep_assessment/cases/case6/case6_05.json @@ -0,0 +1,35 @@ +{ + "meta_info": { + "case_id": "ISRUC_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_05.npy", + "instruction": "Please use the provided sleep-stage label file to analyze the whole-night stage distribution. Determine the dominant sleep stage and the secondary sleep stage across the entire recording, and report both using the fixed stage labels W, N1, N2, N3, and R." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two stage labels from the agent's report:\n1) the dominant sleep stage across the whole night\n2) the secondary sleep stage across the whole night\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"dominant_sleep_stage\" and \"secondary_sleep_stage\".\n5. Each value must be exactly one of: \"W\", \"N1\", \"N2\", \"N3\", \"R\", or null.\n6. Normalize any synonyms to the fixed field set above. For example: Wake -> W, REM -> R.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"dominant_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>, \"secondary_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>}", + "metrics": [ + { + "metric_id": "dominant_stage_accuracy", + "type": "categorical_check", + "target_key": "dominant_sleep_stage", + "weight": 60, + "params": { + "gt_value": "W" + } + }, + { + "metric_id": "secondary_stage_accuracy", + "type": "categorical_check", + "target_key": "secondary_sleep_stage", + "weight": 40, + "params": { + "gt_value": "N2" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case6/case6_06.json b/sleep_assessment/cases/case6/case6_06.json new file mode 100644 index 0000000000000000000000000000000000000000..789596439599386f280a4502fb86d3ec4ab57d53 --- /dev/null +++ b/sleep_assessment/cases/case6/case6_06.json @@ -0,0 +1,35 @@ +{ + "meta_info": { + "case_id": "HMC_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_01.npy", + "instruction": "Please use the provided sleep-stage label file to analyze the whole-night stage distribution. Determine the dominant sleep stage and the secondary sleep stage across the entire recording, and report both using the fixed stage labels W, N1, N2, N3, and R." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two stage labels from the agent's report:\n1) the dominant sleep stage across the whole night\n2) the secondary sleep stage across the whole night\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"dominant_sleep_stage\" and \"secondary_sleep_stage\".\n5. Each value must be exactly one of: \"W\", \"N1\", \"N2\", \"N3\", \"R\", or null.\n6. Normalize any synonyms to the fixed field set above. For example: Wake -> W, REM -> R.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"dominant_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>, \"secondary_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>}", + "metrics": [ + { + "metric_id": "dominant_stage_accuracy", + "type": "categorical_check", + "target_key": "dominant_sleep_stage", + "weight": 60, + "params": { + "gt_value": "N2" + } + }, + { + "metric_id": "secondary_stage_accuracy", + "type": "categorical_check", + "target_key": "secondary_sleep_stage", + "weight": 40, + "params": { + "gt_value": "W" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case6/case6_07.json b/sleep_assessment/cases/case6/case6_07.json new file mode 100644 index 0000000000000000000000000000000000000000..6a250e832b8f0233e8867a912546cd2d0a70bce5 --- /dev/null +++ b/sleep_assessment/cases/case6/case6_07.json @@ -0,0 +1,35 @@ +{ + "meta_info": { + "case_id": "HMC_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_02.npy", + "instruction": "Please use the provided sleep-stage label file to analyze the whole-night stage distribution. Determine the dominant sleep stage and the secondary sleep stage across the entire recording, and report both using the fixed stage labels W, N1, N2, N3, and R." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two stage labels from the agent's report:\n1) the dominant sleep stage across the whole night\n2) the secondary sleep stage across the whole night\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"dominant_sleep_stage\" and \"secondary_sleep_stage\".\n5. Each value must be exactly one of: \"W\", \"N1\", \"N2\", \"N3\", \"R\", or null.\n6. Normalize any synonyms to the fixed field set above. For example: Wake -> W, REM -> R.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"dominant_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>, \"secondary_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>}", + "metrics": [ + { + "metric_id": "dominant_stage_accuracy", + "type": "categorical_check", + "target_key": "dominant_sleep_stage", + "weight": 60, + "params": { + "gt_value": "N2" + } + }, + { + "metric_id": "secondary_stage_accuracy", + "type": "categorical_check", + "target_key": "secondary_sleep_stage", + "weight": 40, + "params": { + "gt_value": "N3" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case6/case6_08.json b/sleep_assessment/cases/case6/case6_08.json new file mode 100644 index 0000000000000000000000000000000000000000..da92c9aebec9c6b829a89229cc8eb5fb653c0705 --- /dev/null +++ b/sleep_assessment/cases/case6/case6_08.json @@ -0,0 +1,35 @@ +{ + "meta_info": { + "case_id": "HMC_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_03.npy", + "instruction": "Please use the provided sleep-stage label file to analyze the whole-night stage distribution. Determine the dominant sleep stage and the secondary sleep stage across the entire recording, and report both using the fixed stage labels W, N1, N2, N3, and R." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two stage labels from the agent's report:\n1) the dominant sleep stage across the whole night\n2) the secondary sleep stage across the whole night\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"dominant_sleep_stage\" and \"secondary_sleep_stage\".\n5. Each value must be exactly one of: \"W\", \"N1\", \"N2\", \"N3\", \"R\", or null.\n6. Normalize any synonyms to the fixed field set above. For example: Wake -> W, REM -> R.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"dominant_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>, \"secondary_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>}", + "metrics": [ + { + "metric_id": "dominant_stage_accuracy", + "type": "categorical_check", + "target_key": "dominant_sleep_stage", + "weight": 60, + "params": { + "gt_value": "W" + } + }, + { + "metric_id": "secondary_stage_accuracy", + "type": "categorical_check", + "target_key": "secondary_sleep_stage", + "weight": 40, + "params": { + "gt_value": "N2" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case6/case6_09.json b/sleep_assessment/cases/case6/case6_09.json new file mode 100644 index 0000000000000000000000000000000000000000..0640e0b4de483557d1b6a8601b16013fc0ec63ff --- /dev/null +++ b/sleep_assessment/cases/case6/case6_09.json @@ -0,0 +1,35 @@ +{ + "meta_info": { + "case_id": "HMC_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_04.npy", + "instruction": "Please use the provided sleep-stage label file to analyze the whole-night stage distribution. Determine the dominant sleep stage and the secondary sleep stage across the entire recording, and report both using the fixed stage labels W, N1, N2, N3, and R." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two stage labels from the agent's report:\n1) the dominant sleep stage across the whole night\n2) the secondary sleep stage across the whole night\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"dominant_sleep_stage\" and \"secondary_sleep_stage\".\n5. Each value must be exactly one of: \"W\", \"N1\", \"N2\", \"N3\", \"R\", or null.\n6. Normalize any synonyms to the fixed field set above. For example: Wake -> W, REM -> R.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"dominant_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>, \"secondary_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>}", + "metrics": [ + { + "metric_id": "dominant_stage_accuracy", + "type": "categorical_check", + "target_key": "dominant_sleep_stage", + "weight": 60, + "params": { + "gt_value": "N2" + } + }, + { + "metric_id": "secondary_stage_accuracy", + "type": "categorical_check", + "target_key": "secondary_sleep_stage", + "weight": 40, + "params": { + "gt_value": "R" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case6/case6_10.json b/sleep_assessment/cases/case6/case6_10.json new file mode 100644 index 0000000000000000000000000000000000000000..8d86b7860c3693364a3665e5fd58b549bc56787f --- /dev/null +++ b/sleep_assessment/cases/case6/case6_10.json @@ -0,0 +1,35 @@ +{ + "meta_info": { + "case_id": "HMC_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_05.npy", + "instruction": "Please use the provided sleep-stage label file to analyze the whole-night stage distribution. Determine the dominant sleep stage and the secondary sleep stage across the entire recording, and report both using the fixed stage labels W, N1, N2, N3, and R." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two stage labels from the agent's report:\n1) the dominant sleep stage across the whole night\n2) the secondary sleep stage across the whole night\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"dominant_sleep_stage\" and \"secondary_sleep_stage\".\n5. Each value must be exactly one of: \"W\", \"N1\", \"N2\", \"N3\", \"R\", or null.\n6. Normalize any synonyms to the fixed field set above. For example: Wake -> W, REM -> R.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"dominant_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>, \"secondary_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>}", + "metrics": [ + { + "metric_id": "dominant_stage_accuracy", + "type": "categorical_check", + "target_key": "dominant_sleep_stage", + "weight": 60, + "params": { + "gt_value": "N2" + } + }, + { + "metric_id": "secondary_stage_accuracy", + "type": "categorical_check", + "target_key": "secondary_sleep_stage", + "weight": 40, + "params": { + "gt_value": "W" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case6/case6_11.json b/sleep_assessment/cases/case6/case6_11.json new file mode 100644 index 0000000000000000000000000000000000000000..8e256cf760bcb89f7d460e7a957208606c39136f --- /dev/null +++ b/sleep_assessment/cases/case6/case6_11.json @@ -0,0 +1,35 @@ +{ + "meta_info": { + "case_id": "SHHS1_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_01.npy", + "instruction": "Please use the provided sleep-stage label file to analyze the whole-night stage distribution. Determine the dominant sleep stage and the secondary sleep stage across the entire recording, and report both using the fixed stage labels W, N1, N2, N3, and R." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two stage labels from the agent's report:\n1) the dominant sleep stage across the whole night\n2) the secondary sleep stage across the whole night\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"dominant_sleep_stage\" and \"secondary_sleep_stage\".\n5. Each value must be exactly one of: \"W\", \"N1\", \"N2\", \"N3\", \"R\", or null.\n6. Normalize any synonyms to the fixed field set above. For example: Wake -> W, REM -> R.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"dominant_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>, \"secondary_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>}", + "metrics": [ + { + "metric_id": "dominant_stage_accuracy", + "type": "categorical_check", + "target_key": "dominant_sleep_stage", + "weight": 60, + "params": { + "gt_value": "N2" + } + }, + { + "metric_id": "secondary_stage_accuracy", + "type": "categorical_check", + "target_key": "secondary_sleep_stage", + "weight": 40, + "params": { + "gt_value": "W" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case6/case6_12.json b/sleep_assessment/cases/case6/case6_12.json new file mode 100644 index 0000000000000000000000000000000000000000..a019ae0fb77e26801003e292d85309cc7a97727c --- /dev/null +++ b/sleep_assessment/cases/case6/case6_12.json @@ -0,0 +1,35 @@ +{ + "meta_info": { + "case_id": "SHHS1_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_02.npy", + "instruction": "Please use the provided sleep-stage label file to analyze the whole-night stage distribution. Determine the dominant sleep stage and the secondary sleep stage across the entire recording, and report both using the fixed stage labels W, N1, N2, N3, and R." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two stage labels from the agent's report:\n1) the dominant sleep stage across the whole night\n2) the secondary sleep stage across the whole night\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"dominant_sleep_stage\" and \"secondary_sleep_stage\".\n5. Each value must be exactly one of: \"W\", \"N1\", \"N2\", \"N3\", \"R\", or null.\n6. Normalize any synonyms to the fixed field set above. For example: Wake -> W, REM -> R.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"dominant_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>, \"secondary_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>}", + "metrics": [ + { + "metric_id": "dominant_stage_accuracy", + "type": "categorical_check", + "target_key": "dominant_sleep_stage", + "weight": 60, + "params": { + "gt_value": "W" + } + }, + { + "metric_id": "secondary_stage_accuracy", + "type": "categorical_check", + "target_key": "secondary_sleep_stage", + "weight": 40, + "params": { + "gt_value": "N2" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case6/case6_13.json b/sleep_assessment/cases/case6/case6_13.json new file mode 100644 index 0000000000000000000000000000000000000000..118bee7ced9dae362d5cffeb4bad6c69e143cda1 --- /dev/null +++ b/sleep_assessment/cases/case6/case6_13.json @@ -0,0 +1,35 @@ +{ + "meta_info": { + "case_id": "SHHS1_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_03.npy", + "instruction": "Please use the provided sleep-stage label file to analyze the whole-night stage distribution. Determine the dominant sleep stage and the secondary sleep stage across the entire recording, and report both using the fixed stage labels W, N1, N2, N3, and R." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two stage labels from the agent's report:\n1) the dominant sleep stage across the whole night\n2) the secondary sleep stage across the whole night\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"dominant_sleep_stage\" and \"secondary_sleep_stage\".\n5. Each value must be exactly one of: \"W\", \"N1\", \"N2\", \"N3\", \"R\", or null.\n6. Normalize any synonyms to the fixed field set above. For example: Wake -> W, REM -> R.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"dominant_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>, \"secondary_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>}", + "metrics": [ + { + "metric_id": "dominant_stage_accuracy", + "type": "categorical_check", + "target_key": "dominant_sleep_stage", + "weight": 60, + "params": { + "gt_value": "W" + } + }, + { + "metric_id": "secondary_stage_accuracy", + "type": "categorical_check", + "target_key": "secondary_sleep_stage", + "weight": 40, + "params": { + "gt_value": "N3" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case6/case6_14.json b/sleep_assessment/cases/case6/case6_14.json new file mode 100644 index 0000000000000000000000000000000000000000..f3a5d246372d62817fedee1d2216a643fe17ac87 --- /dev/null +++ b/sleep_assessment/cases/case6/case6_14.json @@ -0,0 +1,35 @@ +{ + "meta_info": { + "case_id": "SHHS1_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_04.npy", + "instruction": "Please use the provided sleep-stage label file to analyze the whole-night stage distribution. Determine the dominant sleep stage and the secondary sleep stage across the entire recording, and report both using the fixed stage labels W, N1, N2, N3, and R." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two stage labels from the agent's report:\n1) the dominant sleep stage across the whole night\n2) the secondary sleep stage across the whole night\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"dominant_sleep_stage\" and \"secondary_sleep_stage\".\n5. Each value must be exactly one of: \"W\", \"N1\", \"N2\", \"N3\", \"R\", or null.\n6. Normalize any synonyms to the fixed field set above. For example: Wake -> W, REM -> R.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"dominant_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>, \"secondary_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>}", + "metrics": [ + { + "metric_id": "dominant_stage_accuracy", + "type": "categorical_check", + "target_key": "dominant_sleep_stage", + "weight": 60, + "params": { + "gt_value": "N3" + } + }, + { + "metric_id": "secondary_stage_accuracy", + "type": "categorical_check", + "target_key": "secondary_sleep_stage", + "weight": 40, + "params": { + "gt_value": "W" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case6/case6_15.json b/sleep_assessment/cases/case6/case6_15.json new file mode 100644 index 0000000000000000000000000000000000000000..01f4d90fa64a8bfaabaa39ba57ffc9431f36c3c1 --- /dev/null +++ b/sleep_assessment/cases/case6/case6_15.json @@ -0,0 +1,35 @@ +{ + "meta_info": { + "case_id": "SHHS1_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_05.npy", + "instruction": "Please use the provided sleep-stage label file to analyze the whole-night stage distribution. Determine the dominant sleep stage and the secondary sleep stage across the entire recording, and report both using the fixed stage labels W, N1, N2, N3, and R." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two stage labels from the agent's report:\n1) the dominant sleep stage across the whole night\n2) the secondary sleep stage across the whole night\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"dominant_sleep_stage\" and \"secondary_sleep_stage\".\n5. Each value must be exactly one of: \"W\", \"N1\", \"N2\", \"N3\", \"R\", or null.\n6. Normalize any synonyms to the fixed field set above. For example: Wake -> W, REM -> R.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"dominant_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>, \"secondary_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>}", + "metrics": [ + { + "metric_id": "dominant_stage_accuracy", + "type": "categorical_check", + "target_key": "dominant_sleep_stage", + "weight": 60, + "params": { + "gt_value": "N2" + } + }, + { + "metric_id": "secondary_stage_accuracy", + "type": "categorical_check", + "target_key": "secondary_sleep_stage", + "weight": 40, + "params": { + "gt_value": "W" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case6/case6_16.json b/sleep_assessment/cases/case6/case6_16.json new file mode 100644 index 0000000000000000000000000000000000000000..4db2b5679570f32a453badc41f1de3bd8cc5fd17 --- /dev/null +++ b/sleep_assessment/cases/case6/case6_16.json @@ -0,0 +1,35 @@ +{ + "meta_info": { + "case_id": "MASSSS3_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_01.npy", + "instruction": "Please use the provided sleep-stage label file to analyze the whole-night stage distribution. Determine the dominant sleep stage and the secondary sleep stage across the entire recording, and report both using the fixed stage labels W, N1, N2, N3, and R." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two stage labels from the agent's report:\n1) the dominant sleep stage across the whole night\n2) the secondary sleep stage across the whole night\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"dominant_sleep_stage\" and \"secondary_sleep_stage\".\n5. Each value must be exactly one of: \"W\", \"N1\", \"N2\", \"N3\", \"R\", or null.\n6. Normalize any synonyms to the fixed field set above. For example: Wake -> W, REM -> R.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"dominant_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>, \"secondary_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>}", + "metrics": [ + { + "metric_id": "dominant_stage_accuracy", + "type": "categorical_check", + "target_key": "dominant_sleep_stage", + "weight": 60, + "params": { + "gt_value": "N2" + } + }, + { + "metric_id": "secondary_stage_accuracy", + "type": "categorical_check", + "target_key": "secondary_sleep_stage", + "weight": 40, + "params": { + "gt_value": "R" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case6/case6_17.json b/sleep_assessment/cases/case6/case6_17.json new file mode 100644 index 0000000000000000000000000000000000000000..895fabfbd5b96099e372e1a8f57e33142cd95381 --- /dev/null +++ b/sleep_assessment/cases/case6/case6_17.json @@ -0,0 +1,35 @@ +{ + "meta_info": { + "case_id": "MASSSS3_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_02.npy", + "instruction": "Please use the provided sleep-stage label file to analyze the whole-night stage distribution. Determine the dominant sleep stage and the secondary sleep stage across the entire recording, and report both using the fixed stage labels W, N1, N2, N3, and R." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two stage labels from the agent's report:\n1) the dominant sleep stage across the whole night\n2) the secondary sleep stage across the whole night\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"dominant_sleep_stage\" and \"secondary_sleep_stage\".\n5. Each value must be exactly one of: \"W\", \"N1\", \"N2\", \"N3\", \"R\", or null.\n6. Normalize any synonyms to the fixed field set above. For example: Wake -> W, REM -> R.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"dominant_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>, \"secondary_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>}", + "metrics": [ + { + "metric_id": "dominant_stage_accuracy", + "type": "categorical_check", + "target_key": "dominant_sleep_stage", + "weight": 60, + "params": { + "gt_value": "N2" + } + }, + { + "metric_id": "secondary_stage_accuracy", + "type": "categorical_check", + "target_key": "secondary_sleep_stage", + "weight": 40, + "params": { + "gt_value": "R" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case6/case6_18.json b/sleep_assessment/cases/case6/case6_18.json new file mode 100644 index 0000000000000000000000000000000000000000..9073932f1832c386bbc6aa5e9e4879a800bd5749 --- /dev/null +++ b/sleep_assessment/cases/case6/case6_18.json @@ -0,0 +1,35 @@ +{ + "meta_info": { + "case_id": "MASSSS3_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_03.npy", + "instruction": "Please use the provided sleep-stage label file to analyze the whole-night stage distribution. Determine the dominant sleep stage and the secondary sleep stage across the entire recording, and report both using the fixed stage labels W, N1, N2, N3, and R." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two stage labels from the agent's report:\n1) the dominant sleep stage across the whole night\n2) the secondary sleep stage across the whole night\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"dominant_sleep_stage\" and \"secondary_sleep_stage\".\n5. Each value must be exactly one of: \"W\", \"N1\", \"N2\", \"N3\", \"R\", or null.\n6. Normalize any synonyms to the fixed field set above. For example: Wake -> W, REM -> R.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"dominant_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>, \"secondary_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>}", + "metrics": [ + { + "metric_id": "dominant_stage_accuracy", + "type": "categorical_check", + "target_key": "dominant_sleep_stage", + "weight": 60, + "params": { + "gt_value": "N2" + } + }, + { + "metric_id": "secondary_stage_accuracy", + "type": "categorical_check", + "target_key": "secondary_sleep_stage", + "weight": 40, + "params": { + "gt_value": "R" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case6/case6_19.json b/sleep_assessment/cases/case6/case6_19.json new file mode 100644 index 0000000000000000000000000000000000000000..630b74657b22b56f9512759e8b4fc8a202b2baf0 --- /dev/null +++ b/sleep_assessment/cases/case6/case6_19.json @@ -0,0 +1,35 @@ +{ + "meta_info": { + "case_id": "MASSSS3_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_04.npy", + "instruction": "Please use the provided sleep-stage label file to analyze the whole-night stage distribution. Determine the dominant sleep stage and the secondary sleep stage across the entire recording, and report both using the fixed stage labels W, N1, N2, N3, and R." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two stage labels from the agent's report:\n1) the dominant sleep stage across the whole night\n2) the secondary sleep stage across the whole night\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"dominant_sleep_stage\" and \"secondary_sleep_stage\".\n5. Each value must be exactly one of: \"W\", \"N1\", \"N2\", \"N3\", \"R\", or null.\n6. Normalize any synonyms to the fixed field set above. For example: Wake -> W, REM -> R.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"dominant_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>, \"secondary_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>}", + "metrics": [ + { + "metric_id": "dominant_stage_accuracy", + "type": "categorical_check", + "target_key": "dominant_sleep_stage", + "weight": 60, + "params": { + "gt_value": "N2" + } + }, + { + "metric_id": "secondary_stage_accuracy", + "type": "categorical_check", + "target_key": "secondary_sleep_stage", + "weight": 40, + "params": { + "gt_value": "R" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case6/case6_20.json b/sleep_assessment/cases/case6/case6_20.json new file mode 100644 index 0000000000000000000000000000000000000000..6232d3c856888e4b17decaf9f3f8bfa14c096d14 --- /dev/null +++ b/sleep_assessment/cases/case6/case6_20.json @@ -0,0 +1,35 @@ +{ + "meta_info": { + "case_id": "MASSSS3_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_05.npy", + "instruction": "Please use the provided sleep-stage label file to analyze the whole-night stage distribution. Determine the dominant sleep stage and the secondary sleep stage across the entire recording, and report both using the fixed stage labels W, N1, N2, N3, and R." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two stage labels from the agent's report:\n1) the dominant sleep stage across the whole night\n2) the secondary sleep stage across the whole night\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"dominant_sleep_stage\" and \"secondary_sleep_stage\".\n5. Each value must be exactly one of: \"W\", \"N1\", \"N2\", \"N3\", \"R\", or null.\n6. Normalize any synonyms to the fixed field set above. For example: Wake -> W, REM -> R.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"dominant_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>, \"secondary_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>}", + "metrics": [ + { + "metric_id": "dominant_stage_accuracy", + "type": "categorical_check", + "target_key": "dominant_sleep_stage", + "weight": 60, + "params": { + "gt_value": "N2" + } + }, + { + "metric_id": "secondary_stage_accuracy", + "type": "categorical_check", + "target_key": "secondary_sleep_stage", + "weight": 40, + "params": { + "gt_value": "R" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case6/case6_21.json b/sleep_assessment/cases/case6/case6_21.json new file mode 100644 index 0000000000000000000000000000000000000000..21c9f9a7ba3baf8a30828e2c7dc3e33c7b284def --- /dev/null +++ b/sleep_assessment/cases/case6/case6_21.json @@ -0,0 +1,35 @@ +{ + "meta_info": { + "case_id": "Physionet2018_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_01.npy", + "instruction": "Please use the provided sleep-stage label file to analyze the whole-night stage distribution. Determine the dominant sleep stage and the secondary sleep stage across the entire recording, and report both using the fixed stage labels W, N1, N2, N3, and R." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two stage labels from the agent's report:\n1) the dominant sleep stage across the whole night\n2) the secondary sleep stage across the whole night\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"dominant_sleep_stage\" and \"secondary_sleep_stage\".\n5. Each value must be exactly one of: \"W\", \"N1\", \"N2\", \"N3\", \"R\", or null.\n6. Normalize any synonyms to the fixed field set above. For example: Wake -> W, REM -> R.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"dominant_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>, \"secondary_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>}", + "metrics": [ + { + "metric_id": "dominant_stage_accuracy", + "type": "categorical_check", + "target_key": "dominant_sleep_stage", + "weight": 60, + "params": { + "gt_value": "W" + } + }, + { + "metric_id": "secondary_stage_accuracy", + "type": "categorical_check", + "target_key": "secondary_sleep_stage", + "weight": 40, + "params": { + "gt_value": "N2" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case6/case6_22.json b/sleep_assessment/cases/case6/case6_22.json new file mode 100644 index 0000000000000000000000000000000000000000..94ed4993e182e149d7482094d7e52b2b3b3b256d --- /dev/null +++ b/sleep_assessment/cases/case6/case6_22.json @@ -0,0 +1,35 @@ +{ + "meta_info": { + "case_id": "Physionet2018_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_02.npy", + "instruction": "Please use the provided sleep-stage label file to analyze the whole-night stage distribution. Determine the dominant sleep stage and the secondary sleep stage across the entire recording, and report both using the fixed stage labels W, N1, N2, N3, and R." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two stage labels from the agent's report:\n1) the dominant sleep stage across the whole night\n2) the secondary sleep stage across the whole night\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"dominant_sleep_stage\" and \"secondary_sleep_stage\".\n5. Each value must be exactly one of: \"W\", \"N1\", \"N2\", \"N3\", \"R\", or null.\n6. Normalize any synonyms to the fixed field set above. For example: Wake -> W, REM -> R.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"dominant_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>, \"secondary_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>}", + "metrics": [ + { + "metric_id": "dominant_stage_accuracy", + "type": "categorical_check", + "target_key": "dominant_sleep_stage", + "weight": 60, + "params": { + "gt_value": "W" + } + }, + { + "metric_id": "secondary_stage_accuracy", + "type": "categorical_check", + "target_key": "secondary_sleep_stage", + "weight": 40, + "params": { + "gt_value": "N2" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case6/case6_23.json b/sleep_assessment/cases/case6/case6_23.json new file mode 100644 index 0000000000000000000000000000000000000000..6c4ccce752488619939a22402d3f1a586248114b --- /dev/null +++ b/sleep_assessment/cases/case6/case6_23.json @@ -0,0 +1,35 @@ +{ + "meta_info": { + "case_id": "Physionet2018_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_03.npy", + "instruction": "Please use the provided sleep-stage label file to analyze the whole-night stage distribution. Determine the dominant sleep stage and the secondary sleep stage across the entire recording, and report both using the fixed stage labels W, N1, N2, N3, and R." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two stage labels from the agent's report:\n1) the dominant sleep stage across the whole night\n2) the secondary sleep stage across the whole night\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"dominant_sleep_stage\" and \"secondary_sleep_stage\".\n5. Each value must be exactly one of: \"W\", \"N1\", \"N2\", \"N3\", \"R\", or null.\n6. Normalize any synonyms to the fixed field set above. For example: Wake -> W, REM -> R.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"dominant_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>, \"secondary_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>}", + "metrics": [ + { + "metric_id": "dominant_stage_accuracy", + "type": "categorical_check", + "target_key": "dominant_sleep_stage", + "weight": 60, + "params": { + "gt_value": "W" + } + }, + { + "metric_id": "secondary_stage_accuracy", + "type": "categorical_check", + "target_key": "secondary_sleep_stage", + "weight": 40, + "params": { + "gt_value": "N2" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case6/case6_24.json b/sleep_assessment/cases/case6/case6_24.json new file mode 100644 index 0000000000000000000000000000000000000000..3b07f3c7d25c47a1bb89a710b450fe8de6d40c6a --- /dev/null +++ b/sleep_assessment/cases/case6/case6_24.json @@ -0,0 +1,35 @@ +{ + "meta_info": { + "case_id": "Physionet2018_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_04.npy", + "instruction": "Please use the provided sleep-stage label file to analyze the whole-night stage distribution. Determine the dominant sleep stage and the secondary sleep stage across the entire recording, and report both using the fixed stage labels W, N1, N2, N3, and R." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two stage labels from the agent's report:\n1) the dominant sleep stage across the whole night\n2) the secondary sleep stage across the whole night\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"dominant_sleep_stage\" and \"secondary_sleep_stage\".\n5. Each value must be exactly one of: \"W\", \"N1\", \"N2\", \"N3\", \"R\", or null.\n6. Normalize any synonyms to the fixed field set above. For example: Wake -> W, REM -> R.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"dominant_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>, \"secondary_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>}", + "metrics": [ + { + "metric_id": "dominant_stage_accuracy", + "type": "categorical_check", + "target_key": "dominant_sleep_stage", + "weight": 60, + "params": { + "gt_value": "N2" + } + }, + { + "metric_id": "secondary_stage_accuracy", + "type": "categorical_check", + "target_key": "secondary_sleep_stage", + "weight": 40, + "params": { + "gt_value": "N3" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case6/case6_25.json b/sleep_assessment/cases/case6/case6_25.json new file mode 100644 index 0000000000000000000000000000000000000000..8b3cee71f5bc45d873703fe6a7b455cd95b64348 --- /dev/null +++ b/sleep_assessment/cases/case6/case6_25.json @@ -0,0 +1,35 @@ +{ + "meta_info": { + "case_id": "Physionet2018_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_05.npy", + "instruction": "Please use the provided sleep-stage label file to analyze the whole-night stage distribution. Determine the dominant sleep stage and the secondary sleep stage across the entire recording, and report both using the fixed stage labels W, N1, N2, N3, and R." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two stage labels from the agent's report:\n1) the dominant sleep stage across the whole night\n2) the secondary sleep stage across the whole night\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"dominant_sleep_stage\" and \"secondary_sleep_stage\".\n5. Each value must be exactly one of: \"W\", \"N1\", \"N2\", \"N3\", \"R\", or null.\n6. Normalize any synonyms to the fixed field set above. For example: Wake -> W, REM -> R.\n7. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"dominant_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>, \"secondary_sleep_stage\": <\"W\"|\"N1\"|\"N2\"|\"N3\"|\"R\"|null>}", + "metrics": [ + { + "metric_id": "dominant_stage_accuracy", + "type": "categorical_check", + "target_key": "dominant_sleep_stage", + "weight": 60, + "params": { + "gt_value": "N2" + } + }, + { + "metric_id": "secondary_stage_accuracy", + "type": "categorical_check", + "target_key": "secondary_sleep_stage", + "weight": 40, + "params": { + "gt_value": "N1" + } + } + ] + } +} diff --git a/sleep_assessment/cases/case7/case7_01.json b/sleep_assessment/cases/case7/case7_01.json new file mode 100644 index 0000000000000000000000000000000000000000..c0a86fc5a55e3a45efbbdc6a06fad2d923227d4c --- /dev/null +++ b/sleep_assessment/cases/case7/case7_01.json @@ -0,0 +1,36 @@ +{ + "meta_info": { + "case_id": "ISRUC_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_01.npy", + "instruction": "Please use the provided sleep-stage label file to calculate the light-sleep to deep-sleep ratio for the whole night. Then interpret what this ratio suggests about the sleep architecture, including whether sleep appears balanced, relatively restorative, too shallow, or atypical. Please report the final ratio and give a brief explanation of the sleep quality implication." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the light-sleep to deep-sleep ratio from the agent's report.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key must be EXACTLY \"light_deep_sleep_ratio\".\n5. The value must be a FLOAT or null.\n6. If the value is missing or cannot be found, return {\"light_deep_sleep_ratio\": null}.\n\n### OUTPUT TEMPLATE\n{\"light_deep_sleep_ratio\": }", + "metrics": [ + { + "metric_id": "light_deep_ratio_accuracy", + "type": "numeric_check", + "target_key": "light_deep_sleep_ratio", + "weight": 40, + "params": { + "gt_value": 1.155844155844156, + "tolerance": 0.0577922077922078 + } + }, + { + "metric_id": "sleep_quality_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 60, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is ISRUC_01.edf. The ground-truth light/deep sleep ratio is 1.155844, where the ratio is defined as (N1+N2)/N3. The correct response must explicitly conclude that deep sleep is relatively high and that the sleep shows an enhanced restorative tendency. Mark the response as correct only if its final conclusion matches that rule. If the response gives the opposite conclusion or contradicts that rule, mark it as incorrect. Output only a valid JSON object with exactly one key named status whose value is either True or False. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case7/case7_02.json b/sleep_assessment/cases/case7/case7_02.json new file mode 100644 index 0000000000000000000000000000000000000000..c329f490bf453107c17ad82e24925bc1eee5d441 --- /dev/null +++ b/sleep_assessment/cases/case7/case7_02.json @@ -0,0 +1,36 @@ +{ + "meta_info": { + "case_id": "ISRUC_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_02.npy", + "instruction": "Please use the provided sleep-stage label file to calculate the light-sleep to deep-sleep ratio for the whole night. Then interpret what this ratio suggests about the sleep architecture, including whether sleep appears balanced, relatively restorative, too shallow, or atypical. Please report the final ratio and give a brief explanation of the sleep quality implication." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the light-sleep to deep-sleep ratio from the agent's report.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key must be EXACTLY \"light_deep_sleep_ratio\".\n5. The value must be a FLOAT or null.\n6. If the value is missing or cannot be found, return {\"light_deep_sleep_ratio\": null}.\n\n### OUTPUT TEMPLATE\n{\"light_deep_sleep_ratio\": }", + "metrics": [ + { + "metric_id": "light_deep_ratio_accuracy", + "type": "numeric_check", + "target_key": "light_deep_sleep_ratio", + "weight": 40, + "params": { + "gt_value": 2.929936305732484, + "tolerance": 0.1464968152866242 + } + }, + { + "metric_id": "sleep_quality_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 60, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is ISRUC_02.edf. The ground-truth light/deep sleep ratio is 2.929936, where the ratio is defined as (N1+N2)/N3. The correct response must explicitly conclude that the sleep structure is balanced or normal. Mark the response as correct only if its final conclusion matches that rule. If the response gives the opposite conclusion or contradicts that rule, mark it as incorrect. Output only a valid JSON object with exactly one key named status whose value is either True or False. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case7/case7_03.json b/sleep_assessment/cases/case7/case7_03.json new file mode 100644 index 0000000000000000000000000000000000000000..52dbee1ddfad5c4fc65b33a9a6e11f6e479f9e03 --- /dev/null +++ b/sleep_assessment/cases/case7/case7_03.json @@ -0,0 +1,36 @@ +{ + "meta_info": { + "case_id": "ISRUC_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_03.npy", + "instruction": "Please use the provided sleep-stage label file to calculate the light-sleep to deep-sleep ratio for the whole night. Then interpret what this ratio suggests about the sleep architecture, including whether sleep appears balanced, relatively restorative, too shallow, or atypical. Please report the final ratio and give a brief explanation of the sleep quality implication." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the light-sleep to deep-sleep ratio from the agent's report.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key must be EXACTLY \"light_deep_sleep_ratio\".\n5. The value must be a FLOAT or null.\n6. If the value is missing or cannot be found, return {\"light_deep_sleep_ratio\": null}.\n\n### OUTPUT TEMPLATE\n{\"light_deep_sleep_ratio\": }", + "metrics": [ + { + "metric_id": "light_deep_ratio_accuracy", + "type": "numeric_check", + "target_key": "light_deep_sleep_ratio", + "weight": 40, + "params": { + "gt_value": 2.3757225433526012, + "tolerance": 0.11878612716763007 + } + }, + { + "metric_id": "sleep_quality_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 60, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is ISRUC_03.edf. The ground-truth light/deep sleep ratio is 2.375723, where the ratio is defined as (N1+N2)/N3. The correct response must explicitly conclude that the sleep structure is balanced or normal. Mark the response as correct only if its final conclusion matches that rule. If the response gives the opposite conclusion or contradicts that rule, mark it as incorrect. Output only a valid JSON object with exactly one key named status whose value is either True or False. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case7/case7_04.json b/sleep_assessment/cases/case7/case7_04.json new file mode 100644 index 0000000000000000000000000000000000000000..70e43873234b67d807cf342e5c541a1f9de12cb7 --- /dev/null +++ b/sleep_assessment/cases/case7/case7_04.json @@ -0,0 +1,36 @@ +{ + "meta_info": { + "case_id": "ISRUC_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_04.npy", + "instruction": "Please use the provided sleep-stage label file to calculate the light-sleep to deep-sleep ratio for the whole night. Then interpret what this ratio suggests about the sleep architecture, including whether sleep appears balanced, relatively restorative, too shallow, or atypical. Please report the final ratio and give a brief explanation of the sleep quality implication." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the light-sleep to deep-sleep ratio from the agent's report.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key must be EXACTLY \"light_deep_sleep_ratio\".\n5. The value must be a FLOAT or null.\n6. If the value is missing or cannot be found, return {\"light_deep_sleep_ratio\": null}.\n\n### OUTPUT TEMPLATE\n{\"light_deep_sleep_ratio\": }", + "metrics": [ + { + "metric_id": "light_deep_ratio_accuracy", + "type": "numeric_check", + "target_key": "light_deep_sleep_ratio", + "weight": 40, + "params": { + "gt_value": 2.294392523364486, + "tolerance": 0.11471962616822431 + } + }, + { + "metric_id": "sleep_quality_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 60, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is ISRUC_04.edf. The ground-truth light/deep sleep ratio is 2.294393, where the ratio is defined as (N1+N2)/N3. The correct response must explicitly conclude that the sleep structure is balanced or normal. Mark the response as correct only if its final conclusion matches that rule. If the response gives the opposite conclusion or contradicts that rule, mark it as incorrect. Output only a valid JSON object with exactly one key named status whose value is either True or False. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case7/case7_05.json b/sleep_assessment/cases/case7/case7_05.json new file mode 100644 index 0000000000000000000000000000000000000000..105b97c3688427fbcd9f4285d4d97dfebb683e67 --- /dev/null +++ b/sleep_assessment/cases/case7/case7_05.json @@ -0,0 +1,36 @@ +{ + "meta_info": { + "case_id": "ISRUC_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_05.npy", + "instruction": "Please use the provided sleep-stage label file to calculate the light-sleep to deep-sleep ratio for the whole night. Then interpret what this ratio suggests about the sleep architecture, including whether sleep appears balanced, relatively restorative, too shallow, or atypical. Please report the final ratio and give a brief explanation of the sleep quality implication." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the light-sleep to deep-sleep ratio from the agent's report.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key must be EXACTLY \"light_deep_sleep_ratio\".\n5. The value must be a FLOAT or null.\n6. If the value is missing or cannot be found, return {\"light_deep_sleep_ratio\": null}.\n\n### OUTPUT TEMPLATE\n{\"light_deep_sleep_ratio\": }", + "metrics": [ + { + "metric_id": "light_deep_ratio_accuracy", + "type": "numeric_check", + "target_key": "light_deep_sleep_ratio", + "weight": 40, + "params": { + "gt_value": 2.274390243902439, + "tolerance": 0.11371951219512196 + } + }, + { + "metric_id": "sleep_quality_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 60, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is ISRUC_05.edf. The ground-truth light/deep sleep ratio is 2.274390, where the ratio is defined as (N1+N2)/N3. The correct response must explicitly conclude that the sleep structure is balanced or normal. Mark the response as correct only if its final conclusion matches that rule. If the response gives the opposite conclusion or contradicts that rule, mark it as incorrect. Output only a valid JSON object with exactly one key named status whose value is either True or False. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case7/case7_06.json b/sleep_assessment/cases/case7/case7_06.json new file mode 100644 index 0000000000000000000000000000000000000000..e7da1e15e1be5a669b457d7f908bac1072b50fba --- /dev/null +++ b/sleep_assessment/cases/case7/case7_06.json @@ -0,0 +1,36 @@ +{ + "meta_info": { + "case_id": "HMC_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_01.npy", + "instruction": "Please use the provided sleep-stage label file to calculate the light-sleep to deep-sleep ratio for the whole night. Then interpret what this ratio suggests about the sleep architecture, including whether sleep appears balanced, relatively restorative, too shallow, or atypical. Please report the final ratio and give a brief explanation of the sleep quality implication." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the light-sleep to deep-sleep ratio from the agent's report.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key must be EXACTLY \"light_deep_sleep_ratio\".\n5. The value must be a FLOAT or null.\n6. If the value is missing or cannot be found, return {\"light_deep_sleep_ratio\": null}.\n\n### OUTPUT TEMPLATE\n{\"light_deep_sleep_ratio\": }", + "metrics": [ + { + "metric_id": "light_deep_ratio_accuracy", + "type": "numeric_check", + "target_key": "light_deep_sleep_ratio", + "weight": 40, + "params": { + "gt_value": 23.434782608695652, + "tolerance": 1.1717391304347826 + } + }, + { + "metric_id": "sleep_quality_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 60, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is HMC_01.edf. The ground-truth light/deep sleep ratio is 23.434783, where the ratio is defined as (N1+N2)/N3. The correct response must explicitly conclude that deep sleep is markedly insufficient and that the sleep structure is abnormally shallow. Mark the response as correct only if its final conclusion matches that rule. If the response gives the opposite conclusion or contradicts that rule, mark it as incorrect. Output only a valid JSON object with exactly one key named status whose value is either True or False. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case7/case7_07.json b/sleep_assessment/cases/case7/case7_07.json new file mode 100644 index 0000000000000000000000000000000000000000..fdf26ba0070543e522c44e2367c49b333862807c --- /dev/null +++ b/sleep_assessment/cases/case7/case7_07.json @@ -0,0 +1,36 @@ +{ + "meta_info": { + "case_id": "HMC_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_02.npy", + "instruction": "Please use the provided sleep-stage label file to calculate the light-sleep to deep-sleep ratio for the whole night. Then interpret what this ratio suggests about the sleep architecture, including whether sleep appears balanced, relatively restorative, too shallow, or atypical. Please report the final ratio and give a brief explanation of the sleep quality implication." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the light-sleep to deep-sleep ratio from the agent's report.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key must be EXACTLY \"light_deep_sleep_ratio\".\n5. The value must be a FLOAT or null.\n6. If the value is missing or cannot be found, return {\"light_deep_sleep_ratio\": null}.\n\n### OUTPUT TEMPLATE\n{\"light_deep_sleep_ratio\": }", + "metrics": [ + { + "metric_id": "light_deep_ratio_accuracy", + "type": "numeric_check", + "target_key": "light_deep_sleep_ratio", + "weight": 40, + "params": { + "gt_value": 1.6785714285714286, + "tolerance": 0.08392857142857144 + } + }, + { + "metric_id": "sleep_quality_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 60, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is HMC_02.edf. The ground-truth light/deep sleep ratio is 1.678571, where the ratio is defined as (N1+N2)/N3. The correct response must explicitly conclude that the sleep structure is balanced or normal. Mark the response as correct only if its final conclusion matches that rule. If the response gives the opposite conclusion or contradicts that rule, mark it as incorrect. Output only a valid JSON object with exactly one key named status whose value is either True or False. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case7/case7_08.json b/sleep_assessment/cases/case7/case7_08.json new file mode 100644 index 0000000000000000000000000000000000000000..e5d2862b8badb270258d738df90cad1346a1e749 --- /dev/null +++ b/sleep_assessment/cases/case7/case7_08.json @@ -0,0 +1,36 @@ +{ + "meta_info": { + "case_id": "HMC_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_03.npy", + "instruction": "Please use the provided sleep-stage label file to calculate the light-sleep to deep-sleep ratio for the whole night. Then interpret what this ratio suggests about the sleep architecture, including whether sleep appears balanced, relatively restorative, too shallow, or atypical. Please report the final ratio and give a brief explanation of the sleep quality implication." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the light-sleep to deep-sleep ratio from the agent's report.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key must be EXACTLY \"light_deep_sleep_ratio\".\n5. The value must be a FLOAT or null.\n6. If the value is missing or cannot be found, return {\"light_deep_sleep_ratio\": null}.\n\n### OUTPUT TEMPLATE\n{\"light_deep_sleep_ratio\": }", + "metrics": [ + { + "metric_id": "light_deep_ratio_accuracy", + "type": "numeric_check", + "target_key": "light_deep_sleep_ratio", + "weight": 40, + "params": { + "gt_value": 1.66, + "tolerance": 0.083 + } + }, + { + "metric_id": "sleep_quality_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 60, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is HMC_03.edf. The ground-truth light/deep sleep ratio is 1.660000, where the ratio is defined as (N1+N2)/N3. The correct response must explicitly conclude that the sleep structure is balanced or normal. Mark the response as correct only if its final conclusion matches that rule. If the response gives the opposite conclusion or contradicts that rule, mark it as incorrect. Output only a valid JSON object with exactly one key named status whose value is either True or False. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case7/case7_09.json b/sleep_assessment/cases/case7/case7_09.json new file mode 100644 index 0000000000000000000000000000000000000000..21fd035d5fa167fb6695da71126c4705af617570 --- /dev/null +++ b/sleep_assessment/cases/case7/case7_09.json @@ -0,0 +1,36 @@ +{ + "meta_info": { + "case_id": "HMC_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_04.npy", + "instruction": "Please use the provided sleep-stage label file to calculate the light-sleep to deep-sleep ratio for the whole night. Then interpret what this ratio suggests about the sleep architecture, including whether sleep appears balanced, relatively restorative, too shallow, or atypical. Please report the final ratio and give a brief explanation of the sleep quality implication." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the light-sleep to deep-sleep ratio from the agent's report.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key must be EXACTLY \"light_deep_sleep_ratio\".\n5. The value must be a FLOAT or null.\n6. If the value is missing or cannot be found, return {\"light_deep_sleep_ratio\": null}.\n\n### OUTPUT TEMPLATE\n{\"light_deep_sleep_ratio\": }", + "metrics": [ + { + "metric_id": "light_deep_ratio_accuracy", + "type": "numeric_check", + "target_key": "light_deep_sleep_ratio", + "weight": 40, + "params": { + "gt_value": 9.765625, + "tolerance": 0.48828125 + } + }, + { + "metric_id": "sleep_quality_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 60, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is HMC_04.edf. The ground-truth light/deep sleep ratio is 9.765625, where the ratio is defined as (N1+N2)/N3. The correct response must explicitly conclude that deep sleep is markedly insufficient and that the sleep structure is abnormally shallow. Mark the response as correct only if its final conclusion matches that rule. If the response gives the opposite conclusion or contradicts that rule, mark it as incorrect. Output only a valid JSON object with exactly one key named status whose value is either True or False. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case7/case7_10.json b/sleep_assessment/cases/case7/case7_10.json new file mode 100644 index 0000000000000000000000000000000000000000..3c7831286d33bca9d41113ee9771c45cd27fa3a3 --- /dev/null +++ b/sleep_assessment/cases/case7/case7_10.json @@ -0,0 +1,36 @@ +{ + "meta_info": { + "case_id": "HMC_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_05.npy", + "instruction": "Please use the provided sleep-stage label file to calculate the light-sleep to deep-sleep ratio for the whole night. Then interpret what this ratio suggests about the sleep architecture, including whether sleep appears balanced, relatively restorative, too shallow, or atypical. Please report the final ratio and give a brief explanation of the sleep quality implication." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the light-sleep to deep-sleep ratio from the agent's report.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key must be EXACTLY \"light_deep_sleep_ratio\".\n5. The value must be a FLOAT or null.\n6. If the value is missing or cannot be found, return {\"light_deep_sleep_ratio\": null}.\n\n### OUTPUT TEMPLATE\n{\"light_deep_sleep_ratio\": }", + "metrics": [ + { + "metric_id": "light_deep_ratio_accuracy", + "type": "numeric_check", + "target_key": "light_deep_sleep_ratio", + "weight": 40, + "params": { + "gt_value": 3.2348993288590604, + "tolerance": 0.16174496644295303 + } + }, + { + "metric_id": "sleep_quality_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 60, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is HMC_05.edf. The ground-truth light/deep sleep ratio is 3.234899, where the ratio is defined as (N1+N2)/N3. The correct response must explicitly conclude that sleep is somewhat shallow and that deep sleep is slightly insufficient. Mark the response as correct only if its final conclusion matches that rule. If the response gives the opposite conclusion or contradicts that rule, mark it as incorrect. Output only a valid JSON object with exactly one key named status whose value is either True or False. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case7/case7_11.json b/sleep_assessment/cases/case7/case7_11.json new file mode 100644 index 0000000000000000000000000000000000000000..c4ebf19131c8fce7fbca5ba97107a60faf39a0d9 --- /dev/null +++ b/sleep_assessment/cases/case7/case7_11.json @@ -0,0 +1,36 @@ +{ + "meta_info": { + "case_id": "SHHS1_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_01.npy", + "instruction": "Please use the provided sleep-stage label file to calculate the light-sleep to deep-sleep ratio for the whole night. Then interpret what this ratio suggests about the sleep architecture, including whether sleep appears balanced, relatively restorative, too shallow, or atypical. Please report the final ratio and give a brief explanation of the sleep quality implication." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the light-sleep to deep-sleep ratio from the agent's report.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key must be EXACTLY \"light_deep_sleep_ratio\".\n5. The value must be a FLOAT or null.\n6. If the value is missing or cannot be found, return {\"light_deep_sleep_ratio\": null}.\n\n### OUTPUT TEMPLATE\n{\"light_deep_sleep_ratio\": }", + "metrics": [ + { + "metric_id": "light_deep_ratio_accuracy", + "type": "numeric_check", + "target_key": "light_deep_sleep_ratio", + "weight": 40, + "params": { + "gt_value": 3.475862068965517, + "tolerance": 0.17379310344827587 + } + }, + { + "metric_id": "sleep_quality_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 60, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is SHHS1_01.edf. The ground-truth light/deep sleep ratio is 3.475862, where the ratio is defined as (N1+N2)/N3. The correct response must explicitly conclude that sleep is somewhat shallow and that deep sleep is slightly insufficient. Mark the response as correct only if its final conclusion matches that rule. If the response gives the opposite conclusion or contradicts that rule, mark it as incorrect. Output only a valid JSON object with exactly one key named status whose value is either True or False. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case7/case7_12.json b/sleep_assessment/cases/case7/case7_12.json new file mode 100644 index 0000000000000000000000000000000000000000..afc5864385ae7be9a99220ba6de2a3f46a3f1e5d --- /dev/null +++ b/sleep_assessment/cases/case7/case7_12.json @@ -0,0 +1,36 @@ +{ + "meta_info": { + "case_id": "SHHS1_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_02.npy", + "instruction": "Please use the provided sleep-stage label file to calculate the light-sleep to deep-sleep ratio for the whole night. Then interpret what this ratio suggests about the sleep architecture, including whether sleep appears balanced, relatively restorative, too shallow, or atypical. Please report the final ratio and give a brief explanation of the sleep quality implication." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the light-sleep to deep-sleep ratio from the agent's report.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key must be EXACTLY \"light_deep_sleep_ratio\".\n5. The value must be a FLOAT or null.\n6. If the value is missing or cannot be found, return {\"light_deep_sleep_ratio\": null}.\n\n### OUTPUT TEMPLATE\n{\"light_deep_sleep_ratio\": }", + "metrics": [ + { + "metric_id": "light_deep_ratio_accuracy", + "type": "numeric_check", + "target_key": "light_deep_sleep_ratio", + "weight": 40, + "params": { + "gt_value": 3.9672131147540983, + "tolerance": 0.19836065573770492 + } + }, + { + "metric_id": "sleep_quality_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 60, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is SHHS1_02.edf. The ground-truth light/deep sleep ratio is 3.967213, where the ratio is defined as (N1+N2)/N3. The correct response must explicitly conclude that sleep is somewhat shallow and that deep sleep is slightly insufficient. Mark the response as correct only if its final conclusion matches that rule. If the response gives the opposite conclusion or contradicts that rule, mark it as incorrect. Output only a valid JSON object with exactly one key named status whose value is either True or False. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case7/case7_13.json b/sleep_assessment/cases/case7/case7_13.json new file mode 100644 index 0000000000000000000000000000000000000000..c9ee4fcaaac2c525fb1a628823a3556938be3e94 --- /dev/null +++ b/sleep_assessment/cases/case7/case7_13.json @@ -0,0 +1,36 @@ +{ + "meta_info": { + "case_id": "SHHS1_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_03.npy", + "instruction": "Please use the provided sleep-stage label file to calculate the light-sleep to deep-sleep ratio for the whole night. Then interpret what this ratio suggests about the sleep architecture, including whether sleep appears balanced, relatively restorative, too shallow, or atypical. Please report the final ratio and give a brief explanation of the sleep quality implication." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the light-sleep to deep-sleep ratio from the agent's report.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key must be EXACTLY \"light_deep_sleep_ratio\".\n5. The value must be a FLOAT or null.\n6. If the value is missing or cannot be found, return {\"light_deep_sleep_ratio\": null}.\n\n### OUTPUT TEMPLATE\n{\"light_deep_sleep_ratio\": }", + "metrics": [ + { + "metric_id": "light_deep_ratio_accuracy", + "type": "numeric_check", + "target_key": "light_deep_sleep_ratio", + "weight": 40, + "params": { + "gt_value": 1.0553745928338762, + "tolerance": 0.052768729641693816 + } + }, + { + "metric_id": "sleep_quality_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 60, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is SHHS1_03.edf. The ground-truth light/deep sleep ratio is 1.055375, where the ratio is defined as (N1+N2)/N3. The correct response must explicitly conclude that deep sleep is relatively high and that the sleep shows an enhanced restorative tendency. Mark the response as correct only if its final conclusion matches that rule. If the response gives the opposite conclusion or contradicts that rule, mark it as incorrect. Output only a valid JSON object with exactly one key named status whose value is either True or False. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case7/case7_14.json b/sleep_assessment/cases/case7/case7_14.json new file mode 100644 index 0000000000000000000000000000000000000000..787d42e891f44e740412ad712c750706cad3eb0c --- /dev/null +++ b/sleep_assessment/cases/case7/case7_14.json @@ -0,0 +1,36 @@ +{ + "meta_info": { + "case_id": "SHHS1_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_04.npy", + "instruction": "Please use the provided sleep-stage label file to calculate the light-sleep to deep-sleep ratio for the whole night. Then interpret what this ratio suggests about the sleep architecture, including whether sleep appears balanced, relatively restorative, too shallow, or atypical. Please report the final ratio and give a brief explanation of the sleep quality implication." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the light-sleep to deep-sleep ratio from the agent's report.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key must be EXACTLY \"light_deep_sleep_ratio\".\n5. The value must be a FLOAT or null.\n6. If the value is missing or cannot be found, return {\"light_deep_sleep_ratio\": null}.\n\n### OUTPUT TEMPLATE\n{\"light_deep_sleep_ratio\": }", + "metrics": [ + { + "metric_id": "light_deep_ratio_accuracy", + "type": "numeric_check", + "target_key": "light_deep_sleep_ratio", + "weight": 40, + "params": { + "gt_value": 0.6190476190476191, + "tolerance": 0.05 + } + }, + { + "metric_id": "sleep_quality_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 60, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is SHHS1_04.edf. The ground-truth light/deep sleep ratio is 0.619048, where the ratio is defined as (N1+N2)/N3. The correct response must explicitly conclude that deep sleep is unusually high and that the overall sleep structure is atypical. It must not describe the structure as balanced, normal, or shallow. Mark the response as correct only if its final conclusion matches that rule. If the response gives the opposite conclusion or contradicts that rule, mark it as incorrect. Output only a valid JSON object with exactly one key named status whose value is either True or False. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case7/case7_15.json b/sleep_assessment/cases/case7/case7_15.json new file mode 100644 index 0000000000000000000000000000000000000000..c49bc0010f9d8cc3cf1364383cdbddbc2360658e --- /dev/null +++ b/sleep_assessment/cases/case7/case7_15.json @@ -0,0 +1,36 @@ +{ + "meta_info": { + "case_id": "SHHS1_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_05.npy", + "instruction": "Please use the provided sleep-stage label file to calculate the light-sleep to deep-sleep ratio for the whole night. Then interpret what this ratio suggests about the sleep architecture, including whether sleep appears balanced, relatively restorative, too shallow, or atypical. Please report the final ratio and give a brief explanation of the sleep quality implication." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the light-sleep to deep-sleep ratio from the agent's report.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key must be EXACTLY \"light_deep_sleep_ratio\".\n5. The value must be a FLOAT or null.\n6. If the value is missing or cannot be found, return {\"light_deep_sleep_ratio\": null}.\n\n### OUTPUT TEMPLATE\n{\"light_deep_sleep_ratio\": }", + "metrics": [ + { + "metric_id": "light_deep_ratio_accuracy", + "type": "numeric_check", + "target_key": "light_deep_sleep_ratio", + "weight": 40, + "params": { + "gt_value": 5.555555555555555, + "tolerance": 0.2777777777777778 + } + }, + { + "metric_id": "sleep_quality_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 60, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is SHHS1_05.edf. The ground-truth light/deep sleep ratio is 5.555556, where the ratio is defined as (N1+N2)/N3. The correct response must explicitly conclude that deep sleep is markedly insufficient and that the sleep structure is abnormally shallow. Mark the response as correct only if its final conclusion matches that rule. If the response gives the opposite conclusion or contradicts that rule, mark it as incorrect. Output only a valid JSON object with exactly one key named status whose value is either True or False. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case7/case7_16.json b/sleep_assessment/cases/case7/case7_16.json new file mode 100644 index 0000000000000000000000000000000000000000..cc32e3c15f935d6413ea066fa836348e13a62d92 --- /dev/null +++ b/sleep_assessment/cases/case7/case7_16.json @@ -0,0 +1,36 @@ +{ + "meta_info": { + "case_id": "MASSSS3_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_01.npy", + "instruction": "Please use the provided sleep-stage label file to calculate the light-sleep to deep-sleep ratio for the whole night. Then interpret what this ratio suggests about the sleep architecture, including whether sleep appears balanced, relatively restorative, too shallow, or atypical. Please report the final ratio and give a brief explanation of the sleep quality implication." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the light-sleep to deep-sleep ratio from the agent's report.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key must be EXACTLY \"light_deep_sleep_ratio\".\n5. The value must be a FLOAT or null.\n6. If the value is missing or cannot be found, return {\"light_deep_sleep_ratio\": null}.\n\n### OUTPUT TEMPLATE\n{\"light_deep_sleep_ratio\": }", + "metrics": [ + { + "metric_id": "light_deep_ratio_accuracy", + "type": "numeric_check", + "target_key": "light_deep_sleep_ratio", + "weight": 40, + "params": { + "gt_value": 4.191780821917808, + "tolerance": 0.2095890410958904 + } + }, + { + "metric_id": "sleep_quality_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 60, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is MASSSS3_01.edf. The ground-truth light/deep sleep ratio is 4.191781, where the ratio is defined as (N1+N2)/N3. The correct response must explicitly conclude that deep sleep is markedly insufficient and that the sleep structure is abnormally shallow. Mark the response as correct only if its final conclusion matches that rule. If the response gives the opposite conclusion or contradicts that rule, mark it as incorrect. Output only a valid JSON object with exactly one key named status whose value is either True or False. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case7/case7_17.json b/sleep_assessment/cases/case7/case7_17.json new file mode 100644 index 0000000000000000000000000000000000000000..220bf60f49758a0932b9f1a69c7e0e7d89365948 --- /dev/null +++ b/sleep_assessment/cases/case7/case7_17.json @@ -0,0 +1,36 @@ +{ + "meta_info": { + "case_id": "MASSSS3_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_02.npy", + "instruction": "Please use the provided sleep-stage label file to calculate the light-sleep to deep-sleep ratio for the whole night. Then interpret what this ratio suggests about the sleep architecture, including whether sleep appears balanced, relatively restorative, too shallow, or atypical. Please report the final ratio and give a brief explanation of the sleep quality implication." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the light-sleep to deep-sleep ratio from the agent's report.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key must be EXACTLY \"light_deep_sleep_ratio\".\n5. The value must be a FLOAT or null.\n6. If the value is missing or cannot be found, return {\"light_deep_sleep_ratio\": null}.\n\n### OUTPUT TEMPLATE\n{\"light_deep_sleep_ratio\": }", + "metrics": [ + { + "metric_id": "light_deep_ratio_accuracy", + "type": "numeric_check", + "target_key": "light_deep_sleep_ratio", + "weight": 40, + "params": { + "gt_value": 3.0977011494252875, + "tolerance": 0.15488505747126438 + } + }, + { + "metric_id": "sleep_quality_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 60, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is MASSSS3_02.edf. The ground-truth light/deep sleep ratio is 3.097701, where the ratio is defined as (N1+N2)/N3. The correct response must explicitly conclude that sleep is somewhat shallow and that deep sleep is slightly insufficient. Mark the response as correct only if its final conclusion matches that rule. If the response gives the opposite conclusion or contradicts that rule, mark it as incorrect. Output only a valid JSON object with exactly one key named status whose value is either True or False. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case7/case7_18.json b/sleep_assessment/cases/case7/case7_18.json new file mode 100644 index 0000000000000000000000000000000000000000..4af68e9f37437174ebe096064023e82748a55c82 --- /dev/null +++ b/sleep_assessment/cases/case7/case7_18.json @@ -0,0 +1,36 @@ +{ + "meta_info": { + "case_id": "MASSSS3_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_03.npy", + "instruction": "Please use the provided sleep-stage label file to calculate the light-sleep to deep-sleep ratio for the whole night. Then interpret what this ratio suggests about the sleep architecture, including whether sleep appears balanced, relatively restorative, too shallow, or atypical. Please report the final ratio and give a brief explanation of the sleep quality implication." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the light-sleep to deep-sleep ratio from the agent's report.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key must be EXACTLY \"light_deep_sleep_ratio\".\n5. The value must be a FLOAT or null.\n6. If the value is missing or cannot be found, return {\"light_deep_sleep_ratio\": null}.\n\n### OUTPUT TEMPLATE\n{\"light_deep_sleep_ratio\": }", + "metrics": [ + { + "metric_id": "light_deep_ratio_accuracy", + "type": "numeric_check", + "target_key": "light_deep_sleep_ratio", + "weight": 40, + "params": { + "gt_value": 4.120967741935484, + "tolerance": 0.2060483870967742 + } + }, + { + "metric_id": "sleep_quality_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 60, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is MASSSS3_03.edf. The ground-truth light/deep sleep ratio is 4.120968, where the ratio is defined as (N1+N2)/N3. The correct response must explicitly conclude that deep sleep is markedly insufficient and that the sleep structure is abnormally shallow. Mark the response as correct only if its final conclusion matches that rule. If the response gives the opposite conclusion or contradicts that rule, mark it as incorrect. Output only a valid JSON object with exactly one key named status whose value is either True or False. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case7/case7_19.json b/sleep_assessment/cases/case7/case7_19.json new file mode 100644 index 0000000000000000000000000000000000000000..68279e8d65a1209af7665753d90eb164d5de3219 --- /dev/null +++ b/sleep_assessment/cases/case7/case7_19.json @@ -0,0 +1,36 @@ +{ + "meta_info": { + "case_id": "MASSSS3_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_04.npy", + "instruction": "Please use the provided sleep-stage label file to calculate the light-sleep to deep-sleep ratio for the whole night. Then interpret what this ratio suggests about the sleep architecture, including whether sleep appears balanced, relatively restorative, too shallow, or atypical. Please report the final ratio and give a brief explanation of the sleep quality implication." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the light-sleep to deep-sleep ratio from the agent's report.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key must be EXACTLY \"light_deep_sleep_ratio\".\n5. The value must be a FLOAT or null.\n6. If the value is missing or cannot be found, return {\"light_deep_sleep_ratio\": null}.\n\n### OUTPUT TEMPLATE\n{\"light_deep_sleep_ratio\": }", + "metrics": [ + { + "metric_id": "light_deep_ratio_accuracy", + "type": "numeric_check", + "target_key": "light_deep_sleep_ratio", + "weight": 40, + "params": { + "gt_value": 9.25, + "tolerance": 0.4625 + } + }, + { + "metric_id": "sleep_quality_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 60, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is MASSSS3_04.edf. The ground-truth light/deep sleep ratio is 9.250000, where the ratio is defined as (N1+N2)/N3. The correct response must explicitly conclude that deep sleep is markedly insufficient and that the sleep structure is abnormally shallow. Mark the response as correct only if its final conclusion matches that rule. If the response gives the opposite conclusion or contradicts that rule, mark it as incorrect. Output only a valid JSON object with exactly one key named status whose value is either True or False. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case7/case7_20.json b/sleep_assessment/cases/case7/case7_20.json new file mode 100644 index 0000000000000000000000000000000000000000..0c111fc37179638b5bd6f2b709869556e3090674 --- /dev/null +++ b/sleep_assessment/cases/case7/case7_20.json @@ -0,0 +1,36 @@ +{ + "meta_info": { + "case_id": "MASSSS3_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_05.npy", + "instruction": "Please use the provided sleep-stage label file to calculate the light-sleep to deep-sleep ratio for the whole night. Then interpret what this ratio suggests about the sleep architecture, including whether sleep appears balanced, relatively restorative, too shallow, or atypical. Please report the final ratio and give a brief explanation of the sleep quality implication." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the light-sleep to deep-sleep ratio from the agent's report.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key must be EXACTLY \"light_deep_sleep_ratio\".\n5. The value must be a FLOAT or null.\n6. If the value is missing or cannot be found, return {\"light_deep_sleep_ratio\": null}.\n\n### OUTPUT TEMPLATE\n{\"light_deep_sleep_ratio\": }", + "metrics": [ + { + "metric_id": "light_deep_ratio_accuracy", + "type": "numeric_check", + "target_key": "light_deep_sleep_ratio", + "weight": 40, + "params": { + "gt_value": 2.7897435897435896, + "tolerance": 0.13948717948717948 + } + }, + { + "metric_id": "sleep_quality_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 60, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is MASSSS3_05.edf. The ground-truth light/deep sleep ratio is 2.789744, where the ratio is defined as (N1+N2)/N3. The correct response must explicitly conclude that the sleep structure is balanced or normal. Mark the response as correct only if its final conclusion matches that rule. If the response gives the opposite conclusion or contradicts that rule, mark it as incorrect. Output only a valid JSON object with exactly one key named status whose value is either True or False. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case7/case7_21.json b/sleep_assessment/cases/case7/case7_21.json new file mode 100644 index 0000000000000000000000000000000000000000..ecfac0ae2fd375ff046c71b38f1c0664de5d7724 --- /dev/null +++ b/sleep_assessment/cases/case7/case7_21.json @@ -0,0 +1,36 @@ +{ + "meta_info": { + "case_id": "Physionet2018_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_01.npy", + "instruction": "Please use the provided sleep-stage label file to calculate the light-sleep to deep-sleep ratio for the whole night. Then interpret what this ratio suggests about the sleep architecture, including whether sleep appears balanced, relatively restorative, too shallow, or atypical. Please report the final ratio and give a brief explanation of the sleep quality implication." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the light-sleep to deep-sleep ratio from the agent's report.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key must be EXACTLY \"light_deep_sleep_ratio\".\n5. The value must be a FLOAT or null.\n6. If the value is missing or cannot be found, return {\"light_deep_sleep_ratio\": null}.\n\n### OUTPUT TEMPLATE\n{\"light_deep_sleep_ratio\": }", + "metrics": [ + { + "metric_id": "light_deep_ratio_accuracy", + "type": "numeric_check", + "target_key": "light_deep_sleep_ratio", + "weight": 40, + "params": { + "gt_value": 4.513888888888889, + "tolerance": 0.22569444444444448 + } + }, + { + "metric_id": "sleep_quality_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 60, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is Physionet2018_01.edf. The ground-truth light/deep sleep ratio is 4.513889, where the ratio is defined as (N1+N2)/N3. The correct response must explicitly conclude that deep sleep is markedly insufficient and that the sleep structure is abnormally shallow. Mark the response as correct only if its final conclusion matches that rule. If the response gives the opposite conclusion or contradicts that rule, mark it as incorrect. Output only a valid JSON object with exactly one key named status whose value is either True or False. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case7/case7_22.json b/sleep_assessment/cases/case7/case7_22.json new file mode 100644 index 0000000000000000000000000000000000000000..1a11bffa7f832fd1c531ad40eb437d5107e71293 --- /dev/null +++ b/sleep_assessment/cases/case7/case7_22.json @@ -0,0 +1,36 @@ +{ + "meta_info": { + "case_id": "Physionet2018_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_02.npy", + "instruction": "Please use the provided sleep-stage label file to calculate the light-sleep to deep-sleep ratio for the whole night. Then interpret what this ratio suggests about the sleep architecture, including whether sleep appears balanced, relatively restorative, too shallow, or atypical. Please report the final ratio and give a brief explanation of the sleep quality implication." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the light-sleep to deep-sleep ratio from the agent's report.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key must be EXACTLY \"light_deep_sleep_ratio\".\n5. The value must be a FLOAT or null.\n6. If the value is missing or cannot be found, return {\"light_deep_sleep_ratio\": null}.\n\n### OUTPUT TEMPLATE\n{\"light_deep_sleep_ratio\": }", + "metrics": [ + { + "metric_id": "light_deep_ratio_accuracy", + "type": "numeric_check", + "target_key": "light_deep_sleep_ratio", + "weight": 40, + "params": { + "gt_value": 20.857142857142858, + "tolerance": 1.042857142857143 + } + }, + { + "metric_id": "sleep_quality_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 60, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is Physionet2018_02.edf. The ground-truth light/deep sleep ratio is 20.857143, where the ratio is defined as (N1+N2)/N3. The correct response must explicitly conclude that deep sleep is markedly insufficient and that the sleep structure is abnormally shallow. Mark the response as correct only if its final conclusion matches that rule. If the response gives the opposite conclusion or contradicts that rule, mark it as incorrect. Output only a valid JSON object with exactly one key named status whose value is either True or False. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case7/case7_23.json b/sleep_assessment/cases/case7/case7_23.json new file mode 100644 index 0000000000000000000000000000000000000000..09a6353805a46f794e85d33e5309e53d45613c04 --- /dev/null +++ b/sleep_assessment/cases/case7/case7_23.json @@ -0,0 +1,36 @@ +{ + "meta_info": { + "case_id": "Physionet2018_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_03.npy", + "instruction": "Please use the provided sleep-stage label file to calculate the light-sleep to deep-sleep ratio for the whole night. Then interpret what this ratio suggests about the sleep architecture, including whether sleep appears balanced, relatively restorative, too shallow, or atypical. Please report the final ratio and give a brief explanation of the sleep quality implication." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the light-sleep to deep-sleep ratio from the agent's report.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key must be EXACTLY \"light_deep_sleep_ratio\".\n5. The value must be a FLOAT or null.\n6. If the value is missing or cannot be found, return {\"light_deep_sleep_ratio\": null}.\n\n### OUTPUT TEMPLATE\n{\"light_deep_sleep_ratio\": }", + "metrics": [ + { + "metric_id": "light_deep_ratio_accuracy", + "type": "numeric_check", + "target_key": "light_deep_sleep_ratio", + "weight": 40, + "params": { + "gt_value": 6.274193548387097, + "tolerance": 0.31370967741935485 + } + }, + { + "metric_id": "sleep_quality_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 60, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is Physionet2018_03.edf. The ground-truth light/deep sleep ratio is 6.274194, where the ratio is defined as (N1+N2)/N3. The correct response must explicitly conclude that deep sleep is markedly insufficient and that the sleep structure is abnormally shallow. Mark the response as correct only if its final conclusion matches that rule. If the response gives the opposite conclusion or contradicts that rule, mark it as incorrect. Output only a valid JSON object with exactly one key named status whose value is either True or False. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case7/case7_24.json b/sleep_assessment/cases/case7/case7_24.json new file mode 100644 index 0000000000000000000000000000000000000000..4c4fb2ffae62baf33d07b7a59f32d33a47ebbe3b --- /dev/null +++ b/sleep_assessment/cases/case7/case7_24.json @@ -0,0 +1,36 @@ +{ + "meta_info": { + "case_id": "Physionet2018_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_04.npy", + "instruction": "Please use the provided sleep-stage label file to calculate the light-sleep to deep-sleep ratio for the whole night. Then interpret what this ratio suggests about the sleep architecture, including whether sleep appears balanced, relatively restorative, too shallow, or atypical. Please report the final ratio and give a brief explanation of the sleep quality implication." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the light-sleep to deep-sleep ratio from the agent's report.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key must be EXACTLY \"light_deep_sleep_ratio\".\n5. The value must be a FLOAT or null.\n6. If the value is missing or cannot be found, return {\"light_deep_sleep_ratio\": null}.\n\n### OUTPUT TEMPLATE\n{\"light_deep_sleep_ratio\": }", + "metrics": [ + { + "metric_id": "light_deep_ratio_accuracy", + "type": "numeric_check", + "target_key": "light_deep_sleep_ratio", + "weight": 40, + "params": { + "gt_value": 2.9127906976744184, + "tolerance": 0.14563953488372092 + } + }, + { + "metric_id": "sleep_quality_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 60, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is Physionet2018_04.edf. The ground-truth light/deep sleep ratio is 2.912791, where the ratio is defined as (N1+N2)/N3. The correct response must explicitly conclude that the sleep structure is balanced or normal. Mark the response as correct only if its final conclusion matches that rule. If the response gives the opposite conclusion or contradicts that rule, mark it as incorrect. Output only a valid JSON object with exactly one key named status whose value is either True or False. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case7/case7_25.json b/sleep_assessment/cases/case7/case7_25.json new file mode 100644 index 0000000000000000000000000000000000000000..8b33e9d7c914c63cf6817c0aae70573e99857206 --- /dev/null +++ b/sleep_assessment/cases/case7/case7_25.json @@ -0,0 +1,36 @@ +{ + "meta_info": { + "case_id": "Physionet2018_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_05.npy", + "instruction": "Please use the provided sleep-stage label file to calculate the light-sleep to deep-sleep ratio for the whole night. Then interpret what this ratio suggests about the sleep architecture, including whether sleep appears balanced, relatively restorative, too shallow, or atypical. Please report the final ratio and give a brief explanation of the sleep quality implication." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the light-sleep to deep-sleep ratio from the agent's report.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The key must be EXACTLY \"light_deep_sleep_ratio\".\n5. The value must be a FLOAT or null.\n6. If the value is missing or cannot be found, return {\"light_deep_sleep_ratio\": null}.\n\n### OUTPUT TEMPLATE\n{\"light_deep_sleep_ratio\": }", + "metrics": [ + { + "metric_id": "light_deep_ratio_accuracy", + "type": "numeric_check", + "target_key": "light_deep_sleep_ratio", + "weight": 40, + "params": { + "gt_value": 7.0606060606060606, + "tolerance": 0.353030303030303 + } + }, + { + "metric_id": "sleep_quality_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 60, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is Physionet2018_05.edf. The ground-truth light/deep sleep ratio is 7.060606, where the ratio is defined as (N1+N2)/N3. The correct response must explicitly conclude that deep sleep is markedly insufficient and that the sleep structure is abnormally shallow. Mark the response as correct only if its final conclusion matches that rule. If the response gives the opposite conclusion or contradicts that rule, mark it as incorrect. Output only a valid JSON object with exactly one key named status whose value is either True or False. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case8/case8_01.json b/sleep_assessment/cases/case8/case8_01.json new file mode 100644 index 0000000000000000000000000000000000000000..cf5a8f0cfa0afef94d809979229ba83fb7e6ee9f --- /dev/null +++ b/sleep_assessment/cases/case8/case8_01.json @@ -0,0 +1,56 @@ +{ + "meta_info": { + "case_id": "ISRUC_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_01.npy", + "instruction": "Please use the provided sleep-stage label file to identify the three longest uninterrupted sleep episodes across the whole night and report their lengths in descending order. Then briefly interpret what these episodes suggest about the overall sleep continuity of the night." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the lengths of the three longest uninterrupted sleep episodes in minutes.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"top1_sleep_episode_min\", \"top2_sleep_episode_min\", and \"top3_sleep_episode_min\".\n5. All three values must be FLOATS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"top1_sleep_episode_min\": , \"top2_sleep_episode_min\": , \"top3_sleep_episode_min\": }", + "metrics": [ + { + "metric_id": "top1_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top1_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 101.5, + "tolerance": 5.075 + } + }, + { + "metric_id": "top2_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top2_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 43.5, + "tolerance": 2.1750000000000003 + } + }, + { + "metric_id": "top3_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top3_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 43.0, + "tolerance": 2.15 + } + }, + { + "metric_id": "sleep_continuity_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 40, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is ISRUC_01.edf. The three longest uninterrupted sleep episodes are 101.500000, 43.500000, and 43.000000 minutes. The benchmark rule is: if the longest episode is <20 minutes, sleep is severely fragmented; 20-40 minutes means poor continuity; 40-90 minutes means moderate continuity; >=90 minutes means at least one good continuous sleep episode. The correct response must explicitly conclude that there is at least one clearly good continuous sleep episode. Because the second and third longest episodes are also at least 40 minutes, the response must also say that overall sleep continuity is relatively stable. Score the response in two parts. Give 0.5 points if the base continuity judgement is correct. Give 0.5 points if the secondary stability-or-fragmentation judgement is correct. The total score must therefore be exactly one of 0.0, 0.5, or 1.0. Output only a valid JSON object with exactly one key named score whose value is 0.0, 0.5, or 1.0. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case8/case8_02.json b/sleep_assessment/cases/case8/case8_02.json new file mode 100644 index 0000000000000000000000000000000000000000..762b7581b46729d5954114b16b566ab3b5facedd --- /dev/null +++ b/sleep_assessment/cases/case8/case8_02.json @@ -0,0 +1,56 @@ +{ + "meta_info": { + "case_id": "ISRUC_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_02.npy", + "instruction": "Please use the provided sleep-stage label file to identify the three longest uninterrupted sleep episodes across the whole night and report their lengths in descending order. Then briefly interpret what these episodes suggest about the overall sleep continuity of the night." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the lengths of the three longest uninterrupted sleep episodes in minutes.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"top1_sleep_episode_min\", \"top2_sleep_episode_min\", and \"top3_sleep_episode_min\".\n5. All three values must be FLOATS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"top1_sleep_episode_min\": , \"top2_sleep_episode_min\": , \"top3_sleep_episode_min\": }", + "metrics": [ + { + "metric_id": "top1_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top1_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 60.5, + "tolerance": 3.0250000000000004 + } + }, + { + "metric_id": "top2_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top2_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 37.0, + "tolerance": 1.85 + } + }, + { + "metric_id": "top3_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top3_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 34.5, + "tolerance": 1.725 + } + }, + { + "metric_id": "sleep_continuity_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 40, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is ISRUC_02.edf. The three longest uninterrupted sleep episodes are 60.500000, 37.000000, and 34.500000 minutes. The benchmark rule is: if the longest episode is <20 minutes, sleep is severely fragmented; 20-40 minutes means poor continuity; 40-90 minutes means moderate continuity; >=90 minutes means at least one good continuous sleep episode. The correct response must explicitly conclude that sleep continuity is moderate or average. Because only the longest episode is clearly long while the other long episodes are shorter, the response must also note that the overall night still shows some fragmentation. Score the response in two parts. Give 0.5 points if the base continuity judgement is correct. Give 0.5 points if the secondary stability-or-fragmentation judgement is correct. The total score must therefore be exactly one of 0.0, 0.5, or 1.0. Output only a valid JSON object with exactly one key named score whose value is 0.0, 0.5, or 1.0. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case8/case8_03.json b/sleep_assessment/cases/case8/case8_03.json new file mode 100644 index 0000000000000000000000000000000000000000..a2a55236d60d4f2f9ae2b86ffc13a5d4260edd91 --- /dev/null +++ b/sleep_assessment/cases/case8/case8_03.json @@ -0,0 +1,56 @@ +{ + "meta_info": { + "case_id": "ISRUC_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_03.npy", + "instruction": "Please use the provided sleep-stage label file to identify the three longest uninterrupted sleep episodes across the whole night and report their lengths in descending order. Then briefly interpret what these episodes suggest about the overall sleep continuity of the night." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the lengths of the three longest uninterrupted sleep episodes in minutes.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"top1_sleep_episode_min\", \"top2_sleep_episode_min\", and \"top3_sleep_episode_min\".\n5. All three values must be FLOATS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"top1_sleep_episode_min\": , \"top2_sleep_episode_min\": , \"top3_sleep_episode_min\": }", + "metrics": [ + { + "metric_id": "top1_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top1_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 67.5, + "tolerance": 3.375 + } + }, + { + "metric_id": "top2_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top2_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 45.0, + "tolerance": 2.25 + } + }, + { + "metric_id": "top3_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top3_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 42.0, + "tolerance": 2.1 + } + }, + { + "metric_id": "sleep_continuity_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 40, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is ISRUC_03.edf. The three longest uninterrupted sleep episodes are 67.500000, 45.000000, and 42.000000 minutes. The benchmark rule is: if the longest episode is <20 minutes, sleep is severely fragmented; 20-40 minutes means poor continuity; 40-90 minutes means moderate continuity; >=90 minutes means at least one good continuous sleep episode. The correct response must explicitly conclude that sleep continuity is moderate or average. Because the second and third longest episodes are also at least 40 minutes, the response must also say that overall sleep continuity is relatively stable. Score the response in two parts. Give 0.5 points if the base continuity judgement is correct. Give 0.5 points if the secondary stability-or-fragmentation judgement is correct. The total score must therefore be exactly one of 0.0, 0.5, or 1.0. Output only a valid JSON object with exactly one key named score whose value is 0.0, 0.5, or 1.0. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case8/case8_04.json b/sleep_assessment/cases/case8/case8_04.json new file mode 100644 index 0000000000000000000000000000000000000000..12ab01b16fcb2cb608f20b765c1494e9f02d3df2 --- /dev/null +++ b/sleep_assessment/cases/case8/case8_04.json @@ -0,0 +1,56 @@ +{ + "meta_info": { + "case_id": "ISRUC_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_04.npy", + "instruction": "Please use the provided sleep-stage label file to identify the three longest uninterrupted sleep episodes across the whole night and report their lengths in descending order. Then briefly interpret what these episodes suggest about the overall sleep continuity of the night." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the lengths of the three longest uninterrupted sleep episodes in minutes.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"top1_sleep_episode_min\", \"top2_sleep_episode_min\", and \"top3_sleep_episode_min\".\n5. All three values must be FLOATS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"top1_sleep_episode_min\": , \"top2_sleep_episode_min\": , \"top3_sleep_episode_min\": }", + "metrics": [ + { + "metric_id": "top1_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top1_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 97.5, + "tolerance": 4.875 + } + }, + { + "metric_id": "top2_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top2_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 87.0, + "tolerance": 4.3500000000000005 + } + }, + { + "metric_id": "top3_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top3_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 74.0, + "tolerance": 3.7 + } + }, + { + "metric_id": "sleep_continuity_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 40, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is ISRUC_04.edf. The three longest uninterrupted sleep episodes are 97.500000, 87.000000, and 74.000000 minutes. The benchmark rule is: if the longest episode is <20 minutes, sleep is severely fragmented; 20-40 minutes means poor continuity; 40-90 minutes means moderate continuity; >=90 minutes means at least one good continuous sleep episode. The correct response must explicitly conclude that there is at least one clearly good continuous sleep episode. Because the second and third longest episodes are also at least 40 minutes, the response must also say that overall sleep continuity is relatively stable. Score the response in two parts. Give 0.5 points if the base continuity judgement is correct. Give 0.5 points if the secondary stability-or-fragmentation judgement is correct. The total score must therefore be exactly one of 0.0, 0.5, or 1.0. Output only a valid JSON object with exactly one key named score whose value is 0.0, 0.5, or 1.0. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case8/case8_05.json b/sleep_assessment/cases/case8/case8_05.json new file mode 100644 index 0000000000000000000000000000000000000000..20910355b112a0028fe6dee99d96c66434b1921a --- /dev/null +++ b/sleep_assessment/cases/case8/case8_05.json @@ -0,0 +1,56 @@ +{ + "meta_info": { + "case_id": "ISRUC_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_05.npy", + "instruction": "Please use the provided sleep-stage label file to identify the three longest uninterrupted sleep episodes across the whole night and report their lengths in descending order. Then briefly interpret what these episodes suggest about the overall sleep continuity of the night." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the lengths of the three longest uninterrupted sleep episodes in minutes.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"top1_sleep_episode_min\", \"top2_sleep_episode_min\", and \"top3_sleep_episode_min\".\n5. All three values must be FLOATS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"top1_sleep_episode_min\": , \"top2_sleep_episode_min\": , \"top3_sleep_episode_min\": }", + "metrics": [ + { + "metric_id": "top1_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top1_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 68.0, + "tolerance": 3.4000000000000004 + } + }, + { + "metric_id": "top2_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top2_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 63.5, + "tolerance": 3.1750000000000003 + } + }, + { + "metric_id": "top3_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top3_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 57.5, + "tolerance": 2.875 + } + }, + { + "metric_id": "sleep_continuity_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 40, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is ISRUC_05.edf. The three longest uninterrupted sleep episodes are 68.000000, 63.500000, and 57.500000 minutes. The benchmark rule is: if the longest episode is <20 minutes, sleep is severely fragmented; 20-40 minutes means poor continuity; 40-90 minutes means moderate continuity; >=90 minutes means at least one good continuous sleep episode. The correct response must explicitly conclude that sleep continuity is moderate or average. Because the second and third longest episodes are also at least 40 minutes, the response must also say that overall sleep continuity is relatively stable. Score the response in two parts. Give 0.5 points if the base continuity judgement is correct. Give 0.5 points if the secondary stability-or-fragmentation judgement is correct. The total score must therefore be exactly one of 0.0, 0.5, or 1.0. Output only a valid JSON object with exactly one key named score whose value is 0.0, 0.5, or 1.0. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case8/case8_06.json b/sleep_assessment/cases/case8/case8_06.json new file mode 100644 index 0000000000000000000000000000000000000000..37ef8caef35c73af5c518ac17a51fee01d1c2fea --- /dev/null +++ b/sleep_assessment/cases/case8/case8_06.json @@ -0,0 +1,56 @@ +{ + "meta_info": { + "case_id": "HMC_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_01.npy", + "instruction": "Please use the provided sleep-stage label file to identify the three longest uninterrupted sleep episodes across the whole night and report their lengths in descending order. Then briefly interpret what these episodes suggest about the overall sleep continuity of the night." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the lengths of the three longest uninterrupted sleep episodes in minutes.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"top1_sleep_episode_min\", \"top2_sleep_episode_min\", and \"top3_sleep_episode_min\".\n5. All three values must be FLOATS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"top1_sleep_episode_min\": , \"top2_sleep_episode_min\": , \"top3_sleep_episode_min\": }", + "metrics": [ + { + "metric_id": "top1_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top1_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 84.5, + "tolerance": 4.2250000000000005 + } + }, + { + "metric_id": "top2_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top2_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 70.5, + "tolerance": 3.5250000000000004 + } + }, + { + "metric_id": "top3_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top3_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 50.0, + "tolerance": 2.5 + } + }, + { + "metric_id": "sleep_continuity_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 40, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is HMC_01.edf. The three longest uninterrupted sleep episodes are 84.500000, 70.500000, and 50.000000 minutes. The benchmark rule is: if the longest episode is <20 minutes, sleep is severely fragmented; 20-40 minutes means poor continuity; 40-90 minutes means moderate continuity; >=90 minutes means at least one good continuous sleep episode. The correct response must explicitly conclude that sleep continuity is moderate or average. Because the second and third longest episodes are also at least 40 minutes, the response must also say that overall sleep continuity is relatively stable. Score the response in two parts. Give 0.5 points if the base continuity judgement is correct. Give 0.5 points if the secondary stability-or-fragmentation judgement is correct. The total score must therefore be exactly one of 0.0, 0.5, or 1.0. Output only a valid JSON object with exactly one key named score whose value is 0.0, 0.5, or 1.0. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case8/case8_07.json b/sleep_assessment/cases/case8/case8_07.json new file mode 100644 index 0000000000000000000000000000000000000000..99ed3261f3a207a5aeaffa3ad3cba1a59b12492f --- /dev/null +++ b/sleep_assessment/cases/case8/case8_07.json @@ -0,0 +1,56 @@ +{ + "meta_info": { + "case_id": "HMC_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_02.npy", + "instruction": "Please use the provided sleep-stage label file to identify the three longest uninterrupted sleep episodes across the whole night and report their lengths in descending order. Then briefly interpret what these episodes suggest about the overall sleep continuity of the night." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the lengths of the three longest uninterrupted sleep episodes in minutes.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"top1_sleep_episode_min\", \"top2_sleep_episode_min\", and \"top3_sleep_episode_min\".\n5. All three values must be FLOATS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"top1_sleep_episode_min\": , \"top2_sleep_episode_min\": , \"top3_sleep_episode_min\": }", + "metrics": [ + { + "metric_id": "top1_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top1_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 90.0, + "tolerance": 4.5 + } + }, + { + "metric_id": "top2_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top2_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 66.0, + "tolerance": 3.3000000000000003 + } + }, + { + "metric_id": "top3_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top3_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 64.0, + "tolerance": 3.2 + } + }, + { + "metric_id": "sleep_continuity_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 40, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is HMC_02.edf. The three longest uninterrupted sleep episodes are 90.000000, 66.000000, and 64.000000 minutes. The benchmark rule is: if the longest episode is <20 minutes, sleep is severely fragmented; 20-40 minutes means poor continuity; 40-90 minutes means moderate continuity; >=90 minutes means at least one good continuous sleep episode. The correct response must explicitly conclude that there is at least one clearly good continuous sleep episode. Because the second and third longest episodes are also at least 40 minutes, the response must also say that overall sleep continuity is relatively stable. Score the response in two parts. Give 0.5 points if the base continuity judgement is correct. Give 0.5 points if the secondary stability-or-fragmentation judgement is correct. The total score must therefore be exactly one of 0.0, 0.5, or 1.0. Output only a valid JSON object with exactly one key named score whose value is 0.0, 0.5, or 1.0. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case8/case8_08.json b/sleep_assessment/cases/case8/case8_08.json new file mode 100644 index 0000000000000000000000000000000000000000..bbfde4872db368f8dc6dc8f17b404eac4ac4d963 --- /dev/null +++ b/sleep_assessment/cases/case8/case8_08.json @@ -0,0 +1,56 @@ +{ + "meta_info": { + "case_id": "HMC_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_03.npy", + "instruction": "Please use the provided sleep-stage label file to identify the three longest uninterrupted sleep episodes across the whole night and report their lengths in descending order. Then briefly interpret what these episodes suggest about the overall sleep continuity of the night." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the lengths of the three longest uninterrupted sleep episodes in minutes.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"top1_sleep_episode_min\", \"top2_sleep_episode_min\", and \"top3_sleep_episode_min\".\n5. All three values must be FLOATS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"top1_sleep_episode_min\": , \"top2_sleep_episode_min\": , \"top3_sleep_episode_min\": }", + "metrics": [ + { + "metric_id": "top1_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top1_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 116.5, + "tolerance": 5.825 + } + }, + { + "metric_id": "top2_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top2_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 48.0, + "tolerance": 2.4000000000000004 + } + }, + { + "metric_id": "top3_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top3_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 33.5, + "tolerance": 1.675 + } + }, + { + "metric_id": "sleep_continuity_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 40, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is HMC_03.edf. The three longest uninterrupted sleep episodes are 116.500000, 48.000000, and 33.500000 minutes. The benchmark rule is: if the longest episode is <20 minutes, sleep is severely fragmented; 20-40 minutes means poor continuity; 40-90 minutes means moderate continuity; >=90 minutes means at least one good continuous sleep episode. The correct response must explicitly conclude that there is at least one clearly good continuous sleep episode. Because only the longest episode is clearly long while the other long episodes are shorter, the response must also note that the overall night still shows some fragmentation. Score the response in two parts. Give 0.5 points if the base continuity judgement is correct. Give 0.5 points if the secondary stability-or-fragmentation judgement is correct. The total score must therefore be exactly one of 0.0, 0.5, or 1.0. Output only a valid JSON object with exactly one key named score whose value is 0.0, 0.5, or 1.0. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case8/case8_09.json b/sleep_assessment/cases/case8/case8_09.json new file mode 100644 index 0000000000000000000000000000000000000000..d7df0c8c96202870c646abfce11f7a1cc5286e26 --- /dev/null +++ b/sleep_assessment/cases/case8/case8_09.json @@ -0,0 +1,56 @@ +{ + "meta_info": { + "case_id": "HMC_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_04.npy", + "instruction": "Please use the provided sleep-stage label file to identify the three longest uninterrupted sleep episodes across the whole night and report their lengths in descending order. Then briefly interpret what these episodes suggest about the overall sleep continuity of the night." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the lengths of the three longest uninterrupted sleep episodes in minutes.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"top1_sleep_episode_min\", \"top2_sleep_episode_min\", and \"top3_sleep_episode_min\".\n5. All three values must be FLOATS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"top1_sleep_episode_min\": , \"top2_sleep_episode_min\": , \"top3_sleep_episode_min\": }", + "metrics": [ + { + "metric_id": "top1_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top1_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 85.0, + "tolerance": 4.25 + } + }, + { + "metric_id": "top2_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top2_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 65.5, + "tolerance": 3.2750000000000004 + } + }, + { + "metric_id": "top3_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top3_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 53.5, + "tolerance": 2.6750000000000003 + } + }, + { + "metric_id": "sleep_continuity_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 40, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is HMC_04.edf. The three longest uninterrupted sleep episodes are 85.000000, 65.500000, and 53.500000 minutes. The benchmark rule is: if the longest episode is <20 minutes, sleep is severely fragmented; 20-40 minutes means poor continuity; 40-90 minutes means moderate continuity; >=90 minutes means at least one good continuous sleep episode. The correct response must explicitly conclude that sleep continuity is moderate or average. Because the second and third longest episodes are also at least 40 minutes, the response must also say that overall sleep continuity is relatively stable. Score the response in two parts. Give 0.5 points if the base continuity judgement is correct. Give 0.5 points if the secondary stability-or-fragmentation judgement is correct. The total score must therefore be exactly one of 0.0, 0.5, or 1.0. Output only a valid JSON object with exactly one key named score whose value is 0.0, 0.5, or 1.0. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case8/case8_10.json b/sleep_assessment/cases/case8/case8_10.json new file mode 100644 index 0000000000000000000000000000000000000000..0b6dca80b5c741e04b482fbaa49c216ee8f9812d --- /dev/null +++ b/sleep_assessment/cases/case8/case8_10.json @@ -0,0 +1,56 @@ +{ + "meta_info": { + "case_id": "HMC_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_05.npy", + "instruction": "Please use the provided sleep-stage label file to identify the three longest uninterrupted sleep episodes across the whole night and report their lengths in descending order. Then briefly interpret what these episodes suggest about the overall sleep continuity of the night." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the lengths of the three longest uninterrupted sleep episodes in minutes.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"top1_sleep_episode_min\", \"top2_sleep_episode_min\", and \"top3_sleep_episode_min\".\n5. All three values must be FLOATS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"top1_sleep_episode_min\": , \"top2_sleep_episode_min\": , \"top3_sleep_episode_min\": }", + "metrics": [ + { + "metric_id": "top1_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top1_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 52.5, + "tolerance": 2.625 + } + }, + { + "metric_id": "top2_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top2_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 46.0, + "tolerance": 2.3000000000000003 + } + }, + { + "metric_id": "top3_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top3_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 35.0, + "tolerance": 1.75 + } + }, + { + "metric_id": "sleep_continuity_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 40, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is HMC_05.edf. The three longest uninterrupted sleep episodes are 52.500000, 46.000000, and 35.000000 minutes. The benchmark rule is: if the longest episode is <20 minutes, sleep is severely fragmented; 20-40 minutes means poor continuity; 40-90 minutes means moderate continuity; >=90 minutes means at least one good continuous sleep episode. The correct response must explicitly conclude that sleep continuity is moderate or average. Because only the longest episode is clearly long while the other long episodes are shorter, the response must also note that the overall night still shows some fragmentation. Score the response in two parts. Give 0.5 points if the base continuity judgement is correct. Give 0.5 points if the secondary stability-or-fragmentation judgement is correct. The total score must therefore be exactly one of 0.0, 0.5, or 1.0. Output only a valid JSON object with exactly one key named score whose value is 0.0, 0.5, or 1.0. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case8/case8_11.json b/sleep_assessment/cases/case8/case8_11.json new file mode 100644 index 0000000000000000000000000000000000000000..5fce9053817c7498fe87c6201aa56cc8cddd8fd1 --- /dev/null +++ b/sleep_assessment/cases/case8/case8_11.json @@ -0,0 +1,56 @@ +{ + "meta_info": { + "case_id": "SHHS1_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_01.npy", + "instruction": "Please use the provided sleep-stage label file to identify the three longest uninterrupted sleep episodes across the whole night and report their lengths in descending order. Then briefly interpret what these episodes suggest about the overall sleep continuity of the night." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the lengths of the three longest uninterrupted sleep episodes in minutes.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"top1_sleep_episode_min\", \"top2_sleep_episode_min\", and \"top3_sleep_episode_min\".\n5. All three values must be FLOATS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"top1_sleep_episode_min\": , \"top2_sleep_episode_min\": , \"top3_sleep_episode_min\": }", + "metrics": [ + { + "metric_id": "top1_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top1_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 60.5, + "tolerance": 3.0250000000000004 + } + }, + { + "metric_id": "top2_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top2_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 43.5, + "tolerance": 2.1750000000000003 + } + }, + { + "metric_id": "top3_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top3_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 31.5, + "tolerance": 1.5750000000000002 + } + }, + { + "metric_id": "sleep_continuity_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 40, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is SHHS1_01.edf. The three longest uninterrupted sleep episodes are 60.500000, 43.500000, and 31.500000 minutes. The benchmark rule is: if the longest episode is <20 minutes, sleep is severely fragmented; 20-40 minutes means poor continuity; 40-90 minutes means moderate continuity; >=90 minutes means at least one good continuous sleep episode. The correct response must explicitly conclude that sleep continuity is moderate or average. Because only the longest episode is clearly long while the other long episodes are shorter, the response must also note that the overall night still shows some fragmentation. Score the response in two parts. Give 0.5 points if the base continuity judgement is correct. Give 0.5 points if the secondary stability-or-fragmentation judgement is correct. The total score must therefore be exactly one of 0.0, 0.5, or 1.0. Output only a valid JSON object with exactly one key named score whose value is 0.0, 0.5, or 1.0. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case8/case8_12.json b/sleep_assessment/cases/case8/case8_12.json new file mode 100644 index 0000000000000000000000000000000000000000..0cd9f6bfb38a67ba7934ce94d2e6d16a4466d08e --- /dev/null +++ b/sleep_assessment/cases/case8/case8_12.json @@ -0,0 +1,56 @@ +{ + "meta_info": { + "case_id": "SHHS1_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_02.npy", + "instruction": "Please use the provided sleep-stage label file to identify the three longest uninterrupted sleep episodes across the whole night and report their lengths in descending order. Then briefly interpret what these episodes suggest about the overall sleep continuity of the night." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the lengths of the three longest uninterrupted sleep episodes in minutes.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"top1_sleep_episode_min\", \"top2_sleep_episode_min\", and \"top3_sleep_episode_min\".\n5. All three values must be FLOATS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"top1_sleep_episode_min\": , \"top2_sleep_episode_min\": , \"top3_sleep_episode_min\": }", + "metrics": [ + { + "metric_id": "top1_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top1_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 66.5, + "tolerance": 3.325 + } + }, + { + "metric_id": "top2_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top2_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 37.5, + "tolerance": 1.875 + } + }, + { + "metric_id": "top3_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top3_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 28.5, + "tolerance": 1.425 + } + }, + { + "metric_id": "sleep_continuity_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 40, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is SHHS1_02.edf. The three longest uninterrupted sleep episodes are 66.500000, 37.500000, and 28.500000 minutes. The benchmark rule is: if the longest episode is <20 minutes, sleep is severely fragmented; 20-40 minutes means poor continuity; 40-90 minutes means moderate continuity; >=90 minutes means at least one good continuous sleep episode. The correct response must explicitly conclude that sleep continuity is moderate or average. Because only the longest episode is clearly long while the other long episodes are shorter, the response must also note that the overall night still shows some fragmentation. Score the response in two parts. Give 0.5 points if the base continuity judgement is correct. Give 0.5 points if the secondary stability-or-fragmentation judgement is correct. The total score must therefore be exactly one of 0.0, 0.5, or 1.0. Output only a valid JSON object with exactly one key named score whose value is 0.0, 0.5, or 1.0. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case8/case8_13.json b/sleep_assessment/cases/case8/case8_13.json new file mode 100644 index 0000000000000000000000000000000000000000..60a2166699b0f59e40fd6459580f526d2933804b --- /dev/null +++ b/sleep_assessment/cases/case8/case8_13.json @@ -0,0 +1,56 @@ +{ + "meta_info": { + "case_id": "SHHS1_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_03.npy", + "instruction": "Please use the provided sleep-stage label file to identify the three longest uninterrupted sleep episodes across the whole night and report their lengths in descending order. Then briefly interpret what these episodes suggest about the overall sleep continuity of the night." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the lengths of the three longest uninterrupted sleep episodes in minutes.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"top1_sleep_episode_min\", \"top2_sleep_episode_min\", and \"top3_sleep_episode_min\".\n5. All three values must be FLOATS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"top1_sleep_episode_min\": , \"top2_sleep_episode_min\": , \"top3_sleep_episode_min\": }", + "metrics": [ + { + "metric_id": "top1_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top1_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 52.5, + "tolerance": 2.625 + } + }, + { + "metric_id": "top2_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top2_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 51.5, + "tolerance": 2.575 + } + }, + { + "metric_id": "top3_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top3_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 38.5, + "tolerance": 1.925 + } + }, + { + "metric_id": "sleep_continuity_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 40, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is SHHS1_03.edf. The three longest uninterrupted sleep episodes are 52.500000, 51.500000, and 38.500000 minutes. The benchmark rule is: if the longest episode is <20 minutes, sleep is severely fragmented; 20-40 minutes means poor continuity; 40-90 minutes means moderate continuity; >=90 minutes means at least one good continuous sleep episode. The correct response must explicitly conclude that sleep continuity is moderate or average. Because only the longest episode is clearly long while the other long episodes are shorter, the response must also note that the overall night still shows some fragmentation. Score the response in two parts. Give 0.5 points if the base continuity judgement is correct. Give 0.5 points if the secondary stability-or-fragmentation judgement is correct. The total score must therefore be exactly one of 0.0, 0.5, or 1.0. Output only a valid JSON object with exactly one key named score whose value is 0.0, 0.5, or 1.0. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case8/case8_14.json b/sleep_assessment/cases/case8/case8_14.json new file mode 100644 index 0000000000000000000000000000000000000000..14d60fbd890bcfccb5272046a4f664d82e83e288 --- /dev/null +++ b/sleep_assessment/cases/case8/case8_14.json @@ -0,0 +1,56 @@ +{ + "meta_info": { + "case_id": "SHHS1_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_04.npy", + "instruction": "Please use the provided sleep-stage label file to identify the three longest uninterrupted sleep episodes across the whole night and report their lengths in descending order. Then briefly interpret what these episodes suggest about the overall sleep continuity of the night." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the lengths of the three longest uninterrupted sleep episodes in minutes.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"top1_sleep_episode_min\", \"top2_sleep_episode_min\", and \"top3_sleep_episode_min\".\n5. All three values must be FLOATS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"top1_sleep_episode_min\": , \"top2_sleep_episode_min\": , \"top3_sleep_episode_min\": }", + "metrics": [ + { + "metric_id": "top1_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top1_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 50.5, + "tolerance": 2.5250000000000004 + } + }, + { + "metric_id": "top2_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top2_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 50.0, + "tolerance": 2.5 + } + }, + { + "metric_id": "top3_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top3_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 42.0, + "tolerance": 2.1 + } + }, + { + "metric_id": "sleep_continuity_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 40, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is SHHS1_04.edf. The three longest uninterrupted sleep episodes are 50.500000, 50.000000, and 42.000000 minutes. The benchmark rule is: if the longest episode is <20 minutes, sleep is severely fragmented; 20-40 minutes means poor continuity; 40-90 minutes means moderate continuity; >=90 minutes means at least one good continuous sleep episode. The correct response must explicitly conclude that sleep continuity is moderate or average. Because the second and third longest episodes are also at least 40 minutes, the response must also say that overall sleep continuity is relatively stable. Score the response in two parts. Give 0.5 points if the base continuity judgement is correct. Give 0.5 points if the secondary stability-or-fragmentation judgement is correct. The total score must therefore be exactly one of 0.0, 0.5, or 1.0. Output only a valid JSON object with exactly one key named score whose value is 0.0, 0.5, or 1.0. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case8/case8_15.json b/sleep_assessment/cases/case8/case8_15.json new file mode 100644 index 0000000000000000000000000000000000000000..17cf9b3605a2e7f8e994177cbf732316412cd076 --- /dev/null +++ b/sleep_assessment/cases/case8/case8_15.json @@ -0,0 +1,56 @@ +{ + "meta_info": { + "case_id": "SHHS1_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_05.npy", + "instruction": "Please use the provided sleep-stage label file to identify the three longest uninterrupted sleep episodes across the whole night and report their lengths in descending order. Then briefly interpret what these episodes suggest about the overall sleep continuity of the night." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the lengths of the three longest uninterrupted sleep episodes in minutes.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"top1_sleep_episode_min\", \"top2_sleep_episode_min\", and \"top3_sleep_episode_min\".\n5. All three values must be FLOATS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"top1_sleep_episode_min\": , \"top2_sleep_episode_min\": , \"top3_sleep_episode_min\": }", + "metrics": [ + { + "metric_id": "top1_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top1_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 61.0, + "tolerance": 3.0500000000000003 + } + }, + { + "metric_id": "top2_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top2_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 39.0, + "tolerance": 1.9500000000000002 + } + }, + { + "metric_id": "top3_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top3_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 29.0, + "tolerance": 1.4500000000000002 + } + }, + { + "metric_id": "sleep_continuity_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 40, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is SHHS1_05.edf. The three longest uninterrupted sleep episodes are 61.000000, 39.000000, and 29.000000 minutes. The benchmark rule is: if the longest episode is <20 minutes, sleep is severely fragmented; 20-40 minutes means poor continuity; 40-90 minutes means moderate continuity; >=90 minutes means at least one good continuous sleep episode. The correct response must explicitly conclude that sleep continuity is moderate or average. Because only the longest episode is clearly long while the other long episodes are shorter, the response must also note that the overall night still shows some fragmentation. Score the response in two parts. Give 0.5 points if the base continuity judgement is correct. Give 0.5 points if the secondary stability-or-fragmentation judgement is correct. The total score must therefore be exactly one of 0.0, 0.5, or 1.0. Output only a valid JSON object with exactly one key named score whose value is 0.0, 0.5, or 1.0. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case8/case8_16.json b/sleep_assessment/cases/case8/case8_16.json new file mode 100644 index 0000000000000000000000000000000000000000..f2b07554ea00b2fea3e1f6a05d1c07f350c5296f --- /dev/null +++ b/sleep_assessment/cases/case8/case8_16.json @@ -0,0 +1,56 @@ +{ + "meta_info": { + "case_id": "MASSSS3_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_01.npy", + "instruction": "Please use the provided sleep-stage label file to identify the three longest uninterrupted sleep episodes across the whole night and report their lengths in descending order. Then briefly interpret what these episodes suggest about the overall sleep continuity of the night." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the lengths of the three longest uninterrupted sleep episodes in minutes.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"top1_sleep_episode_min\", \"top2_sleep_episode_min\", and \"top3_sleep_episode_min\".\n5. All three values must be FLOATS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"top1_sleep_episode_min\": , \"top2_sleep_episode_min\": , \"top3_sleep_episode_min\": }", + "metrics": [ + { + "metric_id": "top1_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top1_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 164.0, + "tolerance": 8.200000000000001 + } + }, + { + "metric_id": "top2_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top2_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 76.0, + "tolerance": 3.8000000000000003 + } + }, + { + "metric_id": "top3_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top3_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 56.5, + "tolerance": 2.825 + } + }, + { + "metric_id": "sleep_continuity_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 40, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is MASSSS3_01.edf. The three longest uninterrupted sleep episodes are 164.000000, 76.000000, and 56.500000 minutes. The benchmark rule is: if the longest episode is <20 minutes, sleep is severely fragmented; 20-40 minutes means poor continuity; 40-90 minutes means moderate continuity; >=90 minutes means at least one good continuous sleep episode. The correct response must explicitly conclude that there is at least one clearly good continuous sleep episode. Because the second and third longest episodes are also at least 40 minutes, the response must also say that overall sleep continuity is relatively stable. Score the response in two parts. Give 0.5 points if the base continuity judgement is correct. Give 0.5 points if the secondary stability-or-fragmentation judgement is correct. The total score must therefore be exactly one of 0.0, 0.5, or 1.0. Output only a valid JSON object with exactly one key named score whose value is 0.0, 0.5, or 1.0. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case8/case8_17.json b/sleep_assessment/cases/case8/case8_17.json new file mode 100644 index 0000000000000000000000000000000000000000..344364afdf3dd5e04323cdf7b1a3368652f0a561 --- /dev/null +++ b/sleep_assessment/cases/case8/case8_17.json @@ -0,0 +1,56 @@ +{ + "meta_info": { + "case_id": "MASSSS3_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_02.npy", + "instruction": "Please use the provided sleep-stage label file to identify the three longest uninterrupted sleep episodes across the whole night and report their lengths in descending order. Then briefly interpret what these episodes suggest about the overall sleep continuity of the night." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the lengths of the three longest uninterrupted sleep episodes in minutes.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"top1_sleep_episode_min\", \"top2_sleep_episode_min\", and \"top3_sleep_episode_min\".\n5. All three values must be FLOATS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"top1_sleep_episode_min\": , \"top2_sleep_episode_min\": , \"top3_sleep_episode_min\": }", + "metrics": [ + { + "metric_id": "top1_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top1_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 77.0, + "tolerance": 3.85 + } + }, + { + "metric_id": "top2_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top2_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 71.0, + "tolerance": 3.5500000000000003 + } + }, + { + "metric_id": "top3_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top3_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 45.0, + "tolerance": 2.25 + } + }, + { + "metric_id": "sleep_continuity_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 40, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is MASSSS3_02.edf. The three longest uninterrupted sleep episodes are 77.000000, 71.000000, and 45.000000 minutes. The benchmark rule is: if the longest episode is <20 minutes, sleep is severely fragmented; 20-40 minutes means poor continuity; 40-90 minutes means moderate continuity; >=90 minutes means at least one good continuous sleep episode. The correct response must explicitly conclude that sleep continuity is moderate or average. Because the second and third longest episodes are also at least 40 minutes, the response must also say that overall sleep continuity is relatively stable. Score the response in two parts. Give 0.5 points if the base continuity judgement is correct. Give 0.5 points if the secondary stability-or-fragmentation judgement is correct. The total score must therefore be exactly one of 0.0, 0.5, or 1.0. Output only a valid JSON object with exactly one key named score whose value is 0.0, 0.5, or 1.0. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case8/case8_18.json b/sleep_assessment/cases/case8/case8_18.json new file mode 100644 index 0000000000000000000000000000000000000000..31cf79d147b6f9d7c4b02bc09a307c4d4c77c449 --- /dev/null +++ b/sleep_assessment/cases/case8/case8_18.json @@ -0,0 +1,56 @@ +{ + "meta_info": { + "case_id": "MASSSS3_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_03.npy", + "instruction": "Please use the provided sleep-stage label file to identify the three longest uninterrupted sleep episodes across the whole night and report their lengths in descending order. Then briefly interpret what these episodes suggest about the overall sleep continuity of the night." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the lengths of the three longest uninterrupted sleep episodes in minutes.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"top1_sleep_episode_min\", \"top2_sleep_episode_min\", and \"top3_sleep_episode_min\".\n5. All three values must be FLOATS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"top1_sleep_episode_min\": , \"top2_sleep_episode_min\": , \"top3_sleep_episode_min\": }", + "metrics": [ + { + "metric_id": "top1_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top1_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 101.0, + "tolerance": 5.050000000000001 + } + }, + { + "metric_id": "top2_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top2_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 76.5, + "tolerance": 3.825 + } + }, + { + "metric_id": "top3_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top3_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 62.0, + "tolerance": 3.1 + } + }, + { + "metric_id": "sleep_continuity_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 40, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is MASSSS3_03.edf. The three longest uninterrupted sleep episodes are 101.000000, 76.500000, and 62.000000 minutes. The benchmark rule is: if the longest episode is <20 minutes, sleep is severely fragmented; 20-40 minutes means poor continuity; 40-90 minutes means moderate continuity; >=90 minutes means at least one good continuous sleep episode. The correct response must explicitly conclude that there is at least one clearly good continuous sleep episode. Because the second and third longest episodes are also at least 40 minutes, the response must also say that overall sleep continuity is relatively stable. Score the response in two parts. Give 0.5 points if the base continuity judgement is correct. Give 0.5 points if the secondary stability-or-fragmentation judgement is correct. The total score must therefore be exactly one of 0.0, 0.5, or 1.0. Output only a valid JSON object with exactly one key named score whose value is 0.0, 0.5, or 1.0. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case8/case8_19.json b/sleep_assessment/cases/case8/case8_19.json new file mode 100644 index 0000000000000000000000000000000000000000..6dcda708c2c1ffd163abcf96a0ce318ea0579b07 --- /dev/null +++ b/sleep_assessment/cases/case8/case8_19.json @@ -0,0 +1,56 @@ +{ + "meta_info": { + "case_id": "MASSSS3_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_04.npy", + "instruction": "Please use the provided sleep-stage label file to identify the three longest uninterrupted sleep episodes across the whole night and report their lengths in descending order. Then briefly interpret what these episodes suggest about the overall sleep continuity of the night." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the lengths of the three longest uninterrupted sleep episodes in minutes.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"top1_sleep_episode_min\", \"top2_sleep_episode_min\", and \"top3_sleep_episode_min\".\n5. All three values must be FLOATS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"top1_sleep_episode_min\": , \"top2_sleep_episode_min\": , \"top3_sleep_episode_min\": }", + "metrics": [ + { + "metric_id": "top1_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top1_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 174.0, + "tolerance": 8.700000000000001 + } + }, + { + "metric_id": "top2_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top2_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 161.5, + "tolerance": 8.075000000000001 + } + }, + { + "metric_id": "top3_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top3_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 48.5, + "tolerance": 2.4250000000000003 + } + }, + { + "metric_id": "sleep_continuity_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 40, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is MASSSS3_04.edf. The three longest uninterrupted sleep episodes are 174.000000, 161.500000, and 48.500000 minutes. The benchmark rule is: if the longest episode is <20 minutes, sleep is severely fragmented; 20-40 minutes means poor continuity; 40-90 minutes means moderate continuity; >=90 minutes means at least one good continuous sleep episode. The correct response must explicitly conclude that there is at least one clearly good continuous sleep episode. Because the second and third longest episodes are also at least 40 minutes, the response must also say that overall sleep continuity is relatively stable. Score the response in two parts. Give 0.5 points if the base continuity judgement is correct. Give 0.5 points if the secondary stability-or-fragmentation judgement is correct. The total score must therefore be exactly one of 0.0, 0.5, or 1.0. Output only a valid JSON object with exactly one key named score whose value is 0.0, 0.5, or 1.0. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case8/case8_20.json b/sleep_assessment/cases/case8/case8_20.json new file mode 100644 index 0000000000000000000000000000000000000000..7625cf3a48efb3797c17f2e1897e63812d19f1d9 --- /dev/null +++ b/sleep_assessment/cases/case8/case8_20.json @@ -0,0 +1,56 @@ +{ + "meta_info": { + "case_id": "MASSSS3_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_05.npy", + "instruction": "Please use the provided sleep-stage label file to identify the three longest uninterrupted sleep episodes across the whole night and report their lengths in descending order. Then briefly interpret what these episodes suggest about the overall sleep continuity of the night." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the lengths of the three longest uninterrupted sleep episodes in minutes.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"top1_sleep_episode_min\", \"top2_sleep_episode_min\", and \"top3_sleep_episode_min\".\n5. All three values must be FLOATS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"top1_sleep_episode_min\": , \"top2_sleep_episode_min\": , \"top3_sleep_episode_min\": }", + "metrics": [ + { + "metric_id": "top1_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top1_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 87.5, + "tolerance": 4.375 + } + }, + { + "metric_id": "top2_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top2_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 54.0, + "tolerance": 2.7 + } + }, + { + "metric_id": "top3_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top3_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 51.0, + "tolerance": 2.5500000000000003 + } + }, + { + "metric_id": "sleep_continuity_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 40, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is MASSSS3_05.edf. The three longest uninterrupted sleep episodes are 87.500000, 54.000000, and 51.000000 minutes. The benchmark rule is: if the longest episode is <20 minutes, sleep is severely fragmented; 20-40 minutes means poor continuity; 40-90 minutes means moderate continuity; >=90 minutes means at least one good continuous sleep episode. The correct response must explicitly conclude that sleep continuity is moderate or average. Because the second and third longest episodes are also at least 40 minutes, the response must also say that overall sleep continuity is relatively stable. Score the response in two parts. Give 0.5 points if the base continuity judgement is correct. Give 0.5 points if the secondary stability-or-fragmentation judgement is correct. The total score must therefore be exactly one of 0.0, 0.5, or 1.0. Output only a valid JSON object with exactly one key named score whose value is 0.0, 0.5, or 1.0. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case8/case8_21.json b/sleep_assessment/cases/case8/case8_21.json new file mode 100644 index 0000000000000000000000000000000000000000..b3af72a979b27f7908593fa052c158b86946c2c9 --- /dev/null +++ b/sleep_assessment/cases/case8/case8_21.json @@ -0,0 +1,56 @@ +{ + "meta_info": { + "case_id": "Physionet2018_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_01.npy", + "instruction": "Please use the provided sleep-stage label file to identify the three longest uninterrupted sleep episodes across the whole night and report their lengths in descending order. Then briefly interpret what these episodes suggest about the overall sleep continuity of the night." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the lengths of the three longest uninterrupted sleep episodes in minutes.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"top1_sleep_episode_min\", \"top2_sleep_episode_min\", and \"top3_sleep_episode_min\".\n5. All three values must be FLOATS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"top1_sleep_episode_min\": , \"top2_sleep_episode_min\": , \"top3_sleep_episode_min\": }", + "metrics": [ + { + "metric_id": "top1_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top1_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 41.5, + "tolerance": 2.075 + } + }, + { + "metric_id": "top2_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top2_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 40.0, + "tolerance": 2.0 + } + }, + { + "metric_id": "top3_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top3_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 31.0, + "tolerance": 1.55 + } + }, + { + "metric_id": "sleep_continuity_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 40, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is Physionet2018_01.edf. The three longest uninterrupted sleep episodes are 41.500000, 40.000000, and 31.000000 minutes. The benchmark rule is: if the longest episode is <20 minutes, sleep is severely fragmented; 20-40 minutes means poor continuity; 40-90 minutes means moderate continuity; >=90 minutes means at least one good continuous sleep episode. The correct response must explicitly conclude that sleep continuity is moderate or average. Because only the longest episode is clearly long while the other long episodes are shorter, the response must also note that the overall night still shows some fragmentation. Score the response in two parts. Give 0.5 points if the base continuity judgement is correct. Give 0.5 points if the secondary stability-or-fragmentation judgement is correct. The total score must therefore be exactly one of 0.0, 0.5, or 1.0. Output only a valid JSON object with exactly one key named score whose value is 0.0, 0.5, or 1.0. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case8/case8_22.json b/sleep_assessment/cases/case8/case8_22.json new file mode 100644 index 0000000000000000000000000000000000000000..6dd1d2e2f03bf29e4288de1e2b650b25ebde2b0e --- /dev/null +++ b/sleep_assessment/cases/case8/case8_22.json @@ -0,0 +1,56 @@ +{ + "meta_info": { + "case_id": "Physionet2018_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_02.npy", + "instruction": "Please use the provided sleep-stage label file to identify the three longest uninterrupted sleep episodes across the whole night and report their lengths in descending order. Then briefly interpret what these episodes suggest about the overall sleep continuity of the night." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the lengths of the three longest uninterrupted sleep episodes in minutes.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"top1_sleep_episode_min\", \"top2_sleep_episode_min\", and \"top3_sleep_episode_min\".\n5. All three values must be FLOATS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"top1_sleep_episode_min\": , \"top2_sleep_episode_min\": , \"top3_sleep_episode_min\": }", + "metrics": [ + { + "metric_id": "top1_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top1_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 82.5, + "tolerance": 4.125 + } + }, + { + "metric_id": "top2_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top2_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 26.0, + "tolerance": 1.3 + } + }, + { + "metric_id": "top3_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top3_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 21.5, + "tolerance": 1.075 + } + }, + { + "metric_id": "sleep_continuity_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 40, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is Physionet2018_02.edf. The three longest uninterrupted sleep episodes are 82.500000, 26.000000, and 21.500000 minutes. The benchmark rule is: if the longest episode is <20 minutes, sleep is severely fragmented; 20-40 minutes means poor continuity; 40-90 minutes means moderate continuity; >=90 minutes means at least one good continuous sleep episode. The correct response must explicitly conclude that sleep continuity is moderate or average. Because only the longest episode is clearly long while the other long episodes are shorter, the response must also note that the overall night still shows some fragmentation. Score the response in two parts. Give 0.5 points if the base continuity judgement is correct. Give 0.5 points if the secondary stability-or-fragmentation judgement is correct. The total score must therefore be exactly one of 0.0, 0.5, or 1.0. Output only a valid JSON object with exactly one key named score whose value is 0.0, 0.5, or 1.0. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case8/case8_23.json b/sleep_assessment/cases/case8/case8_23.json new file mode 100644 index 0000000000000000000000000000000000000000..f49035c8ff14c92f24d005213749c72ab6cc4708 --- /dev/null +++ b/sleep_assessment/cases/case8/case8_23.json @@ -0,0 +1,56 @@ +{ + "meta_info": { + "case_id": "Physionet2018_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_03.npy", + "instruction": "Please use the provided sleep-stage label file to identify the three longest uninterrupted sleep episodes across the whole night and report their lengths in descending order. Then briefly interpret what these episodes suggest about the overall sleep continuity of the night." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the lengths of the three longest uninterrupted sleep episodes in minutes.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"top1_sleep_episode_min\", \"top2_sleep_episode_min\", and \"top3_sleep_episode_min\".\n5. All three values must be FLOATS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"top1_sleep_episode_min\": , \"top2_sleep_episode_min\": , \"top3_sleep_episode_min\": }", + "metrics": [ + { + "metric_id": "top1_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top1_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 43.0, + "tolerance": 2.15 + } + }, + { + "metric_id": "top2_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top2_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 38.0, + "tolerance": 1.9000000000000001 + } + }, + { + "metric_id": "top3_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top3_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 36.5, + "tolerance": 1.8250000000000002 + } + }, + { + "metric_id": "sleep_continuity_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 40, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is Physionet2018_03.edf. The three longest uninterrupted sleep episodes are 43.000000, 38.000000, and 36.500000 minutes. The benchmark rule is: if the longest episode is <20 minutes, sleep is severely fragmented; 20-40 minutes means poor continuity; 40-90 minutes means moderate continuity; >=90 minutes means at least one good continuous sleep episode. The correct response must explicitly conclude that sleep continuity is moderate or average. Because only the longest episode is clearly long while the other long episodes are shorter, the response must also note that the overall night still shows some fragmentation. Score the response in two parts. Give 0.5 points if the base continuity judgement is correct. Give 0.5 points if the secondary stability-or-fragmentation judgement is correct. The total score must therefore be exactly one of 0.0, 0.5, or 1.0. Output only a valid JSON object with exactly one key named score whose value is 0.0, 0.5, or 1.0. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case8/case8_24.json b/sleep_assessment/cases/case8/case8_24.json new file mode 100644 index 0000000000000000000000000000000000000000..33560cb84b25cab8cc5ef9762c7042f96f497392 --- /dev/null +++ b/sleep_assessment/cases/case8/case8_24.json @@ -0,0 +1,56 @@ +{ + "meta_info": { + "case_id": "Physionet2018_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_04.npy", + "instruction": "Please use the provided sleep-stage label file to identify the three longest uninterrupted sleep episodes across the whole night and report their lengths in descending order. Then briefly interpret what these episodes suggest about the overall sleep continuity of the night." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the lengths of the three longest uninterrupted sleep episodes in minutes.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"top1_sleep_episode_min\", \"top2_sleep_episode_min\", and \"top3_sleep_episode_min\".\n5. All three values must be FLOATS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"top1_sleep_episode_min\": , \"top2_sleep_episode_min\": , \"top3_sleep_episode_min\": }", + "metrics": [ + { + "metric_id": "top1_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top1_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 141.0, + "tolerance": 7.050000000000001 + } + }, + { + "metric_id": "top2_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top2_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 55.0, + "tolerance": 2.75 + } + }, + { + "metric_id": "top3_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top3_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 36.0, + "tolerance": 1.8 + } + }, + { + "metric_id": "sleep_continuity_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 40, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is Physionet2018_04.edf. The three longest uninterrupted sleep episodes are 141.000000, 55.000000, and 36.000000 minutes. The benchmark rule is: if the longest episode is <20 minutes, sleep is severely fragmented; 20-40 minutes means poor continuity; 40-90 minutes means moderate continuity; >=90 minutes means at least one good continuous sleep episode. The correct response must explicitly conclude that there is at least one clearly good continuous sleep episode. Because only the longest episode is clearly long while the other long episodes are shorter, the response must also note that the overall night still shows some fragmentation. Score the response in two parts. Give 0.5 points if the base continuity judgement is correct. Give 0.5 points if the secondary stability-or-fragmentation judgement is correct. The total score must therefore be exactly one of 0.0, 0.5, or 1.0. Output only a valid JSON object with exactly one key named score whose value is 0.0, 0.5, or 1.0. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case8/case8_25.json b/sleep_assessment/cases/case8/case8_25.json new file mode 100644 index 0000000000000000000000000000000000000000..925003870decbada784da3c858347767b134ece0 --- /dev/null +++ b/sleep_assessment/cases/case8/case8_25.json @@ -0,0 +1,56 @@ +{ + "meta_info": { + "case_id": "Physionet2018_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1.5, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_05.npy", + "instruction": "Please use the provided sleep-stage label file to identify the three longest uninterrupted sleep episodes across the whole night and report their lengths in descending order. Then briefly interpret what these episodes suggest about the overall sleep continuity of the night." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract the lengths of the three longest uninterrupted sleep episodes in minutes.\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"top1_sleep_episode_min\", \"top2_sleep_episode_min\", and \"top3_sleep_episode_min\".\n5. All three values must be FLOATS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"top1_sleep_episode_min\": , \"top2_sleep_episode_min\": , \"top3_sleep_episode_min\": }", + "metrics": [ + { + "metric_id": "top1_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top1_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 207.0, + "tolerance": 10.350000000000001 + } + }, + { + "metric_id": "top2_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top2_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 170.5, + "tolerance": 8.525 + } + }, + { + "metric_id": "top3_sleep_episode_accuracy", + "type": "numeric_check", + "target_key": "top3_sleep_episode_min", + "weight": 20, + "params": { + "gt_value": 33.0, + "tolerance": 1.6500000000000001 + } + }, + { + "metric_id": "sleep_continuity_semantic_consistency", + "type": "semantic_consistency", + "target_key": "full_text", + "weight": 40, + "params": { + "judge_prompt": "You are judging semantic consistency for a sleep-medicine benchmark. The sample is Physionet2018_05.edf. The three longest uninterrupted sleep episodes are 207.000000, 170.500000, and 33.000000 minutes. The benchmark rule is: if the longest episode is <20 minutes, sleep is severely fragmented; 20-40 minutes means poor continuity; 40-90 minutes means moderate continuity; >=90 minutes means at least one good continuous sleep episode. The correct response must explicitly conclude that there is at least one clearly good continuous sleep episode. Because only the longest episode is clearly long while the other long episodes are shorter, the response must also note that the overall night still shows some fragmentation. Score the response in two parts. Give 0.5 points if the base continuity judgement is correct. Give 0.5 points if the secondary stability-or-fragmentation judgement is correct. The total score must therefore be exactly one of 0.0, 0.5, or 1.0. Output only a valid JSON object with exactly one key named score whose value is 0.0, 0.5, or 1.0. Do not output Markdown, explanations, or additional fields." + } + } + ] + } +} diff --git a/sleep_assessment/cases/case9/case9_01.json b/sleep_assessment/cases/case9/case9_01.json new file mode 100644 index 0000000000000000000000000000000000000000..d1c7ca57b62be350fdc4f46a95370ce290070fd8 --- /dev/null +++ b/sleep_assessment/cases/case9/case9_01.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "ISRUC_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_01.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two transition-based metrics for the whole night: the total number of sleep-stage transitions, and the number of interruptions from deep sleep into wakefulness. Please clearly report both final counts." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two transition counts from the agent's report:\n1) the total number of sleep-stage transitions across the whole night\n2) the number of deep-sleep interruptions into wakefulness\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"total_stage_transitions\" and \"n3_to_w_interruptions\".\n5. Both values must be INTEGERS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"total_stage_transitions\": , \"n3_to_w_interruptions\": }", + "metrics": [ + { + "metric_id": "total_stage_transition_accuracy", + "type": "numeric_check", + "target_key": "total_stage_transitions", + "weight": 50, + "params": { + "gt_value": 133, + "tolerance": 3 + } + }, + { + "metric_id": "n3_to_w_interruptions_accuracy", + "type": "numeric_check", + "target_key": "n3_to_w_interruptions", + "weight": 50, + "params": { + "gt_value": 3, + "tolerance": 0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case9/case9_02.json b/sleep_assessment/cases/case9/case9_02.json new file mode 100644 index 0000000000000000000000000000000000000000..9473ad1bc02ebbca55a8665e60f2234b47a2143a --- /dev/null +++ b/sleep_assessment/cases/case9/case9_02.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "ISRUC_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_02.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two transition-based metrics for the whole night: the total number of sleep-stage transitions, and the number of interruptions from deep sleep into wakefulness. Please clearly report both final counts." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two transition counts from the agent's report:\n1) the total number of sleep-stage transitions across the whole night\n2) the number of deep-sleep interruptions into wakefulness\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"total_stage_transitions\" and \"n3_to_w_interruptions\".\n5. Both values must be INTEGERS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"total_stage_transitions\": , \"n3_to_w_interruptions\": }", + "metrics": [ + { + "metric_id": "total_stage_transition_accuracy", + "type": "numeric_check", + "target_key": "total_stage_transitions", + "weight": 50, + "params": { + "gt_value": 180, + "tolerance": 5 + } + }, + { + "metric_id": "n3_to_w_interruptions_accuracy", + "type": "numeric_check", + "target_key": "n3_to_w_interruptions", + "weight": 50, + "params": { + "gt_value": 3, + "tolerance": 0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case9/case9_03.json b/sleep_assessment/cases/case9/case9_03.json new file mode 100644 index 0000000000000000000000000000000000000000..94e7d6e59d97aacfcab00c92ad75c2bb13ddbbc5 --- /dev/null +++ b/sleep_assessment/cases/case9/case9_03.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "ISRUC_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_03.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two transition-based metrics for the whole night: the total number of sleep-stage transitions, and the number of interruptions from deep sleep into wakefulness. Please clearly report both final counts." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two transition counts from the agent's report:\n1) the total number of sleep-stage transitions across the whole night\n2) the number of deep-sleep interruptions into wakefulness\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"total_stage_transitions\" and \"n3_to_w_interruptions\".\n5. Both values must be INTEGERS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"total_stage_transitions\": , \"n3_to_w_interruptions\": }", + "metrics": [ + { + "metric_id": "total_stage_transition_accuracy", + "type": "numeric_check", + "target_key": "total_stage_transitions", + "weight": 50, + "params": { + "gt_value": 184, + "tolerance": 5 + } + }, + { + "metric_id": "n3_to_w_interruptions_accuracy", + "type": "numeric_check", + "target_key": "n3_to_w_interruptions", + "weight": 50, + "params": { + "gt_value": 1, + "tolerance": 0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case9/case9_04.json b/sleep_assessment/cases/case9/case9_04.json new file mode 100644 index 0000000000000000000000000000000000000000..a7fff26ee19328db50a1d46d155badb01d83e3b7 --- /dev/null +++ b/sleep_assessment/cases/case9/case9_04.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "ISRUC_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_04.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two transition-based metrics for the whole night: the total number of sleep-stage transitions, and the number of interruptions from deep sleep into wakefulness. Please clearly report both final counts." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two transition counts from the agent's report:\n1) the total number of sleep-stage transitions across the whole night\n2) the number of deep-sleep interruptions into wakefulness\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"total_stage_transitions\" and \"n3_to_w_interruptions\".\n5. Both values must be INTEGERS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"total_stage_transitions\": , \"n3_to_w_interruptions\": }", + "metrics": [ + { + "metric_id": "total_stage_transition_accuracy", + "type": "numeric_check", + "target_key": "total_stage_transitions", + "weight": 50, + "params": { + "gt_value": 123, + "tolerance": 3 + } + }, + { + "metric_id": "n3_to_w_interruptions_accuracy", + "type": "numeric_check", + "target_key": "n3_to_w_interruptions", + "weight": 50, + "params": { + "gt_value": 4, + "tolerance": 0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case9/case9_05.json b/sleep_assessment/cases/case9/case9_05.json new file mode 100644 index 0000000000000000000000000000000000000000..02553e77521ecf4186883aa33d31294aa72a9600 --- /dev/null +++ b/sleep_assessment/cases/case9/case9_05.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "ISRUC_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "ISRUC" + }, + "agent_input": { + "label_path": "data/sleep/ISRUC_05.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two transition-based metrics for the whole night: the total number of sleep-stage transitions, and the number of interruptions from deep sleep into wakefulness. Please clearly report both final counts." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two transition counts from the agent's report:\n1) the total number of sleep-stage transitions across the whole night\n2) the number of deep-sleep interruptions into wakefulness\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"total_stage_transitions\" and \"n3_to_w_interruptions\".\n5. Both values must be INTEGERS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"total_stage_transitions\": , \"n3_to_w_interruptions\": }", + "metrics": [ + { + "metric_id": "total_stage_transition_accuracy", + "type": "numeric_check", + "target_key": "total_stage_transitions", + "weight": 50, + "params": { + "gt_value": 123, + "tolerance": 3 + } + }, + { + "metric_id": "n3_to_w_interruptions_accuracy", + "type": "numeric_check", + "target_key": "n3_to_w_interruptions", + "weight": 50, + "params": { + "gt_value": 0, + "tolerance": 0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case9/case9_06.json b/sleep_assessment/cases/case9/case9_06.json new file mode 100644 index 0000000000000000000000000000000000000000..f8202b9b5f2abe81fe192447cb543b460cc6bc33 --- /dev/null +++ b/sleep_assessment/cases/case9/case9_06.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "HMC_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_01.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two transition-based metrics for the whole night: the total number of sleep-stage transitions, and the number of interruptions from deep sleep into wakefulness. Please clearly report both final counts." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two transition counts from the agent's report:\n1) the total number of sleep-stage transitions across the whole night\n2) the number of deep-sleep interruptions into wakefulness\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"total_stage_transitions\" and \"n3_to_w_interruptions\".\n5. Both values must be INTEGERS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"total_stage_transitions\": , \"n3_to_w_interruptions\": }", + "metrics": [ + { + "metric_id": "total_stage_transition_accuracy", + "type": "numeric_check", + "target_key": "total_stage_transitions", + "weight": 50, + "params": { + "gt_value": 98, + "tolerance": 2 + } + }, + { + "metric_id": "n3_to_w_interruptions_accuracy", + "type": "numeric_check", + "target_key": "n3_to_w_interruptions", + "weight": 50, + "params": { + "gt_value": 0, + "tolerance": 0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case9/case9_07.json b/sleep_assessment/cases/case9/case9_07.json new file mode 100644 index 0000000000000000000000000000000000000000..170dedfe84d8b26efd5a811a99c336a1a0b2497a --- /dev/null +++ b/sleep_assessment/cases/case9/case9_07.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "HMC_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_02.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two transition-based metrics for the whole night: the total number of sleep-stage transitions, and the number of interruptions from deep sleep into wakefulness. Please clearly report both final counts." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two transition counts from the agent's report:\n1) the total number of sleep-stage transitions across the whole night\n2) the number of deep-sleep interruptions into wakefulness\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"total_stage_transitions\" and \"n3_to_w_interruptions\".\n5. Both values must be INTEGERS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"total_stage_transitions\": , \"n3_to_w_interruptions\": }", + "metrics": [ + { + "metric_id": "total_stage_transition_accuracy", + "type": "numeric_check", + "target_key": "total_stage_transitions", + "weight": 50, + "params": { + "gt_value": 111, + "tolerance": 3 + } + }, + { + "metric_id": "n3_to_w_interruptions_accuracy", + "type": "numeric_check", + "target_key": "n3_to_w_interruptions", + "weight": 50, + "params": { + "gt_value": 0, + "tolerance": 0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case9/case9_08.json b/sleep_assessment/cases/case9/case9_08.json new file mode 100644 index 0000000000000000000000000000000000000000..5fcfad8cf8aaa9a8980f7b18dfd273b664248d00 --- /dev/null +++ b/sleep_assessment/cases/case9/case9_08.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "HMC_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_03.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two transition-based metrics for the whole night: the total number of sleep-stage transitions, and the number of interruptions from deep sleep into wakefulness. Please clearly report both final counts." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two transition counts from the agent's report:\n1) the total number of sleep-stage transitions across the whole night\n2) the number of deep-sleep interruptions into wakefulness\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"total_stage_transitions\" and \"n3_to_w_interruptions\".\n5. Both values must be INTEGERS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"total_stage_transitions\": , \"n3_to_w_interruptions\": }", + "metrics": [ + { + "metric_id": "total_stage_transition_accuracy", + "type": "numeric_check", + "target_key": "total_stage_transitions", + "weight": 50, + "params": { + "gt_value": 151, + "tolerance": 4 + } + }, + { + "metric_id": "n3_to_w_interruptions_accuracy", + "type": "numeric_check", + "target_key": "n3_to_w_interruptions", + "weight": 50, + "params": { + "gt_value": 4, + "tolerance": 0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case9/case9_09.json b/sleep_assessment/cases/case9/case9_09.json new file mode 100644 index 0000000000000000000000000000000000000000..9f8850b1d16f769a0bfaa862143a8cd3b3201870 --- /dev/null +++ b/sleep_assessment/cases/case9/case9_09.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "HMC_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_04.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two transition-based metrics for the whole night: the total number of sleep-stage transitions, and the number of interruptions from deep sleep into wakefulness. Please clearly report both final counts." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two transition counts from the agent's report:\n1) the total number of sleep-stage transitions across the whole night\n2) the number of deep-sleep interruptions into wakefulness\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"total_stage_transitions\" and \"n3_to_w_interruptions\".\n5. Both values must be INTEGERS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"total_stage_transitions\": , \"n3_to_w_interruptions\": }", + "metrics": [ + { + "metric_id": "total_stage_transition_accuracy", + "type": "numeric_check", + "target_key": "total_stage_transitions", + "weight": 50, + "params": { + "gt_value": 135, + "tolerance": 4 + } + }, + { + "metric_id": "n3_to_w_interruptions_accuracy", + "type": "numeric_check", + "target_key": "n3_to_w_interruptions", + "weight": 50, + "params": { + "gt_value": 0, + "tolerance": 0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case9/case9_10.json b/sleep_assessment/cases/case9/case9_10.json new file mode 100644 index 0000000000000000000000000000000000000000..a521e0b3530d945f38c808aa6a7c128503294378 --- /dev/null +++ b/sleep_assessment/cases/case9/case9_10.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "HMC_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "HMC" + }, + "agent_input": { + "label_path": "data/sleep/HMC_05.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two transition-based metrics for the whole night: the total number of sleep-stage transitions, and the number of interruptions from deep sleep into wakefulness. Please clearly report both final counts." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two transition counts from the agent's report:\n1) the total number of sleep-stage transitions across the whole night\n2) the number of deep-sleep interruptions into wakefulness\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"total_stage_transitions\" and \"n3_to_w_interruptions\".\n5. Both values must be INTEGERS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"total_stage_transitions\": , \"n3_to_w_interruptions\": }", + "metrics": [ + { + "metric_id": "total_stage_transition_accuracy", + "type": "numeric_check", + "target_key": "total_stage_transitions", + "weight": 50, + "params": { + "gt_value": 249, + "tolerance": 7 + } + }, + { + "metric_id": "n3_to_w_interruptions_accuracy", + "type": "numeric_check", + "target_key": "n3_to_w_interruptions", + "weight": 50, + "params": { + "gt_value": 2, + "tolerance": 0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case9/case9_11.json b/sleep_assessment/cases/case9/case9_11.json new file mode 100644 index 0000000000000000000000000000000000000000..cd891995c7a0e1a463455411ebdc503346c41fed --- /dev/null +++ b/sleep_assessment/cases/case9/case9_11.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "SHHS1_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_01.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two transition-based metrics for the whole night: the total number of sleep-stage transitions, and the number of interruptions from deep sleep into wakefulness. Please clearly report both final counts." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two transition counts from the agent's report:\n1) the total number of sleep-stage transitions across the whole night\n2) the number of deep-sleep interruptions into wakefulness\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"total_stage_transitions\" and \"n3_to_w_interruptions\".\n5. Both values must be INTEGERS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"total_stage_transitions\": , \"n3_to_w_interruptions\": }", + "metrics": [ + { + "metric_id": "total_stage_transition_accuracy", + "type": "numeric_check", + "target_key": "total_stage_transitions", + "weight": 50, + "params": { + "gt_value": 180, + "tolerance": 5 + } + }, + { + "metric_id": "n3_to_w_interruptions_accuracy", + "type": "numeric_check", + "target_key": "n3_to_w_interruptions", + "weight": 50, + "params": { + "gt_value": 4, + "tolerance": 0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case9/case9_12.json b/sleep_assessment/cases/case9/case9_12.json new file mode 100644 index 0000000000000000000000000000000000000000..fcd04d85c0e1011a446f625ce53a796a5c74865c --- /dev/null +++ b/sleep_assessment/cases/case9/case9_12.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "SHHS1_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_02.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two transition-based metrics for the whole night: the total number of sleep-stage transitions, and the number of interruptions from deep sleep into wakefulness. Please clearly report both final counts." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two transition counts from the agent's report:\n1) the total number of sleep-stage transitions across the whole night\n2) the number of deep-sleep interruptions into wakefulness\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"total_stage_transitions\" and \"n3_to_w_interruptions\".\n5. Both values must be INTEGERS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"total_stage_transitions\": , \"n3_to_w_interruptions\": }", + "metrics": [ + { + "metric_id": "total_stage_transition_accuracy", + "type": "numeric_check", + "target_key": "total_stage_transitions", + "weight": 50, + "params": { + "gt_value": 95, + "tolerance": 2 + } + }, + { + "metric_id": "n3_to_w_interruptions_accuracy", + "type": "numeric_check", + "target_key": "n3_to_w_interruptions", + "weight": 50, + "params": { + "gt_value": 0, + "tolerance": 0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case9/case9_13.json b/sleep_assessment/cases/case9/case9_13.json new file mode 100644 index 0000000000000000000000000000000000000000..3b6acd059f4a2cd7f2d21d6db419d0aad535eabc --- /dev/null +++ b/sleep_assessment/cases/case9/case9_13.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "SHHS1_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_03.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two transition-based metrics for the whole night: the total number of sleep-stage transitions, and the number of interruptions from deep sleep into wakefulness. Please clearly report both final counts." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two transition counts from the agent's report:\n1) the total number of sleep-stage transitions across the whole night\n2) the number of deep-sleep interruptions into wakefulness\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"total_stage_transitions\" and \"n3_to_w_interruptions\".\n5. Both values must be INTEGERS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"total_stage_transitions\": , \"n3_to_w_interruptions\": }", + "metrics": [ + { + "metric_id": "total_stage_transition_accuracy", + "type": "numeric_check", + "target_key": "total_stage_transitions", + "weight": 50, + "params": { + "gt_value": 143, + "tolerance": 4 + } + }, + { + "metric_id": "n3_to_w_interruptions_accuracy", + "type": "numeric_check", + "target_key": "n3_to_w_interruptions", + "weight": 50, + "params": { + "gt_value": 6, + "tolerance": 0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case9/case9_14.json b/sleep_assessment/cases/case9/case9_14.json new file mode 100644 index 0000000000000000000000000000000000000000..d656123a15d5d4153f40efd4dbacd418362a5d2d --- /dev/null +++ b/sleep_assessment/cases/case9/case9_14.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "SHHS1_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_04.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two transition-based metrics for the whole night: the total number of sleep-stage transitions, and the number of interruptions from deep sleep into wakefulness. Please clearly report both final counts." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two transition counts from the agent's report:\n1) the total number of sleep-stage transitions across the whole night\n2) the number of deep-sleep interruptions into wakefulness\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"total_stage_transitions\" and \"n3_to_w_interruptions\".\n5. Both values must be INTEGERS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"total_stage_transitions\": , \"n3_to_w_interruptions\": }", + "metrics": [ + { + "metric_id": "total_stage_transition_accuracy", + "type": "numeric_check", + "target_key": "total_stage_transitions", + "weight": 50, + "params": { + "gt_value": 138, + "tolerance": 4 + } + }, + { + "metric_id": "n3_to_w_interruptions_accuracy", + "type": "numeric_check", + "target_key": "n3_to_w_interruptions", + "weight": 50, + "params": { + "gt_value": 4, + "tolerance": 0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case9/case9_15.json b/sleep_assessment/cases/case9/case9_15.json new file mode 100644 index 0000000000000000000000000000000000000000..07a7c23619c7cb14e5a3bd2289f5c19754786055 --- /dev/null +++ b/sleep_assessment/cases/case9/case9_15.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "SHHS1_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "SHHS1" + }, + "agent_input": { + "label_path": "data/sleep/SHHS1_05.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two transition-based metrics for the whole night: the total number of sleep-stage transitions, and the number of interruptions from deep sleep into wakefulness. Please clearly report both final counts." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two transition counts from the agent's report:\n1) the total number of sleep-stage transitions across the whole night\n2) the number of deep-sleep interruptions into wakefulness\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"total_stage_transitions\" and \"n3_to_w_interruptions\".\n5. Both values must be INTEGERS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"total_stage_transitions\": , \"n3_to_w_interruptions\": }", + "metrics": [ + { + "metric_id": "total_stage_transition_accuracy", + "type": "numeric_check", + "target_key": "total_stage_transitions", + "weight": 50, + "params": { + "gt_value": 133, + "tolerance": 3 + } + }, + { + "metric_id": "n3_to_w_interruptions_accuracy", + "type": "numeric_check", + "target_key": "n3_to_w_interruptions", + "weight": 50, + "params": { + "gt_value": 2, + "tolerance": 0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case9/case9_16.json b/sleep_assessment/cases/case9/case9_16.json new file mode 100644 index 0000000000000000000000000000000000000000..078da77d1dc8837186f9ba616f9cff24574b83bd --- /dev/null +++ b/sleep_assessment/cases/case9/case9_16.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "MASSSS3_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_01.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two transition-based metrics for the whole night: the total number of sleep-stage transitions, and the number of interruptions from deep sleep into wakefulness. Please clearly report both final counts." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two transition counts from the agent's report:\n1) the total number of sleep-stage transitions across the whole night\n2) the number of deep-sleep interruptions into wakefulness\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"total_stage_transitions\" and \"n3_to_w_interruptions\".\n5. Both values must be INTEGERS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"total_stage_transitions\": , \"n3_to_w_interruptions\": }", + "metrics": [ + { + "metric_id": "total_stage_transition_accuracy", + "type": "numeric_check", + "target_key": "total_stage_transitions", + "weight": 50, + "params": { + "gt_value": 179, + "tolerance": 5 + } + }, + { + "metric_id": "n3_to_w_interruptions_accuracy", + "type": "numeric_check", + "target_key": "n3_to_w_interruptions", + "weight": 50, + "params": { + "gt_value": 0, + "tolerance": 0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case9/case9_17.json b/sleep_assessment/cases/case9/case9_17.json new file mode 100644 index 0000000000000000000000000000000000000000..d16cb749fa1df7b60f3dc7c7c1885fdf2833d093 --- /dev/null +++ b/sleep_assessment/cases/case9/case9_17.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "MASSSS3_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_02.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two transition-based metrics for the whole night: the total number of sleep-stage transitions, and the number of interruptions from deep sleep into wakefulness. Please clearly report both final counts." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two transition counts from the agent's report:\n1) the total number of sleep-stage transitions across the whole night\n2) the number of deep-sleep interruptions into wakefulness\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"total_stage_transitions\" and \"n3_to_w_interruptions\".\n5. Both values must be INTEGERS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"total_stage_transitions\": , \"n3_to_w_interruptions\": }", + "metrics": [ + { + "metric_id": "total_stage_transition_accuracy", + "type": "numeric_check", + "target_key": "total_stage_transitions", + "weight": 50, + "params": { + "gt_value": 195, + "tolerance": 5 + } + }, + { + "metric_id": "n3_to_w_interruptions_accuracy", + "type": "numeric_check", + "target_key": "n3_to_w_interruptions", + "weight": 50, + "params": { + "gt_value": 3, + "tolerance": 0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case9/case9_18.json b/sleep_assessment/cases/case9/case9_18.json new file mode 100644 index 0000000000000000000000000000000000000000..fe55487c768e864d5e2cf141db904c80fbaddeaf --- /dev/null +++ b/sleep_assessment/cases/case9/case9_18.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "MASSSS3_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_03.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two transition-based metrics for the whole night: the total number of sleep-stage transitions, and the number of interruptions from deep sleep into wakefulness. Please clearly report both final counts." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two transition counts from the agent's report:\n1) the total number of sleep-stage transitions across the whole night\n2) the number of deep-sleep interruptions into wakefulness\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"total_stage_transitions\" and \"n3_to_w_interruptions\".\n5. Both values must be INTEGERS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"total_stage_transitions\": , \"n3_to_w_interruptions\": }", + "metrics": [ + { + "metric_id": "total_stage_transition_accuracy", + "type": "numeric_check", + "target_key": "total_stage_transitions", + "weight": 50, + "params": { + "gt_value": 144, + "tolerance": 4 + } + }, + { + "metric_id": "n3_to_w_interruptions_accuracy", + "type": "numeric_check", + "target_key": "n3_to_w_interruptions", + "weight": 50, + "params": { + "gt_value": 1, + "tolerance": 0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case9/case9_19.json b/sleep_assessment/cases/case9/case9_19.json new file mode 100644 index 0000000000000000000000000000000000000000..6158b94b18ef94a899a44b366cbd4f5daaad889d --- /dev/null +++ b/sleep_assessment/cases/case9/case9_19.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "MASSSS3_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_04.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two transition-based metrics for the whole night: the total number of sleep-stage transitions, and the number of interruptions from deep sleep into wakefulness. Please clearly report both final counts." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two transition counts from the agent's report:\n1) the total number of sleep-stage transitions across the whole night\n2) the number of deep-sleep interruptions into wakefulness\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"total_stage_transitions\" and \"n3_to_w_interruptions\".\n5. Both values must be INTEGERS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"total_stage_transitions\": , \"n3_to_w_interruptions\": }", + "metrics": [ + { + "metric_id": "total_stage_transition_accuracy", + "type": "numeric_check", + "target_key": "total_stage_transitions", + "weight": 50, + "params": { + "gt_value": 100, + "tolerance": 3 + } + }, + { + "metric_id": "n3_to_w_interruptions_accuracy", + "type": "numeric_check", + "target_key": "n3_to_w_interruptions", + "weight": 50, + "params": { + "gt_value": 0, + "tolerance": 0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case9/case9_20.json b/sleep_assessment/cases/case9/case9_20.json new file mode 100644 index 0000000000000000000000000000000000000000..fb7f9abb83cffbf315c2847675aa336b9b40b95b --- /dev/null +++ b/sleep_assessment/cases/case9/case9_20.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "MASSSS3_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "MASSSS3" + }, + "agent_input": { + "label_path": "data/sleep/MASSSS3_05.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two transition-based metrics for the whole night: the total number of sleep-stage transitions, and the number of interruptions from deep sleep into wakefulness. Please clearly report both final counts." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two transition counts from the agent's report:\n1) the total number of sleep-stage transitions across the whole night\n2) the number of deep-sleep interruptions into wakefulness\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"total_stage_transitions\" and \"n3_to_w_interruptions\".\n5. Both values must be INTEGERS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"total_stage_transitions\": , \"n3_to_w_interruptions\": }", + "metrics": [ + { + "metric_id": "total_stage_transition_accuracy", + "type": "numeric_check", + "target_key": "total_stage_transitions", + "weight": 50, + "params": { + "gt_value": 117, + "tolerance": 3 + } + }, + { + "metric_id": "n3_to_w_interruptions_accuracy", + "type": "numeric_check", + "target_key": "n3_to_w_interruptions", + "weight": 50, + "params": { + "gt_value": 2, + "tolerance": 0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case9/case9_21.json b/sleep_assessment/cases/case9/case9_21.json new file mode 100644 index 0000000000000000000000000000000000000000..e61165d392fdce717f1b91d4e48cf19a66ba0e59 --- /dev/null +++ b/sleep_assessment/cases/case9/case9_21.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "Physionet2018_01.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_01.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two transition-based metrics for the whole night: the total number of sleep-stage transitions, and the number of interruptions from deep sleep into wakefulness. Please clearly report both final counts." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two transition counts from the agent's report:\n1) the total number of sleep-stage transitions across the whole night\n2) the number of deep-sleep interruptions into wakefulness\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"total_stage_transitions\" and \"n3_to_w_interruptions\".\n5. Both values must be INTEGERS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"total_stage_transitions\": , \"n3_to_w_interruptions\": }", + "metrics": [ + { + "metric_id": "total_stage_transition_accuracy", + "type": "numeric_check", + "target_key": "total_stage_transitions", + "weight": 50, + "params": { + "gt_value": 99, + "tolerance": 2 + } + }, + { + "metric_id": "n3_to_w_interruptions_accuracy", + "type": "numeric_check", + "target_key": "n3_to_w_interruptions", + "weight": 50, + "params": { + "gt_value": 0, + "tolerance": 0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case9/case9_22.json b/sleep_assessment/cases/case9/case9_22.json new file mode 100644 index 0000000000000000000000000000000000000000..c59dacadbbef97e788a4c8c6a5df50af347bfada --- /dev/null +++ b/sleep_assessment/cases/case9/case9_22.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "Physionet2018_02.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_02.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two transition-based metrics for the whole night: the total number of sleep-stage transitions, and the number of interruptions from deep sleep into wakefulness. Please clearly report both final counts." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two transition counts from the agent's report:\n1) the total number of sleep-stage transitions across the whole night\n2) the number of deep-sleep interruptions into wakefulness\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"total_stage_transitions\" and \"n3_to_w_interruptions\".\n5. Both values must be INTEGERS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"total_stage_transitions\": , \"n3_to_w_interruptions\": }", + "metrics": [ + { + "metric_id": "total_stage_transition_accuracy", + "type": "numeric_check", + "target_key": "total_stage_transitions", + "weight": 50, + "params": { + "gt_value": 101, + "tolerance": 3 + } + }, + { + "metric_id": "n3_to_w_interruptions_accuracy", + "type": "numeric_check", + "target_key": "n3_to_w_interruptions", + "weight": 50, + "params": { + "gt_value": 0, + "tolerance": 0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case9/case9_23.json b/sleep_assessment/cases/case9/case9_23.json new file mode 100644 index 0000000000000000000000000000000000000000..28a916acd2105dbd343801e9bba3ca588e24555d --- /dev/null +++ b/sleep_assessment/cases/case9/case9_23.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "Physionet2018_03.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_03.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two transition-based metrics for the whole night: the total number of sleep-stage transitions, and the number of interruptions from deep sleep into wakefulness. Please clearly report both final counts." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two transition counts from the agent's report:\n1) the total number of sleep-stage transitions across the whole night\n2) the number of deep-sleep interruptions into wakefulness\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"total_stage_transitions\" and \"n3_to_w_interruptions\".\n5. Both values must be INTEGERS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"total_stage_transitions\": , \"n3_to_w_interruptions\": }", + "metrics": [ + { + "metric_id": "total_stage_transition_accuracy", + "type": "numeric_check", + "target_key": "total_stage_transitions", + "weight": 50, + "params": { + "gt_value": 84, + "tolerance": 2 + } + }, + { + "metric_id": "n3_to_w_interruptions_accuracy", + "type": "numeric_check", + "target_key": "n3_to_w_interruptions", + "weight": 50, + "params": { + "gt_value": 1, + "tolerance": 0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case9/case9_24.json b/sleep_assessment/cases/case9/case9_24.json new file mode 100644 index 0000000000000000000000000000000000000000..0509f2cc514c408a2fae6f53bcf5a6ced7d6f41a --- /dev/null +++ b/sleep_assessment/cases/case9/case9_24.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "Physionet2018_04.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_04.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two transition-based metrics for the whole night: the total number of sleep-stage transitions, and the number of interruptions from deep sleep into wakefulness. Please clearly report both final counts." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two transition counts from the agent's report:\n1) the total number of sleep-stage transitions across the whole night\n2) the number of deep-sleep interruptions into wakefulness\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"total_stage_transitions\" and \"n3_to_w_interruptions\".\n5. Both values must be INTEGERS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"total_stage_transitions\": , \"n3_to_w_interruptions\": }", + "metrics": [ + { + "metric_id": "total_stage_transition_accuracy", + "type": "numeric_check", + "target_key": "total_stage_transitions", + "weight": 50, + "params": { + "gt_value": 155, + "tolerance": 4 + } + }, + { + "metric_id": "n3_to_w_interruptions_accuracy", + "type": "numeric_check", + "target_key": "n3_to_w_interruptions", + "weight": 50, + "params": { + "gt_value": 1, + "tolerance": 0 + } + } + ] + } +} diff --git a/sleep_assessment/cases/case9/case9_25.json b/sleep_assessment/cases/case9/case9_25.json new file mode 100644 index 0000000000000000000000000000000000000000..e9c6a741e9102c10217bf193ede5539b05b37a14 --- /dev/null +++ b/sleep_assessment/cases/case9/case9_25.json @@ -0,0 +1,37 @@ +{ + "meta_info": { + "case_id": "Physionet2018_05.edf", + "bench_subset": "NeuroBench-Sleep", + "difficult": 1, + "original_dataset": "Physionet2018" + }, + "agent_input": { + "label_path": "data/sleep/Physionet2018_05.npy", + "instruction": "Please use the provided sleep-stage label file to calculate two transition-based metrics for the whole night: the total number of sleep-stage transitions, and the number of interruptions from deep sleep into wakefulness. Please clearly report both final counts." + }, + "eval_config": { + "parser_prompt": "### ROLE\nYou are a precise JSON Extraction Engine for sleep medicine reports. Your sole task is to convert natural language reports into structured JSON data.\n\n### TASK\nExtract two transition counts from the agent's report:\n1) the total number of sleep-stage transitions across the whole night\n2) the number of deep-sleep interruptions into wakefulness\n\n### STRICT CONSTRAINTS (MANDATORY)\n1. Output ONLY a valid JSON object.\n2. DO NOT include Markdown code blocks.\n3. DO NOT include conversational text, explanations, or units.\n4. The keys must be EXACTLY \"total_stage_transitions\" and \"n3_to_w_interruptions\".\n5. Both values must be INTEGERS or null.\n6. If one value is missing or cannot be found, return null for that value.\n\n### OUTPUT TEMPLATE\n{\"total_stage_transitions\": , \"n3_to_w_interruptions\": }", + "metrics": [ + { + "metric_id": "total_stage_transition_accuracy", + "type": "numeric_check", + "target_key": "total_stage_transitions", + "weight": 50, + "params": { + "gt_value": 83, + "tolerance": 2 + } + }, + { + "metric_id": "n3_to_w_interruptions_accuracy", + "type": "numeric_check", + "target_key": "n3_to_w_interruptions", + "weight": 50, + "params": { + "gt_value": 0, + "tolerance": 0 + } + } + ] + } +}