Ontologies with Style(s): Unterschied zwischen den Versionen

Aus CTS2-LE
Zur Navigation springen Zur Suche springen
K (OwS Tutorial)
K
 
(9 dazwischenliegende Versionen desselben Benutzers werden nicht angezeigt)
Zeile 1: Zeile 1:
  
== About Ontologies with Style(s) ==
+
==About Ontologies with Style(s)==
  
 
Ontologies with Style(s) - or OwS for short - is a language for defining structured vocabularies - from simple value sets up to complex ontologies. The editor for writing OwS programs is MS Word. OwS progams are executed by an interpreter that is implemented as a MS Word makro.
 
Ontologies with Style(s) - or OwS for short - is a language for defining structured vocabularies - from simple value sets up to complex ontologies. The editor for writing OwS programs is MS Word. OwS progams are executed by an interpreter that is implemented as a MS Word makro.
Zeile 13: Zeile 13:
 
:OwS runs from within your MS Word. Make sure you have all required libraries properly installed.
 
:OwS runs from within your MS Word. Make sure you have all required libraries properly installed.
  
== OwS Core Concepts ==
+
==OwS Core Concepts==
 
OwS is two interpreter languages in one. Under the hood there is a powerful but simple OwS Object Language (OOL) that allows to define arbitrary complex ontologies using a small set of OwS statements. You may write OwS programs in this language but mostly you will instead rather write some small macros in the OwS Macro Language (OML). Such macros define how common means of MS Word like style sheets and heading levels map onto the OwS Object Language. E.g. with a one-line-macro you can define that a level-2-headline shall define a ''codesystem'' object in the OwS Object Language with the name and URI of the codesystem povided in the headline text.
 
OwS is two interpreter languages in one. Under the hood there is a powerful but simple OwS Object Language (OOL) that allows to define arbitrary complex ontologies using a small set of OwS statements. You may write OwS programs in this language but mostly you will instead rather write some small macros in the OwS Macro Language (OML). Such macros define how common means of MS Word like style sheets and heading levels map onto the OwS Object Language. E.g. with a one-line-macro you can define that a level-2-headline shall define a ''codesystem'' object in the OwS Object Language with the name and URI of the codesystem povided in the headline text.
  
Zeile 21: Zeile 21:
 
:Learn more about objects and properties and OwS features for customizing these to your demands.
 
:Learn more about objects and properties and OwS features for customizing these to your demands.
  
== OwS Tutorial ==
+
==OwS Tutorial==
 +
 
 
;Defining a Terminology: From OOL to OML
 
;Defining a Terminology: From OOL to OML
 
:This initial course shows how to define a simple terminology. Starting with plain OOL, step-by-step additional OML means are applied in order to make the terminology definition look like a ordinary MS Word document.
 
:This initial course shows how to define a simple terminology. Starting with plain OOL, step-by-step additional OML means are applied in order to make the terminology definition look like a ordinary MS Word document.
:Lessons: [[OwS Tutorial: Defining a Terminology|Defining a Terminology]], [[OwS Tutorial: Setting Properties (Part 1)|Setting Properties (Part 1)]], [[OwS Tutorial: Mapping Concept Hierarchies onto Word Sections|Using Heading Styles]], [[OwS Tutorial: Using Defaults (Part 1)|Using Defaults (Part 1)]], [[OwS Tutorial: Mapping Properties onto Style Sheets|Binding Properties to Styles]], [[OwS Tutorial: Defining Custom Properties|Defining Custom Properties]], [[OwS Tutorial: Defining Custom Types|Defining Custom Types]]
+
:Lessons: [[OwS Tutorial: Defining a Terminology|Defining a Terminology]], [[OwS Tutorial: Setting Properties (Part 1)|Setting Properties (Part 1)]], [[OwS Tutorial: Mapping Concept Hierarchies onto Word Sections|Using Heading Styles]], [[OwS Tutorial: Using Defaults (Part 1)|Using Defaults (Part 1)]], [[OwS Tutorial: Mapping Properties onto Style Sheets|Binding Properties to Styles]], [[OwS Tutorial: Defining Custom Types|Defining Custom Types]]
 
;Linking Concepts: From Value Sets to Ontologies
 
;Linking Concepts: From Value Sets to Ontologies
 
:The second course shows how concepts from external code systems (e.g. ICD-10 or SNOMED CT) can be used in OwS. Starting with the setup of a value set based on existing concepts this section closes with the definition of an ontology that includes manifold links among concepts from different code systems.
 
:The second course shows how concepts from external code systems (e.g. ICD-10 or SNOMED CT) can be used in OwS. Starting with the setup of a value set based on existing concepts this section closes with the definition of an ontology that includes manifold links among concepts from different code systems.
Zeile 32: Zeile 33:
 
