← Back to Pack Library
Jurisdictionslibraryuncertifiedv2026.12.0

us-ny

New York employment compliance library pack: NY Labor Law §195(1) Pay Notice at Hire and NY Labor Law §201-g annual Sexual Harassment Prevention Training.

Verify locally with CLI
Validate schema & rules
pnpm ir check packs/us-ny/pack.json
Run pack scenarios
pnpm ir test packs/us-ny/pack.json
2Requirements
0Concepts
6Scenarios

Requirements (2)

Compliance and operational rules declared in this pack's policies, with authority classification, legal citations, and due/renewal schedules.

New York Pay Notice at Hire (NY Labor Law §195(1))

ny_pay_notice
statutedocumentny_notices
Dueemployer: engagement/start_date (on day) · employee: engagement/start_date (on day)
Citations
  • NY Labor Law §195(1)

New York Sexual Harassment Prevention Training (Annual)

ny_harassment_training
statutedocumentny_training
Dueemployee: engagement/start_date (+30d)
Expires1 year
Renew within30 days
Citations
  • NY Labor Law §201-g

Scenarios (6)

Executable compliance test cases verified against this pack by pnpm ir test.

ny-w2-new-hire
as of 2026-12-01

New US W-2 employee working in New York requires the NY Labor Law §195(1) pay notice at hire and NY Labor Law §201-g sexual harassment prevention training.

Given facts
work/location_country=USwork/location_state=NYengagement/classification=w2engagement/start_date=2026-12-07engagement/reviewer=usr_reviewer_01engagement/employer_id=emp_ny_01
Expected outcomes
+ ny_pay_notice+ ny_harassment_trainingny_pay_notice: availableny_harassment_training: available
non-ny-w2-exempt
as of 2026-12-01

US W-2 employee working in New Jersey does not trigger New York statutory requirements.

Given facts
work/location_country=USwork/location_state=NJengagement/classification=w2engagement/start_date=2026-12-07engagement/reviewer=usr_reviewer_01engagement/employer_id=emp_ny_01
Expected outcomes
− ny_pay_notice− ny_harassment_training
ny-1099-contractor-exempt
as of 2026-12-01

1099 independent contractor working in New York is exempt from W-2 NY pay notice and employee sexual harassment training requirements.

Given facts
work/location_country=USwork/location_state=NYengagement/classification=1099engagement/start_date=2026-12-07engagement/reviewer=usr_reviewer_01engagement/employer_id=emp_ny_01
Expected outcomes
− ny_pay_notice− ny_harassment_training
missing-work-state-waiting
as of 2026-12-011 step

When work/location_state is unknown, NY requirements wait on missing facts; supplying NY makes both available.

Given facts
work/location_country=USengagement/classification=w2engagement/start_date=2026-12-07engagement/reviewer=usr_reviewer_01engagement/employer_id=emp_ny_01
Expected outcomes
+ ny_pay_notice+ ny_harassment_trainingny_pay_notice: blocked_on_factsny_harassment_training: blocked_on_facts
ny-due-dates-and-overdue
as of 2026-12-072 steps

NY pay notice is due on engagement/start_date (day 0) and becomes overdue the following day; harassment training is due 30 days after start_date.

Given facts
work/location_country=USwork/location_state=NYengagement/classification=w2engagement/start_date=2026-12-07engagement/reviewer=usr_reviewer_01engagement/employer_id=emp_ny_01
Expected outcomes
+ ny_pay_notice+ ny_harassment_trainingny_pay_notice: availableny_harassment_training: available
ny-rehire-reuse-and-annual-renewal
as of 2026-12-011 step

New York W-2 rehire with prior harassment training for the same employer reuses it while within 1 year and opens a renewal within 30 days of expiry; pay notice is required fresh; advancing past 1-year expiry requires fresh training.

Given facts
work/location_country=USwork/location_state=NYengagement/classification=w2engagement/start_date=2026-12-28engagement/reviewer=usr_reviewer_01engagement/employer_id=emp_ny_01
Expected outcomes
+ ny_pay_notice+ ny_harassment_training+ ny_harassment_training:renewalny_pay_notice: availableny_harassment_training: completeny_harassment_training:renewal: available

