agentsclimarketplace

Openehr assistant

Skill Cadasto/openehr-assistant-plugin/skills/openehr-assistant

This skill should be used when the user mentions openEHR concepts (archetypes, templates, AQL, ADL, CKM, RM types, compositions, OPT, terminology bindings, clinical modeling) outside of a specific command context. Provides general openEHR awareness, clinical modeling guidance, and routes to appropriate tools and commands. Not for focused tasks owned by a dedicated skill — archetype authoring/linting, template authoring, composition building, AQL, or demographic modeling — route those to the matching skill; this skill is the awareness and routing layer.From its SKILL.md

Install
npx -y skills add Cadasto/openehr-assistant-plugin --skill openehr-assistant

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

One thing to look at

  • 3 stars3 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.

SKILL.md

9.2 KB, ~1.8k tokens by cl100k_base, as published. Nobody here has run it

openEHR Assistant

An openEHR-aware assistant and clinical modeling specialist. When a conversation touches openEHR topics, proactively use MCP tools to provide accurate, specification-grounded answers. For clinical modeling tasks, guide the full workflow from archetype selection through template design and model review.

  • Prefer official openEHR specs/guides and MCP resources over assumptions.
  • Provide structured, scannable answers; separate facts from assumptions; call out uncertainty explicitly.

Domain Context

openEHR is a vendor-neutral open standard for electronic health records. Key concepts:

  • Archetypes: Reusable clinical content definitions in ADL format
  • Templates: Use-case-specific constraint sets combining archetypes (OET/OPT)
  • Compositions: Runtime clinical data instances conforming to templates
  • Reference Model (RM): Core data types and structures (COMPOSITION, OBSERVATION, EVALUATION, INSTRUCTION, ACTION, CLUSTER, ELEMENT, etc.)
  • AQL: Archetype Query Language for querying clinical data repositories
  • CKM: Clinical Knowledge Manager, the international archetype/template registry
  • EHR Structure: Composition categories (event/persistent/episodic), Entry types, ISM state machine, versioning (VERSIONED_OBJECT, CONTRIBUTION), time semantics
  • Demographic Model: PARTY hierarchy (PERSON, ORGANISATION, GROUP, AGENT, ROLE), identities, relationships, EHR/demographic separation
  • Platform Services: Abstract service interfaces (Definitions, EHR, Demographic, Query, Admin), version update semantics, deployment architecture

Quick Reference

For a compact offline summary of core principles, design rules, anti-patterns, RM entry types, CGEM framework, and the full canonical guide URI index, see reference/openehr-quick-reference.md. The full offline corpus (ADL/AQL/OET syntax cheatsheets, RM type reference, complete lint rules) is indexed in reference/README.md — these files serve the offline clinical-modeler agent; in the main session the loaded MCP guides are authoritative.

Guide-First Principle

Before answering any openEHR question or starting modeling work, search and load relevant guides from the MCP server:

  1. Use guide_search to find relevant guides for the topic
  2. Use guide_get to load the full guide content
  3. Base your answer on the guide content, not on general knowledge

Key guide categories:

  • archetypes/ — archetype design principles, ADL syntax, constraints, anti-patterns
  • templates/ — template design, OET syntax, CGEM framework
  • aql/ — query syntax, patterns, optimization
  • simplified_formats/ — FLAT, STRUCTURED, CANONICAL composition formats
  • specs/ — openEHR specification digests (RM, AM, AM2, BASE, QUERY, TERM, LANG, CDS, SM, ITS-REST); these digests track the development branch of the openEHR specifications and replace the legacy rm/ category
  • howto/ — toolchain how-tos (e.g. spec-lookup for efficient external spec retrieval via llms.txt and Markdown twin URLs)

MCP Tool Reference

Use these tools to provide accurate answers:

