ointment-rheology-analysis

For rheological analysis of ointments (semi-solid topical formulations): accepts rotational rheometer data (e.g., Kinexus/Malvern) such as steady flow, frequency/amplitude/temperature scans, creep recovery, thixotropic hysteresis loops, 3ITT in CSV or screenshots. Triggers when the user requests “fit rheological models,” “analyze yield stress/thixotropy,” “assess spreadability–stability–residence–drug release,” “compare multiple formulations,” or “give optimization suggestions.” Performs mandatory multi-model comparison (Herschel–Bulkley, Bingham, Casson, generalized Maxwell, Burgers, thixotropic models), uses scipy for actual fitting, and links results to ointment application performance. Guided by Chinese Pharmacopoeia general rule 0115 and supports Netzsch CSV with Chinese headers (analyze_netzsch.py). Instrument software template/model code mapping is in references/instrument_model_mapping.md.

Installation

Review the source and dependencies with a prompt.

Install with an AI assistant

Copy the prompt so your assistant can review the pinned revision and dependencies first.

View promptHide prompt
Check whether SkillPI Skill Finder is installed for your current agent. If it is missing, install and enable it using the official instructions at https://github.com/Findskills/skillpi. Then use Skill Finder to locate and install "ointment-rheology-analysis" from this exact SkillPI detail page: https://skillpi.com/skills/deepskill-52d429961449faafb29004d1aeb9c7870fcddd89e8f642756b932019df98cfde. Verify the upstream source and version against https://skillhub.cn/skills/user_c160f2b7/ointment-rheology-analysis before installing. If they do not match, stop and report the mismatch. Report the installed path and source version.

Download permission for this version is unverified or restricted.

Source and setup

skillhub.cn

Setup guidance pending

See the original source for supported tools, dependencies, and permissions.

Installation test pending

For rheological analysis of ointments (semi-solid topical formulations): accepts rotational rheometer data (e.g., Kinexus/Malvern) such as steady flow, frequency/amplitude/temperature scans, creep recovery, thixotropic hysteresis loops, 3ITT in CSV or screenshots. Triggers when the user requests “fit rheological models,” “analyze yield stress/thixotropy,” “assess spreadability–stability–residence–drug release,” “compare multiple formulations,” or “give optimization suggestions.” Performs mandatory multi-model comparison (Herschel–Bulkley, Bingham, Casson, generalized Maxwell, Burgers, thixotropic models), uses scipy for actual fitting, and links results to ointment application performance. Guided by Chinese Pharmacopoeia general rule 0115 and supports Netzsch CSV with Chinese headers (analyze_netzsch.py). Instrument software template/model code mapping is in references/instrument_model_mapping.md.

0 Downloads

Introduction source: third_party · user_c160f2b7 · 1.0.2 Reference

SkillPi interpretation

Tasks
Translation pending; see source documentation.
Audience
Not specified in the source documentation.
Inputs and outputs
Not specified in the source documentation.
Software, accounts and paid services
python -m venv venv && venv/Scripts/python -m pip install numpy scipy matplotlib PY=venv/Scripts/python bash
Limits and differences
Not specified in the source documentation.
Testing
Not tested

Browse files

A verified file list is not available on Skillπ yet.

Browse files at the source ↗

Original SKILL.md

Open original ↗
Frontmatter
name: ointment-rheology-analysis
description: 软膏剂(半固体外用制剂)流变学分析技能。当用户提供 Kinexus(Malvern)等旋转流变仪数据(稳态流动/频率扫描/振幅扫描/温度扫描/蠕变回复/触变迟滞环/3ITT,CSV 或截图),并要求"拟合流变模型""分析屈服应力/触变性""判断涂展性-稳定性-滞留-药物释放""对比多组配方""给出优化建议"时触发。强制多模型对比(Herschel-Bulkley/Bingham/Casson/广义 Maxwell/Burgers/触变),用 scipy 实际拟合并关联软膏剂应用性能。中国药典通则 0115 导向。耐驰(Netzsch) 中文表头 CSV 亦支持(analyze_netzsch.py)。仪器软件模板/模型码对照见 references/instrument_model_mapping.md。
agent_created: true

软膏剂(半固体外用制剂)流变学分析技能

概述

本技能模拟一位资深半固体外用制剂(软膏剂)流变学专家:接收旋转流变仪实测数据, 用多种流变学模型实际拟合(scipy,非肉眼估参),对比各模型的拟合优度与参数物理意义, 将粘弹性参数转化为屈服应力、触变性、涂展性、稳定性(抗沉降/抗分层)、皮肤滞留/附着、 药物释放、挤出性、使用感等软膏剂关键应用性能,并给出配方/工艺优化建议。

