# Ewc Fisher Importance

> Estimate and normalize diagonal Fisher importance vectors for Elastic Weight Consolidation from first-order gradients.

- Skill: `yzj623/ewc-fisher-importance` (Agent Skill)
- Install (CLI): `npx get-skill add yzj623/ewc-fisher-importance`
- Raw SKILL.md: https://api.skillmd.com/api/skills/yzj623/ewc-fisher-importance/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Coding & Dev Tools
- Author: yzj623 (https://skillmd.com/u/yzj623)
- Updated: 2026-11-19
- Page: https://skillmd.com/skills/yzj623/ewc-fisher-importance

---


# EWC Fisher Importance

Use this skill after learning a previous task and before applying an EWC penalty. It converts per-example gradients into a nonnegative diagonal Fisher estimate and can compute normalized Fisher overlap diagnostics.

## Inputs

- Per-example gradient vectors for the previous task.
- Optional Fisher vectors for normalization or overlap.

## Outputs

- Mean squared-gradient Fisher vector.
- Trace-normalized Fisher vector.
- Fisher-overlap score for diagnostics.

## Workflow

1. Collect gradients at or near the previous-task solution.
2. Square every gradient component.
3. Average squared gradients across examples.
4. Normalize by trace only for overlap/comparison diagnostics.
5. Pass the unnormalized Fisher to the EWC penalty.

## Validation

Run:

```bash
python tests/test_fisher_importance.py
```

## Limitations

The helper expects gradient vectors supplied by a model-specific training harness. It does not compute autograd gradients itself.

