WHO SMART Trust
1.0.0 - 1.0.0

WHO SMART Trust, published by WHO. This guide is not an authorized publication; it is the continuous build for version 1.0.0 built by the FHIR (HL7® FHIR® Standard) CI Build. This version is based on the current content of https://github.com/WorldHealthOrganization/smart-trust and changes regularly. See the Directory of published versions

## Instructions

This Implementation Guide, smart-ig-empty, is a GitHub template repostiory which means that it can be used as a starting point for developing a new Implementation Guide. Following these instructions will ensure consistent styling and content structure to ease adoption of WHO's SMART Guidelines. This

### Creating a new WHO SMART Guidline

#### Creating a new GitHub repository

- Choose an apporpriate for the Implementation Guide you are developing. The code of this implemenation guide is smart-ig-empty. For the sake of the following instructions, we will assume that you have chosen smart-ig-my-guide.
- This Implementation Guide is a template repository and you should create a repository from this template named smart-ig-my-guide.
- If you don't have a gh-pages branch, you can reate an empty gh-pages branch on the new repo using the commands:

  >     git checkout --orphan gh-pages
  >     git reset --hard
  >     git commit --allow-empty -m "Initializing gh-pages branch"
  >     git push origin gh-pages
  >     git checkout main

  Then, under the repoistory, navigate to 'Settings->Pages' and set the 'Source' to 'gh-pages'.

#### Modifying the template repository

- Modify the following files as indiciated:
  ig.ini
    Change the text smart-ig-empty to smart-ig-my-guide in the 'ig' field.
  sushi-config.yaml
    - Choose a title for this Implementation Guide and update the 'title' field.
    - Modify the 'email' field as apporpriate. TODO: create a SMART Guidlines email
    - Modify the 'description' field as appopriate.
    - Change the text smart-ig-empty to smart-ig-my-guide in the 'id', 'canonical' and 'name' fields
    - Change the 'date' field to the current date
    - Add an appropriate dependencies under the 'dependencies' field.
    See sushi config instructions for more infomration on this file.
  input/data/features.yml
    Change the text smart-ig-empty to smart-ig-my-guide in the 'feedback.dashboard.url' field @Jose: anything else to do here?

### Country adaptation of an existing guide

Basic country adaptation of SMART Implementation Guide has a few additional steps. In this case, rather than creating a new repostiory based off of smart-ig-empty you should fork an existing repository, such as smart-ig-anc. Determine the appropriate ISO-alpha3 and M49 ISO-3166 jurisdicition codes. For the purposes of these instructions, suppose it is EXA and 999 for an 'Example' country.

- Name the forked repository the same as the repository you are forking from but you should add the ISO-alpha3 code to then end. For example smart-ig-anc would beceom smart-ig-anc-exa
- Further modify the following files:
  ig.ini
    - Change the occurence of who in the 'ig' field to the lower-case version of the country code, exa, or whatever is the convention in your country. For example, 'ig = fsh-generated/resources/ImplementationGuide-fhir.exa.smart-ig-anc.json.
  sushi-config.yaml
    - Modigy the 'id' field and replace who with the lower-case version of the country code, exa, or whatever is the convention in your country. For example 'id: fhir.exa.smart-ig-anc-exa
    - Modifty the 'jursidiciton' field by changing the #001 to the appropriate M49 code found here. For example 'jurisdiction: http://unstats.un.org/unsd/methods/m49/m49.htm#999'
    - Update the 'publisher.name' and 'publisher.url' fields to something appropriate
    - Update the 'email' field to something appropriate
    - Change the 'title' field to add in the country name yet still show that it is adapted from the WHO SMART Guidelines. For example, 'WHO SMART Guideline: Antenatal Care' becomes 'WHO SMART Guideline: Antenatal Care for Example Country'
- Create new ValueSets and appopriate ConceptMaps based on country requirements
- Modify data collection resources (e.g. Questionnaires), logical models, and document structures to account for country specific data fields

### Directory layout for content