Pack JSON

Show raw packs/us-ny/pack.json
{
  "format": 1,
  "name": "us-ny",
  "version": "2026.12.0",
  "kind": "library",
  "description": "New York employment compliance library pack: NY Labor Law §195(1) Pay Notice at Hire and NY Labor Law §201-g annual Sexual Harassment Prevention Training.",
  "requires": [
    {
      "name": "staffing-core",
      "range": "^2026.12"
    }
  ],
  "templates": [
    {
      "key": "us_ny_ls54_pay_notice",
      "version": "2026.1.0",
      "title": "New York Notice and Acknowledgment of Pay Rate and Payday (NY Labor Law §195(1))",
      "roles": [
        {
          "name": "employer",
          "kind": "user",
          "label": "Employer Representative"
        },
        {
          "name": "employee",
          "kind": "person",
          "label": "Employee",
          "after": [
            "employer"
          ]
        }
      ],
      "sections": [
        {
          "id": "pay_notice_terms",
          "role": "employer",
          "title": "Employer and Pay Rate Disclosures",
          "fields": [
            {
              "id": "legal_employer_name",
              "type": "text",
              "label": "Legal Name of Hiring Employer",
              "required": true
            },
            {
              "id": "dba_name",
              "type": "text",
              "label": "Doing Business As (DBA) Name(s)",
              "required": false
            },
            {
              "id": "pay_rate",
              "type": "text",
              "label": "Rate(s) of Pay and Overtime Rate",
              "required": true
            },
            {
              "id": "pay_basis",
              "type": "choice",
              "label": "Basis of Pay",
              "options": [
                "hour",
                "shift",
                "day",
                "week",
                "salary",
                "piece",
                "commission"
              ],
              "required": true
            },
            {
              "id": "allowances_claimed",
              "type": "choice",
              "label": "Allowances Claimed as Part of Minimum Wage",
              "options": [
                "none",
                "tips",
                "meals",
                "lodging",
                "other"
              ],
              "required": true
            },
            {
              "id": "regular_payday",
              "type": "text",
              "label": "Regular Payday Designated by Employer",
              "required": true
            },
            {
              "id": "primary_language",
              "type": "text",
              "label": "Employee Primary Language",
              "required": true
            }
          ]
        },
        {
          "id": "acknowledgment",
          "role": "employee",
          "title": "Employee Acknowledgment of Receipt",
          "readable": [
            "pay_notice_terms"
          ],
          "fields": [
            {
              "id": "received_date",
              "type": "date",
              "label": "Date Received",
              "required": true
            }
          ],
          "signature": {
            "id": "employee_signature",
            "attestation": "I acknowledge receipt of this Notice and Acknowledgment of Pay Rate and Payday pursuant to New York Labor Law §195(1).",
            "covers": [
              "pay_notice_terms",
              "acknowledgment"
            ]
          }
        }
      ]
    },
    {
      "key": "us_ny_harassment_training",
      "version": "2026.1.0",
      "title": "New York Sexual Harassment Prevention Training Attestation (NY Labor Law §201-g)",
      "roles": [
        {
          "name": "employee",
          "kind": "person",
          "label": "Employee"
        }
      ],
      "sections": [
        {
          "id": "training_completion",
          "role": "employee",
          "title": "Annual Training Completion Record",
          "fields": [
            {
              "id": "completed_date",
              "type": "date",
              "label": "Completion Date",
              "required": true
            },
            {
              "id": "delivery_format",
              "type": "choice",
              "label": "Interactive Delivery Format",
              "options": [
                "interactive_online",
                "live_in_person",
                "live_virtual"
              ],
              "required": true
            },
            {
              "id": "provider_name",
              "type": "text",
              "label": "Training Provider or Program",
              "required": true
            }
          ],
          "signature": {
            "id": "employee_signature",
            "attestation": "I attest that I have completed the interactive New York sexual harassment prevention training required under New York Labor Law §201-g.",
            "covers": [
              "training_completion"
            ]
          }
        }
      ]
    }
  ],
  "policies": [
    {
      "key": "us-ny",
      "version": "2026.12.0",
      "facts": {
        "work/location_country": {
          "type": "choice",
          "options": [
            "US",
            "CA",
            "GB",
            "MX",
            "OTHER"
          ]
        },
        "work/location_state": {
          "type": "choice",
          "options": [
            "AL",
            "AK",
            "AZ",
            "AR",
            "CA",
            "CO",
            "CT",
            "DE",
            "DC",
            "FL",
            "GA",
            "HI",
            "ID",
            "IL",
            "IN",
            "IA",
            "KS",
            "KY",
            "LA",
            "ME",
            "MD",
            "MA",
            "MI",
            "MN",
            "MS",
            "MO",
            "MT",
            "NE",
            "NV",
            "NH",
            "NJ",
            "NM",
            "NY",
            "NC",
            "ND",
            "OH",
            "OK",
            "OR",
            "PA",
            "PR",
            "RI",
            "SC",
            "SD",
            "TN",
            "TX",
            "UT",
            "VT",
            "VA",
            "WA",
            "WV",
            "WI",
            "WY"
          ]
        },
        "engagement/classification": {
          "type": "choice",
          "options": [
            "w2",
            "1099"
          ]
        },
        "engagement/start_date": {
          "type": "date"
        },
        "engagement/reviewer": {
          "type": "string"
        },
        "engagement/employer_id": {
          "type": "string"
        }
      },
      "stages": [
        {
          "id": "ny_notices",
          "title": "New York Statutory Notices"
        },
        {
          "id": "ny_training",
          "title": "New York Mandatory Training"
        }
      ],
      "requirements": {
        "ny_pay_notice": {
          "title": "New York Pay Notice at Hire (NY Labor Law §195(1))",
          "kind": "document",
          "template": "us_ny_ls54_pay_notice",
          "stage": "ny_notices",
          "parties": {
            "employer": "engagement/reviewer",
            "employee": "subject"
          },
          "due": {
            "employer": {
              "relative_to": "engagement/start_date",
              "days": 0
            },
            "employee": {
              "relative_to": "engagement/start_date",
              "days": 0
            }
          },
          "on_unknown": "wait",
          "cites": [
            "NY Labor Law §195(1)"
          ],
          "authority": "statute"
        },
        "ny_harassment_training": {
          "title": "New York Sexual Harassment Prevention Training (Annual)",
          "kind": "document",
          "template": "us_ny_harassment_training",
          "stage": "ny_training",
          "parties": {
            "employee": "subject"
          },
          "due": {
            "employee": {
              "relative_to": "engagement/start_date",
              "days": 30
            }
          },
          "reuse": {
            "same": [
              "engagement/employer_id"
            ],
            "max_age_days": 365,
            "outcome": "satisfies"
          },
          "expires": {
            "years": 1
          },
          "renew_within": {
            "days": 30
          },
          "on_unknown": "wait",
          "cites": [
            "NY Labor Law §201-g"
          ],
          "authority": "statute"
        }
      },
      "policies": [
        {
          "id": "us-ny-pay-notice-w2",
          "title": "New York Pay Notice at Hire for W-2 employees working in New York",
          "when": {
            "all": [
              {
                "fact": "work/location_country",
                "operator": "equal",
                "value": "US"
              },
              {
                "fact": "work/location_state",
                "operator": "equal",
                "value": "NY"
              },
              {
                "fact": "engagement/classification",
                "operator": "equal",
                "value": "w2"
              }
            ]
          },
          "require": [
            "ny_pay_notice"
          ],
          "optional": false,
          "cites": [
            "NY Labor Law §195(1)"
          ]
        },
        {
          "id": "us-ny-harassment-training-w2",
          "title": "New York annual Sexual Harassment Prevention Training for New York W-2 employees",
          "when": {
            "all": [
              {
                "fact": "work/location_country",
                "operator": "equal",
                "value": "US"
              },
              {
                "fact": "work/location_state",
                "operator": "equal",
                "value": "NY"
              },
              {
                "fact": "engagement/classification",
                "operator": "equal",
                "value": "w2"
              }
            ]
          },
          "require": [
            "ny_harassment_training"
          ],
          "optional": false,
          "cites": [
            "NY Labor Law §201-g"
          ]
        }
      ]
    }
  ],
  "scenarios": [
    {
      "name": "ny-w2-new-hire",
      "description": "New US W-2 employee working in New York requires the NY Labor Law §195(1) pay notice at hire and NY Labor Law §201-g sexual harassment prevention training.",
      "policy_set": "us-ny",
      "as_of": "2026-12-01",
      "facts": {
        "work/location_country": "US",
        "work/location_state": "NY",
        "engagement/classification": "w2",
        "engagement/start_date": "2026-12-07",
        "engagement/reviewer": "usr_reviewer_01",
        "engagement/employer_id": "emp_ny_01"
      },
      "expect": {
        "required": [
          "ny_pay_notice",
          "ny_harassment_training"
        ],
        "not_required": [],
        "states": {
          "ny_pay_notice": "available",
          "ny_harassment_training": "available"
        },
        "missing_facts": []
      }
    },
    {
      "name": "non-ny-w2-exempt",
      "description": "US W-2 employee working in New Jersey does not trigger New York statutory requirements.",
      "policy_set": "us-ny",
      "as_of": "2026-12-01",
      "facts": {
        "work/location_country": "US",
        "work/location_state": "NJ",
        "engagement/classification": "w2",
        "engagement/start_date": "2026-12-07",
        "engagement/reviewer": "usr_reviewer_01",
        "engagement/employer_id": "emp_ny_01"
      },
      "expect": {
        "required": [],
        "not_required": [
          "ny_pay_notice",
          "ny_harassment_training"
        ],
        "missing_facts": []
      }
    },
    {
      "name": "ny-1099-contractor-exempt",
      "description": "1099 independent contractor working in New York is exempt from W-2 NY pay notice and employee sexual harassment training requirements.",
      "policy_set": "us-ny",
      "as_of": "2026-12-01",
      "facts": {
        "work/location_country": "US",
        "work/location_state": "NY",
        "engagement/classification": "1099",
        "engagement/start_date": "2026-12-07",
        "engagement/reviewer": "usr_reviewer_01",
        "engagement/employer_id": "emp_ny_01"
      },
      "expect": {
        "required": [],
        "not_required": [
          "ny_pay_notice",
          "ny_harassment_training"
        ],
        "missing_facts": []
      }
    },
    {
      "name": "missing-work-state-waiting",
      "description": "When work/location_state is unknown, NY requirements wait on missing facts; supplying NY makes both available.",
      "policy_set": "us-ny",
      "as_of": "2026-12-01",
      "facts": {
        "work/location_country": "US",
        "engagement/classification": "w2",
        "engagement/start_date": "2026-12-07",
        "engagement/reviewer": "usr_reviewer_01",
        "engagement/employer_id": "emp_ny_01"
      },
      "expect": {
        "required": [
          "ny_pay_notice",
          "ny_harassment_training"
        ],
        "not_required": [],
        "states": {
          "ny_pay_notice": "blocked_on_facts",
          "ny_harassment_training": "blocked_on_facts"
        },
        "missing_facts": [
          "work/location_state"
        ]
      },
      "steps": [
        {
          "name": "provide-ny-work-state",
          "set_facts": {
            "work/location_state": "NY"
          },
          "expect": {
            "required": [
              "ny_pay_notice",
              "ny_harassment_training"
            ],
            "not_required": [],
            "states": {
              "ny_pay_notice": "available",
              "ny_harassment_training": "available"
            },
            "missing_facts": []
          }
        }
      ]
    },
    {
      "name": "ny-due-dates-and-overdue",
      "description": "NY pay notice is due on engagement/start_date (day 0) and becomes overdue the following day; harassment training is due 30 days after start_date.",
      "policy_set": "us-ny",
      "as_of": "2026-12-07",
      "facts": {
        "work/location_country": "US",
        "work/location_state": "NY",
        "engagement/classification": "w2",
        "engagement/start_date": "2026-12-07",
        "engagement/reviewer": "usr_reviewer_01",
        "engagement/employer_id": "emp_ny_01"
      },
      "expect": {
        "required": [
          "ny_pay_notice",
          "ny_harassment_training"
        ],
        "not_required": [],
        "states": {
          "ny_pay_notice": "available",
          "ny_harassment_training": "available"
        },
        "missing_facts": []
      },
      "steps": [
        {
          "name": "advance-past-pay-notice-due-date",
          "as_of": "2026-12-08",
          "expect": {
            "required": [
              "ny_pay_notice",
              "ny_harassment_training"
            ],
            "not_required": [],
            "states": {
              "ny_pay_notice": "overdue",
              "ny_harassment_training": "available"
            },
            "missing_facts": []
          }
        },
        {
          "name": "advance-past-training-due-date",
          "as_of": "2027-01-07",
          "expect": {
            "required": [
              "ny_pay_notice",
              "ny_harassment_training"
            ],
            "not_required": [],
            "states": {
              "ny_pay_notice": "overdue",
              "ny_harassment_training": "overdue"
            },
            "missing_facts": []
          }
        }
      ]
    },
    {
      "name": "ny-rehire-reuse-and-annual-renewal",
      "description": "New York W-2 rehire with prior harassment training for the same employer reuses it while within 1 year and opens a renewal within 30 days of expiry; pay notice is required fresh; advancing past 1-year expiry requires fresh training.",
      "policy_set": "us-ny",
      "as_of": "2026-12-01",
      "facts": {
        "work/location_country": "US",
        "work/location_state": "NY",
        "engagement/classification": "w2",
        "engagement/start_date": "2026-12-28",
        "engagement/reviewer": "usr_reviewer_01",
        "engagement/employer_id": "emp_ny_01"
      },
      "evidence": [
        {
          "id": "doc_prior_ny_training",
          "template": "us_ny_harassment_training",
          "template_version": "2026.1.0",
          "status": "completed",
          "completed_at": "2025-12-20",
          "facts": {
            "engagement/employer_id": "emp_ny_01"
          }
        }
      ],
      "expect": {
        "required": [
          "ny_pay_notice",
          "ny_harassment_training",
          "ny_harassment_training:renewal"
        ],
        "not_required": [],
        "states": {
          "ny_pay_notice": "available",
          "ny_harassment_training": "complete",
          "ny_harassment_training:renewal": "available"
        },
        "missing_facts": []
      },
      "steps": [
        {
          "name": "advance-past-1-year-training-expiry",
          "as_of": "2026-12-21",
          "expect": {
            "required": [
              "ny_pay_notice",
              "ny_harassment_training"
            ],
            "not_required": [
              "ny_harassment_training:renewal"
            ],
            "states": {
              "ny_pay_notice": "available",
              "ny_harassment_training": "available"
            },
            "missing_facts": []
          }
        }
      ]
    }
  ]
}