:Lessons: Using Patterns (Part 1), The Power of Obligations (Part 1), Defining your own Macro, Setting Properties (Part 3), Generating a Code Hierarchy
 
:Lessons: Using Patterns (Part 1), The Power of Obligations (Part 1), Defining your own Macro, Setting Properties (Part 3), Generating a Code Hierarchy
  
== OwS Language Reference ==
+
==OwS Language Reference==
 
This section provides links to the full OwS language reference that gives full definition for all OwS statements, directives, types and objects.  
 
This section provides links to the full OwS language reference that gives full definition for all OwS statements, directives, types and objects.  
  
;[[OwS Syntax|OOL Syntax Overview]]  
+
;[[OwS Syntax|OOL Syntax Overview]]
 
:This overview shows the complete OwS language syntax on a single page.
 
:This overview shows the complete OwS language syntax on a single page.
  
 
;[[OwS Object Language (OOL)|OwS Object Language (OOL)]]
 
;[[OwS Object Language (OOL)|OwS Object Language (OOL)]]
:'''OOL Language Reference:''' [[OwS Statement: Base Types|''Base Types'']] ;[[OwS Statement: define|''define'' statement]], [[OwS Statement: set|''set'' statement]], [[OwS Statement: default|''default'' statement]], [[OwS Statement: Object Relationship|''---->'' statement]]
+
:'''OOL Language Reference:''' [[OwS Statement: Base Types|''Base Types'']] ;[[OwS Statement: define|''define'' statement]], [[OwS Statement: set|''set'' statement]], [[OwS Statement: default|''default'' statement]], [[OwS Statement: Object Relationship|''---->'' statement]], [[OwS Statement: linksystem|''linksystem'' statement]]
:'''OOL Object Types:''' [[OwS Object Type: codesystem|''codesystem'']], [[OwS Object Type: system|''system'']], [[OwS Object Type: concept|''concept'']], [[OwS Object Type: predicate|''predicate'']], [[OwS Object Type: property|''property'']], [[OwS Object Type: string|''string'']], [[OwS Object Type: collection|''collection'']], [[OwS Object Type: object|object]], [[OwS Object Type: type|type]]
+
:'''OOL Object Types:''' [[OwS Object Type: ''Domain|Domain'']], [[OwS Object Type: codesystem|''Codesystem'']], [[OwS Object Type: system|''System'']], [[OwS Object Type: Concept|''Concept'']], [[OwS Object Type: predicate|''Predicate'']], [[OwS Object Type: property|''Property'']], [[OwS Object Type: string|''string'']], [[OwS Object Type: collection|''collection'']], [[OwS Object Type: object|''Object'']], [[OwS Object Type: type|''Type'']]
 
:'''OOL System Objects:''' [[OwS System Object: CTS2LE|''CTS2LE'']], [[OwS System Object: OwS|''OwS'']], [[OwS System Object: FHIR|''FHIR'']]
 
:'''OOL System Objects:''' [[OwS System Object: CTS2LE|''CTS2LE'']], [[OwS System Object: OwS|''OwS'']], [[OwS System Object: FHIR|''FHIR'']]
  
 
;[[OwS Macro Language (OML)|OwS Macro Language (OML)]]
 
