Skip to content
Skill

Spatial prediction uncertainty

Maps where a spatial ML soil prediction is reliable, using AOA, DI and LPD

Spatial prediction uncertainty is an open-source agent skill for analytics and data. It is available on Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, Windsurf and Goose.

Scripts
None
Platforms
Claude Code, Codex, Cursor
GitHub stars
13
Last commit
License
MIT
Listing updated

Similar skills

About Spatial prediction uncertainty

This skill guides an agent through producing per-pixel uncertainty for raster machine learning predictions, such as digital soil maps and nutrient or soil organic carbon products. It pairs a distributional view (prediction intervals from quantile regression forests, ensemble spread or conformal prediction) with a coverage view that shows whether the model has seen data similar to each location. The coverage side relies on the area of applicability, dissimilarity index and local data point density, computed with the R CAST package.

The workflow starts with an honest cross-validation chosen to match the sampling structure, since the applicability threshold depends on its nearest-neighbour distances. The agent then masks predictions to the applicability area, adds a density layer, and can calibrate dissimilarity or density values into expected error for a performance map. It also covers evaluating intervals with coverage and proper scoring rules, and using low-coverage zones to plan new sampling.

The skill expects a raster prediction stack, training data with coordinates, and R with the CAST package. General validation metrics are delegated to a companion skill in the same plugin.

When your agent uses it

Quantify, map, and communicate the uncertainty of a spatial ML prediction on BOTH axes — distributional ("how variable is the outcome here?") and epistemic coverage ("has the model even seen anything like here?"). Use when you need honest per-pixel uncertainty for a digital soil map, nutrient/fertility map, SOC prediction, or any raster ML product: prediction intervals, the area of applicability (AOA), the dissimilarity index (DI), local data point density (LPD), a DI/LPD→performance map, and targeted resampling of low-coverage zones. Triggers: "area of applicability", "AOA", "dissimilarity index", "DI", "local data point density", "LPD", "CAST", "aoa()", "where can I trust this map", "extrapolation risk", "prediction uncertainty map", "conformal prediction", "proper scoring rule / CRPS", "mask the map where the model is guessing".

From the skill's SKILL.md. Your agent reads this description to decide when to load the skill.

What it can access

From a static check of its 1 file (9 KB) on GitHub on 4 December 2026. Nothing was run. Read the files before you install a skill: it can tell your agent to run anything its tools allow.

Check another skill before you install it.

Install

This skill ships in the dsm-soil plugin. In Claude Code, add the marketplace and install the plugin (it may include other skills too):

/plugin marketplace add ccarbajal16/soil-dsm-skills
/plugin install dsm-soil@soil-dsm-skills

Or copy only this skill to ~/.claude/skills/spatial-prediction-uncertainty:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/ccarbajal16/soil-dsm-skills.git "$tmp" &&
mkdir -p ~/.claude/skills &&
rm -rf ~/.claude/skills/spatial-prediction-uncertainty &&
cp -R "$tmp/plugins/dsm-soil/skills/spatial-prediction-uncertainty" ~/.claude/skills/spatial-prediction-uncertainty &&
rm -rf "$tmp"

For one project only, put the folder in .claude/skills/spatial-prediction-uncertainty inside it instead.

Claude Code docs on skills

Copy the skill folder to ~/.agents/skills/spatial-prediction-uncertainty to use it in every repository:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/ccarbajal16/soil-dsm-skills.git "$tmp" &&
mkdir -p ~/.agents/skills &&
rm -rf ~/.agents/skills/spatial-prediction-uncertainty &&
cp -R "$tmp/plugins/dsm-soil/skills/spatial-prediction-uncertainty" ~/.agents/skills/spatial-prediction-uncertainty &&
rm -rf "$tmp"

For one repository only, put the folder in .agents/skills/spatial-prediction-uncertainty inside it instead.

Codex docs on skills

Copy the skill folder to ~/.cursor/skills/spatial-prediction-uncertainty to use it in every project:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/ccarbajal16/soil-dsm-skills.git "$tmp" &&
mkdir -p ~/.cursor/skills &&
rm -rf ~/.cursor/skills/spatial-prediction-uncertainty &&
cp -R "$tmp/plugins/dsm-soil/skills/spatial-prediction-uncertainty" ~/.cursor/skills/spatial-prediction-uncertainty &&
rm -rf "$tmp"

For one project only, put the folder in .cursor/skills/spatial-prediction-uncertainty inside it instead.

Cursor docs on skills

Run in a terminal (add --scope workspace to install it for the current workspace only):