Forma Lisp

Show Forma Lisp source us-ny.forma
(pack us-ny
  :format 1
  :version "2026.12.0"
  :kind "library"
  :description "New York employment compliance library pack: NY Labor Law §195(1) Pay Notice at Hire and NY Labor Law §201-g annual Sexual Harassment Prevention Training.")

;; ── Pack Dependencies ──────────────────────────────────────────────────────

(require-pack staffing-core :range "^2026.12")

;; ── Document Templates ─────────────────────────────────────────────────────

(template us_ny_ls54_pay_notice
  :version "2026.1.0"
  :title "New York Notice and Acknowledgment of Pay Rate and Payday (NY Labor Law §195(1))"
  :roles
    [{:name "employer" :kind "user" :label "Employer Representative"}
     {:name "employee" :kind "person" :label "Employee" :after ["employer"]}]
  :sections
    [{:id "pay_notice_terms"
       :role "employer"
       :title "Employer and Pay Rate Disclosures"
       :fields
        [{:id "legal_employer_name"
           :type "text"
           :label "Legal Name of Hiring Employer"
           :required true}
         {:id "dba_name"
           :type "text"
           :label "Doing Business As (DBA) Name(s)"
           :required false}
         {:id "pay_rate"
           :type "text"
           :label "Rate(s) of Pay and Overtime Rate"
           :required true}
         {:id "pay_basis"
           :type "choice"
           :label "Basis of Pay"
           :options ["hour" "shift" "day" "week" "salary" "piece" "commission"]
           :required true}
         {:id "allowances_claimed"
           :type "choice"
           :label "Allowances Claimed as Part of Minimum Wage"
           :options ["none" "tips" "meals" "lodging" "other"]
           :required true}
         {:id "regular_payday"
           :type "text"
           :label "Regular Payday Designated by Employer"
           :required true}
         {:id "primary_language"
           :type "text"
           :label "Employee Primary Language"
           :required true}]}
     {:id "acknowledgment"
       :role "employee"
       :title "Employee Acknowledgment of Receipt"
       :readable ["pay_notice_terms"]
       :fields [{:id "received_date" :type "date" :label "Date Received" :required true}]
       :signature
        {:id "employee_signature"
         :attestation "I acknowledge receipt of this Notice and Acknowledgment of Pay Rate and Payday pursuant to New York Labor Law §195(1)."
         :covers ["pay_notice_terms" "acknowledgment"]}}])

