STD: Positive Sigmoid Rule (POSSIGMOID)
Version: v1.0.0 Status: Draft SRS Source:
docusaurus/docs/srs/rules/rule-positive-sigmoid.mdRule Name: POSITIVE_SIGMOID Domain: RULES-POSSIGMOID
Overview
This document specifies tests for the Positive Sigmoid rule using decision tables and test vectors. The rule validates that wells with a positive final classification exhibit the expected upward sigmoid curve shape and flags errors when an incorrect downward pattern is detected.
Rule Characteristics:
- Pure business logic (no UI)
- Skip conditions evaluated first (manual classification, resolution code)
- Error codes assigned at both well and target levels
- Part of sigmoid rule validation suite (companion: NEGATIVE_SIGMOID)
Test Method: TM-API (per Test Plan Section 3.3 - Rules use automated API tests)
Verification Approach: Rule verification is performed using data-driven test vectors. Each row in a decision table represents a complete verification scenario with defined inputs and expected outputs. This format enables exhaustive condition coverage while remaining concise and auditable.
Coverage Summary
| REQ ID | Title | Conditions | Test Vectors | Coverage | Gaps |
|---|---|---|---|---|---|
| REQ-RULES-POSSIGMOID-001 | Core Sigmoid Validation | 4 | 4 | 100% | None |
| REQ-RULES-POSSIGMOID-002 | Skip on Resolution Code | 2 | 2 | 100% | None |
| REQ-RULES-POSSIGMOID-003 | Skip on Manual Classification | 2 | 2 | 100% | None |
Totals: 3 REQs, 8 Conditions, 8 Test Vectors, 100% Coverage
Input Variables
| Variable | Type | Valid Values | Description |
|---|---|---|---|
sigmoid_direction | enum | upward, downward | Direction of the sigmoid curve |
final_cls | enum | positive, negative | Final classification assigned to the well |
resolution_code | string | POSITIVE_SIGMOID, null | Resolution code applied to the well |
manual_cls | string | any value, null | Manual classification assigned by user |
Output Variables
| Variable | Type | Description |
|---|---|---|
well.error_code | string? | INCORRECT_POSITIVE_SIGMOID or null |
target.error_code | string? | INCORRECT_POSITIVE_SIGMOID_TARGET or null |
REQ-RULES-POSSIGMOID-001: Core Sigmoid Validation
Decision Table: Sigmoid Direction vs Classification
This table covers the core rule logic: detect incorrect sigmoid curve direction on positive wells.
| TV | sigmoid_direction | final_cls | well.error_code | target.error_code | Covers |
|---|---|---|---|---|---|
| TV-001-001 | downward | positive | INCORRECT_POSITIVE_SIGMOID | INCORRECT_POSITIVE_SIGMOID_TARGET | AC: Error Detection - downward on positive triggers error |
| TV-001-002 | upward | positive | null | null | AC: Correct Pattern - upward on positive passes |
| TV-001-003 | downward | negative | null | null | AC: Scope Exclusion - negative wells out of scope |
| TV-001-004 | upward | negative | null | null | AC: Scope Exclusion - negative wells out of scope |
Notes:
- TV-001-001 validates the primary error detection capability
- TV-001-002 validates that correct patterns do not trigger errors
- TV-001-003 and TV-001-004 validate that negative wells are excluded from this rule's scope (handled by NEGATIVE_SIGMOID rule instead)
REQ-RULES-POSSIGMOID-002: Skip on Resolution Code
Decision Table: Resolution Code Skip Behavior
This table covers the skip condition when resolution code POSITIVE_SIGMOID is present.
| TV | sigmoid_direction | final_cls | resolution_code | well.error_code | target.error_code | Covers |
|---|---|---|---|---|---|---|
| TV-002-001 | downward | positive | POSITIVE_SIGMOID | null | null | AC: Resolution code skips rule - no error assigned |
| TV-002-002 | downward | positive | null | INCORRECT_POSITIVE_SIGMOID | INCORRECT_POSITIVE_SIGMOID_TARGET | AC: No resolution code - error assigned |
Notes:
- TV-002-001 validates that the resolution code POSITIVE_SIGMOID acknowledges and dismisses the error
- TV-002-002 serves as control case showing error is assigned without the resolution code
REQ-RULES-POSSIGMOID-003: Skip on Manual Classification
Decision Table: Manual Classification Skip Behavior
This table covers the skip condition when manual classification is present.
| TV | sigmoid_direction | final_cls | manual_cls | well.error_code | target.error_code | Covers |
|---|---|---|---|---|---|---|
| TV-003-001 | downward | positive | positive | null | null | AC: Manual classification skips rule - no error |
| TV-003-002 | downward | positive | null | INCORRECT_POSITIVE_SIGMOID | INCORRECT_POSITIVE_SIGMOID_TARGET | AC: No manual classification - error assigned |
Notes:
- TV-003-001 validates that any manual classification (regardless of value) bypasses automated validation
- TV-003-002 serves as control case showing error is assigned without manual classification
- Per SRS: "The skip shall apply regardless of what value the manual classification is set to"
Composite Decision Table: Skip Precedence
This composite table demonstrates the evaluation order when multiple conditions are present.
| TV | sigmoid_direction | final_cls | manual_cls | resolution_code | well.error_code | target.error_code | Notes |
|---|---|---|---|---|---|---|---|
| TV-COMP-001 | downward | positive | positive | POSITIVE_SIGMOID | null | null | Both skip conditions present - skipped |
| TV-COMP-002 | downward | positive | positive | null | null | null | Manual only - skipped |
| TV-COMP-003 | downward | positive | null | POSITIVE_SIGMOID | null | null | Resolution only - skipped |
| TV-COMP-004 | downward | positive | null | null | INCORRECT_POSITIVE_SIGMOID | INCORRECT_POSITIVE_SIGMOID_TARGET | No skip conditions - error |
Evaluation Order (per SRS flowchart):
- Check manual classification (if present, skip)
- Check resolution code (if present, skip)
- Check final_cls (if not positive, skip)
- Check sigmoid direction (if downward, assign error)
Traceability to Existing Tests
| Requirement | Jira Tests | Automation Status |
|---|---|---|
| REQ-RULES-POSSIGMOID-001 | BT-5021 | Automated |
| REQ-RULES-POSSIGMOID-002 | Pending | Automated |
| REQ-RULES-POSSIGMOID-003 | Pending | Automated |
Gap Analysis
Identified Gaps
| Gap | Requirement | Description | Priority | Owner |
|---|---|---|---|---|
| GAP-001 | REQ-RULES-POSSIGMOID-002 | No Jira test ticket for resolution code skip behavior | Medium | TBD |
| GAP-002 | REQ-RULES-POSSIGMOID-003 | No Jira test ticket for manual classification skip behavior | Medium | TBD |
Remediation Plan
- GAP-001: Create test ticket covering TV-002-001 and TV-002-002
- GAP-002: Create test ticket covering TV-003-001 and TV-003-002