- ​ Create your content following the Smart Guidelines IG checklist and using the following directory and file structure:
  input/fsh
    ​ put any FHIR Shorthand (or fsh) files in this directory.
  input/images
    put any graphical artifacts that are used in this implementation guide
  input/images-source
    put UML, sequence diagrams, etc in this directory as plantUML diagrams. A UML diagram named XXXX.plantuml can be referenced in a xml file under input/pagecontent as 'include XXXX.svg' TODO: figure out how to esacpe jekyll control sequences
  input/pagecontent
    ​ Edit the following pages by providing content according to the Smart Guidelines IG checklist below.
    actors.xml
      Provide a list and definition of of any human or system actors involved in any transactions or sequence diagrams defined in this profile.
    changes.xml
      A list of verisoned changes to this implementation guide.
    concepts.xml
      Provide a descipription or definition of key concepts needed to understand this implementation guide. Some of these concepts may be introduced in referenced L2 content, in which case they should be copied over hear for ease of the reader as well as precise references to appropraite section(s) should be given here.
    content_profiles.xml
      Provide an overview of the health specific content profiles specified in the implementation guide.
    dependencies.xml
      Provide a list, linkages and description of the use of any dependencies in this implementation guide.
    dictionary.xml
      Replicate any relevant data dictionaries defined in L2 content. Each data dictionary should have a corresponding logical model.
    functional.xml
      Provide a descipription or definition of key concepts needed to understand this implementation guide. Some of these concepts may be introduced in referenced L2 content, in which case precise references to the appropriate section(s) should be given here.
    index.html
      Remove or comment out these instructions and the checklist. Modify the <blockquote class="stu-note"/> with the appropriate disclaimer text.
    personas.xml
      Provide a brief overview of the personas covered by this implementation guide. Some of these concepts may be introduced in referenced L2 content, in which case they should be copied over hear for ease of the reader as well as precise references to appropraite section(s) should be given here.
    usecases.xml
      Provide a brief overview of the use cases covered by this implementation guide. Some of these concepts may be introduced in referenced L2 content, in which case they should be copied over hear for ease of the reader as well as precise references to appropraite section(s) should be given here.
    testing.xml
      Provide information about testing executable artifacts based on this implementation guide
    security_privacy.xml
      Provide guidance on specific security and privacy concerns that may arise in executable versions of this profile.
    transactions.xml
      Provide a list and definition of of any transactions defined in this profile. There should be transactions defined or referneced in other implementation guides for each of the steps in the workflows in this implementation guide.
    workflows.xml
      Provide a list and desciption of workflows as UML sequence diagrams consiting of actors and transactions for each of the use cases taken up in this implementation guide.
  input/resources
    Resources defined by this profile (that are not .fsh files) are expected to be managed in the following structure
    examples
      Examples resources. As much as possible, examples should be provided in the official six UN languages.
    examples-src
      templated examples TODO: need @Richard's six UN language template example instructions
    maps-src
      StructureDefinition source files in the FHIR Mapping language
    structuredefinitions
      StructureDefintition defined in this profile
  local-template/package
    Contains any changes to the WHO SMART IG style template that are specific to this IG. More information is in these instructions.
    content/assets/css/local.css
      for any css changes that nad be added or overidden
  README.md
    Change the title and any instances of the text smart-ig-empty to smart-ig-my-guide.

### Generating an implmentation guide

- Install Implemenation Guide Publisher dependencies (Ubuntu instructions)

  >     apt-get install npm node.js jekyll
  >     npm install -g sushi

  See sushi install for more details.
- Run the IG Publisher in the root of the github repo (unix-y instructions):

  >     ./_updatePublisher.sh
  >     ./_genonce.sh

- If all is successful, open the local file 'output/index.html' in your browser and review the content as well as the quality assurance page under 'output/qa.html'
- Do a github commit, let the github action run. For a WHO SMART Guideline you can open GitHub pages at trust but change smart-ig-empty to smart-ig-my-guide.