@governed-ai/health
v1.0.0
Published
Health domain pack for @governed-ai/runtime: query classification, fabrication/safety validators, response normalization, policy, entity rules, and certification scenarios for the health domain.
Maintainers
Readme
@governed-ai/health
Health domain pack for @governed-ai/runtime.
Purpose
@governed-ai/runtime is an agent-agnostic governance framework. It contains no
healthcare-specific logic by design. @governed-ai/health is the domain pack that
supplies the healthcare behavior the runtime expects through composition:
- Health query classification
- Fabrication / safety reasoning validation
- Response normalization
- Health policy pack (blocked queries, privacy, safety)
- Health entity rules
- Health certification scenarios
Relationship to @governed-ai/runtime
The dependency direction is one-way:
@governed-ai/runtime (domain-agnostic core)
▲
@governed-ai/health (this package — depends on the runtime)The runtime never depends on this package. This package depends on the runtime's interfaces and is wired in at your application's composition root.
Installation
npm install @governed-ai/runtime @governed-ai/healthThis package requires @governed-ai/runtime ^2.0.0. See Version compatibility
below.
Quick start
import { PolicyEngine } from "@governed-ai/runtime";
import {
healthDefaultImplementations,
healthEntityRules,
HEALTH_POLICY_PATH,
HEALTH_CERTIFICATION_SCENARIOS,
} from "@governed-ai/health";
// Drive the runtime's policy engine with the health policy pack.
const policyEngine = new PolicyEngine(HEALTH_POLICY_PATH);
// Provide the health implementations of the runtime's governance interfaces.
const { queryClassifier, postInteractionGovernance, responseNormalizer } =
healthDefaultImplementations;
// healthEntityRules and HEALTH_CERTIFICATION_SCENARIOS plug into the runtime's
// domain registry and certification test runner respectively.Exported components
| Export | Kind | Description |
| --- | --- | --- |
| QueryClassifier | class | Health implementation of the runtime IQueryClassifier. |
| PostInteractionGovernance | class | Health implementation of IPostInteractionGovernance (fabrication / safety). |
| ResponseNormalizer | class | Health implementation of IResponseNormalizer. |
| healthDefaultImplementations | const | Bundle of the three implementations above. |
| defaultGovernanceImplementations | const | Alias bundle for generic wiring. |
| healthEntityRules | const | Health DomainEntityRules for the domain registry. |
| HEALTH_POLICY_PATH | const | Absolute path to the bundled health policy YAML. |
| HEALTH_CERTIFICATION_SCENARIOS | const | Health UAT scenarios for the certification runner. |
| HealthQueryType | type | Health-specific query type literals. |
HealthQueryType
The runtime exposes an open QueryType (GovernanceQueryType | (string & {})) so
each domain supplies its own literals without modifying the runtime. HealthQueryType
provides the health domain's literals (e.g. biomarker, diagnosis, medication, and
general-health queries) and is used by the health QueryClassifier.
Health policy pack
HEALTH_POLICY_PATH resolves to the bundled domains/health/policy.yaml inside the
installed package (resolved via import.meta.url, so it works from any consumer).
Pass it to new PolicyEngine(HEALTH_POLICY_PATH) to enforce blocked-query, privacy,
and safety policy for the health domain.
Certification scenarios
HEALTH_CERTIFICATION_SCENARIOS is an array of UAT scenarios consumable by the
runtime's CertificationTestRunner to certify safety, hallucination, privacy, and
tool-governance behavior for the health domain.
Version compatibility
| @governed-ai/health | requires @governed-ai/runtime | | --- | --- | | 1.0.0 | ^2.0.0 |
This package depends on the runtime 2.0.0 contract (entity-based context fields and
the domain-agnostic governance interfaces). It is not compatible with
@governed-ai/[email protected].
