[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M7EJ1C6NA8E5PKERQJS9ZWR5":3,"skill-same:01M7EJ1C6NA8E5PKERQJS9ZWR5":63},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":31,"commitSha":32,"skillDirectory":33,"forksCount":14,"repositoryHtmlUrl":34,"repositoryHomepageUrl":34,"ownerHtmlUrl":35,"ownerBlogUrl":6,"ownerDescription":6,"updatedAt":36,"install":37,"resources":50},"01M7EJ1C6NA8E5PKERQJS9ZWR5","bayesian-hierarchical-process-models",null,">- Fit Bayesian hierarchical (multi-level) regression models on process data using PyMC: campaign \u002F regime random intercepts, censored likelihoods, AR(1) residuals, weakly informative priors. Use when you need calibrated uncertainty across regimes (campaigns, units, operators) or for partially poole","Mr-Nobody-Anonymous\u002FAll-skills","Mr-Nobody-Anonymous","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F184253119?v=4","01M7AEXFJHKTYQW5R0ZCQQTWFV","anonymous","01M7C00M3GQR4QKP9GZA42GFAK",0,"MIT","https:\u002F\u002Fgithub.com\u002FMr-Nobody-Anonymous\u002FAll-skills\u002Fblob\u002Fmain\u002Fawesome_skills\u002Fchemical-engineering\u002Fbayesian-hierarchical-process-models\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: bayesian-hierarchical-process-models\ndescription: \">- Fit Bayesian hierarchical (multi-level) regression models on process data using PyMC: campaign \u002F regime random intercepts, censored likelihoods, AR(1) residuals, weakly informative priors. Use when you need calibrated uncertainty across regimes (campaigns, units, operators) or for partially poole\"\ncategory: chemical-engineering\nversion: 1.0.0\ndisable-model-invocation: false\nrisk: low\nsource: \"https:\u002F\u002Fgithub.com\u002Fjskherman\u002Fengg-skills\"\nsource_repository: \"jskherman\u002Fengg-skills\"\nsource_path: \"skills\u002Fbayesian-hierarchical-process-models\u002FSKILL.md\"\nlicense: \"MIT\"\nimported_at: \"2026-09-20\"\n---\n# Bayesian Hierarchical Process Models\n\n## Overview\n\nFits hierarchical (multi-level) Bayesian regressions of the form\n\n    y_t | x_t, group ~ Normal(alpha_{group[t]} + x_t' beta, sigma)\n\nwith optional censoring on `y_t` and an AR(1) residual structure. Group\nintercepts are drawn from a hyperprior, enabling partial pooling across\nregimes.\n\nThe implementation uses PyMC (NUTS sampler) via a thin wrapper. The\nscript accepts a YAML model specification so analysts can iterate on\npriors and likelihoods without editing code.\n\n## Prerequisites\n\n1. `uv` available.\n2. The script declares `pymc`, `arviz`, `pandas`, `pyyaml` in PEP-723;\n   first run installs them (sizeable: ~500 MB combined).\n3. On first use, writes `LICENSE_NOTIFICATION.txt`.\n\n## When to Use\n\n- Data has natural groupings (campaigns, operators, instruments) and you\n  want partial pooling.\n- You need calibrated credible intervals that propagate censoring,\n  autocorrelation, and shrinkage.\n- The model needs informative priors (e.g. from engineering judgement).\n\n## Don't use for\n\n- Plain OLS or single-level GLMs (`engineering-statistics`).\n- Time-series forecasting (use a dedicated state-space tool).\n- Extremely large datasets (>1M rows) without thinning — NUTS is not\n  designed for that scale.\n\n## Utility Scripts\n\n- `uv run scripts\u002Fbhm.py fit --data data.csv --spec spec.yaml --output \u002Ftmp\u002Ffit.json`\n\nExample spec.yaml:\n```yaml\nresponse: log_S_total\npredictors: [z_heavy, source_split, lean_loading]\ngroup: campaign\ncensoring:\n  lower_col: LOQ_log\nar1: true\npriors:\n  beta: {dist: normal, mu: 0, sigma: 5}\n  sigma: {dist: half_normal, sigma: 1}\n  tau_group: {dist: half_normal, sigma: 0.5}\nsampler:\n  draws: 2000\n  tune: 1000\n  chains: 4\n  target_accept: 0.95\n```\n\n## Procedure\n\n1. Build a tidy CSV: one row per observation; columns for response,\n   predictors, group, and censoring bounds.\n2. Write the spec YAML. Start with weakly informative priors.\n3. Run `fit`. Inspect:\n   - R-hat (should be \u003C 1.01 for all parameters).\n   - Effective sample size (ESS bulk and tail > 400).\n   - Divergences (should be 0).\n   - Posterior predictive checks.\n4. If diagnostics fail, increase `target_accept`, tighten priors, or\n   reparameterise.\n5. Report posterior means with 94% HDI; never report point estimates\n   alone.\n\n## Pitfalls\n\n- Using flat priors and being surprised by funnel shapes. Weakly\n  informative priors (e.g. `Normal(0, 5)` on standardised predictors) work\n  better.\n- Failing to standardise predictors; PyMC + NUTS works much better with\n  scaled inputs.\n- Treating the posterior mean as the only output; report the HDI.\n- Running with `chains=1`; convergence diagnostics need at least 2 chains.\n- Ignoring divergences; they indicate biased posterior geometry.\n- Using non-centred parameterisation for groups with many observations\n  but the centred version for groups with few; pick consistently and\n  re-fit if diagnostics fail.\n- Forgetting to write the InferenceData artefact (NetCDF) to disk —\n  re-fitting is expensive.\n\n## Fallback Strategies\n\n- If PyMC is unavailable, surface to the user; there is no clean\n  pure-Python fallback for hierarchical Bayesian with censoring.\n- For sensitivity, fit the same model with at least two prior choices and\n  compare.\n\n## Verification\n\n- Run the listed script with representative inputs and an `--output` file when a deterministic calculation is available.\n- Confirm the JSON result contains `ok: true`, expected units, and no unhandled warnings.\n- Check result magnitudes against the stated assumptions, references, and a hand calculation or known operating range before reporting them.\n\n## References\n\n- `references\u002Fspec_format.md` — full spec.yaml grammar.\n- Gelman, Carlin, Stern, Dunson, Vehtari, Rubin, *Bayesian Data Analysis*\n  (3rd ed).\n- PyMC docs: https:\u002F\u002Fwww.pymc.io\u002F\n\n## Anti-Patterns\n\n- Reporting Bayesian posterior intervals as if they were classical CIs\n  without naming the model.\n- Skipping convergence diagnostics.\n- Treating sampling failure as a tuning issue without reviewing the model\n  geometry.\n","# Bayesian Hierarchical Process Models\n\n## Overview\n\nFits hierarchical (multi-level) Bayesian regressions of the form\n\n    y_t | x_t, group ~ Normal(alpha_{group[t]} + x_t' beta, sigma)\n\nwith optional censoring on `y_t` and an AR(1) residual structure. Group\nintercepts are drawn from a hyperprior, enabling partial pooling across\nregimes.\n\nThe implementation uses PyMC (NUTS sampler) via a thin wrapper. The\nscript accepts a YAML model specification so analysts can iterate on\npriors and likelihoods without editing code.\n\n## Prerequisites\n\n1. `uv` available.\n2. The script declares `pymc`, `arviz`, `pandas`, `pyyaml` in PEP-723;\n   first run installs them (sizeable: ~500 MB combined).\n3. On first use, writes `LICENSE_NOTIFICATION.txt`.\n\n## When to Use\n\n- Data has natural groupings (campaigns, operators, instruments) and you\n  want partial pooling.\n- You need calibrated credible intervals that propagate censoring,\n  autocorrelation, and shrinkage.\n- The model needs informative priors (e.g. from engineering judgement).\n\n## Don't use for\n\n- Plain OLS or single-level GLMs (`engineering-statistics`).\n- Time-series forecasting (use a dedicated state-space tool).\n- Extremely large datasets (>1M rows) without thinning — NUTS is not\n  designed for that scale.\n\n## Utility Scripts\n\n- `uv run scripts\u002Fbhm.py fit --data data.csv --spec spec.yaml --output \u002Ftmp\u002Ffit.json`\n\nExample spec.yaml:\n```yaml\nresponse: log_S_total\npredictors: [z_heavy, source_split, lean_loading]\ngroup: campaign\ncensoring:\n  lower_col: LOQ_log\nar1: true\npriors:\n  beta: {dist: normal, mu: 0, sigma: 5}\n  sigma: {dist: half_normal, sigma: 1}\n  tau_group: {dist: half_normal, sigma: 0.5}\nsampler:\n  draws: 2000\n  tune: 1000\n  chains: 4\n  target_accept: 0.95\n```\n\n## Procedure\n\n1. Build a tidy CSV: one row per observation; columns for response,\n   predictors, group, and censoring bounds.\n2. Write the spec YAML. Start with weakly informative priors.\n3. Run `fit`. Inspect:\n   - R-hat (should be \u003C 1.01 for all parameters).\n   - Effective sample size (ESS bulk and tail > 400).\n   - Divergences (should be 0).\n   - Posterior predictive checks.\n4. If diagnostics fail, increase `target_accept`, tighten priors, or\n   reparameterise.\n5. Report posterior means with 94% HDI; never report point estimates\n   alone.\n\n## Pitfalls\n\n- Using flat priors and being surprised by funnel shapes. Weakly\n  informative priors (e.g. `Normal(0, 5)` on standardised predictors) work\n  better.\n- Failing to standardise predictors; PyMC + NUTS works much better with\n  scaled inputs.\n- Treating the posterior mean as the only output; report the HDI.\n- Running with `chains=1`; convergence diagnostics need at least 2 chains.\n- Ignoring divergences; they indicate biased posterior geometry.\n- Using non-centred parameterisation for groups with many observations\n  but the centred version for groups with few; pick consistently and\n  re-fit if diagnostics fail.\n- Forgetting to write the InferenceData artefact (NetCDF) to disk —\n  re-fitting is expensive.\n\n## Fallback Strategies\n\n- If PyMC is unavailable, surface to the user; there is no clean\n  pure-Python fallback for hierarchical Bayesian with censoring.\n- For sensitivity, fit the same model with at least two prior choices and\n  compare.\n\n## Verification\n\n- Run the listed script with representative inputs and an `--output` file when a deterministic calculation is available.\n- Confirm the JSON result contains `ok: true`, expected units, and no unhandled warnings.\n- Check result magnitudes against the stated assumptions, references, and a hand calculation or known operating range before reporting them.\n\n## References\n\n- `references\u002Fspec_format.md` — full spec.yaml grammar.\n- Gelman, Carlin, Stern, Dunson, Vehtari, Rubin, *Bayesian Data Analysis*\n  (3rd ed).\n- PyMC docs: https:\u002F\u002Fwww.pymc.io\u002F\n\n## Anti-Patterns\n\n- Reporting Bayesian posterior intervals as if they were classical CIs\n  without naming the model.\n- Skipping convergence diagnostics.\n- Treating sampling failure as a tuning issue without reviewing the model\n  geometry.\n",{"name":5,"risk":24,"source":25,"license":15,"version":26,"category":27,"description":7,"imported_at":28,"source_path":29,"source_repository":30,"disable-model-invocation":20},"low","https:\u002F\u002Fgithub.com\u002Fjskherman\u002Fengg-skills","1.0.0","chemical-engineering","2026-09-20","skills\u002Fbayesian-hierarchical-process-models\u002FSKILL.md","jskherman\u002Fengg-skills","main","2d1750717747097b602acf30bd09a7cbd4b4c6ea","awesome_skills\u002Fchemical-engineering\u002Fbayesian-hierarchical-process-models","https:\u002F\u002Fgithub.com\u002FMr-Nobody-Anonymous\u002FAll-skills","https:\u002F\u002Fgithub.com\u002FMr-Nobody-Anonymous","2026-11-09 11:45:36",{"source":8,"skillName":5,"commands":38,"prompt":48,"zipAvailable":49},[39,42,45],{"tool":40,"command":41},"npx","npx skills add Mr-Nobody-Anonymous\u002FAll-skills --skill bayesian-hierarchical-process-models",{"tool":43,"command":44},"bunx","bunx skills add Mr-Nobody-Anonymous\u002FAll-skills --skill bayesian-hierarchical-process-models",{"tool":46,"command":47},"pnpm","pnpm dlx skills add Mr-Nobody-Anonymous\u002FAll-skills --skill bayesian-hierarchical-process-models","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002FMr-Nobody-Anonymous\u002FAll-skills\u002Fblob\u002Fmain\u002Fawesome_skills\u002Fchemical-engineering\u002Fbayesian-hierarchical-process-models\u002FSKILL.md",true,[51,57],{"path":52,"resourceType":53,"resourceTypeDesc":54,"sizeBytes":55,"sourceHtmlUrl":56},"references\u002Fspec_format.md","REFERENCE","参考文档",1559,"https:\u002F\u002Fgithub.com\u002FMr-Nobody-Anonymous\u002FAll-skills\u002Fblob\u002Fmain\u002Fawesome_skills\u002Fchemical-engineering\u002Fbayesian-hierarchical-process-models\u002Freferences\u002Fspec_format.md",{"path":58,"resourceType":59,"resourceTypeDesc":60,"sizeBytes":61,"sourceHtmlUrl":62},"scripts\u002Fbhm.py","SCRIPT","脚本",9824,"https:\u002F\u002Fgithub.com\u002FMr-Nobody-Anonymous\u002FAll-skills\u002Fblob\u002Fmain\u002Fawesome_skills\u002Fchemical-engineering\u002Fbayesian-hierarchical-process-models\u002Fscripts\u002Fbhm.py",[64,72,79,86,93,100],{"skillNo":65,"name":66,"nameZh":6,"description":67,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":68,"categories":69,"keywords":70,"publishedAt":71},"01M7FFFZPC2025JQQHPHDX154J","dei-assessment","Assess diversity, equity, and inclusion with metrics. TRIGGERS - Use when user needs help with dei-assessment related tasks.","https:\u002F\u002Fgithub.com\u002FMr-Nobody-Anonymous\u002FAll-skills\u002Fblob\u002Fmain\u002Fawesome_skills\u002Fhr-people\u002Fdei-assessment\u002FSKILL.md",[],[],"2026-11-16 10:05:34",{"skillNo":73,"name":74,"nameZh":6,"description":75,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":76,"categories":77,"keywords":78,"publishedAt":71},"01M7FFFWN8H4WA7A6Y398QKB6J","dei-action-plan","Create DEI action plans with goals and initiatives. TRIGGERS - Use when user needs help with dei-action-plan related tasks.","https:\u002F\u002Fgithub.com\u002FMr-Nobody-Anonymous\u002FAll-skills\u002Fblob\u002Fmain\u002Fawesome_skills\u002Fhr-people\u002Fdei-action-plan\u002FSKILL.md",[],[],{"skillNo":80,"name":81,"nameZh":6,"description":82,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":83,"categories":84,"keywords":85,"publishedAt":71},"01M7FFFSHTM0QZRVZ2NRJTJ0PY","culture-fit-assessment","Design culture add assessment processes. TRIGGERS - Use when user needs help with culture-fit-assessment related tasks.","https:\u002F\u002Fgithub.com\u002FMr-Nobody-Anonymous\u002FAll-skills\u002Fblob\u002Fmain\u002Fawesome_skills\u002Fhr-people\u002Fculture-fit-assessment\u002FSKILL.md",[],[],{"skillNo":87,"name":88,"nameZh":6,"description":89,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":90,"categories":91,"keywords":92,"publishedAt":71},"01M7FFFMA12RKEQA38KHJSXXPS","cowork-to-code-bridge","Use an already-installed, independently verified cowork-to-code bridge to run narrowly approved actions on the user's own macOS, Linux, or WSL2 machine through a local file queue.","https:\u002F\u002Fgithub.com\u002FMr-Nobody-Anonymous\u002FAll-skills\u002Fblob\u002Fmain\u002Fawesome_skills\u002Fhr-people\u002Fcowork-to-code-bridge\u002FSKILL.md",[],[],{"skillNo":94,"name":95,"nameZh":6,"description":96,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":97,"categories":98,"keywords":99,"publishedAt":71},"01M7FFFH1F6M8YRGW5V487GH1K","counter-offer-response","Draft counter-offer responses for retention. TRIGGERS - Use when user needs help with counter-offer-response related tasks.","https:\u002F\u002Fgithub.com\u002FMr-Nobody-Anonymous\u002FAll-skills\u002Fblob\u002Fmain\u002Fawesome_skills\u002Fhr-people\u002Fcounter-offer-response\u002FSKILL.md",[],[],{"skillNo":101,"name":102,"nameZh":6,"description":103,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":104,"categories":105,"keywords":106,"publishedAt":71},"01M7FFFDGEHV8Y7J9N40HZXW52","continuous-feedback-system","Design continuous feedback systems. TRIGGERS - Use when user needs help with continuous-feedback-system related tasks.","https:\u002F\u002Fgithub.com\u002FMr-Nobody-Anonymous\u002FAll-skills\u002Fblob\u002Fmain\u002Fawesome_skills\u002Fhr-people\u002Fcontinuous-feedback-system\u002FSKILL.md",[],[]]