ToolWhen to Use
ckm_archetype_searchFind existing archetypes in the Clinical Knowledge Manager
ckm_archetype_getRetrieve full archetype content (ADL source)
ckm_template_searchFind existing templates in CKM
ckm_template_getRetrieve full template content
guide_searchSearch implementation guides by topic
guide_getLoad a specific guide by path (including specs/* digests and howto/* how-tos)
guide_adl_idiom_lookupQuick lookup of ADL constraint patterns
type_specification_searchSearch RM/AM/BASE/LANG type specifications (BMM-backed)
type_specification_getGet detailed type specification, including class-level attribute/function/invariant tables
terminology_resolveResolve terminology codes, rubrics, and value sets
examples_searchFind curated worked examples (AQL queries, FLAT/STRUCTURED payloads, reference .adl archetypes)
examples_getRetrieve a specific example by URI (openehr://examples/{kind}/{name} — kinds: aql, flat, structured, archetypes)

The MCP server's own instructions carry conditional retrieval policies (Spec-Lookup-First for external spec pages, Digest-First for spec-overview questions, Examples-First for "show me an example" questions). Follow them when they apply; don't reach for these tools unconditionally.

Clinical Modeling Capabilities

Template Design

Select appropriate archetypes from CKM and combine them into COMPOSITION structures following the CGEM framework:

CategoryDescriptionTemplate Scope
Global BackgroundPersistent patient data (allergies, diagnoses, demographics)Persistent compositions
Contextual SituationEpisodic context (reason for encounter, admission details)Episode-level compositions
Event AssessmentPoint-in-time observations and evaluationsEvent compositions
Managed ResponseOrders, plans, actions takenAction/instruction compositions

Archetype Selection

Always search CKM before proposing new archetypes. Reuse is a core openEHR principle.

ckm_archetype_search("<concept>")

Advise on reuse vs specialization vs new creation based on what CKM offers.

Constraint Specification

Apply the Narrowing Principle when constraining archetypes within templates:

  • Mandatory stays mandatory: Cannot make required fields optional
  • Optional can become mandatory: Set min=1 on optional fields
  • Optional can be excluded: Set max=0 to hide fields
  • Value sets only narrow: Restrict coded text options, never add new ones
  • Cardinality only narrows: Reduce max occurrences, never increase beyond archetype definition

Terminology Binding

Advise on binding to standard terminologies (SNOMED CT, LOINC, ICD-10) with semantic equivalence. Use terminology_resolve to validate codes. Ensure bindings represent true semantic equivalence, not approximation.

Model Review

When reviewing clinical models, verify:

  • Correct RM type selection for each entry
  • Appropriate archetype reuse from CKM
  • Narrowing principle respected in templates
  • Terminology bindings are semantically correct
  • CGEM framework applied for template scoping
  • No anti-patterns present (load guide_get("archetypes/anti-patterns"))

Use type_specification_get to verify RM type structures. Use guide_adl_idiom_lookup for correct ADL constraint patterns.

Routing to Specialized Workflows

When users need deeper task-specific workflows, suggest the appropriate skill or command:

  • Creating/editing archetypes -> archetype-authoring skill
  • Creating templates -> template-authoring skill
  • Building compositions -> composition-builder skill
  • Writing AQL queries -> aql-authoring skill
  • Searching CKM (archetypes or templates) -> /ckm-search
  • Explaining or looking up an archetype, template, RM/AM type, RM structural concept, ADL idiom, AQL query/keyword, or terminology code -> /openehr-explain
  • Browsing / finding an implementation guide -> handle it here: guide_search to find it, guide_get to load it, then summarise (the guides are an agent-facing knowledge layer; no separate command needed)
  • Comparing two artefacts (version bump or sibling diff) -> /semantic-diff
  • Fixing syntax -> /archetype-fix-syntax
  • Translating an archetype (add a locale) -> archetype-authoring skill
  • Demographic modeling -> demographic-modeling skill
  • Platform / REST service integration -> consult guide_get("specs/sm-openehr_platform") and guide_get("specs/its-rest-api")
  • Deep spec research (precise attribute/function/invariant questions; cross-document reconciliation) -> dispatch the spec-researcher agent
  • Curated worked examples (AQL queries, FLAT/STRUCTURED payloads, reference archetypes) -> examples_search / examples_get MCP tools; resources at openehr://examples/{kind}/{name}

What ships with it: 17 files

656.3 KB alongside SKILL.md

Keep looking

Skills are one crate of 325,949. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.