WDCLSC Invert Sigmoid Rule
Version: v3.0.0 Status: Normative (text), Illustrative (diagrams only) Scope: CLS discrepancy detection for Control wells with sigmoid curve consideration Domain: RULES-WDCLSCINVSIG Precedence: After minimum fluorescence check, before error assignment
Statement
The system shall validate CLS (classification) discrepancies between DXAI and machine classifications on Control wells while considering sigmoid curve patterns, with intelligent skip conditions to reduce false-positive discrepancy errors.
The rule provides three distinct skip conditions evaluated in order: (1) minimum fluorescence threshold - skips rule entirely when max reading is below threshold; (2) sigmoid pattern - skips discrepancy error when both downward sigmoid AND negative classification are present; (3) maximum CT threshold - skips discrepancy error when final CT meets or exceeds the configured maximum. When a curve shows a downward sigmoid pattern with negative classification, the discrepancy is expected behavior indicating a truly negative sample.
Quick Reference
| ID | Core Behavior | Priority | Status |
|---|---|---|---|
| REQ-RULES-WDCLSCINVSIG-001 | Skip discrepancy for downward sigmoid + negative classification | HIGH | Draft |
| REQ-RULES-WDCLSCINVSIG-002 | Skip discrepancy when final CT exceeds max threshold | HIGH | Draft |
| REQ-RULES-WDCLSCINVSIG-003 | Skip rule when max reading below min fluorescence | HIGH | Draft |
Key Integration Points: WDCLSC Rule (base logic), Sigmoid Detection Algorithm, Target Configuration
Rule Summary
| Property | Value |
|---|---|
| Name | WDCLSC_INVERT_SIGMOID_POS |
| Execution Order | Minimum Fluorescence -> Sigmoid Pattern -> Max CT -> Error Assignment |
| Triggers | Control well with DXAI cls != machine cls |
| Output | Skip discrepancy error OR assign discrepancy error |
Rule Flowchart (Illustrative)
This diagram illustrates the skip condition evaluation order. The rule specifically handles Quest invalid sigmoid issues by recognizing that downward sigmoid + negative classification represents expected behavior.
Definitions
| Term | Definition |
|---|---|
| CLS | Classification - the positive/negative determination for an observation |
| CT | Cycle Threshold - the cycle number at which fluorescence crosses the detection threshold |
| DXAI | Diagnostic AI classification system |
| Sigmoid | S-shaped curve pattern in fluorescence readings over amplification cycles |
| Downward Sigmoid | Sigmoid curve pattern where readings trend downward, indicating signal decay |
| Upward Sigmoid | Sigmoid curve pattern where readings trend upward, indicating amplification |
| Control Well | A well designated for quality control purposes (positive or negative control) |
| WDCLSC | Wrong Discrepancy CLS Control - the base rule for Control well discrepancy detection |
| Discrepancy Error | An error assigned when DXAI classification differs from machine classification |
Assumptions
- The well being evaluated is a Control well (not a sample well)
- DXAI classification differs from machine classification (discrepancy condition exists)
- Sigmoid pattern detection algorithm is available and returns upward/downward classification
- Target configuration parameters are accessible for the observation's target
Requirements
Minimum Fluorescence Skip (REQ-RULES-WDCLSCINVSIG-003)
FR-WDCLSCINVSIG-003: Skip Rule When Maximum Reading Below Minimum Fluorescence Threshold
The system shall skip the entire WDCLSC Invert Sigmoid rule when the maximum fluorescence reading in the observation is strictly less than the configured minimum fluorescence to positive threshold.
Acceptance Criteria
Threshold Comparison:
- Use strict less-than comparison for skip condition: max(readings) < minimum_fluorescence_to_positive
- When max reading equals minimum_fluorescence_to_positive, execute the rule (exclusive lower bound)
- Apply the minimum_fluorescence_to_positive configuration to WD (Well Discrepancy) rules generally
Boundary Cases:
- max value 99 with threshold 100: skip rule entirely
- max value 100 with threshold 100: execute rule and apply errors if other conditions satisfied
Error Handling
- Missing minimum_fluorescence_to_positive configuration: proceed with rule execution (no skip)
- Empty readings array: skip the rule (no valid max reading can be determined)
Trace: Source: 3.0.0-WDCLSC_INVERT_SIGMOID_POS: Consider Minimum Fluorescence in WD Rules (Row 1 Cases 1-2) | Epic: BT-5367 | Jira: BT-5368 | Tests: See scenarios
Sigmoid Pattern Skip (REQ-RULES-WDCLSCINVSIG-001)
FR-WDCLSCINVSIG-001: Skip CLS Discrepancy for Downward Sigmoid with Negative Classification
The system shall skip the CLS discrepancy check for control well observations with downward sigmoid readings and negative final classification, and shall assign a discrepancy error for all other combinations of sigmoid pattern and classification.
Acceptance Criteria
Skip Condition (Both Required):
- Require BOTH downward sigmoid AND negative classification for the skip condition (logical AND)
- Assign a discrepancy error when any single skip condition is false
Sigmoid + Classification Matrix:
| Sigmoid Pattern | Final CLS | Result |
|---|---|---|
| Downward | Negative | Skip discrepancy error |
| Downward | Positive | Assign discrepancy error |
| Upward | Negative | Assign discrepancy error |
| Upward | Positive | Assign discrepancy error |
Rule Identity:
- Use programmatic rule code: WDCLSC_INVERT_SIGMOID_POS
- Perform check before other discrepancy validations in rule execution order
Error Handling
- Missing readings array: do not evaluate sigmoid pattern; discrepancy check proceeds with other conditions
- Sigmoid pattern undetermined: treat as non-skip condition and continue to discrepancy error evaluation
Trace: Source: 3.0.0-WDCLSC Invert Sigmoid Rule (Row 1, Row 2 Cases 1-4) | Jira: BT-5214 | X-ray: BT-5220 | Tests: See scenarios | Related: WDCLSC Rule (base logic pattern)
Maximum CT Skip (REQ-RULES-WDCLSCINVSIG-002)
FR-WDCLSCINVSIG-002: Skip CLS Discrepancy When Final CT Exceeds Maximum Threshold
The system shall skip the CLS discrepancy check when the observation's final CT value meets or exceeds the configured maximum CT for CLS discrepancy threshold, and shall proceed with the discrepancy check when the configuration is null or the final CT is below the threshold.
Acceptance Criteria
Threshold Comparison:
- Use greater-than-or-equal comparison for skip condition: final_ct >= max_ct_for_cls_discrepancy
- Skip the discrepancy check when final CT equals max_ct_for_cls_discrepancy (inclusive upper bound)
- Share the max_ct_for_cls_discrepancy configuration option with WDCLS/C Rules
Configuration Behavior:
| max_ct_for_cls_discrepancy | final_ct | Result |
|---|---|---|
| null | 36 | Assign discrepancy error |
| 35 | 36 | Skip discrepancy error |
| 36 | 36 | Skip discrepancy error (boundary) |
| 37 | 36 | Assign discrepancy error |
Error Handling
- Invalid CT value: log warning and continue with discrepancy check
- Missing target configuration: use default behavior (no skip, discrepancy check proceeds)
Trace: Source: 3.0.0-WDCLSC Invert Sigmoid Rule (Row 3 Cases 1-4) | Jira: BT-5227 | X-ray: BT-5237 | Tests: See scenarios | Related: REQ-RULES-WDCLSCINVSIG-001
Configuration Options
| Option | Type | Default | Description | Affects |
|---|---|---|---|---|
max_ct_for_cls_discrepancy | Number (nullable) | null | Maximum CT value above which discrepancy errors are suppressed | REQ-RULES-WDCLSCINVSIG-002 |
minimum_fluorescence_to_positive | Number | Required | Minimum fluorescence reading required for rule to apply | REQ-RULES-WDCLSCINVSIG-003 |
Notes
- The WDCLSC Invert Sigmoid rule follows the same base logic as the WDCLSC Rule for determining CLS discrepancy presence
- The rule is specifically designed to handle Quest invalid sigmoid issues (Epic BT-5215)
- When a curve shows a downward sigmoid pattern with a negative classification, the discrepancy between DXAI and machine classification is expected behavior - the inverted sigmoid indicates the sample is truly negative
- Rule execution order: Minimum Fluorescence Check -> Sigmoid Pattern Check -> Max CT Check -> Discrepancy Error Assignment
Implementation (Illustrative)
| Component | Location |
|---|---|
| Rule Class | Analyzer/Rules/WdclscInvertSigmoidPosRule |
Traceability Matrix
| Requirement | Title | Verification | Implementation | Test Cases | Status |
|---|---|---|---|---|---|
| REQ-RULES-WDCLSCINVSIG-001 | Skip CLS Discrepancy for Downward Sigmoid + Negative | Test | WdclscInvertSigmoidPosRule | BT-5220 | Draft |
| REQ-RULES-WDCLSCINVSIG-002 | Skip CLS Discrepancy When Final CT Exceeds Max | Test | WdclscInvertSigmoidPosRule | BT-5237 | Draft |
| REQ-RULES-WDCLSCINVSIG-003 | Skip Rule When Max Reading Below Min Fluorescence | Test | WdclscInvertSigmoidPosRule | [Pending] | Draft |
Acceptance Tests
Test: REQ-RULES-WDCLSCINVSIG-003
Test: Max Reading Below Threshold (Skip)
Given: A control well with observation
And: The target has minimum fluorescence to positive: 100
And: The observation readings have max value: 99
When: The WDCLSC Invert Sigmoid rule is evaluated
Then: The rule shall be skipped entirely
Test: Max Reading At Threshold (Rule Applies - Boundary)
Given: A control well with observation
And: The target has minimum fluorescence to positive: 100
And: The observation readings have max value: 100
When: The WDCLSC Invert Sigmoid rule is evaluated
Then: The rule shall execute and apply errors if other conditions are satisfied
Test: REQ-RULES-WDCLSCINVSIG-001
Test: Case 1 - Skip Condition (Downward Sigmoid + Negative)
Given: A control well with observation where DXAI cls != machine cls
And: The observation has final cls: negative
And: The readings exhibit downward sigmoid pattern
When: The WDCLSC Invert Sigmoid rule is executed
Then: The observation shall NOT receive a cls discrepancy error
Test: Case 2 - Error (Upward Sigmoid + Negative)
Given: A control well with observation where DXAI cls != machine cls
And: The observation has final cls: negative
And: The readings exhibit upward sigmoid pattern
When: The WDCLSC Invert Sigmoid rule is executed
Then: The observation SHALL receive a cls discrepancy error
Test: Case 3 - Error (Downward Sigmoid + Positive)
Given: A control well with observation where DXAI cls != machine cls
And: The observation has final cls: positive
And: The readings exhibit downward sigmoid pattern
When: The WDCLSC Invert Sigmoid rule is executed
Then: The observation SHALL receive a cls discrepancy error
Test: Case 4 - Error (Upward Sigmoid + Positive)
Given: A control well with observation where DXAI cls != machine cls
And: The observation has final cls: positive
And: The readings exhibit upward sigmoid pattern
When: The WDCLSC Invert Sigmoid rule is executed
Then: The observation SHALL receive a cls discrepancy error
Test: REQ-RULES-WDCLSCINVSIG-002
Test: Case 1 - Null Configuration (Error Applies)
Given: A control well with observation where DXAI cls != machine cls
And: The target has max_ct_for_cls_discrepancy: null
And: The observation has final CT: 36
When: The WDCLSC Invert Sigmoid rule is executed
Then: The well SHALL receive a discrepancy error
Test: Case 2 - Final CT Exceeds Max (Skip)
Given: A control well with observation where DXAI cls != machine cls
And: The target has max_ct_for_cls_discrepancy: 35
And: The observation has final CT: 36
When: The WDCLSC Invert Sigmoid rule is executed
Then: The well shall NOT receive a discrepancy error
Test: Case 3 - Final CT Equals Max (Skip - Boundary)
Given: A control well with observation where DXAI cls != machine cls
And: The target has max_ct_for_cls_discrepancy: 36
And: The observation has final CT: 36
When: The WDCLSC Invert Sigmoid rule is executed
Then: The well shall NOT receive a discrepancy error
Test: Case 4 - Final CT Below Max (Error Applies)
Given: A control well with observation where DXAI cls != machine cls
And: The target has max_ct_for_cls_discrepancy: 37
And: The observation has final CT: 36
When: The WDCLSC Invert Sigmoid rule is executed
Then: The well SHALL receive a discrepancy error
Appendix: Process Artifacts
Completion Checklist
- All requirements are capability-level (describe behavior, not UI)
- Requirement variants consolidated (no requirement explosion) - N/A: RULES domain, no consolidation appropriate
- UI details are fully demoted to Illustrative section
- Configuration options are not encoded as requirements
- Acceptance criteria describe behavior, not UI mechanics
- Every requirement has acceptance criteria and source traceability
- Error handling addressed for I/O, validation, and external system requirements
- Open questions documented with owners assigned - N/A: no open questions identified
- Consolidations documented in Reviewer Notes with reversibility info
- Module can survive a full UI redesign unchanged
- Refinements folded into acceptance criteria
- Traceability matrix is complete
Reviewer Notes
No Consolidation Required
This domain contains 3 distinct requirements representing separate skip conditions for the WDCLSC Invert Sigmoid rule. These were NOT consolidated because:
- RULES domain policy: Analytics rules require precision; each skip condition has distinct triggering logic and test scenarios
- Distinct capabilities: Each requirement represents an independent skip mechanism:
- REQ-001: Sigmoid pattern-based skip
- REQ-002: CT threshold-based skip
- REQ-003: Fluorescence threshold-based skip (first check in order)
- Testing requirements: Each has independent test cases that must be verified separately
Source mapping:
| Requirement | Source Reference | Disposition |
|---|---|---|
| REQ-RULES-WDCLSCINVSIG-001 | 3.0.0-WDCLSC Invert Sigmoid Rule (Rows 1-2) | Preserved |
| REQ-RULES-WDCLSCINVSIG-002 | 3.0.0-WDCLSC Invert Sigmoid Rule (Row 3) | Preserved |
| REQ-RULES-WDCLSCINVSIG-003 | 3.0.0-WDCLSC_INVERT_SIGMOID_POS Sub-Rule (Row 1) | Preserved |
Reversibility: Source file: output/pilot/rules/rule-wdclsc-invert-sigmoid/rule-wdclsc-invert-sigmoid-restructured.md