Skip to content
Back to skills

Score Function Evaluator

ASecurity

Evaluate log density, gradient, Hessian, and finite-difference checks for a Bernoulli-Beta Stan score-model proxy in unconstrained coordinates.

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

Security analysis

A100/100

Pro scans all 3 files and shows the line behind each finding

Scanned September 9, 2026

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

Installs into .claude/skills of the current project.

Are you the author of Score Function Evaluator?

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

Security grade badge for Score Function Evaluator
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/vectorspacelab-score-function-evaluator/badge)](https://www.skillsdirectory.com/skills/vectorspacelab-score-function-evaluator)

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

Download with Pro
SKILL.md
---
name: score_function_evaluator
description: Evaluate log density, gradient, Hessian, and finite-difference checks for a Bernoulli-Beta Stan score-model proxy in unconstrained coordinates.
---

# Score Function Evaluator

Use this skill to exercise BridgeStan-like score-model access on the Bernoulli recovery proxy. It consumes a Stan contract and transform adapter rather than inventing an unrelated objective.

## Inputs
- Contract JSON from `stan_model_contract`.
- Observation data JSON with binary `y` values.
- Unconstrained scalar parameter value.
- Optional path to the transform adapter script.

## Outputs
- JSON with log density, gradient, Hessian, finite-difference diagnostics, and pass/fail checks.

## Workflow
1. Confirm the contract contains a bounded scalar `theta` and Bernoulli likelihood.
2. Convert unconstrained `z` to constrained `theta` using the transform adapter.
3. Evaluate the Bernoulli likelihood with Beta(1,1) prior and the transform Jacobian.
4. Compute analytic gradient and Hessian in `z`.
5. Cross-check the derivatives with central finite differences before accepting the result.

## Validation
Run `python tests/test_score_evaluator.py` from this skill directory.

## Limitations
This is a recovery proxy for the score-model mechanism, not a replacement for full BridgeStan compilation or real Stan autodiff.

Files in this skill

  • SKILL.md1.3 KB
  • scripts/score_evaluator.py4.3 KB
  • tests/test_score_evaluator.py976 B

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.