(template us_ny_harassment_training
  :version "2026.1.0"
  :title "New York Sexual Harassment Prevention Training Attestation (NY Labor Law §201-g)"
  :roles [{:name "employee" :kind "person" :label "Employee"}]
  :sections
    [{:id "training_completion"
       :role "employee"
       :title "Annual Training Completion Record"
       :fields
        [{:id "completed_date" :type "date" :label "Completion Date" :required true}
         {:id "delivery_format"
           :type "choice"
           :label "Interactive Delivery Format"
           :options ["interactive_online" "live_in_person" "live_virtual"]
           :required true}
         {:id "provider_name"
           :type "text"
           :label "Training Provider or Program"
           :required true}]
       :signature
        {:id "employee_signature"
         :attestation "I attest that I have completed the interactive New York sexual harassment prevention training required under New York Labor Law §201-g."
         :covers ["training_completion"]}}])

;; ── Compliance Policy Sets ─────────────────────────────────────────────────

(policy-set us-ny
  :version "2026.12.0"
  :facts
    {"work/location_country" {:type "choice" :options ["US" "CA" "GB" "MX" "OTHER"]}
     "work/location_state"
      {:type "choice"
       :options
        ["AL"
         "AK"
         "AZ"
         "AR"
         "CA"
         "CO"
         "CT"
         "DE"
         "DC"
         "FL"
         "GA"
         "HI"
         "ID"
         "IL"
         "IN"
         "IA"
         "KS"
         "KY"
         "LA"
         "ME"
         "MD"
         "MA"
         "MI"
         "MN"
         "MS"
         "MO"
         "MT"
         "NE"
         "NV"
         "NH"
         "NJ"
         "NM"
         "NY"
         "NC"
         "ND"
         "OH"
         "OK"
         "OR"
         "PA"
         "PR"
         "RI"
         "SC"
         "SD"
         "TN"
         "TX"
         "UT"
         "VT"
         "VA"
         "WA"
         "WV"
         "WI"
         "WY"]}
     "engagement/classification" {:type "choice" :options ["w2" "1099"]}
     "engagement/start_date" {:type "date"}
     "engagement/reviewer" {:type "string"}
     "engagement/employer_id" {:type "string"}}
  :stages
    [{:id "ny_notices" :title "New York Statutory Notices"}
     {:id "ny_training" :title "New York Mandatory Training"}]
  :requirements
    {:ny_pay_notice
      {:title "New York Pay Notice at Hire (NY Labor Law §195(1))"
       :kind "document"
       :template "us_ny_ls54_pay_notice"
       :stage "ny_notices"
       :parties {:employer "engagement/reviewer" :employee "subject"}
       :due
        {:employer {:relative_to "engagement/start_date" :days 0}
         :employee {:relative_to "engagement/start_date" :days 0}}
       :on_unknown "wait"
       :cites ["NY Labor Law §195(1)"]
       :authority "statute"}
     :ny_harassment_training
      {:title "New York Sexual Harassment Prevention Training (Annual)"
       :kind "document"
       :template "us_ny_harassment_training"
       :stage "ny_training"
       :parties {:employee "subject"}
       :due {:employee {:relative_to "engagement/start_date" :days 30}}
       :reuse {:same ["engagement/employer_id"] :max_age_days 365 :outcome "satisfies"}
       :expires {:years 1}
       :renew_within {:days 30}
       :on_unknown "wait"
       :cites ["NY Labor Law §201-g"]
       :authority "statute"}}
  :policies
    [{:id "us-ny-pay-notice-w2"
       :title "New York Pay Notice at Hire for W-2 employees working in New York"
       :when
        {:all
          [{:fact "work/location_country" :operator "equal" :value "US"}
           {:fact "work/location_state" :operator "equal" :value "NY"}
           {:fact "engagement/classification" :operator "equal" :value "w2"}]}
       :require ["ny_pay_notice"]
       :optional false
       :cites ["NY Labor Law §195(1)"]}
     {:id "us-ny-harassment-training-w2"
       :title "New York annual Sexual Harassment Prevention Training for New York W-2 employees"
       :when
        {:all
          [{:fact "work/location_country" :operator "equal" :value "US"}
           {:fact "work/location_state" :operator "equal" :value "NY"}
           {:fact "engagement/classification" :operator "equal" :value "w2"}]}
       :require ["ny_harassment_training"]
       :optional false
       :cites ["NY Labor Law §201-g"]}])

