TcmMycotoxinsProfileQualityChecker
Tcm Mycotoxins Profile
ℹ️ Utility checks content of major mycotoxins according to ChP 2020 (Chapter 2351) and EU regulations:
• Aflatoxin B1: ≤5 ppb (μg/kg)
• Aflatoxin total (B1+B2+G1+G2): ≤10 ppb
• Ochratoxin A: ≤5 ppb
• Fumonisin B1: ≤100 ppb
• Zearalenone: ≤50 ppb
• Deoxynivalenol (DON): ≤500 ppb
• T-2 toxin: ≤10 ppb
⚠️ CRITICAL: Aflatoxins are potent hepatocarcinogens with cumulative effect!
Mycotoxins are HEAT-STABLE: they are not destroyed by drying, boiling or extraction.
Exceedance of limits requires immediate batch disposal — purification is impossible!
Usage:
TcmMycotoxinsProfileQualityChecker.exe → demo mode (console output)
TcmMycotoxinsProfileQualityChecker.exe input.csv output.json → evaluate your data
Input format:
BatchNumber,HerbName,Aflatoxin_B1_ppb,Aflatoxin_Total_ppb,Ochratoxin_A_ppb,Fumonisin_B1_ppb,Zearalenone_ppb,Deoxynivalenol_ppb,T2_Toxin_ppb,Recovery_AFB1_Percent
Example:
TCM-COIX-2026-MYC-001,Coix_lacryma_jobi,1.2,2.5,1.5,50.0,30.0,200.0,5.0,92.5
High-risk raw materials:
• Coix_lacryma_jobi (Coix seeds) — high risk of aflatoxins and fumonisins
• Nelumbo_nucifera (Lotus seeds) — prone to molding during storage
• Glycyrrhiza_uralensis (Licorice) — risk of ochratoxin A
• Zingiber_officinale (Ginger) — aflatoxins with improper drying
• All seeds, nuts and fruits with high starch/oil content
— WHY IS THIS NEEDED?
Mycotoxins are the most dangerous hidden threat in herbal raw materials:
• Produced by mold fungi (Aspergillus, Penicillium, Fusarium) during storage
• Have carcinogenic, nephrotoxic, neurotoxic and immunosuppressive effects
• Tasteless, odorless and colorless, cannot be detected organoleptically
• Stable to high temperatures and acids — not removed during extract production
• Regulated at ppb (parts per billion) level due to extreme toxicity
⚠️ CRITICAL:
• Aflatoxin B1 ≤5 ppb — IARC Group 1 carcinogen, causes liver cancer
• Aflatoxin total ≤10 ppb — synergistic effect of four analogues
• Ochratoxin A ≤5 ppb — nephrotoxin, linked to Balkan endemic nephropathy
• Fumonisin B1 ≤100 ppb — neurotoxin, esophageal carcinogen
• Zearalenone ≤50 ppb — estrogen-like mycotoxin, reproductive dysfunction
• DON ≤500 ppb — vomitoxin, protein synthesis inhibitor
• T-2 toxin ≤10 ppb — most toxic trichothecene, hematopoietic system damage
Key features:
• Multi-residue analysis of 7 key mycotoxins
• Strict limits at ppb level to guarantee safety
• Support for raw materials with different risk profiles
• Method recovery control for result reliability
• Immediate rejection upon any exceedance
Critical parameters:
• Aflatoxin B1: ≤5 ppb
• Aflatoxin total: ≤10 ppb
• Ochratoxin A: ≤5 ppb
• Fumonisin B1: ≤100 ppb
• Zearalenone: ≤50 ppb
• DON: ≤500 ppb
• T-2 toxin: ≤10 ppb
💡 Usage tips:
1. Analysis performed by LC-MS/MS or HPLC-FLD with post-column derivatization
2. Sampling is critical: mycotoxins are unevenly distributed ("hot spots"), use representative samples ≥1 kg
3. Immunoaffinity cleanup (IAC) is mandatory for complex TCM matrices
4. Recovery control (70-120%) confirms absence of matrix effects
5. Store raw materials at moisture <12% and temperature <15°C to prevent mycotoxin formation
⚠️ Note: Unlike heavy metals or pesticides, mycotoxins form UNPREDICTABLY during storage even from initially clean raw materials. One batch may be safe while the next is deadly dangerous. Therefore, mycotoxin control must be performed for EVERY incoming raw material batch, especially for seeds and fruits. This is the only TCM quality parameter where limit exceedance means IMPOSSIBILITY of using raw material in any form.
input.csv
BatchNumber,HerbName,Aflatoxin_B1_ppb,Aflatoxin_Total_ppb,Ochratoxin_A_ppb,Fumonisin_B1_ppb,Zearalenone_ppb,Deoxynivalenol_ppb,T2_Toxin_ppb,Recovery_AFB1_Percent TCM-COIX-2026-MYC-001,Coix_lacryma_jobi,1.2,2.5,1.5,50.0,30.0,200.0,5.0,92.5 TCM-LICORICE-2026-MYC-002,Glycyrrhiza_uralensis,0.8,1.5,3.2,20.0,10.0,150.0,2.0,96.0 TCM-LOTUS-FAIL-2026-003,Nelumbo_nucifera,6.5,12.0,8.0,150.0,80.0,600.0,15.0,88.0 TCM-GINSENG-2026-MYC-004,Panax_ginseng,0.5,1.0,0.8,10.0,5.0,50.0,1.0,98.5
TcmMycotoxinsProfileQualityChecker — URS & FS
TCM Mycotoxins Profile Quality Checker
TCM Mycotoxins Profile Quality Checker
1. Назначение документа
Документ описывает пользовательские требования (URS) и функциональную спецификацию (FS) для утилиты TcmMycotoxinsProfileQualityChecker. Утилита предназначена для детерминированной проверки данных input.csv, формирования структурированного результата output.json и поддержки прослеживаемого QA/QC review.
Документ является проектной URS/FS-основой для CSV/CSA, IQ/OQ/PQ и дальнейшей валидации в контексте конкретной лабораторной процедуры.
2. Исходное описание утилиты
3. URS — пользовательские требования
3.1 Цель и область применения
Система должна принимать табличные результаты лабораторного контроля, выполнять проверку по заранее заданным критериям и возвращать понятный статус по каждой серии/записи: Pass, Review или Fail.
3.2 Нормативная / методическая база
В исходном описании и правилах утилиты используются следующие ориентиры: ChP 2020, ChP, EP, ICH, EMA. Финальные лимиты должны быть подтверждены утверждённой спецификацией, монографией, SOP или протоколом трансфера метода.
3.3 Ключевые QC-проверки
- Афлатоксин B1: ≤5 ppb (мкг/кг)
- Афлатоксин сумма (B1+B2+G1+G2): ≤10 ppb
- Охратоксин А: ≤5 ppb
- Фумонизин B1: ≤100 ppb
- Зеараленон: ≤50 ppb
- Дезоксиниваленол (DON): ≤500 ppb
- Т-2 токсин: ≤10 ppb
- Coix_lacryma_jobi (Семена коикса) — высокий риск афлатоксинов и фумонизинов
3.4 Пользователи
- QC analyst — подготовка и загрузка
input.csv. - QA/QC reviewer — проверка результата и отклонений.
- CSV/validation specialist — подтверждение пригодности утилиты.
- System owner — управление версией, доступом и изменениями.
3.5 Требования к данным и Data Integrity
- каждая строка CSV должна быть прослеживаемой к серии, образцу или измерению;
- исходные значения не должны изменяться утилитой;
- расчёты должны быть воспроизводимыми при повторном запуске;
- любое отклонение должно сохраняться как структурированное finding с указанием поля и правила;
- ручное изменение итогового статуса вне QA-процесса не допускается.
4. FS — функциональная спецификация
4.1 Поток обработки
- Проверить наличие и кодировку
input.csv. - Проверить заголовки, обязательные поля и типы данных.
- Нормализовать числовые и булевы значения без изменения исходного следа.
- Выбрать набор правил по категории продукта/типа, если он предусмотрен.
- Сравнить значения с лимитами и вычислить derived metrics.
- Сформировать запись результата по каждой строке.
- Сохранить
output.jsonс общей сводкой, findings и traceability.
4.2 CSV-схема
| № | Поле CSV | Тип | Обяз. | Назначение |
|---|---|---|---|---|
| 1 | BatchNumber | string | Да | Идентификатор серии / лота для прослеживаемости. |
| 2 | HerbName | string | Да | Идентичность продукта, препарата или образца. |
| 3 | Aflatoxin_B1_ppb | decimal | Да | Измеренный аналитический результат для сравнения с критерием приемлемости. |
| 4 | Aflatoxin_Total_ppb | decimal | Да | Измеренный аналитический результат для сравнения с критерием приемлемости. |
| 5 | Ochratoxin_A_ppb | decimal | Да | Измеренный аналитический результат для сравнения с критерием приемлемости. |
| 6 | Fumonisin_B1_ppb | decimal | Да | Измеренный аналитический результат для сравнения с критерием приемлемости. |
| 7 | Zearalenone_ppb | decimal | Да | Измеренный аналитический результат для сравнения с критерием приемлемости. |
| 8 | Deoxynivalenol_ppb | decimal | Да | Измеренный аналитический результат для сравнения с критерием приемлемости. |
| 9 | T2_Toxin_ppb | decimal | Да | Измеренный аналитический результат для сравнения с критерием приемлемости. |
| 10 | Recovery_AFB1_Percent | decimal | Да | Измеренный аналитический результат для сравнения с критерием приемлемости. |
4.3 Пример входных данных
| BatchNumber | HerbName | Aflatoxin_B1_ppb | Aflatoxin_Total_ppb | Ochratoxin_A_ppb | Fumonisin_B1_ppb | Zearalenone_ppb | Deoxynivalenol_ppb | T2_Toxin_ppb | Recovery_AFB1_Percent |
|---|---|---|---|---|---|---|---|---|---|
| TCM-COIX-2026-MYC-001 | Coix_lacryma_jobi | 1.2 | 2.5 | 1.5 | 50.0 | 30.0 | 200.0 | 5.0 | 92.5 |
| TCM-LICORICE-2026-MYC-002 | Glycyrrhiza_uralensis | 0.8 | 1.5 | 3.2 | 20.0 | 10.0 | 150.0 | 2.0 | 96.0 |
| TCM-LOTUS-FAIL-2026-003 | Nelumbo_nucifera | 6.5 | 12.0 | 8.0 | 150.0 | 80.0 | 600.0 | 15.0 | 88.0 |
| TCM-GINSENG-2026-MYC-004 | Panax_ginseng | 0.5 | 1.0 | 0.8 | 10.0 | 5.0 | 50.0 | 1.0 | 98.5 |
4.4 Выходной JSON
{
"utility": "TcmMycotoxinsProfileQualityChecker",
"runId": "urn:fuzkk:run:example",
"sourceFile": "input.csv",
"recordsProcessed": 4,
"overallStatus": "Pass / Review / Fail",
"records": [
{
"recordId": "TCM-COIX-2026-MYC-001",
"status": "Pass / Review / Fail",
"criticalFindings": [],
"warnings": [],
"evaluatedRules": [
"Configured acceptance criteria from the utility rule set"
],
"inputTrace": {
"BatchNumber": "TCM-COIX-2026-MYC-001",
"HerbName": "Coix_lacryma_jobi",
"Aflatoxin_B1_ppb": "1.2",
"Aflatoxin_Total_ppb": "2.5",
"Ochratoxin_A_ppb": "1.5",
"Fumonisin_B1_ppb": "50.0",
"Zearalenone_ppb": "30.0",
"Deoxynivalenol_ppb": "200.0"
}
}
],
"dataIntegrity": {
"deterministicEvaluation": true,
"sourceRowTraceability": true,
"manualOverrideAllowed": false
}
}
5. Трассировка URS → FS → тесты
| URS | FS-механизм | Проверка |
|---|---|---|
| Загрузка корректного input.csv | CSV parser + schema validator | OQ: валидный/невалидный CSV |
| Детерминированная оценка лимитов | Rule engine с фиксированной конфигурацией | OQ: граничные значения и known expected results |
| Статусы Pass/Review/Fail | Status aggregator по findings | OQ/PQ: образцы с проходными и провальными сериями |
| Прослеживаемость к исходной строке | inputTrace + recordId | PQ: сверка output.json с исходным CSV |
| Поддержка QA review | структурированные findings и warnings | PQ: review сценарии и deviation handling |
6. CSV/CSA и валидационный подход
IQ
- проверка версии утилиты;
- проверка расположения исполняемого файла;
- проверка шаблона CSV;
- контроль прав доступа.
OQ
- проверка обязательных полей;
- проверка типов данных;
- проверка граничных значений;
- проверка zero-tolerance правил.
PQ
- прогоны на реальных/репрезентативных данных;
- сверка с ручным расчётом;
- подтверждение QA review workflow.
Change control
- версионирование лимитов;
- impact assessment при изменении правил;
- регрессия после обновления.
1. Document purpose
This document defines user requirements (URS) and functional specification (FS) for TcmMycotoxinsProfileQualityChecker. The utility is intended to evaluate input.csv data deterministically, generate structured output.json output and support traceable QA/QC review.
This document is a project-level URS/FS baseline for CSV/CSA, IQ/OQ/PQ and further validation under an approved laboratory procedure.
2. Source utility description
3. URS — user requirements
3.1 Intended use and scope
The system shall accept tabular laboratory QC results, evaluate them against configured acceptance criteria and return a clear status for each batch or record: Pass, Review or Fail.
3.2 Regulatory / methodological basis
The source description and utility rules refer to the following framework: ChP 2020, ChP, EP, ICH, EMA. Final acceptance limits shall be confirmed by the approved specification, pharmacopoeial monograph, SOP or method-transfer protocol.
3.3 Key QC checks
- Aflatoxin B1: ≤5 ppb (μg/kg)
- Aflatoxin total (B1+B2+G1+G2): ≤10 ppb
- Ochratoxin A: ≤5 ppb
- Fumonisin B1: ≤100 ppb
- Zearalenone: ≤50 ppb
- Deoxynivalenol (DON): ≤500 ppb
- T-2 toxin: ≤10 ppb
- Coix_lacryma_jobi (Coix seeds) — high risk of aflatoxins and fumonisins
3.4 Users
- QC analyst — prepares and loads
input.csv. - QA/QC reviewer — reviews output, findings and deviations.
- CSV/validation specialist — confirms fitness for intended use.
- System owner — controls versioning, access and change management.
3.5 Data and data-integrity requirements
- each CSV row shall be traceable to a batch, sample or analytical measurement;
- source values shall not be modified by the utility;
- calculations shall be reproducible on repeated execution;
- each deviation shall be captured as a structured finding with field and rule references;
- manual override of the final status outside QA process is not allowed.
4. FS — functional specification
4.1 Processing flow
- Verify presence and encoding of
input.csv. - Validate headers, mandatory fields and data types.
- Normalize numeric and boolean values while preserving the source trace.
- Select an adaptive rule set by product/category type, where applicable.
- Compare values with limits and compute derived metrics.
- Create a result record for each input row.
- Write
output.jsonwith summary, findings and traceability.
4.2 CSV schema
| # | CSV field | Type | Req. | Purpose |
|---|---|---|---|---|
| 1 | BatchNumber | string | Yes | Batch / lot identifier used for traceability. |
| 2 | HerbName | string | Yes | Product, preparation or sample identity. |
| 3 | Aflatoxin_B1_ppb | decimal | Yes | Measured analytical result compared with the configured acceptance criterion. |
| 4 | Aflatoxin_Total_ppb | decimal | Yes | Measured analytical result compared with the configured acceptance criterion. |
| 5 | Ochratoxin_A_ppb | decimal | Yes | Measured analytical result compared with the configured acceptance criterion. |
| 6 | Fumonisin_B1_ppb | decimal | Yes | Measured analytical result compared with the configured acceptance criterion. |
| 7 | Zearalenone_ppb | decimal | Yes | Measured analytical result compared with the configured acceptance criterion. |
| 8 | Deoxynivalenol_ppb | decimal | Yes | Measured analytical result compared with the configured acceptance criterion. |
| 9 | T2_Toxin_ppb | decimal | Yes | Measured analytical result compared with the configured acceptance criterion. |
| 10 | Recovery_AFB1_Percent | decimal | Yes | Measured analytical result compared with the configured acceptance criterion. |
4.3 Input data example
| BatchNumber | HerbName | Aflatoxin_B1_ppb | Aflatoxin_Total_ppb | Ochratoxin_A_ppb | Fumonisin_B1_ppb | Zearalenone_ppb | Deoxynivalenol_ppb | T2_Toxin_ppb | Recovery_AFB1_Percent |
|---|---|---|---|---|---|---|---|---|---|
| TCM-COIX-2026-MYC-001 | Coix_lacryma_jobi | 1.2 | 2.5 | 1.5 | 50.0 | 30.0 | 200.0 | 5.0 | 92.5 |
| TCM-LICORICE-2026-MYC-002 | Glycyrrhiza_uralensis | 0.8 | 1.5 | 3.2 | 20.0 | 10.0 | 150.0 | 2.0 | 96.0 |
| TCM-LOTUS-FAIL-2026-003 | Nelumbo_nucifera | 6.5 | 12.0 | 8.0 | 150.0 | 80.0 | 600.0 | 15.0 | 88.0 |
| TCM-GINSENG-2026-MYC-004 | Panax_ginseng | 0.5 | 1.0 | 0.8 | 10.0 | 5.0 | 50.0 | 1.0 | 98.5 |
4.4 Output JSON
{
"utility": "TcmMycotoxinsProfileQualityChecker",
"runId": "urn:fuzkk:run:example",
"sourceFile": "input.csv",
"recordsProcessed": 4,
"overallStatus": "Pass / Review / Fail",
"records": [
{
"recordId": "TCM-COIX-2026-MYC-001",
"status": "Pass / Review / Fail",
"criticalFindings": [],
"warnings": [],
"evaluatedRules": [
"Configured acceptance criteria from the utility rule set"
],
"inputTrace": {
"BatchNumber": "TCM-COIX-2026-MYC-001",
"HerbName": "Coix_lacryma_jobi",
"Aflatoxin_B1_ppb": "1.2",
"Aflatoxin_Total_ppb": "2.5",
"Ochratoxin_A_ppb": "1.5",
"Fumonisin_B1_ppb": "50.0",
"Zearalenone_ppb": "30.0",
"Deoxynivalenol_ppb": "200.0"
}
}
],
"dataIntegrity": {
"deterministicEvaluation": true,
"sourceRowTraceability": true,
"manualOverrideAllowed": false
}
}
5. Traceability URS → FS → tests
| URS | FS mechanism | Test evidence |
|---|---|---|
| Load valid input.csv | CSV parser + schema validator | OQ: valid/invalid CSV cases |
| Deterministic limit evaluation | Rule engine with fixed configuration | OQ: boundary values and known expected results |
| Pass/Review/Fail statuses | Status aggregator based on findings | OQ/PQ: passing and failing representative batches |
| Traceability to source row | inputTrace + recordId | PQ: output.json reconciliation to source CSV |
| QA review support | structured findings and warnings | PQ: review and deviation-handling scenarios |
6. CSV/CSA and validation approach
IQ
- utility version check;
- executable location check;
- CSV template check;
- access-right verification.
OQ
- mandatory field checks;
- data type checks;
- boundary-value checks;
- zero-tolerance rule checks.
PQ
- runs on real or representative data;
- comparison with manual calculation;
- confirmation of QA review workflow.
Change control
- rule and limit versioning;
- impact assessment for rule changes;
- regression after updates.
Included in packages
Traditional Chinese Medicine (TCM) QC Suite
QC utility package for TCM: botanical identity, fingerprint consistency, marker compounds, decoction pieces, Paozhi processing, pesticides, mycotoxins, heavy metals, sulfur fumigation, microbial limits and adulteration screening.
Open