Skip to content
Back to skills

I2sb Bridge Posterior

ASecurity

Compute the analytic Gaussian bridge posterior q(Xt | X0, X1) for I2SB paired clean/degraded endpoints.

  • 247 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added September 9, 2026
toolspythonbash

Works with

  • terminal

Security analysis

A100/100

Scanned September 9, 2026

npx -y skills add VectorSpaceLab/AREX-Skill --skill i2sb_bridge_posterior --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of I2sb Bridge Posterior?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for I2sb Bridge Posterior
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/vectorspacelab-i2sb-bridge-posterior/badge)](https://www.skillsdirectory.com/skills/vectorspacelab-i2sb-bridge-posterior)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

SKILL.md
---
name: i2sb_bridge_posterior
description: Compute the analytic Gaussian bridge posterior q(Xt | X0, X1) for I2SB paired clean/degraded endpoints.
---

# I2SB Bridge Posterior

Use this skill when implementing or checking I2SB training data construction from paired clean and degraded samples. Do not use it for ordinary diffusion noising to Gaussian noise; the terminal endpoint is the degraded paired sample `X1`.

## Inputs

- Clean endpoint `x0` as a scalar or vector.
- Degraded endpoint `x1` with the same shape.
- Time `t` in `[0, 1]`.
- Positive constant beta, or precomputed accumulated variances.
- Optional seed or explicit standard-normal noise for reproducible sampling.

## Outputs

- `sigma2_t`, `barsigma2_t`, posterior mean, posterior variance.
- Optional posterior sample `xt`.

## Workflow

1. Validate endpoint shapes and time bounds.
2. Compute accumulated variances: for constant beta, `sigma2_t = beta * t` and `barsigma2_t = beta * (1 - t)`.
3. Compute the posterior mean using variance weights from I2SB Equation (11).
4. Compute covariance `sigma2_t * barsigma2_t / (sigma2_t + barsigma2_t)`.
5. Add seeded Gaussian noise only when a sample is requested.

## Validation

Run:

```bash
python scripts/bridge_posterior.py --demo
python tests/test_bridge_posterior.py
```

## Limitations

This skill implements the scalar/vector contract for recovery and validation. Image tensors use the same broadcasted formulas but require external array/tensor containers.

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.