;; ── Declarative Scenarios ──────────────────────────────────────────────────

(scenario ny-w2-new-hire
  :description "New US W-2 employee working in New York requires the NY Labor Law §195(1) pay notice at hire and NY Labor Law §201-g sexual harassment prevention training."
  :policy-set "us-ny"
  :as-of "2026-12-01"
  :facts
    {"work/location_country" "US"
     "work/location_state" "NY"
     "engagement/classification" "w2"
     "engagement/start_date" "2026-12-07"
     "engagement/reviewer" "usr_reviewer_01"
     "engagement/employer_id" "emp_ny_01"}
  :expect
    {:required ["ny_pay_notice" "ny_harassment_training"]
     :not_required []
     :states {:ny_pay_notice "available" :ny_harassment_training "available"}
     :missing_facts []})

(scenario non-ny-w2-exempt
  :description "US W-2 employee working in New Jersey does not trigger New York statutory requirements."
  :policy-set "us-ny"
  :as-of "2026-12-01"
  :facts
    {"work/location_country" "US"
     "work/location_state" "NJ"
     "engagement/classification" "w2"
     "engagement/start_date" "2026-12-07"
     "engagement/reviewer" "usr_reviewer_01"
     "engagement/employer_id" "emp_ny_01"}
  :expect
    {:required []
     :not_required ["ny_pay_notice" "ny_harassment_training"]
     :missing_facts []})

