Safety Stock Review
davila7/claude-code-templates
Size or audit safety stock with assumption checks - the zsigmasqrt(LT) formula plus an empirical stress test of what it actually delivers (cycle service vs fill rate) per variability class.
Calculate safety stock levels to buffer against demand and lead time uncertainty.
$ npx skills add asgard-ai-platform/skills --skill algo-sc-safety-stock -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install asgard-ai-platform/skills algo-sc-safety-stock --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/asgard-ai-platform/skills.git skills-src && mkdir -p .claude/skills && cp -r skills-src/algo-sc-safety-stock .claude/skills/algo-sc-safety-stock && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "algo-sc-safety-stock" agent skill from https://github.com/asgard-ai-platform/skills/tree/main/algo-sc-safety-stock into .claude/skills/algo-sc-safety-stock/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "algo-sc-safety-stock", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/asgard-ai-platform/skills/tree/main/algo-sc-safety-stockType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add asgard-ai-platform/skills --skill algo-sc-safety-stock -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install asgard-ai-platform/skills algo-sc-safety-stock --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/asgard-ai-platform/skills.git skills-src && mkdir -p .agents/skills && cp -r skills-src/algo-sc-safety-stock .agents/skills/algo-sc-safety-stock && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "algo-sc-safety-stock" agent skill from https://github.com/asgard-ai-platform/skills/tree/main/algo-sc-safety-stock into .agents/skills/algo-sc-safety-stock/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "algo-sc-safety-stock", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add asgard-ai-platform/skills --skill algo-sc-safety-stock -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install asgard-ai-platform/skills algo-sc-safety-stock --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/asgard-ai-platform/skills.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/algo-sc-safety-stock .cursor/skills/algo-sc-safety-stock && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "algo-sc-safety-stock" agent skill from https://github.com/asgard-ai-platform/skills/tree/main/algo-sc-safety-stock into .cursor/skills/algo-sc-safety-stock/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "algo-sc-safety-stock", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/asgard-ai-platform/skills.git --path algo-sc-safety-stock--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add asgard-ai-platform/skills --skill algo-sc-safety-stock -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install asgard-ai-platform/skills algo-sc-safety-stock --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/asgard-ai-platform/skills.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/algo-sc-safety-stock .gemini/skills/algo-sc-safety-stock && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "algo-sc-safety-stock" agent skill from https://github.com/asgard-ai-platform/skills/tree/main/algo-sc-safety-stock into .gemini/skills/algo-sc-safety-stock/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "algo-sc-safety-stock", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install asgard-ai-platform/skills algo-sc-safety-stockInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add asgard-ai-platform/skills --skill algo-sc-safety-stock -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/asgard-ai-platform/skills.git skills-src && mkdir -p .github/skills && cp -r skills-src/algo-sc-safety-stock .github/skills/algo-sc-safety-stock && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "algo-sc-safety-stock" agent skill from https://github.com/asgard-ai-platform/skills/tree/main/algo-sc-safety-stock into .github/skills/algo-sc-safety-stock/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "algo-sc-safety-stock", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add asgard-ai-platform/skills --skill algo-sc-safety-stock -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install asgard-ai-platform/skills algo-sc-safety-stock --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/asgard-ai-platform/skills.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/algo-sc-safety-stock .opencode/skills/algo-sc-safety-stock && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "algo-sc-safety-stock" agent skill from https://github.com/asgard-ai-platform/skills/tree/main/algo-sc-safety-stock into .opencode/skills/algo-sc-safety-stock/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "algo-sc-safety-stock", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
algo-sc-safety-stockCalculate safety stock levels to buffer against demand and lead time uncertainty.
Algo Sc Safety Stock is an agent skill from asgard-ai-platform/skills. Calculate safety stock levels to buffer against demand and lead time uncertainty. Use this skill when the user needs to set inventory buffers, determine service level trade-offs, or optimize safety stock across SKUs — even if they say 'how much buffer inventory', 'stockout prevention', or 'service level calculation'.
Its SKILL.md is about 1.1k tokens, which your agent loads only when the skill is triggered. The skill folder holds 7 other files, including scripts and reference files (for example `examples/sample_input.json`, `references/intermittent-demand.md` and `references/multi-echelon.md`).
The repository describes itself as: 301 open-source coding agent skills across 22 domains — methodology, judgment & gotchas packaged as Claude Agent Skills for the Asgard AI Platform. The licence is MIT.
4 steps, taken from the step headings in SKILL.md.
Read from SKILL.md and the folder at commit 4e7f4f8. It shows what the files ask for, not the result of running them.
Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.
From allowed-tools in the SKILL.md frontmatter.
Ships 1 file in scripts/ (Python), which the agent can run.
Shell commands in SKILL.md call:
pythonFrom the folder's file list and the shell code blocks in SKILL.md.
No URLs in SKILL.md.
From URLs in SKILL.md, links to its own repository left out.
Names no API keys, tokens, secrets or passwords.
From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Algo Sc Safety Stock loads about 1.1k tokens when it runs, and up to ~6.8k if it reads all its reference files. Until then it costs about 85 tokens; SKILL.md has 449 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check found no risky patterns in SKILL.md.
Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); the scripts in this folder are not scanned.
The full file from asgard-ai-platform/skills at commit 4e7f4f8, republished under its MIT licence (© asgard-ai-platform). 449 words, ~1,135 tokens.
.claude/skills/algo-sc-safety-stock/SKILL.md (or your agent's skills folder). This skill also uses 4 other files; get the full folder from GitHub.Safety stock is buffer inventory held to protect against demand and lead time variability. Formula: SS = z × √(LT × σ²_d + d² × σ²_LT) where z=service factor, LT=lead time, σ_d=demand std dev, d=avg demand, σ_LT=lead time std dev. Directly trades inventory cost against stockout risk.
Trigger conditions:
When NOT to use:
IRON LAW: Safety Stock Is a TRADE-OFF, Not a Target
More safety stock = fewer stockouts but higher holding cost.
The relationship is non-linear: going from 95% to 99% service level
roughly DOUBLES safety stock. Going from 99% to 99.9% doubles it
again. Always quantify the cost of each service level increment.
z-values: 90%→1.28, 95%→1.65, 99%→2.33, 99.9%→3.09.Collect: historical demand data (weekly/monthly), lead time data (average and variability), target service level, unit cost and holding rate. Gate: Minimum 12 periods of demand data, lead time estimates available.
Simulate: using historical demand, would the computed SS have prevented stockouts at the target service level? Gate: Simulated service level matches target (±2%).
Return safety stock with cost impact and service level analysis.
{
"safety_stock": 250,
"reorder_point": 850,
"service_level": 0.95,
"annual_holding_cost": 5000,
"metadata": {"avg_demand_weekly": 120, "demand_cv": 0.3, "avg_lead_time_weeks": 5}
}Input: Weekly demand: avg=100, σ=30. Lead time: avg=4 weeks, σ=1 week. Target: 95%. Expected: σ_combined = √(4×900 + 10000×1) = √(3600+10000) = √13600 = 116.6. SS = 1.65 × 116.6 = 192 units.
| Input | Expected | Why |
|---|---|---|
| Zero demand variability | SS from LT variability only | σ_d = 0, only lead time risk remains |
| Zero lead time variability | SS from demand variability only | σ_LT = 0, standard formula simplifies |
| Very long lead time | High SS | More uncertainty accumulates over longer periods |
| Script | Description | Usage |
|---|---|---|
scripts/safety_stock.py | Compute safety stock and reorder point with combined demand/lead-time variability | python scripts/safety_stock.py --help |
Run python scripts/safety_stock.py --verify to execute built-in sanity tests.
references/multi-echelon.mdreferences/intermittent-demand.md© asgard-ai-platform, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
SKILL.md and 4 other files (scripts, references) in algo-sc-safety-stock of asgard-ai-platform/skills.
Open the folder on GitHubat commit 4e7f4f8
Algo Sc Safety Stock next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| Algo Sc Safety Stock this skillasgard-ai-platform/skills | 242 | — | ~1.1k | Automated safety check: Pass | MIT | |
| Safety Stock Reviewdavila7/claude-code-templates | 33k | — | ~869 | Automated safety check: Pass | MIT | |
| Buffer Calculatoraipoch/medical-research-skills | 1.9k | — | ~1.8k | Automated safety check: Pass | MIT | |
| Lead Magnetssickn33/agentic-awesome-skills | 47k | 2 repos | ~2.8k | Automated safety check: Pass | MIT | |
| Inventory Demand Planningsickn33/agentic-awesome-skills | 47k | 8 repos | ~6.5k | Automated safety check: Pass | MIT | |
| Lead Magnetscoreyhaines31/marketingskills | 54k | 5 repos | ~2.8k | Automated safety check: Pass | MIT |
davila7/claude-code-templates
Size or audit safety stock with assumption checks - the zsigmasqrt(LT) formula plus an empirical stress test of what it actually delivers (cycle service vs fill rate) per variability class.
aipoch/medical-research-skills
Calculate precise buffer recipes with accurate mass and volume measurements for molecular biology and biochemistry.
sickn33/agentic-awesome-skills
Plan and optimize lead magnets for email capture and lead generation.
sickn33/agentic-awesome-skills
Codified expertise for demand forecasting, safety stock optimisation, replenishment planning, and promotional lift estimation at multi-location retailers.
coreyhaines31/marketingskills
When the user wants to create, plan, or optimize a lead magnet for email capture or lead generation.
sickn33/agentic-awesome-skills
Scrape leads from multiple platforms using Apify Actors. An agent skill from sickn33/agentic-awesome-skills.
asgard-ai-platform/skills
Implement BM25 ranking function for e-commerce product search relevance scoring.
asgard-ai-platform/skills
Calculate Cpk process capability index to assess whether a process meets specification requirements.
asgard-ai-platform/skills
Calculate price elasticity of demand to quantify how price changes affect sales volume.
asgard-ai-platform/skills
Apply Bayesian averaging to rank items by combining observed ratings with prior expectations.
asgard-ai-platform/skills
Implement Elo rating system to rank items or players from pairwise comparison outcomes.
asgard-ai-platform/skills
Calculate Wilson Score confidence intervals for ranking items by positive proportion with sample size correction.
Calculate safety stock levels to buffer against demand and lead time uncertainty. Algo Sc Safety Stock is an agent skill from asgard-ai-platform/skills. Calculate safety stock levels to buffer against demand and lead time uncertainty.
Algo Sc Safety Stock fits situations like: the user needs to set inventory buffers; determine service level trade-offs; optimize safety stock across SKUs — even if they say how much buffer inventory; stockout prevention.
Run `npx skills add asgard-ai-platform/skills --skill algo-sc-safety-stock -a claude-code`. Or copy the skill folder (algo-sc-safety-stock in asgard-ai-platform/skills) into .claude/skills/algo-sc-safety-stock in your project. Claude Code loads it when a task matches its description.
Run `npx skills add asgard-ai-platform/skills --skill algo-sc-safety-stock -a codex`. Or copy the skill folder (algo-sc-safety-stock in asgard-ai-platform/skills) into .agents/skills/algo-sc-safety-stock in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add asgard-ai-platform/skills --skill algo-sc-safety-stock -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/algo-sc-safety-stock, .gemini/skills/algo-sc-safety-stock, .github/skills/algo-sc-safety-stock and .opencode/skills/algo-sc-safety-stock in your project.
Going by SKILL.md and its folder, Algo Sc Safety Stock needs Python for the scripts in its folder and the command-line tools its instructions call (python). Our summary lists: Python 3.
SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. The check reads SKILL.md only: the scripts in the folder are not scanned, so read them before running anything.
Algo Sc Safety Stock is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 1.1k tokens (SKILL.md is roughly 4.5k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 5.7k tokens, read only when the agent opens those files.
Skills that share tags, products or a category with Algo Sc Safety Stock: Safety Stock Review (davila7/claude-code-templates, 33k stars), Buffer Calculator (aipoch/medical-research-skills, 1.9k stars), Lead Magnets (sickn33/agentic-awesome-skills, 47k stars) and Inventory Demand Planning (sickn33/agentic-awesome-skills, 47k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
asgard-ai-platform (a GitHub organization) maintains it in asgard-ai-platform/skills, which has 242 GitHub stars. The repository holds 207 skills in this directory. The repository was last updated on June 6, 2026.
Source: asgard-ai-platform/skills on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.