与 HMPSA 技能的区别:HMPSA 关注初粘-剥离-持粘-涂布(热熔胶),软膏剂关注 屈服应力 + 触变 + 涂展/稳定/滞留/释放平衡(半固体药剂)。因此本技能以 屈服应力模型(Herschel-Bulkley/Bingham/Casson)与触变(迟滞环/3ITT)为核心, 并以《中国药典》通则 0115 软膏剂为判读框架。

触发条件

当用户表达以下意图时触发:

  • "帮我拟合这份流变数据 / 分析这个流动曲线"
  • "用 Herschel-Bulkley / Bingham / Casson 拟合屈服应力"
  • "这块软膏的涂展性、稳定性、滞留怎么样(结合流变)"
  • "对比这几组软膏配方的流变差异 / 为什么 A 比 B 难涂"
  • "测了触变环 / 3ITT,结构恢复率多少"
  • "温度扫描 / 软化点 / 时温叠加 / WLF"
  • "按药典 0115 评价这个软膏的稠度/稳定性"
  • 提交了流变 CSV(或贴出截图让其转写)并要求分析

一、数据接收与识别

  1. 识别测试模式(见下表),先向用户明确说明识别出的模式,再建模。
  2. 截图数据:先转写为 CSV(列名见下),再喂引擎;转写后请用户复核关键数值。
  3. 多组配方数据:对每组独立建模,最后横向对比(见第五节)。
测试模式 识别列 必需列 单位约定
稳态流动 shear_rate + (stress 或 eta) shear_rate(s⁻¹) 给 eta 则 τ=η·γ̇
频率扫描 freq + (Gp/Gpp 或 eta_star) freq(rad/s) ω=2πf;给 Hz 先×2π
振幅扫描 strain + Gp + Gpp 三者 strain=幅值 γ₀
温度扫描 temp + (tan_delta 或 Gp/Gpp) temp 单温→软化点;多温块(freq)→TTS
蠕变回复 time + J 二者 t(s);creep_time=加载时长
触变迟滞环 shear_rate + stress_up + stress_down 三者 上/下行同 γ̇ 网格
三段触变 time + Gp 二者 需 --t1/--t2 定区间边界

列规范、单位陷阱、多模型方程与物理意义详见 references/rheology_models.md(按模式读取对应章节)。 仪器软件模板/模型码对照(本用户仪器 Kinexus/Malvern,七种模式 ↔ 测量模板码与分析拟合模型码)详见 references/instrument_model_mapping.md,完整中英文模型清单见 assets/kinexus_model_mapping.csv。

二、多模型拟合与分析框架

强制要求:对识别出的模式,使用多种模型拟合并对比(R²/SSE + 参数物理意义)。 所有拟合通过脚本执行(真实数值),命令见"执行流程"。模型覆盖建议:

稳态流动 → steady(软膏剂核心)

  • Herschel-Bulkley(赫歇尔-巴尔克莱) τ=τ₀+K·γ̇ⁿ:τ₀ 屈服应力、K 稠度、n 流动指数。软膏剂最常用,含屈服应力 + 剪切变稀。
  • Bingham τ=τ₀+η_p·γ̇:近似线性膏体(O/W 乳膏)。
  • Casson √τ=√τ₀+√(η_c·γ̇):含分散相(悬浮/乳状)体系常优于线性 Bingham。
  • 幂律(无屈服) τ=K·γ̇ⁿ:简化中剪切段,低剪切端常欠拟合。
  • Cross(粘度函数)η(γ̇):取 η∞(高剪切极限)评价挤出性。
  • 自动计算特征剪切速率下的应用关联:屈服应力 τ₀、η_app(10 s⁻¹)(涂展性代表)、η_app(500 s⁻¹)(挤出性代表),并给定性判读。