;[[OwS Macro Language (OML)|OwS Macro Language (OML)]]
:'''OML Style Sheet Directives:''' [[OwS Style Sheet Directive: OwS.StyleName|''OwS.StyleName'']], [[OwS Style Sheet Directive: heading|''#heading'' directive]], [[OwS Style Sheet Directive: obligation|''#obligation'' directive]], [[OwS Style Sheet Directive: pattern|''#pattern'' directive]], [[OwS Style Sheet Directive: table|''#table'' directive]]  
+
:'''OML Style Sheet Directives:''' [[OwS Style Sheet Directive: OwS.StyleName|''OwS.StyleName'']], [[OwS Style Sheet Directive: heading|''#heading'' directive]], [[OwS Style Sheet Directive: obligation|''#obligation'' directive]], [[OwS Style Sheet Directive: pattern|''#pattern'' directive]], [[OwS Style Sheet Directive: table|''#table'' directive]] , [[OwS Style Sheet Directive: stylemapping|''#stylemapping'' directive]]
 
:'''OML Tokenizer Directives:''' [[OwS Tokenizer Directive: goto|''#goto ... #return'']], [[OwS Tokenizer Directive: package|''#package ... #endpackage'']]
 
:'''OML Tokenizer Directives:''' [[OwS Tokenizer Directive: goto|''#goto ... #return'']], [[OwS Tokenizer Directive: package|''#package ... #endpackage'']]
 +
 +
==OwS Plug-Ins==
 +
OwS plug-ins are Word VBA classes that can be linked with the OwS compiler at runtime for processing user-defined input formats and OwS language extensions. 
 +
 +
;Writing your own PwS Plug-In
 +
 +
*[[Executing a Plug-In from an OwS Document]]
 +
*[[Plugin Template for VBA Developers]]
 +
*[[Registering a Plugin with OwS]]
 +
 +
;Available Plug-Ins
 +
 +
*[[puml2ows]]: Import PlantUML classes as OwS type definitions
 +
*[[puml2openAPI]]: Import PlantUML classes for rendering API specifications
 +
 +
 +
==OwS Versions and Fixes==
 +
 +
;[[OwS Change Log|OwS Change Log]]
 +
:The change log records all bug fixes and added features to the OwS interpreter

Aktuelle Version vom 28. Dezember 2022, 19:43 Uhr

About Ontologies with Style(s)

Ontologies with Style(s) - or OwS for short - is a language for defining structured vocabularies - from simple value sets up to complex ontologies. The editor for writing OwS programs is MS Word. OwS progams are executed by an interpreter that is implemented as a MS Word makro.

While OwS commands are embedded into any MS Word document, the specification of a vocabulary is also the documentation of the vocabulary. For making OwS look like "normal" MS Word texts, OwS commands can be linked to style sheets. The OwS interpreter implicitly executes the commands assigned to a style sheet whenever it discovers a line of text within a document that if formatted using this style sheet. By this you can e.g. advise the interpreter to consider headline hierarchies as hierarchies of concepts.

A First Example
This example gives an impression how a typical OwS code system definition looks like.
FHIR, CTS2, CTS2-LE and OwS
Learn how OwS fully builds upon standards and works together with the CTS2-LE terminology server.
Installation and Setup
OwS runs from within your MS Word. Make sure you have all required libraries properly installed.

OwS Core Concepts

OwS is two interpreter languages in one. Under the hood there is a powerful but simple OwS Object Language (OOL) that allows to define arbitrary complex ontologies using a small set of OwS statements. You may write OwS programs in this language but mostly you will instead rather write some small macros in the OwS Macro Language (OML). Such macros define how common means of MS Word like style sheets and heading levels map onto the OwS Object Language. E.g. with a one-line-macro you can define that a level-2-headline shall define a codesystem object in the OwS Object Language with the name and URI of the codesystem povided in the headline text.

Directives vs. Statements
Learn more about the two languages that make up OwS and how they are interlaced to simplify the definition of ontologies.
OwS Objects
Learn more about objects and properties and OwS features for customizing these to your demands.

OwS Tutorial

Defining a Terminology: From OOL to OML
This initial course shows how to define a simple terminology. Starting with plain OOL, step-by-step additional OML means are applied in order to make the terminology definition look like a ordinary MS Word document.
Lessons: Defining a Terminology, Setting Properties (Part 1), Using Heading Styles, Using Defaults (Part 1), Binding Properties to Styles, Defining Custom Types
Linking Concepts: From Value Sets to Ontologies
The second course shows how concepts from external code systems (e.g. ICD-10 or SNOMED CT) can be used in OwS. Starting with the setup of a value set based on existing concepts this section closes with the definition of an ontology that includes manifold links among concepts from different code systems.
Lessons: Using an External Code System, OwS Global Objects, Defining a Value Set, Linking Concepts, Using Defaults (Part 2), Setting Properties (Part 2)
Hiding it All: From Patterns to Programing
The third course shows how you can use OwS features to fully hide away OwS behind commom MS Word elements. Starting with further text replacement directives, this section stepwise goes into programing your own macros for processing MS Word styles.
Lessons: Using Patterns (Part 1), The Power of Obligations (Part 1), Defining your own Macro, Setting Properties (Part 3), Generating a Code Hierarchy

OwS Language Reference

This section provides links to the full OwS language reference that gives full definition for all OwS statements, directives, types and objects.

OOL Syntax Overview
This overview shows the complete OwS language syntax on a single page.
OwS Object Language (OOL)
OOL Language Reference: Base Types ;define statement, set statement, default statement, ----> statement, linksystem statement
OOL Object Types: Domain, Codesystem, System, Concept, Predicate, Property, string, collection, Object, Type
OOL System Objects: CTS2LE, OwS, FHIR
OwS Macro Language (OML)
OML Style Sheet Directives: OwS.StyleName, #heading directive, #obligation directive, #pattern directive, #table directive , #stylemapping directive
OML Tokenizer Directives: #goto ... #return, #package ... #endpackage

OwS Plug-Ins

OwS plug-ins are Word VBA classes that can be linked with the OwS compiler at runtime for processing user-defined input formats and OwS language extensions.

Writing your own PwS Plug-In
Available Plug-Ins
  • puml2ows: Import PlantUML classes as OwS type definitions
  • puml2openAPI: Import PlantUML classes for rendering API specifications


OwS Versions and Fixes

OwS Change Log
The change log records all bug fixes and added features to the OwS interpreter