(scenario ny-1099-contractor-exempt
  :description "1099 independent contractor working in New York is exempt from W-2 NY pay notice and employee sexual harassment training requirements."
  :policy-set "us-ny"
  :as-of "2026-12-01"
  :facts
    {"work/location_country" "US"
     "work/location_state" "NY"
     "engagement/classification" "1099"
     "engagement/start_date" "2026-12-07"
     "engagement/reviewer" "usr_reviewer_01"
     "engagement/employer_id" "emp_ny_01"}
  :expect
    {:required []
     :not_required ["ny_pay_notice" "ny_harassment_training"]
     :missing_facts []})

(scenario missing-work-state-waiting
  :description "When work/location_state is unknown, NY requirements wait on missing facts; supplying NY makes both available."
  :policy-set "us-ny"
  :as-of "2026-12-01"
  :facts
    {"work/location_country" "US"
     "engagement/classification" "w2"
     "engagement/start_date" "2026-12-07"
     "engagement/reviewer" "usr_reviewer_01"
     "engagement/employer_id" "emp_ny_01"}
  :expect
    {:required ["ny_pay_notice" "ny_harassment_training"]
     :not_required []
     :states {:ny_pay_notice "blocked_on_facts" :ny_harassment_training "blocked_on_facts"}
     :missing_facts ["work/location_state"]}
  :steps
    [{:name "provide-ny-work-state"
       :set_facts {"work/location_state" "NY"}
       :expect
        {:required ["ny_pay_notice" "ny_harassment_training"]
         :not_required []
         :states {:ny_pay_notice "available" :ny_harassment_training "available"}
         :missing_facts []}}])