gemini skills install https://github.com/ccarbajal16/soil-dsm-skills.git --path plugins/dsm-soil/skills/spatial-prediction-uncertainty

Or copy the folder to ~/.gemini/skills/spatial-prediction-uncertainty yourself.

Gemini CLI docs on skills

For GitHub Copilot in VS Code, copy the skill folder to ~/.copilot/skills/spatial-prediction-uncertainty:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/ccarbajal16/soil-dsm-skills.git "$tmp" &&
mkdir -p ~/.copilot/skills &&
rm -rf ~/.copilot/skills/spatial-prediction-uncertainty &&
cp -R "$tmp/plugins/dsm-soil/skills/spatial-prediction-uncertainty" ~/.copilot/skills/spatial-prediction-uncertainty &&
rm -rf "$tmp"

For one project only, put the folder in .github/skills/spatial-prediction-uncertainty inside it instead.

VS Code docs on skills

Get the folder:

git clone --depth 1 https://github.com/ccarbajal16/soil-dsm-skills.git

Then copy soil-dsm-skills/plugins/dsm-soil/skills/spatial-prediction-uncertainty into your agent's skills folder as spatial-prediction-uncertainty. Agents that support SKILL.md read one folder per skill.

The SKILL.md format

What it does

Per-pixel prediction intervals
Produces distributional uncertainty from quantile regression forests, ensemble spread or conformal prediction.
Area of applicability mask
Computes dissimilarity index and applicability area to show where the model's error estimate holds.
Local data point density
Counts training points supporting each pixel to grade reliability inside the applicability area.
Performance error mapping
Calibrates dissimilarity or density values into expected RMSE for a per-pixel performance layer.
Honest cross-validation setup
Selects spatial or kNN-based cross-validation matched to clustered or random sampling.
Targeted sampling guidance
Uses low-coverage zones to decide where new field samples would most reduce uncertainty.

Good for

  • Mask a soil organic carbon map to the area where the model is reliable
  • Compute prediction intervals for a per-pixel digital soil map
  • Identify low-coverage zones to target the next soil sampling campaign
  • Calibrate dissimilarity index values into an expected error map
  • Check whether prediction interval coverage matches the nominal level

Spatial prediction uncertainty FAQ

What does Spatial prediction uncertainty need to run?

It expects a raster prediction stack, training data and the R CAST package, with functions such as aoa() and knndm().

When should I use this instead of general validation?

It covers the uncertainty product itself, including intervals, applicability masks and density layers; general cross-validation and accuracy metrics are deferred to a separate soil map validation skill.

Why are prediction intervals not enough on their own?

The skill explains that quantile forest and ensemble intervals can be tight even where the model is extrapolating, so a coverage layer is also needed.

How do I install Spatial prediction uncertainty in Claude Code?

Copy the skill folder from GitHub to ~/.claude/skills/spatial-prediction-uncertainty to use it in all your projects, or to .claude/skills/spatial-prediction-uncertainty in one project. Or install the dsm-soil plugin, which includes it: /plugin marketplace add ccarbajal16/soil-dsm-skills, then /plugin install dsm-soil@soil-dsm-skills.

Does Spatial prediction uncertainty run scripts?

No. It is instructions only, with no scripts. This comes from a static check of the files on GitHub; nothing was run. Read the files before you install it.

Which AI agents can use Spatial prediction uncertainty?

Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, Windsurf and Goose. Each reads skills in the SKILL.md format from its own folder; the install steps on this page list them.

What are the best alternatives to Spatial prediction uncertainty?

The closest alternatives to Spatial prediction uncertainty are Spatial statistics areal, Data scientist, Esf satellite data, Market mirror evidence review and Tao finetune kumo forecast.

Where this comes from

  • Description: from the skill's own SKILL.md.

More from ccarbajal16/soil-dsm-skills

  1. Guides an agent through planning a digital soil mapping project from covariates

    • Open source
    • 13 GitHub stars
    • Health and science
  2. Measures whether combining soil ML models can beat the best single model, and how

    • Open source
    • 13 GitHub stars
    • Health and science
  3. Guides an agent in building hybrid process-plus-ML models for soil carbon change over time

    • Open source
    • 13 GitHub stars
    • Health and science
  4. Guides an agent in choosing, tuning and interpreting ML models for soil property

    • Open source
    • 13 GitHub stars
    • Health and science
  5. Guides an agent through setting up, calibrating and checking RothC soil carbon models

    • Open source
    • 13 GitHub stars
    • Health and science
  6. Guides an agent through soil organic carbon stock change measurement and crediting

    • Open source
    • 13 GitHub stars
    • Health and science