频率扫描 → frequency

  • 广义 Maxwell(离散松弛谱,默认 4 模式):给 (gᵢ,τᵢ) 与谱宽 log₁₀(τmax/τmin);谱越宽 ⇒ 结构时间尺度覆盖越广。
  • 类固/类液判定:tanδ(1Hz)=G''(1Hz)/G'(1Hz);tanδ<1 弹性主导(结构强/稳定但偏硬),tanδ>1 粘性主导(易铺展但弱)。
  • 交叉频率 ω_c(G'=G''):其倒数反映特征松弛;软膏剂常希望 G'>G'' 覆盖全频(无交叉)以保证结构。

振幅扫描 → amplitude

  • LVE 临界应变 γ_LVE(G' 跌破 0.95 平台)、流动点应变 γ_y(G'=G'' 交叉=振荡屈服应变)。
  • γ_LVE / γ_y 越大 ⇒ 结构网络越强(蜡晶/乳化膜/填料),越能承受变形而不流。

温度扫描 → temperature

  • 软膏剂无明确 Tg,关注软化点:用 tanδ 峰值或 G' onset(5%) 定软化/熔化温度(二者物理定义不同,必须标明用哪条)。
  • 多温频率块 ⇒ TTS + WLF:移位因子 a_T → C₁/C₂ → 自由体积 f_g/α_f → master curve, 评估"储存 25°C ↔ 皮肤 32–35°C"的稠度变化是否在可接受范围。

蠕变回复 → creep

  • Burgers 四参数:J₀(瞬时)、η₀(零切)、J₁(延迟)、τ₁(延迟时间)。
  • 计算回复率(可回复柔量/总柔量):越高 ⇒ 撤力后越回弹/保持形状(挤出回弹、涂抹后部分恢复)。

触变性 → thixotropy / three_itt

  • 迟滞环:上/下行 τ 曲线包围面积 = 触变指数;面积越大剪切中破坏越多、恢复越慢(适度触变利于"涂时变稀、静置重建")。
  • 3ITT 三段触变:结构恢复率% = G'(恢复段末)/G'(静置段末)×100%;越高涂抹后网络越快重建,储存稳定、抗沉降。

三、软膏剂应用性能关联(ChP 0115 导向)

以下为经验参考区间,取决于基质类型(油脂性/乳剂/水溶性)、含药量、用药部位与工艺; 正式放行以企业内控标准与药典方法为准。引擎输出为"诊断线索",不是合规判定。

  • 涂展性/易涂性:由 τ₀ 与 η_app(10 s⁻¹) 综合。τ₀ 适中(~20–200 Pa) + n 较小(剪切变稀明显) ⇒ 一涂就开;τ₀ 过高(>~500 Pa) ⇒ 难揉开(顺从性差)。
  • 稳定性(抗沉降/抗分层):需足够 τ₀ 与低频 G' 平台支撑分散相(药物粒子/内相液滴);τ₀ 过低或 tanδ 长期 >1 ⇒ 储存期沉降/乳膏破乳风险。
  • 皮肤滞留/附着:适度 τ₀ + 弹性(G') 使膜贴肤、抗流挂;过高 ⇒ 膜硬使用感差;过低 ⇒ 自流、蹭掉。
  • 药物释放:通常低粘度/高涂展/弱结构 ⇒ 扩散阻力小、释放偏快(尤其水溶性/乳剂基质);油脂性凡士林基质释放慢、偏封闭。释放还强烈依赖药物溶解度与分配系数,流变只是因素之一。
  • 挤出性:由高剪切端 η∞ 或 η_app(500 s⁻¹) 评价;过低 ⇒ 管装易自流,过高 ⇒ 难挤。
  • 使用感/感官:类固弹性(tanδ<1 但不过低) 偏"膏体感"、不油腻易铺;过低 G' 偏"水/稀";凡士林类天然偏"油蜡感"。流变可辅助但需结合感官评价。

四、配方对比与优化建议

多组配方时:

  1. 用表格汇总各模型关键参数:τ₀、K、n、η_app(10)、η∞、tanδ(1Hz)、γ_LVE、γ_y、回复率/恢复率、软化点、谱宽。
  2. 通过参数变化,揭示组分(凡士林/蜡比例、乳化剂类型与用量、液状石蜡/油含量、增稠剂、含药量)如何影响屈服应力、触变与粘弹平衡。
  3. 基于"涂展性–稳定性–滞留–释放四者平衡**"原则,指出当前配方优缺点,并给出调整建议 (如增蜡↑τ₀↑稳定性但损涂展;加液状石蜡↓粘度↑涂展但损稳定),预测调整将如何改变上述模型参数。
  4. 关联 ChP 0115 软膏剂通则(均匀细腻、无刺激性、稠度适宜、易涂布、稳定性)给出放行/工艺建议。

典型材料的经验作用方向(解释用,非拟合依据):凡士林/石蜡/微晶蜡↑→τ₀↑、硬度↑、稳定性↑、封闭性↑、涂展↓ 液状石蜡/轻质油↑→粘度↓、涂展↑、但稳定性/滞留↓ O/W 乳化剂成膜→提供界面屈服、稳定内相 增稠剂(CMC/卡波姆/黄原胶)↑→τ₀↑、触变↑、悬浮力↑

五、报告格式要求

  • 每条分析必须含模型名、方程、参数表、拟合优度(R²/SSE)。引擎自动输出,无需手算。
  • 优先用代码实际拟合(已内置 scripts/rheology_fit.py,scipy 真实拟合 + 可选 matplotlib 图表)。 若确无执行环境,则提供拟合步骤、预估参数范围与曲线趋势的定量描述(不编造精确数字)。
  • 用通俗语言解释专业结论,保留必要术语,使流变学基础薄弱的用户也能理解分析逻辑。
  • 结尾生成"AI 流变诊断总结":用 5 条要点概括核心发现与行动建议。
  • HTML 报告生成:scripts/make_report.py 可一键生成单文件离线 HTML 报告,含图表 (matplotlib base64,无 CDN 依赖)与软膏剂应用诊断。
  • 数据来源与仪器:本用户仪器为 Kinexus(Malvern),导出英文表头 CSV 可直接用 rheology_fit.py 读取(见“执行流程”)。耐驰(Netzsch) 中文表头 CSV 仍支持:scripts/analyze_netzsch.py 自动识别模式、单位换算,输出单文件 HTML 报告(零 JS 依赖),含 AI 诊断与配方/工艺指导(非本机时的备选路径)。仪器软件模板/模型码对照见 references/instrument_model_mapping.md。

执行流程(实际操作)

加载脚本:scripts/rheology_fit.py。运行环境(任选其一):

# 方式一:直接用 PATH 上的 python(需已装 numpy/scipy,绘图另需 matplotlib)
PY=python
SK="C:\Users\Administrator\.workbuddy\skills\ointment-rheology-analysis__skillhub"

# 方式二:无科学栈时自建 venv(推荐,隔离不污染环境)
python -m venv venv && venv/Scripts/python -m pip install numpy scipy matplotlib
PY=venv/Scripts/python

若环境无 numpy/scipy:先 python -m venv <venv> 并在其中 pip install numpy scipy (绘图需 matplotlib,用 --plot 触发;缺失则跳过并提示)。

按识别的模式调用对应子命令,先跑再解读:

# 稳态流动(核心入口):屈服应力模型(HB/Bingham/Casson/幂律) + Cross + 应用关联
$PY $SK/scripts/rheology_fit.py steady --data <稳态CSV> [--plot] [--format json]

# 频率扫描:G'/G''/tanδ、类固-类液判定、广义 Maxwell + 应用关联
$PY $SK/scripts/rheology_fit.py frequency --data <频率CSV> [--modes 4] [--plot]

# 振幅扫描:LVE 临界应变、流动点(G'=G''交叉)
$PY $SK/scripts/rheology_fit.py amplitude --data <振幅CSV> [--plot]

# 温度扫描:软化点判定;含多温频率块则自动 WLF-TTS
$PY $SK/scripts/rheology_fit.py temperature --data <温度CSV> [--tref 32]

# 蠕变回复:Burgers + 回复率
$PY $SK/scripts/rheology_fit.py creep --data <蠕变CSV> [--creep-time 1000] [--plot]

# 触变迟滞环:面积/归一化触变指数
$PY $SK/scripts/rheology_fit.py thixotropy --data <触变CSV>

# 三段触变测试 3ITT:结构恢复率%
$PY $SK/scripts/rheology_fit.py three_itt --data <3ITT_CSV> [--t1 60] [--t2 120]
  • 加 --format json 输出机器可读结果(便于进一步编排/表格汇总)。
  • 样例数据见 assets/sample_*.csv(稳态/频率/振幅/蠕变/触变/温度TTS),可直接运行演示。
  • 复现样例:$PY $SK/scripts/gen_sample_data.py(重写 assets 样例,叠加 ~2% 噪声)。

一键生成 HTML 报告

# 耐驰(Netzsch) CSV(含中文章头)→ 自动识别模式 → 单文件 HTML 报告(非本机 Kinexus 时的备选路径)
$PY $SK/scripts/analyze_netzsch.py --data <耐驰CSV路径> [--outdir .] [--mode frequency]

# 混合任意模式 CSV → 单文件综合 HTML 报告
$PY $SK/scripts/make_report.py \
  --steady   <稳态CSV> \
  --frequency <频率CSV> \
  --amplitude <振幅CSV> \
  --creep    <蠕变CSV> \
  --thixotropy <触变CSV> \
  --temp     <温度CSV> \
  --outdir .

六、边界与诚实性

  1. 数据质量优先:单位不一致(Hz vs rad/s、Pa vs kPa、应力 vs 粘度)是最常见错误源;先核对单位,引擎不猜测性换算。
  2. R² 高 ≠ 模型正确:平台区偏离、外推、过参数化都会误导;优先对比物理可比量(τ₀、n、η_app)。
  3. 过参数化警示:广义 Maxwell(2N 参)、WLF(窄温区)参数不唯一,仅供定性/趋势,勿当精确物性常数。
  4. 数据不足:仅 3~4 个点时引擎会警告并改用定性描述,绝不假装精确拟合。
  5. 模型是手段不是目的:最终落点是"涂展–稳定–滞留–释放平衡"与可执行的配方/工艺调整建议。
  6. 药典边界:本技能提供流变诊断线索,不替代《中国药典》0115 的法定检验(锥入度、粒度、装量、无菌等)。
  7. 截图转写风险:OCR/手输数值可能偏差,转写后请用户复核关键数据点。

典型场景

  • 场景 A(诊断):单组稳态流动 → 屈服应力多模型拟合 → τ₀/η_app 评价涂展性与屈服水平 → 诊断短板。
  • 场景 B(对比):多组软膏流变数据 → 参数汇总表 → 揭示组分影响 → 给出平衡优化方向。
  • 场景 C(温度):多温频率扫描 → WLF 主曲线 → 评估储存 25°C ↔ 皮肤 32–35°C 稠度窗口。
  • 场景 D(结构):振幅 + 触变环/3ITT → 判定网络强度与剪切后恢复能力(抗沉降/抗流挂)。

Current listing version

1.0.2

Verify the source revision ↗

Safety and assessment details

Quality assessment

Out of 100 · Assessment report from SkillPi LAB.

Scenario Value88/100

Highlights

  • 针对软膏剂流变学分析这一制药研发高频刚需场景,提供多模型拟合与药典导向的应用性能关联
  • 强制多模型对比(Herschel-Bulkley/Bingham/Casson/Maxwell/Burgers/触变),确保分析深度与可靠性
Trigger Precision92/100

Highlights

  • 触发词覆盖全面且边界清晰,涵盖拟合、屈服应力、触变性、涂展性、稳定性、药典 0115 等核心需求
  • description 位置正确、内容完整,无截断或错位
Structure and Standards90/100

Areas to improve

  • 缺少显式 When to Use 章节 Reported severity: Minor

    文档未设置独立 'When to Use' 章节,尽管触发条件已详细描述

    Recommendation: 建议在概述后增加显式 'When to Use' 小节,提升用户快速定位效率

Highlights

  • 结构完整,分六大部分,每部分有清晰子步骤与端到端示例
  • frontmatter 完整,单文件长度合理(约 480 行)
Execution Reliability89/100

Highlights

  • 工具来源明确(scipy、matplotlib),参数定义清晰,覆盖单位陷阱、数据不足等主要异常
  • 提供多脚本路径与样例数据,支持 Kinexus 和 Netzsch 双仪器格式
Evidence Verifiability (mean of the first four)90/100

The arithmetic mean of the first four original scores, rounded to a whole number.

Static text checks

100 / 100 · skillpi-20261123-no-r3-v1

No current rules matched the text.

This score reflects rule matches in the text and is provided for reference before use. It excludes attachments and runtime behavior.

Permissions and checks before use

Automatically summarized from this main document. Matches may be examples or defensive advice; they are not actual permission declarations. Attachments, external dependencies and runtime behavior are not covered.

  • Install or fetch external dependencies

    Use official sources and pin versions. Check install scripts in an isolated environment. This document check does not cover code downloaded later.

    Mentioned in main document · lines 136, 140
  • Administrator or elevated privileges

    Elevate only when necessary. Keep protection and certificate validation enabled and avoid broad system access.

    Mentioned in main document · lines 133

These notices grant no permissions. Your host tool must still confirm file changes, secrets, external transfers or costs as needed.

Security rating and access scope

risk · Static evidence review; not a runtime safety guarantee.

python -m venv venv && venv/Scripts/python -m pip install numpy scipy matplotlib PY=venv/Scripts/python bash

Before use, confirm and authorize actual file access, external services and network destinations in your host. This review grants no runtime permissions.