TcmFingerprintConsistencyQualityChecker
Tcm Fingerprint Consistency
ℹ️ Utility checks chromatographic fingerprint consistency of Traditional Chinese Medicine (TCM):
• Similarity index with reference (≥0.90)
• Number of common peaks (≥90% of reference)
• Marker peak area RSD (≤3.0%)
• Retention time shift (≤0.1 min)
• Baseline noise (≤0.5 mAU)
• Critical pair resolution (≥1.5)
⚠️ CRITICAL: Similarity index <0.90 indicates possible adulteration or wrong raw material!
Absence of key marker peaks requires additional identification.
Usage:
TcmFingerprintConsistencyQualityChecker.exe → demo mode (console output)
TcmFingerprintConsistencyQualityChecker.exe input.csv output.json → evaluate your data
Input format:
BatchNumber,HerbName,SimilarityIndex,CommonPeaksCount,ReferencePeaksCount,MarkerPeakAreaRSD,RetentionTimeShift,BaselineNoise,ResolutionCriticalPair
Example:
TCM-GINSENG-2026-001,Panax_ginseng,0.96,14,15,2.1,0.05,0.3,1.8
Supported raw materials:
• Panax_ginseng — genuine ginseng
• Astragalus_membranaceus — membranous astragalus
• Angelica_sinensis — Chinese angelica (danggui)
• Glycyrrhiza_uralensis — Ural licorice
• Salvia_miltiorrhiza — miltiorrhiza sage (danshen)
— WHY IS THIS NEEDED?
Chromatographic fingerprint — key tool for TCM quality control:
• Allows identification of plant raw material by complex compound profile
• Ensures quality reproducibility between different batches
• Detects adulteration, substitution or contamination of raw material
• Complies with Chinese Pharmacopoeia (ChP) and WHO requirements for TCM quality control
⚠️ CRITICAL:
• Similarity index ≥0.90 — ensures reliable raw material identification
• Common peaks ≥90% of reference — guarantees presence of main active components
• Marker peak RSD ≤3.0% — ensures method reproducibility
• Retention time shift ≤0.1 min — critical for correct peak identification
• Baseline noise ≤0.5 mAU — ensures sufficient signal-to-noise ratio
• Critical pair resolution ≥1.5 — guarantees resolution of close peaks
Key features:
• Check of similarity index with reference fingerprint
• Control of common peaks number relative to reference
• Reproducibility assessment by marker peak RSD
• System suitability monitoring (time shift, noise, resolution)
• Support for various types of TCM medicinal plant raw materials
• Compliance with ChP 2020 and WHO guidelines
Critical parameters:
• Similarity index: ≥0.90
• Common peaks: ≥90% of reference
• Marker peak RSD: ≤3.0%
• Retention time shift: ≤0.1 min
• Baseline noise: ≤0.5 mAU
• Critical pair resolution: ≥1.5
💡 Usage tips:
1. Reference fingerprint should be obtained from authenticated raw material
2. Use cosine correlation method for similarity index calculation
3. Select marker peaks among the most characteristic and stable compounds
4. System suitability should be checked before each analysis
5. If similarity index <0.90, perform additional TLC or LC-MS identification
⚠️ Note: Chromatographic fingerprint is ONE OF THE MOST RELIABLE methods for TCM quality control. It allows evaluation of the complex chemical profile of raw material, not just individual markers. This is especially important for multi-component herbal preparations, where synergistic effect is determined by the totality of compounds.
input.csv
BatchNumber,HerbName,SimilarityIndex,CommonPeaksCount,ReferencePeaksCount,MarkerPeakAreaRSD,RetentionTimeShift,BaselineNoise,ResolutionCriticalPair TCM-GINSENG-2026-001,Panax_ginseng,0.96,14,15,2.1,0.05,0.3,1.8 TCM-ASTRAGALUS-2026-002,Astragalus_membranaceus,0.92,18,20,1.8,0.08,0.4,1.6 TCM-DANGGUI-2026-003,Angelica_sinensis,0.88,12,15,3.5,0.12,0.6,1.3
TcmFingerprintConsistencyQualityChecker — URS & FS
TCM Fingerprint Consistency Quality Checker
TCM Fingerprint Consistency Quality Checker
1. Назначение документа
Документ описывает пользовательские требования (URS) и функциональную спецификацию (FS) для утилиты TcmFingerprintConsistencyQualityChecker. Утилита предназначена для детерминированной проверки данных 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, WHO. Финальные лимиты должны быть подтверждены утверждённой спецификацией, монографией, SOP или протоколом трансфера метода.
3.3 Ключевые QC-проверки
- Индекс сходства с эталоном (≥0.90)
- Количество общих пиков (≥90% от эталона)
- RSD площади маркерного пика (≤3.0%)
- Сдвиг времени удерживания (≤0.1 мин)
- Шум базовой линии (≤0.5 mAU)
- Разделение критической пары пиков (≥1.5)
- Panax_ginseng — женьшень настоящий
- Astragalus_membranaceus — астрагал перепончатый
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 | SimilarityIndex | decimal | Да | Входной атрибут для детерминированной оценки правил и прослеживаемости результата. |
| 4 | CommonPeaksCount | integer | Да | Входной атрибут для детерминированной оценки правил и прослеживаемости результата. |
| 5 | ReferencePeaksCount | integer | Да | Входной атрибут для детерминированной оценки правил и прослеживаемости результата. |
| 6 | MarkerPeakAreaRSD | decimal | Да | Параметр пригодности/надёжности аналитического метода. |
| 7 | RetentionTimeShift | decimal | Да | Входной атрибут для детерминированной оценки правил и прослеживаемости результата. |
| 8 | BaselineNoise | decimal | Да | Входной атрибут для детерминированной оценки правил и прослеживаемости результата. |
| 9 | ResolutionCriticalPair | decimal | Да | Входной атрибут для детерминированной оценки правил и прослеживаемости результата. |
4.3 Пример входных данных
| BatchNumber | HerbName | SimilarityIndex | CommonPeaksCount | ReferencePeaksCount | MarkerPeakAreaRSD | RetentionTimeShift | BaselineNoise | ResolutionCriticalPair |
|---|---|---|---|---|---|---|---|---|
| TCM-GINSENG-2026-001 | Panax_ginseng | 0.96 | 14 | 15 | 2.1 | 0.05 | 0.3 | 1.8 |
| TCM-ASTRAGALUS-2026-002 | Astragalus_membranaceus | 0.92 | 18 | 20 | 1.8 | 0.08 | 0.4 | 1.6 |
| TCM-DANGGUI-2026-003 | Angelica_sinensis | 0.88 | 12 | 15 | 3.5 | 0.12 | 0.6 | 1.3 |
4.4 Выходной JSON
{
"utility": "TcmFingerprintConsistencyQualityChecker",
"runId": "urn:fuzkk:run:example",
"sourceFile": "input.csv",
"recordsProcessed": 3,
"overallStatus": "Pass / Review / Fail",
"records": [
{
"recordId": "TCM-GINSENG-2026-001",
"status": "Pass / Review / Fail",
"criticalFindings": [],
"warnings": [],
"evaluatedRules": [
"Configured acceptance criteria from the utility rule set"
],
"inputTrace": {
"BatchNumber": "TCM-GINSENG-2026-001",
"HerbName": "Panax_ginseng",
"SimilarityIndex": "0.96",
"CommonPeaksCount": "14",
"ReferencePeaksCount": "15",
"MarkerPeakAreaRSD": "2.1",
"RetentionTimeShift": "0.05",
"BaselineNoise": "0.3"
}
}
],
"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 TcmFingerprintConsistencyQualityChecker. 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, WHO. Final acceptance limits shall be confirmed by the approved specification, pharmacopoeial monograph, SOP or method-transfer protocol.
3.3 Key QC checks
- Similarity index with reference (≥0.90)
- Number of common peaks (≥90% of reference)
- Marker peak area RSD (≤3.0%)
- Retention time shift (≤0.1 min)
- Baseline noise (≤0.5 mAU)
- Critical pair resolution (≥1.5)
- Panax_ginseng — genuine ginseng
- Astragalus_membranaceus — membranous astragalus
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 | SimilarityIndex | decimal | Yes | Input attribute required for deterministic rule evaluation and output traceability. |
| 4 | CommonPeaksCount | integer | Yes | Input attribute required for deterministic rule evaluation and output traceability. |
| 5 | ReferencePeaksCount | integer | Yes | Input attribute required for deterministic rule evaluation and output traceability. |
| 6 | MarkerPeakAreaRSD | decimal | Yes | Method-performance parameter used to confirm analytical result reliability. |
| 7 | RetentionTimeShift | decimal | Yes | Input attribute required for deterministic rule evaluation and output traceability. |
| 8 | BaselineNoise | decimal | Yes | Input attribute required for deterministic rule evaluation and output traceability. |
| 9 | ResolutionCriticalPair | decimal | Yes | Input attribute required for deterministic rule evaluation and output traceability. |
4.3 Input data example
| BatchNumber | HerbName | SimilarityIndex | CommonPeaksCount | ReferencePeaksCount | MarkerPeakAreaRSD | RetentionTimeShift | BaselineNoise | ResolutionCriticalPair |
|---|---|---|---|---|---|---|---|---|
| TCM-GINSENG-2026-001 | Panax_ginseng | 0.96 | 14 | 15 | 2.1 | 0.05 | 0.3 | 1.8 |
| TCM-ASTRAGALUS-2026-002 | Astragalus_membranaceus | 0.92 | 18 | 20 | 1.8 | 0.08 | 0.4 | 1.6 |
| TCM-DANGGUI-2026-003 | Angelica_sinensis | 0.88 | 12 | 15 | 3.5 | 0.12 | 0.6 | 1.3 |
4.4 Output JSON
{
"utility": "TcmFingerprintConsistencyQualityChecker",
"runId": "urn:fuzkk:run:example",
"sourceFile": "input.csv",
"recordsProcessed": 3,
"overallStatus": "Pass / Review / Fail",
"records": [
{
"recordId": "TCM-GINSENG-2026-001",
"status": "Pass / Review / Fail",
"criticalFindings": [],
"warnings": [],
"evaluatedRules": [
"Configured acceptance criteria from the utility rule set"
],
"inputTrace": {
"BatchNumber": "TCM-GINSENG-2026-001",
"HerbName": "Panax_ginseng",
"SimilarityIndex": "0.96",
"CommonPeaksCount": "14",
"ReferencePeaksCount": "15",
"MarkerPeakAreaRSD": "2.1",
"RetentionTimeShift": "0.05",
"BaselineNoise": "0.3"
}
}
],
"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