Skip to content

InferRxNorm

Source: src/AWS/ComprehendMedical/InferRxNorm.ts

Runtime binding for comprehendmedical:InferRxNorm — detect medication entities in clinical text and link them to concept identifiers in the RxNorm ontology (medication names, dosages, frequencies).

Comprehend Medical has no resource-level IAM, so the binding takes no arguments and grants comprehendmedical:InferRxNorm on *. Provide the implementation with Effect.provide(AWS.ComprehendMedical.InferRxNormHttp).

// init
const inferRxNorm = yield* AWS.ComprehendMedical.InferRxNorm();
// runtime
const result = yield* inferRxNorm({
Text: "Patient takes 50 mg atenolol daily.",
});
const concepts = (result.Entities ?? []).flatMap((e) => e.RxNormConcepts ?? []);