用AI自动生成可解释的脑电波尖峰检测特征,兼顾准确与可读性。
EEG-SpikeAgent: Agentic Closed-Loop Program Synthesis for Automated EEG Spike Detection

- 通过大模型迭代生成信号处理代码,自动优化脑电特征
- 在公开数据集上达到0.935的AUC,敏感度达0.80时精度为0.470
- 生成的代码可审计,适合临床与算法研究者复用
头皮脑电图(EEG)中发作间期癫痫样放电的自动检测具有重要临床意义,但当前高性能深度学习模型常以牺牲可解释性为代价换取准确性。本文提出EEG-SpikeAgent,一种基于大语言模型(LLM)的闭环程序合成框架,用于自动生成头皮EEG尖峰检测的信号处理特征。系统逐轮提出一个确定性特征模块,执行生成代码提取表格化特征,通过梯度提升树分类器评估性能,汇总运行指标并反馈给模型进行迭代优化。在包含2,516个含放电和22,933个无放电4秒片段的29通道公开数据集VEPISET上,五折交叉验证下,代理生成特征在默认操作点实现0.935的受试者工作特征曲线下面积(AUC)、0.699的平衡准确率、0.557的F1分数、0.401的敏感度和0.996的特异性;在敏感度0.80的操作点,平均精确率为0.470,平均特异性为0.900。引入伪影感知特征生成后,平衡准确率与F1分数均优于仅针对尖峰的搜索。结果表明,基于大模型的程序合成可实现可审计、可检查的代码驱动式脑电特征工程,适用于临床与方法学审查。
原文摘要 · Abstract (English)
Automated detection of interictal epileptiform discharges in scalp electroencephalography (EEG) is clinically important, but recent high-performing deep-learning models often trade interpretability for accuracy. We introduce EEG-SpikeAgent, a closed-loop program-synthesis framework that uses a large language model (LLM) agentic system to generate signal-processing features for spike detection in scalp EEG. The system iteratively proposes one deterministic EEG feature module at a time, executes the resulting code on EEG to generate tabular features, evaluates performance via a tabular classifier, summarizes run-level metrics, and feeds structured diagnostics back to the model for refinement. Across iterations, EEG-SpikeAgent proposes and refines candidate signal features and decision rules informed by model performance. We evaluated EEG-SpikeAgent on VEPISET, a public 29-channel dataset of 4-second epochs containing 2,516 discharge-containing and 22,933 non-discharge epochs. Across five-fold cross-validation with a gradient-boosted tree classifier, agent-generated features achieved an area under the receiver operating characteristic curve of 0.935, balanced accuracy of 0.699, F1 score of 0.557, sensitivity of 0.401, and specificity of 0.996 at the default operating point. At an operating point with sensitivity 0.80, mean precision was 0.470 and mean specificity was 0.900. Artifact-aware feature generation improved balanced accuracy and F1 score over spike-only feature search. These results indicate that LLM-based program synthesis can automate EEG feature engineering in auditable and inspectable code-driven manner for clinical and methodological review.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。