(scenario ny-due-dates-and-overdue
  :description "NY pay notice is due on engagement/start_date (day 0) and becomes overdue the following day; harassment training is due 30 days after start_date."
  :policy-set "us-ny"
  :as-of "2026-12-07"
  :facts
    {"work/location_country" "US"
     "work/location_state" "NY"
     "engagement/classification" "w2"
     "engagement/start_date" "2026-12-07"
     "engagement/reviewer" "usr_reviewer_01"
     "engagement/employer_id" "emp_ny_01"}
  :expect
    {:required ["ny_pay_notice" "ny_harassment_training"]
     :not_required []
     :states {:ny_pay_notice "available" :ny_harassment_training "available"}
     :missing_facts []}
  :steps
    [{:name "advance-past-pay-notice-due-date"
       :as_of "2026-12-08"
       :expect
        {:required ["ny_pay_notice" "ny_harassment_training"]
         :not_required []
         :states {:ny_pay_notice "overdue" :ny_harassment_training "available"}
         :missing_facts []}}
     {:name "advance-past-training-due-date"
       :as_of "2027-01-07"
       :expect
        {:required ["ny_pay_notice" "ny_harassment_training"]
         :not_required []
         :states {:ny_pay_notice "overdue" :ny_harassment_training "overdue"}
         :missing_facts []}}])

