Skip to content

Safe-FCL: Continuous risk awareness and fine-grained safety aggregation for federated continual learning of LLMsSafe-FCL: Continual Risk Awareness and Fine-Grained Safety Aggregation for Federated Continual Learning of LLMs

arXiv: Jailbreaks, Prompt Injection, Poisoning & Defenses· arXiv:2610.19968· Shuaijie Ma, Yongkang Hu, Yu Cheng, Jiuan Zhou, Yi Xie, Yushuo Zhang, Zhaoxia YinEast China Normal University; Shanghai Innovation InstituteIndexed by this site · 2026-10-15· Originally publishedDefenses

Quick read

Defenses

Based on the paper PDF (AI-generated); refer to the original

In Llama-3.1-8B federated continual learning, Safe-FCL achieves T4 average Rule 92.54% and MD-Judge 95.98%.

Threat modelMalicious clients submit harmful model updates in federated continual learning, and behavior patterns can evolve across tasks. The server cannot access raw data during aggregation and does not know true malicious identities, so it can only assess risk from observable model updates. The goal is to adapt to new risks, retain historical risk identification, and use fine-grained aggregation to suppress potentially malicious updates.

Questions
In federated continual learning, malicious clients can submit harmful updates, and patterns evolve across tasks. Fixed detectors may miss new risks, continual adaptation may forget old risks, and client-level weighting cannot suppress suspicious updates at the module level.
Methods
Safe-FCL's CRA learns new risks from LoRA update trajectories and constrains detector updates with an orthogonal protection basis formed from historical features. FGSA combines client safety scores with module magnitude and direction deviation relative to historical statistics, using risk-aware gating to adjust the aggregation contribution of each LoRA module.
Experiments and results
Table 2: After Llama-3.1-8B completes four tasks, Safe-FCL averages Rule 92.54%, MD-Judge 95.98%, which the authors claim is 0.41 and 0.64 percentage points above the current SOTA. Table 3 detector AA 94.51%, OOD ACC 96.60%.
Limitations and future work
The authors state that evaluation focuses on controlled text scenarios; multimodal, adaptive attacks, and colluding malicious clients have not been explored; as clients and tasks increase, trajectory evaluation and historical feature retention may increase computational and storage overhead. Experiments use Llama-3.1-8B, 10 clients, and five self-built safety tasks; the paper does not report threshold values or the number of repetitions.
Experimental setupLlama-3.1-8B · physical, public, and material safety、privacy and information protection et al. · Rule、MD-Judge et al.
Evaluated models
Llama-3.1-8B
Benchmarks
physical, public, and material safetyprivacy and information protectionproperty, identity, and information deceptiondigital securitydiscrimination and interpersonal harm
Metrics
RuleMD-JudgeAAAFNew ACCOOD Task ACC
AI summaryThe paper proposes Safe-FCL, which uses continuous risk awareness (CRA) to learn emerging malicious update patterns and constrains detector updates with a protection subspace derived from historical features to prevent forgetting; fine-grained safety aggregation (FGSA) combines client risk assessment with module-level historical deviation to regulate aggregation contributions. Experiments show it outperforms the current SOTA, with global model Rule and MD-Judge scores improving by 0.41% and 0.64%, respectively, and average risk identification accuracy improving by 2.01%.

The paper proposes Safe-FCL, which uses continuous risk awareness (CRA) to learn emerging malicious update patterns and constrains detector updates with a protection subspace derived from historical features to prevent forgetting; fine-grained safety aggregation (FGSA) combines client risk assessment with module-level historical deviation to regulate aggregation contributions. Experiments show it outperforms the current SOTA, with global model Rule and MD-Judge scores improving by 0.41% and 0.64%, respectively, and average risk identification accuracy improving by 2.01%.

Paper analysis

