Skip to content
Back to skills

Inference

ASecurity

"Repository operating skill for Flow Forecast saved-model

  • 247 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added September 8, 2026
devopspythongoapi

Works with

  • api

Security analysis

A100/100

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

Scanned September 8, 2026

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

Installs into .claude/skills of the current project.

Are you the author of Inference?

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

Security grade badge for Inference
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/vectorspacelab-inference-721913c3/badge)](https://www.skillsdirectory.com/skills/vectorspacelab-inference-721913c3)

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: inference
description: "Repository operating skill for Flow Forecast saved-model
  inference, evaluation, TorchScript conversion, plots, and explainability."
disable-model-invocation: true
metadata:
  disco-role: operating
license: GPL 3.0
---

# Inference

Use this sub-skill when the task is about loading a Flow Forecast model, running saved-model forecasts or classification inference, computing evaluation metrics, creating confidence-interval plots, exporting TorchScript, or using SHAP/Plotly explainability helpers.

Start with:

- [../../references/model-overview.md](../../references/model-overview.md) for the package-wide registry when you need the exact model name or supported optional dependency note.
- [references/api-reference.md](references/api-reference.md) for `InferenceMode`, `load_model`, evaluator functions, and plotting helpers.
- [references/workflows.md](references/workflows.md) for local forecast, evaluator, TorchScript, and plotting workflows.
- [references/troubleshooting.md](references/troubleshooting.md) for weight/config/data/plot failures.
- [scripts/check_inference_config.py](scripts/check_inference_config.py) for a safe synthetic inference smoke or a real config preflight.

## What This Sub-skill Covers

- `flood_forecast.deployment.inference.InferenceMode` and `load_model`.
- `infer_now`, `infer_now_classification`, and `make_plots`.
- `flood_forecast.evaluator.infer_on_torch_model`, `evaluate_model`, and `run_evaluation`.
- `convert_to_torch_script` and the currently placeholder `convert_to_onnx`.
- Plotly confidence interval helpers and SHAP summary/heatmap routes.
- Optional GCS upload/download and W&B logging behavior.

## What Belongs Elsewhere

- Data cleaning, datetime normalization, and loader schema validation belong in [data-preparation](../data-preparation/SKILL.md).
- Training configs, checkpoint creation, and loss/optimizer selection belong in [training](../training/SKILL.md).
- Catchment encoders, CrossViViT, NeuralODE, and GR4 hybrid model internals belong in [multimodal-physics](../multimodal-physics/SKILL.md).

## Typical Workflow

1. Validate that the package imports and the desired model name is in the registry.
2. Validate the CSV and inference config locally.
3. Load the saved JSON config and checkpoint path.
4. Use `InferenceMode` or `infer_on_torch_model` to run the forecast.
5. Add plots, SHAP, W&B, or GCS only after the local forecast path works.

## Operating Notes

1. `InferenceMode` wraps `load_model`, which returns a `PyTorchForecast` instance.
2. `inference_params.dataset_params` should use the test-time loader field names; use `scaling` for inference-time scaler construction.
3. `datetime_start` can be a Python `datetime`; string parsing in low-level evaluator paths is more restrictive.
4. `num_prediction_samples` triggers prediction-sample dataframes for confidence intervals.
5. `save_buck`, `save_name`, `wandb_proj`, and GCS paths require external credentials and should not be enabled by default.

## Shared References And Scripts

- [references/api-reference.md](references/api-reference.md): API signatures and output tuples.
- [references/workflows.md](references/workflows.md): local forecast, classification, evaluation, TorchScript, GCS/W&B, and plotting recipes.
- [references/troubleshooting.md](references/troubleshooting.md): missing weights, dataset block mismatches, datetime failures, and SHAP/Plotly caveats.
- [scripts/check_inference_config.py](scripts/check_inference_config.py): synthetic or real-config preflight.

## Non-goals

- Do not use this as a cloud-serving infrastructure guide unrelated to Flow Forecast APIs.
- Do not assume GCS or W&B credentials are present.
- Do not require the original repository checkout to run an inference recipe.

Files in this skill

  • SKILL.md3.7 KB
  • references/api-reference.md3.5 KB
  • references/troubleshooting.md3.7 KB
  • references/workflows.md3.1 KB
  • scripts/check_inference_config.py11.4 KB

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.