(scenario ny-rehire-reuse-and-annual-renewal
  :description "New York W-2 rehire with prior harassment training for the same employer reuses it while within 1 year and opens a renewal within 30 days of expiry; pay notice is required fresh; advancing past 1-year expiry requires fresh training."
  :policy-set "us-ny"
  :as-of "2026-12-01"
  :facts
    {"work/location_country" "US"
     "work/location_state" "NY"
     "engagement/classification" "w2"
     "engagement/start_date" "2026-12-28"
     "engagement/reviewer" "usr_reviewer_01"
     "engagement/employer_id" "emp_ny_01"}
  :evidence
    [{:id "doc_prior_ny_training"
       :template "us_ny_harassment_training"
       :template_version "2026.1.0"
       :status "completed"
       :completed_at "2025-12-20"
       :facts {"engagement/employer_id" "emp_ny_01"}}]
  :expect
    {:required ["ny_pay_notice" "ny_harassment_training" "ny_harassment_training:renewal"]
     :not_required []
     :states
      {:ny_pay_notice "available"
       :ny_harassment_training "complete"
       "ny_harassment_training:renewal" "available"}
     :missing_facts []}
  :steps
    [{:name "advance-past-1-year-training-expiry"
       :as_of "2026-12-21"
       :expect
        {:required ["ny_pay_notice" "ny_harassment_training"]
         :not_required ["ny_harassment_training:renewal"]
         :states {:ny_pay_notice "available" :ny_harassment_training "available"}
         :missing_facts []}}])