6 questions; open one to read the full answer

  1. What problem does this paper attempt to solve?

    In federated continual learning, malicious updates evolve; Safe-FCL uses continual risk awareness and fine-grained aggregation to maintain long-term safety.

    In federated continual learning, malicious update patterns evolve with tasks, and defenses must simultaneously identify new risks and remember old ones.

    • Scenario: The authors state that federated fine-tuning allows LLMs to learn collaboratively without centralizing raw data. Extended to continual learning, the model must acquire new knowledge and retain existing capabilities, while malicious update patterns also change; defenses must address both current threats and long-term effectiveness across tasks.
    • Existing shortcomings: The authors state that FLAME, LASA, and Safe-FedLLM do not explicitly handle malicious updates that evolve across sequential tasks. A fixed detector may miss new threats, while continual adaptation may forget learned risks; client-level risk weighting also lacks targeted control over suspicious module updates.
    • Core observation: The authors believe that only adapting to the current task interferes with learned risk representations, while a fixed detector struggles to cover new patterns; sharing one weight across all modules of the same client also fails to suppress local anomalous updates.
    • Proposed method: They propose Safe-FCL, consisting of Continual Risk Awareness (CRA) and Fine-Grained Safety Aggregation (FGSA).
    • Threat model:
      • Goal: Adapt to evolving malicious updates, retain historical risk identification, and suppress the impact of potentially malicious updates on the global model.
      • Knowledge: During aggregation, the server cannot access client raw data and does not know the true malicious identity; it can only assess risk from observable model updates.
      • Capability: Malicious clients submit harmful model updates, and behavior patterns can evolve across tasks. Appendix B.1 states that malicious identity is used only to construct detector labels and is not provided to the server during aggregation.
      • Victim system: N clients sequentially learn K tasks; the server distributes the global LoRA adapter and aggregates local fine-tuning updates, with adapter parameters inherited across tasks.
  2. What related research exists?

    The authors position this paper between federated continual learning and federated LLM safety defenses, both of which fail to address malicious updates evolving across tasks.

    Federated Continual Learning

    • Sequential Tasks and Forgetting: Kirkpatrick et al. (2017) use parameter regularization, Li and Hoiem (2018) use knowledge distillation, Rebuffi et al. (2017) and Buzzega et al. (2020) use experience replay, and Lopez-Paz and Ranzato (2017), Farajtabar et al. (2020), and Saha et al. (2021) use gradient constraints to mitigate catastrophic forgetting.
    • Federated Settings: Yoon et al. (2021) and Dong et al. (2022) use knowledge transfer and distillation to compensate; Yu et al. (2025) and Zhang et al. (2025a) use feature anchoring and gradient correction; Yi et al. (2025) use multi-expert collaboration to handle client heterogeneity and update conflicts.
    • Extensions to LLMs: Guo et al. (2025) perform federated continual instruction tuning, and Qiu et al. (2026) do conflict-aware layer selection. The paper notes that these works mainly focus on knowledge retention and task adaptation, leaving long-term safety issues from evolving malicious updates underexplored.

    Federated LLM Safety Defenses

    • Aggregation and Filtering: Krum (Blanchard et al., 2017) does robust aggregation, FLTrust (Cao et al., 2021) weights by trust, FLAME (Nguyen et al., 2022) and FedREDefense (Xie et al., 2024) filter anomalies, and LASA (Xu et al., 2025) does layer-adaptive sparse aggregation. The introduction names FLAME, LASA, and Safe-FedLLM, stating they do not explicitly handle malicious updates evolving across sequential tasks, and client-level weighting lacks module-level control.
    • Safe-FedLLM: Tao et al. (2026) use LoRA updates to evaluate client risk and modulate aggregation. Section 2.2 states that as task distributions and malicious patterns evolve, adapting to new threats while retaining historical risk identification remains a key challenge for long-term safety.
    • Evolving System Safety: Cheng et al. (2026a,b) discuss safety of evolving LLM systems. The paper only uses this as background outside federated learning and does not compare with it.

    Other Continual Adaptation Works

    • Hu et al. (2026) and Zhang et al. (2026) study continual adaptation for AI-generated image detection. The paper only lists them and does not compare with Safe-FCL.

    Baseline Methods and Benchmarks

    • Baselines: FedAvg (McMahan et al., 2017), FLAME, LASA, and Safe-FedLLM's Step-Level, Client-Level, and Shadow-Level variants.
    • Data and Metrics: Five self-constructed safety tasks with materials from 49,765 QA pairs across 34 upstream libraries; global model safety is evaluated with Rule (Tao et al., 2026) and MD-Judge (Li et al., 2024).

    The authors position Safe-FCL between two lines of work: existing federated continual learning focuses on knowledge retention, and the named federated defenses do not maintain risk memory across sequential tasks nor map client risk to module-level aggregation.

  3. How does the paper address this problem?

    CRA uses historical protection subspaces to constrain detector updates, and FGSA adjusts LoRA aggregation according to client risk and module deviation.

    Safe-FCL first updates the risk detector on each task, then uses detection results and module historical deviation to adjust LoRA aggregation in federated rounds. CRA handles cross-task risk memory, and FGSA turns that memory into aggregation weights.

    Problem Setting

    • Training loop: N clients sequentially learn K tasks. In communication round r of task Tk, the server distributes the global LoRA adapter to subset Sk,r and aggregates local fine-tuning updates; the adapter is inherited across tasks.
    • Visible information: The server cannot see raw data and does not know who the malicious clients are; it can only use model updates.
    • Key quantities: Table 1 gives risk score pϕ(x), layer protection basis Uk,ℓ, suspicious update ratio ρbi, client safety score si, weight πi, module deviation Di,m, and retention coefficient gi,m. The text does not give the values of thresholds and strength coefficients.

    Continual Risk Awareness CRA

    • Risk score for the current task: Features of cumulative changes in selected LoRA parameters are extracted from benign and malicious client LoRA update trajectories, then passed through the detector to obtain a risk score. Equation (1) applies a sigmoid to the detector output; a high score indicates higher predicted malicious risk.
    • Historical protection basis: Orthogonal protection bases Uk,ℓ are constructed for each layer using the principal directions of the detector's per-layer input activations on previous tasks. Let Dℓ be the layer parameter change given by the optimizer; the constrained update is

    W̄ℓ+=W̄ℓ+Dℓ−(Dℓ Uk,ℓ)⊤Uk,ℓ i.e., the component along historical important feature directions is removed to reduce interference between old and new risk knowledge.

    • Client scoring after fixing: After the current task's detector training ends, parameters ϕ are fixed in the corresponding federated rounds. The local trajectories used for scoring are separate from the updates actually participating in aggregation. Local samples are split into T equal large batches; the proportion of steps where the risk score reaches τcls is ρbi, and the safety score is si=(1−ρbi)η, η>0. The values of T, τcls, and η are not reported.

    Fine-Grained Safety Aggregation FGSA

    • Client-level switch: If the average safety score of participating clients is below τskip, aggregation is skipped and both global parameters and historical module statistics remain unchanged. Otherwise, the base weight πi is proportional to the product of local sample size ni and si.
    • Module deviation: For module m, the effective LoRA update is computed, its norm scaled by the current learning rate and log-transformed as magnitude, and a fixed low-dimensional projection gives direction. These are compared with the historical log-magnitude mean, variance, and average direction inherited across tasks; parts exceeding tolerances δa and δb are combined into Di,m, truncated by Dmax. The authors state that deviating from historical behavior is not necessarily malicious.
    • Risk-aware gating: The retention coefficient is written as

    gi,m=exp[−λ(1−si)Di,m] λ>0. The higher the detected risk and the larger the module deviation, the smaller gi,m, and the more the aggregation increment of that LoRA factor A or B is suppressed.

    • How statistics continue: After evaluating the clients in the current round, only qualified observations with high safety scores, small historical deviation, and limited gating suppression update the magnitude mean, variance estimate, and average direction with β∈(0,1). The numerical thresholds for qualification are not reported.

    Cross-Task Retention and Evaluation

    • What is inherited: When switching tasks, the global LoRA, risk detector, historical protection bases, and module statistics are retained, so CRA continues to adapt to new risks and FGSA continues to evaluate deviation with accumulated statistics.
    • Two protocols: Protocol 1 sequentially learns the first four tasks, evaluating the global model on learned tasks at each stage and evaluating the detector. Protocol 2 fixes the detector obtained in the continual learning stage and continues federated fine-tuning and FGSA statistic updates on unseen tasks.
    • Score definitions: Appendix B.2 defines Rule and MD-Judge as the proportion of queries whose responses are judged safe, then averaged over learned tasks. AA is the average detection accuracy over learned tasks; AF retains its sign, with positive values indicating a decrease relative to the protocol-specified reference accuracy; New ACC is the average accuracy of the current task at the end of each stage. The specific choice of reference accuracy bk,j is not elaborated in the main text.
  4. What experiments did the paper conduct?

    In Table 2, T4 average Rule 92.54%, MD-Judge 95.98%, which the authors claim is above the current SOTA.

    Experimental Setup

    • Backbone and Federated: Llama-3.1-8B with LoRA. 10 clients, 3 of which are malicious; 3 randomly selected each round. 100 communication rounds per task, 10 steps of local optimization per client. The paper does not report the number of repetitions.
    • Tasks and Scale: Five safety tasks arranged per Table 6, the first four used for continual learning, with discrimination and interpersonal harm as OOD. Each task has 5,000 training, 714 validation, and 1,429 test samples, with a benign-to-harmful ratio of 7:3. The snapshot contains 49,765 QA pairs from 34 upstream libraries; the split includes 25,000 for LLM training and 14,050 auxiliary trajectories.
    • Malicious Samples: Types A and B form the benign pool, and type C (harmful requests and harmful responses) forms the malicious pool. Malicious identity is used only for detector labels. The paper does not report generating updates with a separate attack model.
    • Protocols: Protocol 1 evaluates the global model on learned tasks at each stage and evaluates the detector. Protocol 2 fixes the detector, continues federated fine-tuning and FGSA history statistic updates; OOD detection accuracy no longer adapts the detector, and OOD Rule and MD-Judge are computed after fine-tuning.
    • Baselines: FedAvg, FLAME, LASA, and Safe-FedLLM-Step, Safe-FedLLM-Client, Safe-FedLLM-Shadow. Ablations remove CRA or FGSA.
    • Metrics and Review: Global model uses Rule and MD-Judge; detector uses AA, AF, New ACC, and OOD Task ACC. The paper does not state the MD-Judge model version or decision threshold, nor does it report the values of τcls, τskip, η, λ, β.

    Main Results

    The table below shows the average safety scores over the four learned tasks after completing Task 4 in Table 2. Implementation details use Llama-3.1-8B, and it is stated that all methods use the same task order and federated training settings.

    MethodRuleMD-Judge
    FedAvg53.79%52.62%
    FLAME59.33%58.27%
    LASA57.58%55.71%
    Safe-FedLLM-Step90.79%93.65%
    Safe-FedLLM-Client74.48%74.94%
    Safe-FedLLM-Shadow92.13%95.34%
    Safe-FCL92.54%95.98%
    • Stage averages: The authors claim Safe-FCL has the highest average Rule and MD-Judge across learning stages. The Task 1 to Task 4 stage averages in Table 2 are consistent with this claim. The abstract states improvements of 0.41% and 0.64%, and Section 4.2 states 0.41 and 0.64 percentage points higher.
    • Authors' mechanism explanation: The authors state that CRA updates client risk assessment while limiting interference with learned risk knowledge, and FGSA then combines historical magnitude and direction deviation to selectively suppress individual LoRA modules, rather than applying the same risk weight to every module of a client.
    • Cell exceptions: The highest stage average does not mean the highest on every learned task. On Task 2 after completing four tasks, Safe-FedLLM-Shadow has Rule 93.47% and MD-Judge 96.04%, while Safe-FCL has 92.31% and 95.10% (Table 2).

    Continual Risk Identification

    • What was measured: Detector AA, AF, New ACC compared under Protocol 1, and OOD Task ACC measured under Protocol 2 with a frozen detector. Detector results for FedAvg, FLAME, and LASA are not reported.
    • Results: In Table 3, Safe-FCL's four-stage AA is 94.73%, 98.85%, 96.70%, 94.51%, New ACC is 98.55%, and OOD ACC is 96.60%. The authors claim AA is 2.01 percentage points above the current SOTA, New ACC 7.11 percentage points higher, and OOD Task ACC 4.93 percentage points above the strongest baseline. Among baselines in the same table, the highest Task 4 AA is Safe-FedLLM-Client's 92.50%, the highest New ACC is Shadow's 91.44%, and the highest OOD ACC is Client's 91.67%.
    • AF and authors' interpretation: Relative to removing CRA, the authors claim final AA is 2.12 percentage points higher and AF is 1.51 percentage points lower; the corresponding values without CRA are AA 92.39% and AF 8.04%. In Table 3's Task 4 AF, Safe-FCL is 6.53, while Step, Client, and Shadow are -0.50, 1.11, and 1.07; the authors do not explain this gap. The authors believe that protecting historical risk representations does not necessarily sacrifice adaptation to new patterns, and they consider the OOD accuracy with a frozen detector to mean discrimination generalizes to unseen task domains.

    OOD Global Model Safety

    • What was measured: Protocol 2 fixes the detector and continues federated fine-tuning and FGSA statistic updates. Figure 3 compares Rule and MD-Judge across methods; the text does not list the absolute scores of the baselines in the figure.
    • Results: The authors claim Safe-FCL is 2.33% higher in Rule and 0.47% higher in MD-Judge than the current SOTA. Table 4 gives Safe-FCL's OOD Rule 95.57% and MD-Judge 96.97%. The OOD accuracy of 4.93% in the conclusion corresponds to the detector OOD Task ACC in Section 4.3, not the two differences in Figure 3.
    • Authors' interpretation: The authors believe the larger gap in Rule corresponds to suppressing explicit safety violations, and the MD-Judge gain indicates semantic-level safety is also maintained during adaptation. CRA no longer trains the detector; FGSA uses historical module deviation for selective suppression and updates statistics with qualified observations.

    Ablations

    • What was measured: Table 4 removes CRA or FGSA under the same settings as Protocol 1. The OOD column is the global model score after continuing fine-tuning with the detector fixed.
    • Results: The authors claim the full model is 0.70 and 0.29 percentage points higher in final Rule and MD-Judge than without CRA. Table 4's T4 averages are 92.54%/95.98% for the full model, 91.84%/95.69% without CRA, and 92.78%/95.63% without FGSA. On OOD, the three are 95.57%/96.97%, 90.91%/96.27%, and 88.58%/93.01%, respectively.
    • Authors' interpretation and exceptions: The authors believe continual adaptation of risk identification helps safe aggregation after task distribution shifts; FGSA's improvement is more evident after the third task, but the final stage is not better on all metrics. In Table 7, at the T4 stage, Task 4's Rule is 91.84% for the full model and 93.71% without FGSA.

    Other Ablations and Analyses

    • Alternative order completing T4 (Table 8): Safe-FCL averages Rule 88.11%, MD-Judge 91.43%; the authors claim 2.38% and 1.04% above the current SOTA.
    • The newly introduced Task 4 in that order (Table 8): Safe-FCL Rule 78.55%, MD-Judge 83.68%; the authors claim 6.52% and 1.16% above the current SOTA.
    • OOD global model in that order (Table 9, Figure 4): Safe-FCL Rule 93.94%, MD-Judge 98.14%; the authors claim MD-Judge is 0.24 percentage points higher than Safe-FedLLM-Shadow and 2.33 and 2.34 percentage points higher than Step.
    • Detector in that order (Table 11, after T4): Safe-FCL AA 99.64%, AF -0.01%, New ACC 99.62%, OOD ACC 95.87%.
    • Main order Table 4: Task 1 without FGSA is Rule 90.68%, MD-Judge 92.54%, while the full model is 90.44% and 92.31%; on the T4 average Rule, without FGSA at 92.78% is higher than the full model.
    • Main order Table 7, learned Task 3 at the T4 stage: full model Rule 92.31%, MD-Judge 94.64%, without CRA 89.51% and 93.24%; the authors claim 2.80% and 1.40% higher, respectively.
  5. What are some points that can be further explored?

    The authors state that evaluation focuses on controlled text-based federated continual learning, and multimodal and adaptive, collusive malicious scenarios have not been explored.

    Limitations and Future Directions Noted by the Authors

    • Text and controlled malicious clients: Evaluation focuses on text federated continual learning under a controlled malicious client setting (Limitations).
    • More complex adversaries: Multimodal and more complex adversarial scenarios, including adaptive attacks and colluding malicious clients, have not been explored (Limitations).
    • Scale overhead: As clients and tasks increase, evaluation branch optimization, detector adaptation, and historical feature retention may increase computational and storage overhead (Limitations).
    • Future work: The authors plan to study broader threat scenarios and lower-overhead trajectory evaluation and historical feature representations to improve Safe-FCL's scalability and applicability (Limitations).

    Experimental Coverage

    • The tested backbone is Llama-3.1-8B with LoRA; federated setup is 10 clients, 3 of which are malicious, with 3 randomly selected each round; 100 communication rounds per task and 10 local optimization steps per client (Section 4.1).
    • Five self-built safety tasks each have 5,000/714/1,429 training, validation, and test samples, with a benign-to-harmful ratio of 7:3. Protocol 1 sequentially learns the first four tasks; Protocol 2 fixes the detector on discrimination and interpersonal harm and continues federated fine-tuning and FGSA statistic updates (Section 4.1, Table 6, Appendix B.2).
    • Comparisons are FedAvg, FLAME, LASA, and Safe-FedLLM's Step, Client, Shadow; ablations remove CRA or FGSA, plus an alternative task order in Appendix C. Global model metrics are Rule and MD-Judge; detector metrics are AA, AF, New ACC, OOD Task ACC.
    • The data snapshot contains 49,765 QA pairs from 34 upstream libraries, of which 25,000 are used for LLM training and 14,050 for auxiliary trajectories; malicious identity is used for detector labels and is not provided to the server during aggregation (Appendix A, B.1).
    • The paper does not report the number of repetitions, statistical tests, or the values of τcls, τskip, η, λ, β, δa, δb, and the qualification thresholds; nor does it report the MD-Judge model version or the specific choice of AF reference accuracy bk,j.
  6. Summarize the main content of the paper

    Safe-FCL uses CRA and FGSA for cross-task safe aggregation, and the authors claim it outperforms the listed baselines on Llama-3.1-8B.

    Safe-FCL is a safety-aware aggregation framework for federated continual learning of LLMs, addressing malicious updates evolving across tasks, detector forgetting of old risks, and the inability of client-level weights to suppress suspicious updates at the module level.

    • Problem Setting: The server cannot see raw data or know whether clients are malicious, and can only assess risk from model updates. Malicious identity is used only to construct detector labels. The global LoRA adapter is inherited across tasks.
    • Method: CRA learns risk scores from benign and malicious LoRA trajectories and uses an orthogonal protection basis constructed from historical activations to remove corresponding components from detector updates. After training on the current task, the detector is fixed during the corresponding federated rounds, and client safety scores are computed using separate local trajectories. FGSA skips aggregation when the average safety score is below a threshold; otherwise, it combines sample size, safety scores, and deviations of module magnitude and direction from historical statistics, using gating to modulate each LoRA module's contribution, and updates historical statistics only with qualified observations.
    • Main Safety Results: On Llama-3.1-8B with 10 clients (3 malicious) after four safety tasks, Safe-FCL's average Rule and MD-Judge are 92.54% and 95.98% (Table 2). The abstract states improvements of 0.41% and 0.64%, while Section 4.2 states 0.41 and 0.64 percentage points higher. On Task 2 of the completion phase, Safe-FedLLM-Shadow's 93.47% and 96.04% are higher than Safe-FCL's 92.31% and 95.10%.
    • Detector and OOD: In Table 3, Safe-FCL's Task 4 AA is 94.51%, New ACC is 98.55%, and frozen detector's OOD Task ACC is 96.60%. The authors state these are 2.01, 7.11, and 4.93 percentage points higher than the current SOTA or strongest baseline. In the same table, Task 4 AF is 6.53, higher than the three Safe-FedLLM variants. In Table 4, after fixing the detector and continuing fine-tuning, OOD Rule and MD-Judge are 95.57% and 96.97%; the authors state Figure 3 shows 2.33% and 0.47% higher than the current SOTA.
    • Authors' Conclusions: The authors state that CRA maintains cross-task risk identification, and FGSA turns risk awareness into selective control over updates, thereby enhancing long-term safety. They also state that module-level control involves trade-offs across different safety metrics. They plan to explore broader threat scenarios and lower-cost trajectory evaluation and historical feature representations in the future.
Read originalarxiv.org