Reagent expiry alert

From aipoch/medical-research-skills · View interactive version

Reagent expiry alert is an AI agent skill from the GitHub repository aipoch/medical-research-skills. Scan reagent barcodes or IDs, log expiration dates, and generate multi-level alerts before reagent expiry to support laboratory inventory management.

How to use this skill

Skill file

Source: https://github.com/aipoch/medical-research-skills

Reagent Expiry Alert

Scan reagent bottle barcodes or IDs, log expiration dates, and alert before expiry to support safe laboratory inventory management.

Quick Check

python -m py_compile scripts/main.py
python scripts/main.py --help

When to Use

Workflow

  1. Confirm the reagent barcode/ID, expiry date, and action (scan/log or check alerts).
  2. Validate that the request is for reagent expiry tracking, not chemical safety assessment or disposal guidance.
  3. Date validation: If --expiry is provided, validate that it is a valid YYYY-MM-DD date. If the date is in the past, emit a warning: "This reagent is already expired as of [date]. It will be logged with an Expired alert status."
  4. Log the reagent or run the alert check using the packaged script.
  5. Return expiration status, alert level, and reorder recommendations.
  6. If inputs are incomplete, state which fields are missing and request only the minimum additional information.

Usage

# Log a new reagent
python scripts/main.py --scan "REAGENT-001" --name "Tris Buffer" --expiry 2025-12-31 --location "Shelf A"

# Check for upcoming expirations
python scripts/main.py --check-alerts --alert-days 30

# Check with custom alert window
python scripts/main.py --check-alerts --alert-days 60

Parameters

| Parameter | Type | Required | Default | Description |

|-----------|------|----------|---------|-------------|

| --scan | string | No | — | Reagent barcode or ID |

| --name | string | No | — | Reagent name |

| --expiry | date | No | — | Expiration date (YYYY-MM-DD) |

| --location | string | No | — | Storage location |

| --quantity | string | No | — | Quantity on hand |

| --check-alerts | flag | No | — | Check for upcoming expirations |

| --alert-days | integer | No | 30 | Days before expiry to alert |

Alert Levels

Output

Stress-Case Rules

For complex multi-constraint requests, always include these explicit blocks:

  1. Assumptions
  2. Reagents Checked
  3. Alert Report
  4. Reorder Recommendations
  5. Risks and Manual Checks

Error Handling

Input Validation

This skill accepts: reagent barcode/ID and expiry date for logging, or a check-alerts request for inventory review.

If the request does not involve reagent expiry tracking — for example, asking for chemical hazard assessment, waste disposal guidance, or controlled substance management — do not proceed with the workflow. Instead respond:

"reagent-expiry-alert is designed to log reagent expiry dates and generate alerts before expiration. Your request appears to be outside this scope. Please provide a reagent ID and expiry date, or use a more appropriate tool."

Response Template

Use the following fixed structure for non-trivial requests:

  1. Objective
  2. Inputs Received
  3. Assumptions
  4. Workflow
  5. Deliverable
  6. Risks and Limits
  7. Next Checks

If the request is simple, you may compress the structure, but still keep assumptions and limits explicit when they affect correctness.

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.