mirror of
https://github.com/affaan-m/everything-claude-code.git
synced 2026-03-30 13:43:26 +08:00
fix: address Greptile review — frontmatter, CI safety, null guards
Greptile fixes: - Removed non-standard YAML frontmatter fields (observe, feedback, rollback) from all 4 skills — only name, description, origin, version per CONTRIBUTING.md - Added null guard to checkInteractions implementation (was missing despite test) - CI: replaced 2>/dev/null with 2>&1 (was silencing safety-critical errors) - CI: quoted $RESULT variable (was breaking jq on JSON with spaces) - CI: added division-by-zero guard when test suite is empty - CI: added note that Jest is reference implementation, thresholds are framework-agnostic
This commit is contained in:
@@ -3,9 +3,6 @@ name: healthcare-cdss-patterns
|
|||||||
description: Clinical Decision Support System (CDSS) development patterns. Drug interaction checking, dose validation, clinical scoring (NEWS2, qSOFA), alert severity classification, and integration into EMR workflows.
|
description: Clinical Decision Support System (CDSS) development patterns. Drug interaction checking, dose validation, clinical scoring (NEWS2, qSOFA), alert severity classification, and integration into EMR workflows.
|
||||||
origin: Health1 Super Speciality Hospitals — contributed by Dr. Keyur Patel
|
origin: Health1 Super Speciality Hospitals — contributed by Dr. Keyur Patel
|
||||||
version: "1.0.0"
|
version: "1.0.0"
|
||||||
observe: "PostToolUse"
|
|
||||||
feedback: "manual"
|
|
||||||
rollback: "git revert"
|
|
||||||
---
|
---
|
||||||
|
|
||||||
# Healthcare CDSS Development Patterns
|
# Healthcare CDSS Development Patterns
|
||||||
@@ -60,6 +57,7 @@ function checkInteractions(
|
|||||||
currentMedications: string[],
|
currentMedications: string[],
|
||||||
allergyList: string[]
|
allergyList: string[]
|
||||||
): InteractionAlert[] {
|
): InteractionAlert[] {
|
||||||
|
if (!newDrug) return [];
|
||||||
const alerts: InteractionAlert[] = [];
|
const alerts: InteractionAlert[] = [];
|
||||||
for (const current of currentMedications) {
|
for (const current of currentMedications) {
|
||||||
const interaction = findInteraction(newDrug, current);
|
const interaction = findInteraction(newDrug, current);
|
||||||
|
|||||||
@@ -3,9 +3,6 @@ name: healthcare-emr-patterns
|
|||||||
description: EMR/EHR development patterns for healthcare applications. Clinical safety, encounter workflows, prescription generation, clinical decision support integration, and accessibility-first UI for medical data entry.
|
description: EMR/EHR development patterns for healthcare applications. Clinical safety, encounter workflows, prescription generation, clinical decision support integration, and accessibility-first UI for medical data entry.
|
||||||
origin: Health1 Super Speciality Hospitals — contributed by Dr. Keyur Patel
|
origin: Health1 Super Speciality Hospitals — contributed by Dr. Keyur Patel
|
||||||
version: "1.0.0"
|
version: "1.0.0"
|
||||||
observe: "PostToolUse"
|
|
||||||
feedback: "manual"
|
|
||||||
rollback: "git revert"
|
|
||||||
---
|
---
|
||||||
|
|
||||||
# Healthcare EMR Development Patterns
|
# Healthcare EMR Development Patterns
|
||||||
|
|||||||
@@ -3,15 +3,14 @@ name: healthcare-eval-harness
|
|||||||
description: Patient safety evaluation harness for healthcare application deployments. Automated test suites for CDSS accuracy, PHI exposure, clinical workflow integrity, and integration compliance. Blocks deployments on safety failures.
|
description: Patient safety evaluation harness for healthcare application deployments. Automated test suites for CDSS accuracy, PHI exposure, clinical workflow integrity, and integration compliance. Blocks deployments on safety failures.
|
||||||
origin: Health1 Super Speciality Hospitals — contributed by Dr. Keyur Patel
|
origin: Health1 Super Speciality Hospitals — contributed by Dr. Keyur Patel
|
||||||
version: "1.0.0"
|
version: "1.0.0"
|
||||||
observe: "PostToolUse"
|
|
||||||
feedback: "manual"
|
|
||||||
rollback: "git revert"
|
|
||||||
---
|
---
|
||||||
|
|
||||||
# Healthcare Eval Harness — Patient Safety Verification
|
# Healthcare Eval Harness — Patient Safety Verification
|
||||||
|
|
||||||
Automated verification system for healthcare application deployments. A single CRITICAL failure blocks deployment. Patient safety is non-negotiable.
|
Automated verification system for healthcare application deployments. A single CRITICAL failure blocks deployment. Patient safety is non-negotiable.
|
||||||
|
|
||||||
|
> **Note:** Examples use Jest as the reference test runner. Adapt commands for your framework (Vitest, pytest, PHPUnit, etc.) — the test categories and pass thresholds are framework-agnostic.
|
||||||
|
|
||||||
## When to Use
|
## When to Use
|
||||||
|
|
||||||
- Before any deployment of EMR/EHR applications
|
- Before any deployment of EMR/EHR applications
|
||||||
@@ -106,26 +105,33 @@ jobs:
|
|||||||
run: npx jest --testPathPattern='tests/data-integrity' --bail --ci
|
run: npx jest --testPathPattern='tests/data-integrity' --bail --ci
|
||||||
|
|
||||||
# HIGH gates — 95%+ required, custom threshold check
|
# HIGH gates — 95%+ required, custom threshold check
|
||||||
|
# HIGH gates — 95%+ required
|
||||||
- name: Clinical Workflows
|
- name: Clinical Workflows
|
||||||
run: |
|
run: |
|
||||||
RESULT=$(npx jest --testPathPattern='tests/clinical' --ci --json 2>/dev/null)
|
RESULT=$(npx jest --testPathPattern='tests/clinical' --ci --json 2>&1) || true
|
||||||
PASSED=$(echo $RESULT | jq '.numPassedTests')
|
TOTAL=$(echo "$RESULT" | jq '.numTotalTests // 0')
|
||||||
TOTAL=$(echo $RESULT | jq '.numTotalTests')
|
PASSED=$(echo "$RESULT" | jq '.numPassedTests // 0')
|
||||||
|
if [ "$TOTAL" -eq 0 ]; then
|
||||||
|
echo "::error::No clinical tests found"; exit 1
|
||||||
|
fi
|
||||||
RATE=$(echo "scale=2; $PASSED * 100 / $TOTAL" | bc)
|
RATE=$(echo "scale=2; $PASSED * 100 / $TOTAL" | bc)
|
||||||
echo "Pass rate: ${RATE}%"
|
echo "Pass rate: ${RATE}% ($PASSED/$TOTAL)"
|
||||||
if (( $(echo "$RATE < 95" | bc -l) )); then
|
if (( $(echo "$RATE < 95" | bc -l) )); then
|
||||||
echo "::warning::Clinical workflow pass rate ${RATE}% below 95% threshold"
|
echo "::warning::Clinical pass rate ${RATE}% below 95%"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
- name: Integration Compliance
|
- name: Integration Compliance
|
||||||
run: |
|
run: |
|
||||||
RESULT=$(npx jest --testPathPattern='tests/integration' --ci --json 2>/dev/null)
|
RESULT=$(npx jest --testPathPattern='tests/integration' --ci --json 2>&1) || true
|
||||||
PASSED=$(echo $RESULT | jq '.numPassedTests')
|
TOTAL=$(echo "$RESULT" | jq '.numTotalTests // 0')
|
||||||
TOTAL=$(echo $RESULT | jq '.numTotalTests')
|
PASSED=$(echo "$RESULT" | jq '.numPassedTests // 0')
|
||||||
|
if [ "$TOTAL" -eq 0 ]; then
|
||||||
|
echo "::error::No integration tests found"; exit 1
|
||||||
|
fi
|
||||||
RATE=$(echo "scale=2; $PASSED * 100 / $TOTAL" | bc)
|
RATE=$(echo "scale=2; $PASSED * 100 / $TOTAL" | bc)
|
||||||
echo "Pass rate: ${RATE}%"
|
echo "Pass rate: ${RATE}% ($PASSED/$TOTAL)"
|
||||||
if (( $(echo "$RATE < 95" | bc -l) )); then
|
if (( $(echo "$RATE < 95" | bc -l) )); then
|
||||||
echo "::warning::Integration pass rate ${RATE}% below 95% threshold"
|
echo "::warning::Integration pass rate ${RATE}% below 95%"
|
||||||
fi
|
fi
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|||||||
@@ -3,9 +3,6 @@ name: healthcare-phi-compliance
|
|||||||
description: Protected Health Information (PHI) and Personally Identifiable Information (PII) compliance patterns for healthcare applications. Covers data classification, access control, audit trails, encryption, and common leak vectors.
|
description: Protected Health Information (PHI) and Personally Identifiable Information (PII) compliance patterns for healthcare applications. Covers data classification, access control, audit trails, encryption, and common leak vectors.
|
||||||
origin: Health1 Super Speciality Hospitals — contributed by Dr. Keyur Patel
|
origin: Health1 Super Speciality Hospitals — contributed by Dr. Keyur Patel
|
||||||
version: "1.0.0"
|
version: "1.0.0"
|
||||||
observe: "PostToolUse"
|
|
||||||
feedback: "manual"
|
|
||||||
rollback: "git revert"
|
|
||||||
---
|
---
|
||||||
|
|
||||||
# Healthcare PHI/PII Compliance Patterns
|
# Healthcare PHI/PII Compliance Patterns
|
||||||
|
|||||||
Reference in New Issue
Block a user