text:
{
  "@context": "...",
  "id": "person1",
  "type": "IdentityProfile",
  "credential": [{
    "@graph": {
      "id": "cred1",
      "claim": {
        "id": "person1",
        "ageOver": 21
      },
      "signature": { ... }
    }, {
    "@graph": {
      "id": "cred2",
      "claim": {
        "id": "person1",
        "passport": { ... },
      },
      "signature": { ... }
    }
  }]
}


text:
#! /usr/bin/env ruby

require 'linkeddata'

unframed_json = JSON.parse '[
  {
    "@id": "http://vocab.getty.edu/ulan/500115403",
    "http://xmlns.com/foaf/0.1/focus": [
      {
        "@id": "http://vocab.getty.edu/ulan/500115403-agent"
      }
    ],
    "http://www.w3.org/2004/02/skos/core#prefLabel": [
      {
        "@value": "Couture, Thomas"
      }
    ],
    "http://www.w3.org/2004/02/skos/core#inScheme": [
      {
        "@id": "http://vocab.getty.edu/ulan/"
      }
    ],
    "http://schema.org/url": [
      {
        "@id": "http://www.getty.edu/vow/ULANFullDisplay?find=&role=&nation=&subjectid=500115403"
      }
    ]
  }
]'

frame = JSON.parse '{
  "@explicit": true,
  "@context": {
    "skos": "http://www.w3.org/2004/02/skos/core#",
    "foaf": "http://xmlns.com/foaf/0.1/",
    "schema": "http://schema.org/",
    "label": "skos:prefLabel",
    "id": "@id",
    "source": {
      "@id": "skos:inScheme",
      "@type": "@id"
    },
    "agent": {
      "@id": "foaf:focus",
      "@type": "@id"
    },
    "website": {
      "@id": "schema:url",
      "@type": "@id"
    }
  },
  "@requireAll": false,
  "@explicit": false,
  "label": {},
  "id": {},
  "source": {},
  "agent": {},
  "website": {}
}'

puts JSON::LD::API.frame(unframed_json, frame, logger: STDERR).to_json(JSON::LD::JSON_STATE)

repo_name: ruby-rdf/json-ld

repo_language: HTML

mime_type: text/plain


text:
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix owl: <http://www.w3.org/2002/07/owl#> .
@prefix dc: <http://purl.org/dc/elements/1.1/> .

<http://www.w3.org/1999/02/22-rdf-syntax-ns#> a owl:Ontology ;
	dc:title "The RDF Concepts Vocabulary (RDF)" ;
	dc:description "This is the RDF Schema for the RDF vocabulary terms in the RDF Namespace, defined in RDF 1.1 Concepts." .

rdf:HTML a rdfs:Datatype ;
	rdfs:subClassOf rdfs:Literal ;
	rdfs:isDefinedBy <http://www.w3.org/1999/02/22-rdf-syntax-ns#> ;
	rdfs:seeAlso <http://www.w3.org/TR/rdf11-concepts/#section-html> ;
	rdfs:label "HTML" ;
	rdfs:comment "The datatype of RDF literals storing fragments of HTML content" .

rdf:langString a rdfs:Datatype ;
	rdfs:subClassOf rdfs:Literal ;
	rdfs:isDefinedBy <http://www.w3.org/1999/02/22-rdf-syntax-ns#> ;
	rdfs:seeAlso <http://www.w3.org/TR/rdf11-concepts/#section-Graph-Literal> ;
	rdfs:label "langString" ;
	rdfs:comment "The datatype of language-tagged string values" .

rdf:PlainLiteral a rdfs:Datatype ;
	rdfs:isDefinedBy <http://www.w3.org/1999/02/22-rdf-syntax-ns#> ;
	rdfs:subClassOf rdfs:Literal ;
	rdfs:seeAlso <http://www.w3.org/TR/rdf-plain-literal/> ;
	rdfs:label "PlainLiteral" ;
	rdfs:comment "The class of plain (i.e. untyped) literal values, as used in RIF and OWL 2" .

rdf:type a rdf:Property ;
	rdfs:isDefinedBy <http://www.w3.org/1999/02/22-rdf-syntax-ns#> ;
	rdfs:label "type" ;
	rdfs:comment "The subject is an instance of a class." ;
	rdfs:range rdfs:Class ;
	rdfs:domain rdfs:Resource .

rdf:Property a rdfs:Class ;
	rdfs:isDefinedBy <http://www.w3.org/1999/02/22-rdf-syntax-ns#> ;
	rdfs:label "Property" ;
	rdfs:comment "The class of RDF properties." ;
	rdfs:subClassOf rdfs:Resource .

rdf:Statement a rdfs:Class ;
	rdfs:isDefinedBy <http://www.w3.org/1999/02/22-rdf-syntax-ns#> ;
	rdfs:label "Statement" ;
	rdfs:subClassOf rdfs:Resource ;
	rdfs:comment "The class of RDF statements." .

rdf:subject a rdf:Property ;
	rdfs:isDefinedBy <http://www.w3.org/1999/02/22-rdf-syntax-ns#> ;
	rdfs:label "subject" ;
	rdfs:comment "The subject of the subject RDF statement." ;
	rdfs:domain rdf:Statement ;
	rdfs:range rdfs:Resource .

rdf:predicate a rdf:Property ;
	rdfs:isDefinedBy <http://www.w3.org/1999/02/22-rdf-syntax-ns#> ;
	rdfs:label "predicate" ;
	rdfs:comment "The predicate of the subject RDF statement." ;
	rdfs:domain rdf:Statement ;
	rdfs:range rdfs:Resource .

rdf:object a rdf:Property ;
	rdfs:isDefinedBy <http://www.w3.org/1999/02/22-rdf-syntax-ns#> ;
	rdfs:label "object" ;
	rdfs:comment "The object of the subject RDF statement." ;
	rdfs:domain rdf:Statement ;
	rdfs:range rdfs:Resource .

rdf:Bag a rdfs:Class ;
	rdfs:isDefinedBy <http://www.w3.org/1999/02/22-rdf-syntax-ns#> ;
	rdfs:label "Bag" ;
	rdfs:comment "The class of unordered containers." ;
	rdfs:subClassOf rdfs:Container .

rdf:Seq a rdfs:Class ;
	rdfs:isDefinedBy <http://www.w3.org/1999/02/22-rdf-syntax-ns#> ;
	rdfs:label "Seq" ;
	rdfs:comment "The class of ordered containers." ;
	rdfs:subClassOf rdfs:Container .

rdf:Alt a rdfs:Class ;
	rdfs:isDefinedBy <http://www.w3.org/1999/02/22-rdf-syntax-ns#> ;
	rdfs:label "Alt" ;
	rdfs:comment "The class of containers of alternatives." ;
	rdfs:subClassOf rdfs:Container .

rdf:value a rdf:Property ;
	rdfs:isDefinedBy <http://www.w3.org/1999/02/22-rdf-syntax-ns#> ;
	rdfs:label "value" ;
	rdfs:comment "Idiomatic property used for structured values." ;
	rdfs:domain rdfs:Resource ;
	rdfs:range rdfs:Resource .

rdf:List a rdfs:Class ;
	rdfs:isDefinedBy <http://www.w3.org/1999/02/22-rdf-syntax-ns#> ;
	rdfs:label "List" ;
	rdfs:comment "The class of RDF Lists." ;
	rdfs:subClassOf rdfs:Resource .

rdf:nil a rdf:List ;
	rdfs:isDefinedBy <http://www.w3.org/1999/02/22-rdf-syntax-ns#> ;
	rdfs:label "nil" ;
	rdfs:comment "The empty list, with no items in it. If the rest of a list is nil then the list has no more items in it." .

rdf:first a rdf:Property ;
	rdfs:isDefinedBy <http://www.w3.org/1999/02/22-rdf-syntax-ns#> ;
	rdfs:label "first" ;
	rdfs:comment "The first item in the subject RDF list." ;
	rdfs:domain rdf:List ;
	rdfs:range rdfs:Resource .

rdf:rest a rdf:Property ;
	rdfs:isDefinedBy <http://www.w3.org/1999/02/22-rdf-syntax-ns#> ;
	rdfs:label "rest" ;
	rdfs:comment "The rest of the subject RDF list after the first item." ;
	rdfs:domain rdf:List ;
	rdfs:range rdf:List .

rdf:XMLLiteral a rdfs:Datatype ;
	rdfs:subClassOf rdfs:Literal ;
	rdfs:isDefinedBy <http://www.w3.org/1999/02/22-rdf-syntax-ns#> ;
	rdfs:label "XMLLiteral" ;
	rdfs:comment "The datatype of XML literal values." .


text:
require 'pp'
require 'linkeddata'

context = JSON.parse %({
  "@context": {
    "id": "@id",
    "rdfs": {"@id": "http://.../"},
    "seeAlso": {"@id": "rdfs:seeAlso", "@container": "@set"}
  }
})

input = JSON.parse %({
  "@context": {
    "id": "@id",
    "rdfs": {"@id": "http://.../"},
    "seeAlso": {"@id": "rdfs:seeAlso", "@container": "@set"}
  },
  "seeAlso": [
    {
      "id": "http://example.org/reference1"
    },
    "http://example.org/reference2",
    {"id": "http://example.org/reference3", "format": "text/html"}
  ]
})

pp JSON::LD::API.compact(input, context['@context'])


Thing

description: rdfs:comment

description: The most generic type of item.

Class

description: A class, also often called a 'Type'; equivalent to rdfs:Class.

CreativeWork

description: The most generic kind of creative work, including books, movies, photographs, software programs, etc.

Article

description: An article, such as a news article or piece of investigative report. Newspapers and magazines have articles of many different types and this is intended to cover them all.

BlogPosting

description: A blog post.

NewsArticle

description: A news article

ScholarlyArticle

description: A scholarly article.

MedicalScholarlyArticle

description: A scholarly article in the medical domain.

TechArticle

description: A technical article - Example: How-to (task) topics, step-by-step, procedural troubleshooting, specifications, etc.

APIReference

description: Reference documentation for application programming interfaces (APIs).

Blog

description: A blog

Book

description: A book.

Code

description: Computer programming source code. Example: Full (compile ready) solutions, code snippet samples, scripts, templates.

Comment

description: A comment on an item - for example, a comment on a blog post. The comment's content is expressed via the "text" property, and its topic via "about", properties shared with all CreativeWorks.

DataCatalog

description: A collection of datasets.

Dataset

description: A body of structured information describing some topic(s) of interest.

Diet

description: A strategy of regulating the intake of food to achieve or maintain a specific health-related goal.

ExercisePlan

description: Fitness-related activity designed for a specific health-related purpose, including defined exercise routines as well as activity prescribed by a clinician.

ItemList

description: A list of items of any sort—for example, Top 10 Movies About Weathermen, or Top 100 Party Songs. Not to be confused with HTML lists, which are often used only for formatting.

Map

description: A map.

MediaObject

description: An image, video, or audio object embedded in a web page. Note that a creative work may have many media objects associated with it on the same web page. For example, a page about a single song (MusicRecording) may have a music video (VideoObject), and a high and low bandwidth audio stream (2 AudioObject's).

AudioObject

description: An audio file.

DataDownload

description: A dataset in downloadable form.

ImageObject

description: An image file.

MusicVideoObject

description: A music video file.

VideoObject

description: A video file.

Movie

description: A movie.

MusicPlaylist

description: A collection of music tracks in playlist form.

MusicAlbum

description: A collection of music tracks.

MusicRecording

description: A music recording (track), usually a single song.

Painting

description: A painting.

Photograph

description: A photograph.

Recipe

description: A recipe.

Review

description: A review of an item - for example, a restaurant, movie, or store.

Sculpture

description: A piece of sculpture.

SoftwareApplication

description: A software application.

MobileApplication

description: A mobile software application.

WebApplication

description: Web applications.

TVEpisode

description: An episode of a TV series or season.

TVSeason

description: A TV season.

TVSeries

description: A television series.

WebPage

description: A web page. Every web page is implicitly assumed to be declared to be of type WebPage, so the various properties about that webpage, such as breadcrumb may be used. We recommend explicit declaration if these properties are specified, but if they are found outside of an itemscope, they will be assumed to be about the page

AboutPage

description: Web page type: About page.

CheckoutPage

description: Web page type: Checkout page.

CollectionPage

description: Web page type: Collection page.

ImageGallery

description: Web page type: Image gallery page.

VideoGallery

description: Web page type: Video gallery page.

ContactPage

description: Web page type: Contact page.

ItemPage

description: A page devoted to a single item, such as a particular product or hotel.

MedicalWebPage

description: A web page that provides medical information.

ProfilePage

description: Web page type: Profile page.

SearchResultsPage

description: Web page type: Search results page.

WebPageElement

description: A web page element, like a table or an image

SiteNavigationElement

description: A navigation element of the page.

Table

description: A table on the page.

WPAdBlock

description: An advertising section of the page.

WPFooter

description: The footer section of the page.

WPHeader

description: The header section of the page.

WPSideBar

description: A sidebar section of the page.

Event

description: An event happening at a certain time at a certain location.

BusinessEvent

description: Event type: Business event.

ChildrensEvent

description: Event type: Children's event.

ComedyEvent

description: Event type: Comedy event.

DanceEvent

description: Event type: A social dance.

EducationEvent

description: Event type: Education event.

Festival

description: Event type: Festival.

FoodEvent

description: Event type: Food event.

LiteraryEvent

description: Event type: Literary event.

MusicEvent

description: Event type: Music event.

SaleEvent

description: Event type: Sales event.

SocialEvent

description: Event type: Social event.

SportsEvent

description: Event type: Sports event.

TheaterEvent

description: Event type: Theater performance.

UserInteraction

description: A user interacting with a page

UserBlocks

description: User interaction: Block this content.

UserCheckins

description: User interaction: Check-in at a place.

UserComments

description: The UserInteraction event in which a user comments on an item.

UserDownloads

description: User interaction: Download of an item.

UserLikes

description: User interaction: Like an item.

UserPageVisits

description: User interaction: Visit to a web page.

UserPlays

description: User interaction: Play count of an item, for example a video or a song.

UserPlusOnes

description: User interaction: +1.

UserTweets

description: User interaction: Tweets.

VisualArtsEvent

description: Event type: Visual arts event.

Intangible

description: A utility class that serves as the umbrella for a number of 'intangible' things such as quantities, structured values, etc.

AlignmentObject

description: An intangible item that describes an alignment between a learning resource and a node in an educational framework.

Audience

description: Intended audience for an item, i.e. the group for whom the item was created.

EducationalAudience

description: An EducationalAudience

MedicalAudience

description: Target audiences for medical web pages. Enumerated type.

PeopleAudience

description: A set of characteristics belonging to people, e.g. who compose an item's target audience.

ParentAudience

description: A set of characteristics describing parents, who can be interested in viewing some content

Brand

description: A brand is a name used by an organization or business person for labeling a product, product group, or similar.

Demand

description: A demand entity represents the public, not necessarily binding, not necessarily exclusive, announcement by an organization or person to seek a certain type of goods or services. For describing demand using this type, the very same properties used for Offer apply.

Enumeration

description: Lists or enumerations—for example, a list of cuisines or music genres, etc.

BookFormatType

description: The publication format of the book.

BusinessEntityType

description:
A business entity type is a conceptual entity representing the legal form, the size, the main line of business, the position in the value chain, or any combination thereof, of an organization or business person.

    Commonly used values:

    http://purl.org/goodrelations/v1#Business
    http://purl.org/goodrelations/v1#Enduser
    http://purl.org/goodrelations/v1#PublicInstitution
    http://purl.org/goodrelations/v1#Reseller

BusinessFunction

description:
The business function specifies the type of activity or access (i.e., the bundle of rights) offered by the organization or business person through the offer. Typical are sell, rental or lease, maintenance or repair, manufacture / produce, recycle / dispose, engineering / construction, or installation. Proprietary specifications of access rights are also instances of this class.

    Commonly used values:

    http://purl.org/goodrelations/v1#ConstructionInstallation
    http://purl.org/goodrelations/v1#Dispose
    http://purl.org/goodrelations/v1#LeaseOut
    http://purl.org/goodrelations/v1#Maintain
    http://purl.org/goodrelations/v1#ProvideService
    http://purl.org/goodrelations/v1#Repair
    http://purl.org/goodrelations/v1#Sell
    http://purl.org/goodrelations/v1#Buy

DayOfWeek

description:
The day of the week, e.g. used to specify to which day the opening hours of an OpeningHoursSpecification refer.

    Commonly used values:

    http://purl.org/goodrelations/v1#Monday
    http://purl.org/goodrelations/v1#Tuesday
    http://purl.org/goodrelations/v1#Wednesday
    http://purl.org/goodrelations/v1#Thursday
    http://purl.org/goodrelations/v1#Friday
    http://purl.org/goodrelations/v1#Saturday
    http://purl.org/goodrelations/v1#Sunday
    http://purl.org/goodrelations/v1#PublicHolidays

DeliveryMethod

description:
A delivery method is a standardized procedure for transferring the product or service to the destination of fulfilment chosen by the customer. Delivery methods are characterized by the means of transportation used, and by the organization or group that is the contracting party for the sending organization or person.

    Commonly used values:

    http://purl.org/goodrelations/v1#DeliveryModeDirectDownload
    http://purl.org/goodrelations/v1#DeliveryModeFreight
    http://purl.org/goodrelations/v1#DeliveryModeMail
    http://purl.org/goodrelations/v1#DeliveryModeOwnFleet
    http://purl.org/goodrelations/v1#DeliveryModePickUp
    http://purl.org/goodrelations/v1#DHL
    http://purl.org/goodrelations/v1#FederalExpress
    http://purl.org/goodrelations/v1#UPS

ParcelService

description:
A private parcel service as the delivery mode available for a certain offer.

    Commonly used values:

    http://purl.org/goodrelations/v1#DHL
    http://purl.org/goodrelations/v1#FederalExpress
    http://purl.org/goodrelations/v1#UPS

ItemAvailability

description: A list of possible product availablity options.

OfferItemCondition

description: A list of possible conditions for the item for sale.

PaymentMethod

description:
A payment method is a standardized procedure for transferring the monetary amount for a purchase. Payment methods are characterized by the legal and technical structures used, and by the organization or group carrying out the transaction.

    Commonly used values:

    http://purl.org/goodrelations/v1#ByBankTransferInAdvance
    http://purl.org/goodrelations/v1#ByInvoice
    http://purl.org/goodrelations/v1#Cash
    http://purl.org/goodrelations/v1#CheckInAdvance
    http://purl.org/goodrelations/v1#COD
    http://purl.org/goodrelations/v1#DirectDebit
    http://purl.org/goodrelations/v1#GoogleCheckout
    http://purl.org/goodrelations/v1#PayPal
    http://purl.org/goodrelations/v1#PaySwarm

CreditCard

description:
A credit or debit card type as a standardized procedure for transferring the monetary amount for a purchase.

    Commonly used values:

    http://purl.org/goodrelations/v1#AmericanExpress
    http://purl.org/goodrelations/v1#DinersClub
    http://purl.org/goodrelations/v1#Discover
    http://purl.org/goodrelations/v1#JCB
    http://purl.org/goodrelations/v1#MasterCard
    http://purl.org/goodrelations/v1#VISA

QualitativeValue

description: A predefined value for a product characteristic, e.g. the the power cord plug type "US" or the garment sizes "S", "M", "L", and "XL"

Specialty

description: Any branch of a field in which people typically develop specific expertise, usually after significant study, time, and effort.

MedicalSpecialty

description: Any specific branch of medical science or practice. Medical specialities include clinical specialties that pertain to particular organ systems and their respective disease states, as well as allied health specialties. Enumerated type.

WarrantyScope

description:
A range of of services that will be provided to a customer free of charge in case of a defect or malfunction of a product.

    Commonly used values:

    http://purl.org/goodrelations/v1#Labor-BringIn
    http://purl.org/goodrelations/v1#PartsAndLabor-BringIn
    http://purl.org/goodrelations/v1#PartsAndLabor-PickUp

JobPosting

description: A listing that describes a job opening in a certain organization.

Language

description: Natural languages such as Spanish, Tamil, Hindi, English, etc. and programming languages such as Scheme and Lisp.

Offer

description: An offer to sell an item—for example, an offer to sell a product, the DVD of a movie, or tickets to an event.

AggregateOffer

description: When a single product that has different offers (for example, the same pair of shoes is offered by different merchants), then AggregateOffer can be used.

Quantity

description: Quantities such as distance, time, mass, weight, etc. Particular instances of say Mass are entities like '3 Kg' or '4 milligrams'.

Distance

description: Properties that take Distances as values are of the form '<Number> <Length unit of measure>'. E.g., '7 ft'

Duration

description: Quantity: Duration (use  ISO 8601 duration format).

Energy

description: Properties that take Enerygy as values are of the form '<Number> <Energy unit of measure>'

Mass

description: Properties that take Mass as values are of the form '<Number> <Mass unit of measure>'. E.g., '7 kg'

Rating

description: The rating of the video.

AggregateRating

description: The average rating based on multiple ratings or reviews.

StructuredValue

description: Structured values are strings—for example, addresses—that have certain constraints on their structure.

ContactPoint

description: A contact point—for example, a Customer Complaints department.

PostalAddress

description: The mailing address.

GeoCoordinates

description: The geographic coordinates of a place or event.

GeoShape

description: The geographic shape of a place.

NutritionInformation

description: Nutritional information about the recipe.

OpeningHoursSpecification

description: A structured value providing information about the opening hours of a place or a certain service inside a place.

OwnershipInfo

description: A structured value providing information about when a certain organization or person owned a certain product.

PriceSpecification

description: A structured value representing a monetary amount. Typically, only the subclasses of this type are used for markup.

DeliveryChargeSpecification

description: The price for the delivery of an offer using a particular delivery method.

PaymentChargeSpecification

description: The costs of settling the payment using a particular payment method.

UnitPriceSpecification

description: The price asked for a given offer by the respective organization or person.

QuantitativeValue

description: A point value or interval for product characteristics and other purposes.

TypeAndQuantityNode

description: A structured value indicating the quantity, unit of measurement, and business function of goods included in a bundle offer.

WarrantyPromise

description: A structured value representing the duration and scope of services that will be provided to a customer free of charge in case of a defect or malfunction of a product.

MedicalEntity

description: The most generic type of entity related to health and the practice of medicine.

AnatomicalStructure

description: Any part of the human body, typically a component of an anatomical system. Organs, tissues, and cells are all anatomical structures.

Bone

description: Rigid connective tissue that comprises up the skeletal structure of the human body.

BrainStructure

description: Any anatomical structure which pertains to the soft nervous tissue functioning as the coordinating center of sensation and intellectual and nervous activity.

Joint

description: The anatomical location at which two or more bones make contact.

Ligament

description: A short band of tough, flexible, fibrous connective tissue that functions to connect multiple bones, cartilages, and structurally support joints.

Muscle

description: A muscle is an anatomical structure consisting of a contractile form of tissue that animals use to effect movement.

Nerve

description: A common pathway for the electrochemical nerve impulses that are transmitted along each of the axons.

Vessel

description: A component of the human body circulatory system comprised of an intricate network of hollow tubes that transport blood throughout the entire body.

Artery

description: A type of blood vessel that specifically carries blood away from the heart.

LymphaticVessel

description: A type of blood vessel that specifically carries lymph fluid unidirectionally toward the heart.

Vein

description: A type of blood vessel that specifically carries blood to the heart.

AnatomicalSystem

description: An anatomical system is a group of anatomical structures that work together to perform a certain task. Anatomical systems, such as organ systems, are one organizing principle of anatomy, and can includes circulatory, digestive, endocrine, integumentary, immune, lymphatic, muscular, nervous, reproductive, respiratory, skeletal, urinary, vestibular, and other systems.

MedicalCause

description: The causative agent(s) that are responsible for the pathophysiologic process that eventually results in a medical condition, symptom or sign. In this schema, unless otherwise specified this is meant to be the proximate cause of the medical condition, symptom or sign. The proximate cause is defined as the causative agent that most directly results in the medical condition, symptom or sign. For example, the HIV virus could be considered a cause of AIDS. Or in a diagnostic context, if a patient fell and sustained a hip fracture and two days later sustained a pulmonary embolism which eventuated in a cardiac arrest, the cause of the cardiac arrest (the proximate cause) would be the pulmonary embolism and not the fall. <p>Medical causes can include cardiovascular, chemical, dermatologic, endocrine, environmental, gastroenterologic, genetic, hematologic, gynecologic, iatrogenic, infectious, musculoskeletal, neurologic, nutritional, obstetric, oncologic, otolaryngologic, pharmacologic, psychiatric, pulmonary, renal, rheumatologic, toxic, traumatic, or urologic causes; medical conditions can be causes as well.

MedicalCondition

description: Any condition of the human body that affects the normal functioning of a person, whether physically or mentally. Includes diseases, injuries, disabilities, disorders, syndromes, etc.

InfectiousDisease

description: An infectious disease is a clinically evident human disease resulting from the presence of pathogenic microbial agents, like pathogenic viruses, pathogenic bacteria, fungi, protozoa, multicellular parasites, and prions. To be considered an infectious disease, such pathogens are known to be able to cause this disease.

MedicalContraindication

description: A condition or factor that serves as a reason to withhold a certain medical therapy. Contraindications can be absolute (there are no reasonable circumstances for undertaking a course of action) or relative (the patient is at higher risk of complications, but that these risks may be outweighed by other considerations or mitigated by other measures).

MedicalDevice

description: Any object used in a medical capacity, such as to diagnose or treat a patient.

MedicalGuideline

description: Any recommendation made by a standard society (e.g. ACC/AHA) or consensus statement that denotes how to diagnose and treat a particular condition. Note: this type should be used to tag the actual guideline recommendation; if the guideline recommendation occurs in a larger scholarly article, use MedicalScholarlyArticle to tag the overall article, not this type. Note also: the organization making the recommendation should be captured in the recognizingAuthority base property of MedicalEntity.

MedicalGuidelineContraindication

description: A guideline contraindication that designates a process as harmful and where quality of the data supporting the contraindication is sound.

MedicalGuidelineRecommendation

description: A guideline recommendation that is regarded as efficacious and where quality of the data supporting the recommendation is sound.

MedicalIndication

description: A condition or factor that indicates use of a medical therapy, including signs, symptoms, risk factors, anatomical states, etc.

ApprovedIndication

description: An indication for a medical therapy that has been formally specified or approved by a regulatory body that regulates use of the therapy; for example, the US FDA approves indications for most drugs in the US.

PreventionIndication

description: An indication for preventing an underlying condition, symptom, etc.

TreatmentIndication

description: An indication for treating an underlying condition, symptom, etc.

MedicalIntangible

description: A utility class that serves as the umbrella for a number of 'intangible' things in the medical space.

DDxElement

description: An alternative, closely-related condition typically considered later in the differential diagnosis process along with the signs that are used to distinguish it.

DoseSchedule

description: A specific dosing schedule for a drug or supplement.

MaximumDoseSchedule

description: The maximum dosing schedule considered safe for a drug or supplement as recommended by an authority or by the drug/supplement's manufacturer. Capture the recommending authority in the recognizingAuthority property of MedicalEntity.

RecommendedDoseSchedule

description: A recommended dosing schedule for a drug or supplement as prescribed or recommended by an authority or by the drug/supplement's manufacturer. Capture the recommending authority in the recognizingAuthority property of MedicalEntity.

ReportedDoseSchedule

description: A patient-reported or observed dosing schedule for a drug or supplement.

DrugCost

description: The cost per unit of a medical drug. Note that this type is not meant to represent the price in an offer of a drug for sale; see the Offer type for that. This type will typically be used to tag wholesale or average retail cost of a drug, or maximum reimbursable cost. Costs of medical drugs vary widely depending on how and where they are paid for, so while this type captures some of the variables, costs should be used with caution by consumers of this schema's markup.

DrugLegalStatus

description: The legal availability status of a medical drug.

DrugStrength

description: A specific strength in which a medical drug is available in a specific country.

MedicalCode

description: A code for a medical entity.

MedicalConditionStage

description: A stage of a medical condition, such as 'Stage IIIa'.

MedicalEnumeration

description: Enumerations related to health and the practice of medicine.

DrugCostCategory

description: Enumerated categories of medical drug costs.

DrugPregnancyCategory

description: Categories that represent an assessment of the risk of fetal injury due to a drug or pharmaceutical used as directed by the mother during pregnancy.

DrugPrescriptionStatus

description: Indicates whether this drug is available by prescription or over-the-counter.

InfectiousAgentClass

description: Classes of agents or pathogens that transmit infectious diseases. Enumerated type.

MedicalDevicePurpose

description: Categories of medical devices, organized by the purpose or intended use of the device.

MedicalEvidenceLevel

description: Level of evidence for a medical guideline. Enumerated type.

MedicalImagingTechnique

description: Any medical imaging modality typically used for diagnostic purposes. Enumerated type.

MedicalObservationalStudyDesign

description: Design models for observational medical studies. Enumerated type.

MedicalProcedureType

description: An enumeration that describes different types of medical procedures.

MedicalStudyStatus

description: The status of a medical study. Enumerated type.

MedicalTrialDesign

description: Design models for medical trials. Enumerated type.

MedicineSystem

description: Systems of medical practice.

PhysicalActivityCategory

description: Categories of physical activity, organized by physiologic classification.

PhysicalExam

description: A type of physical examination of a patient performed by a physician. Enumerated type.

MedicalProcedure

description: A process of care used in either a diagnostic, therapeutic, or palliative capacity that relies on invasive (surgical), non-invasive, or percutaneous techniques.

DiagnosticProcedure

description: A medical procedure intended primarly for diagnostic, as opposed to therapeutic, purposes.

PalliativeProcedure

description: A medical procedure intended primarly for palliative purposes, aimed at relieving the symptoms of an underlying health condition.

TherapeuticProcedure

description: A medical procedure intended primarly for therapeutic purposes, aimed at improving a health condition.

MedicalRiskEstimator

description: Any rule set or interactive tool for estimating the risk of developing a complication or condition.

MedicalRiskCalculator

description: A complex mathematical calculation requiring an online calculator, used to assess prognosis. Note: use the url property of Thing to record any URLs for online calculators.

MedicalRiskScore

description: A simple system that adds up the number of risk factors to yield a score that is associated with prognosis, e.g. CHAD score, TIMI risk score.

MedicalRiskFactor

description: A risk factor is anything that increases a person's likelihood of developing or contracting a disease, medical condition, or complication.

MedicalSignOrSymptom

description: Any indication of the existence of a medical condition or disease.

MedicalSign

description: Any physical manifestation of a person's medical condition discoverable by objective diagnostic tests or physical examination.

MedicalSymptom

description: Any indication of the existence of a medical condition or disease that is apparent to the patient.

MedicalStudy

description: A medical study is an umbrella type covering all kinds of research studies relating to human medicine or health, including observational studies and interventional trials and registries, randomized, controlled or not. When the specific type of study is known, use one of the extensions of this type, such as MedicalTrial or MedicalObservationalStudy. Also, note that this type should be used to mark up data that describes the study itself; to tag an article that publishes the results of a study, use MedicalScholarlyArticle. Note: use the code property of MedicalEntity to store study IDs, e.g. clinicaltrials.gov ID.

MedicalObservationalStudy

description: An observational study is a type of medical study that attempts to infer the possible effect of a treatment through observation of a cohort of subjects over a period of time. In an observational study, the assignment of subjects into treatment groups versus control groups is outside the control of the investigator. This is in contrast with controlled studies, such as the randomized controlled trials represented by MedicalTrial, where each subject is randomly assigned to a treatment group or a control group before the start of the treatment.

MedicalTrial

description: A medical trial is a type of medical study that uses scientific process used to compare the safety and efficacy of medical therapies or medical procedures. In general, medical trials are controlled and subjects are allocated at random to the different treatment and/or control groups.

MedicalTest

description: Any medical test, typically performed for diagnostic purposes.

BloodTest

description: A medical test performed on a sample of a patient's blood.

ImagingTest

description: Any medical imaging modality typically used for diagnostic purposes.

MedicalTestPanel

description: Any collection of tests commonly ordered together.

PathologyTest

description: A medical test performed by a laboratory that typically involves examination of a tissue sample by a pathologist.

MedicalTherapy

description: Any medical intervention designed to prevent, treat, and cure human diseases and medical conditions, including both curative and palliative therapies. Medical therapies are typically processes of care relying upon pharmacotherapy, behavioral therapy, supportive therapy (with fluid or nutrition for example), or detoxification (e.g. hemodialysis) aimed at improving or preventing a health condition.

DietarySupplement

description: A product taken by mouth that contains a dietary ingredient intended to supplement the diet. Dietary ingredients may include vitamins, minerals, herbs or other botanicals, amino acids, and substances such as enzymes, organ tissues, glandulars and metabolites.

Drug

description: A chemical or biologic substance, used as a medical therapy, that has a physiological effect on an organism.

DrugClass

description: A class of medical drugs, e.g., statins. Classes can represent general pharmacological class, common mechanisms of action, common physiological effects, etc.

LifestyleModification

description: A process of care involving exercise, changes to diet, fitness routines, and other lifestyle changes aimed at improving a health condition.

PhysicalActivity

description: Any bodily activity that enhances or maintains physical fitness and overall health and wellness. Includes activity that is part of daily living and routine, structured exercise, and exercise prescribed as part of a medical treatment or recovery plan.

PhysicalTherapy

description: A process of progressive physical care and rehabilitation aimed at improving a health condition.

PsychologicalTreatment

description: A process of care relying upon counseling, dialogue, communication, verbalization aimed at improving a mental health condition.

RadiationTherapy

description: A process of care using radiation aimed at improving a health condition.

SuperficialAnatomy

description: Anatomical features that can be observed by sight (without dissection), including the form and proportions of the human body as well as surface landmarks that correspond to deeper subcutaneous structures. Superficial anatomy plays an important role in sports medicine, phlebotomy, and other medical specialties as underlying anatomical structures can be identified through surface palpation. For example, during back surgery, superficial anatomy can be used to palpate and count vertebrae to find the site of incision. Or in phlebotomy, superficial anatomy can be used to locate an underlying vein; for example, the median cubital vein can be located by palpating the borders of the cubital fossa (such as the epicondyles of the humerus) and then looking for the superficial signs of the vein, such as size, prominence, ability to refill after depression, and feel of surrounding tissue support. As another example, in a subluxation (dislocation) of the glenohumeral joint, the bony structure becomes pronounced with the deltoid muscle failing to cover the glenohumeral joint allowing the edges of the scapula to be superficially visible. Here, the superficial anatomy is the visible edges of the scapula, implying the underlying dislocation of the joint (the related anatomical structure).

Organization

description: An organization such as a school, NGO, corporation, club, etc.

Corporation

description: Organization: A business corporation.

EducationalOrganization

description: An educational organization.

CollegeOrUniversity

description: A college, university, or other third-level educational institution.

ElementarySchool

description: An elementary school.

HighSchool

description: A high school.

MiddleSchool

description: A middle school.

Preschool

description: A preschool.

School

description: A school.

GovernmentOrganization

description: A governmental organization or agency.

LocalBusiness

description: A particular physical business or branch of an organization. Examples of LocalBusiness include a restaurant, a particular branch of a restaurant chain, a branch of a bank, a medical practice, a club, a bowling alley, etc.

rdfs:subClassOf: schema:Organization schema:Place

TravelAgency

description: A travel agency.

NGO

description: Organization: Non-governmental Organization.

PerformingGroup

description: A performance group, such as a band, an orchestra, or a circus.

DanceGroup

description: A dance group—for example, the Alvin Ailey Dance Theater or Riverdance.

MusicGroup

description: A musical group, such as a band, an orchestra, or a choir. Can also be a solo musician.

TheaterGroup

description: A theater group or company—for example, the Royal Shakespeare Company or Druid Theatre.

SportsTeam

description: Organization: Sports team.

Person

description: A person (alive, dead, undead, or fictional).

Place

description: Entities that have a somewhat fixed, physical extension.

AdministrativeArea

description: A geographical region under the jurisdiction of a particular government.

City

description: A city or town.

Country

description: A country.

State

description: A state or province.

CivicStructure

description: A public structure, such as a town hall or concert hall.

Airport

description: An airport.

Aquarium

description: Aquarium.

Beach

description: Beach.

BusStation

description: A bus station.

BusStop

description: A bus stop.

Campground

description: A campground.

Cemetery

description: A graveyard.

Crematorium

description: A crematorium.

EventVenue

description: An event venue.

FireStation

description: A fire station. With firemen.

GovernmentBuilding

description: A government building.

CityHall

description: A city hall.

Courthouse

description: A courthouse.

DefenceEstablishment

description: A defence establishment, such as an army or navy base.

Embassy

description: An embassy.

LegislativeBuilding

description: A legislative building—for example, the state capitol.

Hospital

description: A hospital.

MovieTheater

description: A movie theater.

Museum

description: A museum.

MusicVenue

description: A music venue.

Park

description: A park.

ParkingFacility

description: A parking lot or other parking facility.

PerformingArtsTheater

description: A theatre or other performing art center.

PlaceOfWorship

description: Place of worship, such as a church, synagogue, or mosque.

BuddhistTemple

description: A Buddhist temple.

CatholicChurch

description: A Catholic church.

Church

description: A church.

HinduTemple

description: A Hindu temple.

Mosque

description: A mosque.

Synagogue

description: A synagogue.

Playground

description: A playground.

PoliceStation

description: A police station.

RVPark

description: An RV park.

StadiumOrArena

description: A stadium.

SubwayStation

description: A subway station.

TaxiStand

description: A taxi stand.

TrainStation

description: A train station.

Zoo

description: A zoo.

Landform

description: A landform or physical feature.  Landform elements include mountains, plains, lakes, rivers, seascape and oceanic waterbody interface features such as bays, peninsulas, seas and so forth, including sub-aqueous terrain features such as submersed mountain ranges, volcanoes, and the great ocean basins.

BodyOfWater

description: A body of water, such as a sea, ocean, or lake.

Canal

description: A canal, like the Panama Canal

LakeBodyOfWater

description: A lake (for example, Lake Pontrachain).

OceanBodyOfWater

description: An ocean (for example, the Pacific).

Pond

description: A pond

Reservoir

description: A reservoir, like the Lake Kariba reservoir.

RiverBodyOfWater

description: A river (for example, the broad majestic Shannon).

SeaBodyOfWater

description: A sea (for example, the Caspian sea).

Waterfall

description: A waterfall, like Niagara

Continent

description: One of the continents (for example, Europe or Africa).

Mountain

description: A mountain, like Mount Whitney or Mount Everest

Volcano

description: A volcano, like Fuji san

LandmarksOrHistoricalBuildings

description: An historical landmark or building.

LocalBusiness

TravelAgency

description: A travel agency.

Residence

description: The place where a person lives.

ApartmentComplex

description: Residence type: Apartment complex.

GatedResidenceCommunity

description: Residence type: Gated community.

SingleFamilyResidence

description: Residence type: Single-family home.

TouristAttraction

description: A tourist attraction.

Product

description: A product is anything that is made available for sale—for example, a pair of shoes, a concert ticket, or a car. Commodity services, like haircuts, can also be represented using this type.

IndividualProduct

description: A single, identifiable product instance (e.g. a laptop with a particular serial number).

ProductModel

description: A datasheet or vendor specification of a product (in the sense of a prototypical description).

SomeProducts

description: A placeholder for multiple similar products of the same kind.

Property

description: A property, used to indicate attributes and relationships of some Thing; equivalent to rdf:Property.


text:
@prefix mo: <http://purl.org/ontology/mo/> .
@prefix dc: <http://purl.org/dc/elements/1.1/> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .
@prefix tl: <http://purl.org/NET/c4dm/timeline.owl#> .
@prefix event: <http://purl.org/NET/c4dm/event.owl#> .
@prefix foaf: <http://xmlns.com/foaf/0.1/> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .

<http://dbpedia.org/resource/Johann_Sebastian_Bach>
    a mo:MusicArtist ;
    foaf:name "Johann Sebastian Bach" .
<#composition>
    a mo:Composition ;
    dc:title "Composition of The Art of Fugue, BWV 1080: Contrapunctus IX, a 4, alla Duodecima" ;
    mo:composer <http://dbpedia.org/resource/Johann_Sebastian_Bach> ;
    event:time [ tl:start "1742"^^xsd:gYear ; tl:end "1749"^^xsd:gYear ] ;
    mo:produced_work <#kunst-der-fuge> .
<#kunst-der-fuge>
    a mo:MusicalWork ;
    dc:title "The Art of Fugue, BWV 1080: Contrapunctus IX, a 4, alla Duodecima" .
<#performance>
    a mo:Performance ;
    mo:performance_of <#kunst-der-fuge> ;
    event:time [ tl:at "2003"^^xsd:gYear ] ;
    mo:performer <http://musicbrainz.org/artist/fd20e8ed-0736-44db-8d97-530fbf00e813#_> ;
    mo:instrument [ a mo:Instrument ; rdfs:label "first violin" ],
                  [ a mo:Instrument ; rdfs:label "second violin" ],
                  [ a mo:Instrument ; rdfs:label "viola" ],
                  [ a mo:Instrument ; rdfs:label "cello" ] ;
    mo:recorded_as <http://musicbrainz.org/recording/93da082b-99c1-4469-9eb6-91e9fbeaeb2a#_> .


text:
Data describing Dave

Data describing Gregg


text:
#!/usr/bin/env ruby
require "bundler/setup"
require 'json/ld'
#require File.expand_path('../schema-context', __FILE__)
require 'benchmark/ips'

source = JSON.parse %({
  "@context": "http://schema.org/",
  "@type": "SoftwareApplication",
  "name": "EtherSia",
  "description": "IPv6 library for the ENC28J60 Ethernet controller",
  "url": "https://github.com/njh/EtherSia",
  "author": {
    "@type": "Person",
    "name": "Nicholas Humfrey <njh@aelius.com>"
  },
  "applicationCategory": "Communication",
  "operatingSystem": "Arduino",
  "downloadUrl": "http://downloads.arduino.cc/libraries/njh/EtherSia-1.0.0.zip",
  "softwareVersion": "1.0.0",
  "fileSize": 77
})

Benchmark.ips do |x|
  x.config(time: 10, warmup: 1)
  x.report('toRdf') {JSON::LD::API.toRdf(source)}
end


text:
@base <http://www.w3.org/TR/microdata-rdf/tests/> .
@prefix mf: <http://www.w3.org/2001/sw/DataAccess/tests/test-manifest#> .
@prefix mq: <http://www.w3.org/2001/sw/DataAccess/tests/test-query#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .

<> <http://www.w3.org/ns/md#item> ([ a mf:Manifest;
       rdfs:comment "Positive processor tests";
       mf:entries [ a mf:ManifestEntry;
         rdfs:comment "Item with no itemtype and literal itemprop";
         mf:action [ a mq:QueryTest;
           mq:data <0001.html>;
           mq:query <0001.ttl>];
         mf:name "Test 0001";
         mf:result "true"],
         [ a mf:ManifestEntry;
         rdfs:comment "Item with no itemtype and 2 elements with equivalent itemprop";
         mf:action [ a mq:QueryTest;
           mq:data <0002.html>;
           mq:query <0002.ttl>];
         mf:name "Test 0002";
         mf:result "true"],
         [ a mf:ManifestEntry;
         rdfs:comment "Item with itemprop having two properties";
         mf:action [ a mq:QueryTest;
           mq:data <0003.html>;
           mq:query <0003.ttl>];
         mf:name "Test 0003";
         mf:result "true"],
         [ a mf:ManifestEntry;
         rdfs:comment "Use of meta and @content";
         mf:action [ a mq:QueryTest;
           mq:data <0004.html>;
           mq:query <0004.ttl>];
         mf:name "Test 0004";
         mf:result "true"],
         [ a mf:ManifestEntry;
         rdfs:comment "Use of audio and @src";
         mf:action [ a mq:QueryTest;
           mq:data <0005.html>;
           mq:query <0005.ttl>];
         mf:name "Test 0005";
         mf:result "true"],
         [ a mf:ManifestEntry;
         rdfs:comment "Use of embed and @src";
         mf:action [ a mq:QueryTest;
           mq:data <0006.html>;
           mq:query <0006.ttl>];
         mf:name "Test 0006";
         mf:result "true"],
         [ a mf:ManifestEntry;
         rdfs:comment "Use of iframe and @src";
         mf:action [ a mq:QueryTest;
           mq:data <0007.html>;
           mq:query <0007.ttl>];
         mf:name "Test 0007";
         mf:result "true"],
         [ a mf:ManifestEntry;
         rdfs:comment "Use of img and @src";
         mf:action [ a mq:QueryTest;
           mq:data <0008.html>;
           mq:query <0008.ttl>];
         mf:name "Test 0008";
         mf:result "true"],
         [ a mf:ManifestEntry;
         rdfs:comment "Use of source and @src";
         mf:action [ a mq:QueryTest;
           mq:data <0009.html>;
           mq:query <0009.ttl>];
         mf:name "Test 0009";
         mf:result "true"],
         [ a mf:ManifestEntry;
         rdfs:comment "Use of track and @src";
         mf:action [ a mq:QueryTest;
           mq:data <0010.html>;
           mq:query <0010.ttl>];
         mf:name "Test 0010";
         mf:result "true"],
         [ a mf:ManifestEntry;
         rdfs:comment "Use of video and @src";
         mf:action [ a mq:QueryTest;
           mq:data <0011.html>;
           mq:query <0011.ttl>];
         mf:name "Test 0011";
         mf:result "true"],
         [ a mf:ManifestEntry;
         rdfs:comment "Use of a and @href";
         mf:action [ a mq:QueryTest;
           mq:data <0012.html>;
           mq:query <0012.ttl>];
         mf:name "Test 0012";
         mf:result "true"],
         [ a mf:ManifestEntry;
         rdfs:comment "Use of area and @href";
         mf:action [ a mq:QueryTest;
           mq:data <0013.html>;
           mq:query <0013.ttl>];
         mf:name "Test 0013";
         mf:result "true"],
         [ a mf:ManifestEntry;
         rdfs:comment "Use of link and @href";
         mf:action [ a mq:QueryTest;
           mq:data <0014.html>;
           mq:query <0014.ttl>];
         mf:name "Test 0014";
         mf:result "true"],
         [ a mf:ManifestEntry;
         rdfs:comment "Use of object and @data";
         mf:action [ a mq:QueryTest;
           mq:data <0015.html>;
           mq:query <0015.ttl>];
         mf:name "Test 0015";
         mf:result "true"]]) .


text:
#!/usr/bin/env ruby
require 'json/ld'

context = JSON.parse %({
  "@vocab": "http://schema.org/" ,
  "dc": "http://purl.org/dc/elements/1.1/",
  "doag": "http://academy.dior.com/doag#",
  "dior": "http://academy.dior.com/terms#",
  "name": {
    "@container": "@language"
  }
})

puts JSON::LD::API.compact("http://semio.dydra.com/arnaudlevy/dior-academy/seasons.jsonld?auth_token=rcelIAhAcmnYXv2A2rZ7", context).to_json(JSON::LD::JSON_STATE)


text:
<http://rdf.freebase.com/ns/m.03lzfx> <http://www.w3.org/2000/01/rdf-schema#label> "Bataille de Liège"@fr .
<http://rdf.freebase.com/ns/m.03lzfx> <http://www.w3.org/2000/01/rdf-schema#label> "Battle of Liège"@en .
<http://rdf.freebase.com/ns/m.03lzfx> <http://www.domain.com/ontology/pmcore/1.0#thumbnail> "http://freebase.cdn.perfect-memory.com/50094f7a625e8caf4622e234889f066aaa1b250a" .
<http://rdf.freebase.com/ns/m.03lzfx> <http://www.domain.com/ontology/pmcore/1.0#hasInfoSource> <http://www.domain.com/profile/pmcore/kb/Agent_Freebase> .
<http://www.domain.com/profile/client/kb/40350292-4496-4AC7-98BA-84F7A86FDD4E> <http://www.w3.org/2000/01/rdf-schema#label> "Justine Henin"@fr .
<http://www.domain.com/profile/client/kb/40350292-4496-4AC7-98BA-84F7A86FDD4E> <http://www.w3.org/2000/01/rdf-schema#label> "Justine Henin"@en .
<http://www.domain.com/profile/client/kb/40350292-4496-4AC7-98BA-84F7A86FDD4E> <http://www.domain.com/ontology/pmcore/1.0#thumbnail> "http://freebase.cdn.perfect-memory.com/1ce82860884dfe5dab93e44d266d8f07854963f5" .
<http://www.domain.com/profile/client/kb/40350292-4496-4AC7-98BA-84F7A86FDD4E> <http://www.domain.com/ontology/pmcore/1.0#hasInfoSource> <http://www.domain.com/profile/client/kb/client> .
<http://www.domain.com/profile/client/kb/40350292-4496-4AC7-98BA-84F7A86FDD4E> <http://www.domain.com/ontology/pmcore/1.0#hasInfoSource> <http://www.domain.com/profile/pmcore/kb/Agent_Freebase> .
<http://rdf.freebase.com/ns/m.0hr5z7z> <http://www.w3.org/2000/01/rdf-schema#label> "2011 Liège attack"@en .
<http://rdf.freebase.com/ns/m.0hr5z7z> <http://www.w3.org/2000/01/rdf-schema#label> "Nordine Amrani"@en .
<http://rdf.freebase.com/ns/m.0hr5z7z> <http://www.w3.org/2000/01/rdf-schema#label> "Nordine Amrani"@fr .
<http://rdf.freebase.com/ns/m.0hr5z7z> <http://www.w3.org/2000/01/rdf-schema#label> "Tuerie de Liège"@fr .
<http://rdf.freebase.com/ns/m.0hr5z7z> <http://www.domain.com/ontology/pmcore/1.0#thumbnail> "http://freebase.cdn.perfect-memory.com/9c8759b0d946a6c1f00a6219708b7dc8305e54e2" .
<http://rdf.freebase.com/ns/m.0hr5z7z> <http://www.domain.com/ontology/pmcore/1.0#hasInfoSource> <http://www.domain.com/profile/client/kb/client> .
<http://rdf.freebase.com/ns/m.0hr5z7z> <http://www.domain.com/ontology/pmcore/1.0#hasInfoSource> <http://www.domain.com/profile/pmcore/kb/Agent_Freebase> .
<http://www.domain.com/profile/client/kb/1566189C-2FC1-4762-B628-1DC9812B170F> <http://www.w3.org/2000/01/rdf-schema#label> "Sclessin"@fr .
<http://www.domain.com/profile/client/kb/1566189C-2FC1-4762-B628-1DC9812B170F> <http://www.domain.com/ontology/pmcore/1.0#hasInfoSource> <http://www.domain.com/profile/client/kb/client> .
<http://www.domain.com/profile/client/kb/client> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.domain.com/ontology/pmcore/1.0#Accessible> .
<http://www.domain.com/profile/client/kb/client> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.domain.com/ontology/pmcore/1.0#Entity> .
<http://www.domain.com/profile/client/kb/client> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Agent> .
<http://www.domain.com/profile/client/kb/client> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://purl.org/dc/terms/Agent> .
<http://www.domain.com/profile/client/kb/client> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.domain.com/ontology/pmcore/1.0#Agent> .
<http://www.domain.com/profile/client/kb/client> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.domain.com/ontology/pmrights/1.0#Agent> .
<http://www.domain.com/profile/client/kb/client> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.domain.com/ontology/pmrights/1.0#PMRightsObject> .
<http://www.domain.com/profile/client/kb/client> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.domain.com/ontology/pmmodel/1.0#PMObject> .
<http://www.domain.com/profile/client/kb/client> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.domain.com/ontology/pmcore/1.0#Subject> .
<http://www.domain.com/profile/client/kb/client> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.domain.com/ontology/pmcore/1.0#PMCoreObject> .
<http://www.domain.com/profile/pmcore/kb/Agent_Freebase> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.domain.com/ontology/pmcore/1.0#Accessible> .
<http://www.domain.com/profile/pmcore/kb/Agent_Freebase> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.domain.com/ontology/pmcore/1.0#Entity> .
<http://www.domain.com/profile/pmcore/kb/Agent_Freebase> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Agent> .
<http://www.domain.com/profile/pmcore/kb/Agent_Freebase> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://purl.org/dc/terms/Agent> .
<http://www.domain.com/profile/pmcore/kb/Agent_Freebase> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.domain.com/ontology/pmcore/1.0#Agent> .
<http://www.domain.com/profile/pmcore/kb/Agent_Freebase> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.domain.com/ontology/pmrights/1.0#Agent> .
<http://www.domain.com/profile/pmcore/kb/Agent_Freebase> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.domain.com/ontology/pmrights/1.0#PMRightsObject> .
<http://www.domain.com/profile/pmcore/kb/Agent_Freebase> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.domain.com/ontology/pmmodel/1.0#PMObject> .
<http://www.domain.com/profile/pmcore/kb/Agent_Freebase> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.domain.com/ontology/pmcore/1.0#Subject> .
<http://www.domain.com/profile/pmcore/kb/Agent_Freebase> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.w3.org/2002/07/owl#NamedIndividual> .
<http://www.domain.com/profile/pmcore/kb/Agent_Freebase> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.domain.com/ontology/pmcore/1.0#PMCoreObject> .
<http://www.domain.com/profile/client/kb/0A786E68-1B16-405C-9EA3-B6221619E832> <http://www.w3.org/2000/01/rdf-schema#label> "Belgium"@en .
<http://www.domain.com/profile/client/kb/0A786E68-1B16-405C-9EA3-B6221619E832> <http://www.w3.org/2000/01/rdf-schema#label> "Belgique"@fr .
<http://www.domain.com/profile/client/kb/0A786E68-1B16-405C-9EA3-B6221619E832> <http://www.domain.com/ontology/pmcore/1.0#thumbnail> "http://freebase.cdn.perfect-memory.com/781ad959270d5a0d78599c6a5515c2997cf629a7" .
<http://www.domain.com/profile/client/kb/0A786E68-1B16-405C-9EA3-B6221619E832> <http://www.domain.com/ontology/pmcore/1.0#hasInfoSource> <http://www.domain.com/profile/client/kb/client> .
<http://www.domain.com/profile/client/kb/0A786E68-1B16-405C-9EA3-B6221619E832> <http://www.domain.com/ontology/pmcore/1.0#hasInfoSource> <http://www.domain.com/profile/pmcore/kb/Agent_Freebase> .
<http://rdf.freebase.com/ns/m.0krxss> <http://www.w3.org/2000/01/rdf-schema#label> "Didier Reynders"@en .
<http://rdf.freebase.com/ns/m.0krxss> <http://www.w3.org/2000/01/rdf-schema#label> "Didier Reynders"@fr .
<http://rdf.freebase.com/ns/m.0krxss> <http://www.domain.com/ontology/pmcore/1.0#thumbnail> "http://freebase.cdn.perfect-memory.com/631b2349398635ca2e7385cad6c12f0ac3a83a26" .
<http://rdf.freebase.com/ns/m.0krxss> <http://www.domain.com/ontology/pmcore/1.0#hasInfoSource> <http://www.domain.com/profile/client/kb/client> .
<http://rdf.freebase.com/ns/m.0krxss> <http://www.domain.com/ontology/pmcore/1.0#hasInfoSource> <http://www.domain.com/profile/pmcore/kb/Agent_Freebase> .
<http://www.domain.com/profile/client/kb/D8043EB6-D3DD-4963-9555-8EE0599C8F22> <http://www.w3.org/2000/01/rdf-schema#label> "Université de Liège"@fr .
<http://www.domain.com/profile/client/kb/D8043EB6-D3DD-4963-9555-8EE0599C8F22> <http://www.w3.org/2000/01/rdf-schema#label> "University of Liège"@en .
<http://www.domain.com/profile/client/kb/D8043EB6-D3DD-4963-9555-8EE0599C8F22> <http://www.domain.com/ontology/pmcore/1.0#thumbnail> "http://freebase.cdn.perfect-memory.com/38fe923f650278a391c23decf211e3588c6ec2a8" .
<http://www.domain.com/profile/client/kb/D8043EB6-D3DD-4963-9555-8EE0599C8F22> <http://www.domain.com/ontology/pmcore/1.0#hasInfoSource> <http://www.domain.com/profile/client/kb/client> .
<http://www.domain.com/profile/client/kb/D8043EB6-D3DD-4963-9555-8EE0599C8F22> <http://www.domain.com/ontology/pmcore/1.0#hasInfoSource> <http://www.domain.com/profile/pmcore/kb/Agent_Freebase> .
<http://rdf.freebase.com/ns/m.0154j> <http://www.w3.org/2000/01/rdf-schema#label> "Belgium"@en .
<http://rdf.freebase.com/ns/m.0154j> <http://www.w3.org/2000/01/rdf-schema#label> "Belgique"@fr .
<http://rdf.freebase.com/ns/m.0154j> <http://www.domain.com/ontology/pmcore/1.0#thumbnail> "http://freebase.cdn.perfect-memory.com/781ad959270d5a0d78599c6a5515c2997cf629a7" .
<http://rdf.freebase.com/ns/m.0154j> <http://www.domain.com/ontology/pmcore/1.0#hasInfoSource> <http://www.domain.com/profile/client/kb/client> .
<http://rdf.freebase.com/ns/m.0154j> <http://www.domain.com/ontology/pmcore/1.0#hasInfoSource> <http://www.domain.com/profile/pmcore/kb/Agent_Freebase> .
<http://www.domain.com/profile/client/kb/779C782A-7142-4906-9B06-067D24FA81B6> <http://www.w3.org/2000/01/rdf-schema#label> "Province de Liège"@fr .
<http://www.domain.com/profile/client/kb/779C782A-7142-4906-9B06-067D24FA81B6> <http://www.w3.org/2000/01/rdf-schema#label> "Liège"@en .
<http://www.domain.com/profile/client/kb/779C782A-7142-4906-9B06-067D24FA81B6> <http://www.domain.com/ontology/pmcore/1.0#thumbnail> "http://freebase.cdn.perfect-memory.com/a442530dc40ea694c5fad7bc94f5a976d2e27dbb" .
<http://www.domain.com/profile/client/kb/779C782A-7142-4906-9B06-067D24FA81B6> <http://www.domain.com/ontology/pmcore/1.0#hasInfoSource> <http://www.domain.com/profile/client/kb/client> .
<http://www.domain.com/profile/client/kb/779C782A-7142-4906-9B06-067D24FA81B6> <http://www.domain.com/ontology/pmcore/1.0#hasInfoSource> <http://www.domain.com/profile/pmcore/kb/Agent_Freebase> .
<http://www.domain.com/profile/client/kb/148F9D55-482A-4A96-B06F-16E05D44AA15> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.domain.com/ontology/pmcore/1.0#Place> .
<http://www.domain.com/profile/client/kb/148F9D55-482A-4A96-B06F-16E05D44AA15> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.domain.com/ontology/client/1.0#Thesaurus> .
<http://www.domain.com/profile/client/kb/148F9D55-482A-4A96-B06F-16E05D44AA15> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.domain.com/ontology/pmcore/1.0#Accessible> .
<http://www.domain.com/profile/client/kb/148F9D55-482A-4A96-B06F-16E05D44AA15> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.domain.com/ontology/pmcore/1.0#Entity> .
<http://www.domain.com/profile/client/kb/148F9D55-482A-4A96-B06F-16E05D44AA15> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://rdf.freebase.com/ns/location.location> .
<http://www.domain.com/profile/client/kb/148F9D55-482A-4A96-B06F-16E05D44AA15> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://rdf.freebase.com/ns/base.type_ontology.inanimate> .
<http://www.domain.com/profile/client/kb/148F9D55-482A-4A96-B06F-16E05D44AA15> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://rdf.freebase.com/ns/film.film_location> .
<http://www.domain.com/profile/client/kb/148F9D55-482A-4A96-B06F-16E05D44AA15> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://rdf.freebase.com/ns/location.dated_location> .
<http://www.domain.com/profile/client/kb/148F9D55-482A-4A96-B06F-16E05D44AA15> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.domain.com/ontology/pmcore/1.0#PMCoreObject> .
<http://www.domain.com/profile/client/kb/148F9D55-482A-4A96-B06F-16E05D44AA15> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://dbpedia.org/ontology/Settlement> .
<http://www.domain.com/profile/client/kb/148F9D55-482A-4A96-B06F-16E05D44AA15> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://rdf.freebase.com/ns/periodicals.newspaper_circulation_area> .
<http://www.domain.com/profile/client/kb/148F9D55-482A-4A96-B06F-16E05D44AA15> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://rdf.freebase.com/ns/base.type_ontology.abstract> .
<http://www.domain.com/profile/client/kb/148F9D55-482A-4A96-B06F-16E05D44AA15> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://rdf.freebase.com/ns/sports.sports_team_location> .
<http://www.domain.com/profile/client/kb/148F9D55-482A-4A96-B06F-16E05D44AA15> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://rdf.freebase.com/ns/location.citytown> .
<http://www.domain.com/profile/client/kb/148F9D55-482A-4A96-B06F-16E05D44AA15> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.domain.com/ontology/pmcore/1.0#Subject> .
<http://www.domain.com/profile/client/kb/148F9D55-482A-4A96-B06F-16E05D44AA15> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://dbpedia.org/ontology/Place> .
<http://www.domain.com/profile/client/kb/148F9D55-482A-4A96-B06F-16E05D44AA15> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://rdf.freebase.com/ns/base.type_ontology.agent> .
<http://www.domain.com/profile/client/kb/148F9D55-482A-4A96-B06F-16E05D44AA15> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.domain.com/ontology/pmcore/1.0#Settlement> .
<http://www.domain.com/profile/client/kb/148F9D55-482A-4A96-B06F-16E05D44AA15> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://rdf.freebase.com/ns/location.statistical_region> .
<http://www.domain.com/profile/client/kb/148F9D55-482A-4A96-B06F-16E05D44AA15> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.domain.com/ontology/pmmodel/1.0#PMObject> .
<http://www.domain.com/profile/client/kb/148F9D55-482A-4A96-B06F-16E05D44AA15> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://rdf.freebase.com/ns/common.topic> .
<http://www.domain.com/profile/client/kb/148F9D55-482A-4A96-B06F-16E05D44AA15> <http://www.w3.org/2000/01/rdf-schema#label> "Liège"@fr .
<http://www.domain.com/profile/client/kb/148F9D55-482A-4A96-B06F-16E05D44AA15> <http://www.w3.org/2000/01/rdf-schema#label> "Liège"@en .
<http://www.domain.com/profile/client/kb/148F9D55-482A-4A96-B06F-16E05D44AA15> <http://rdf.freebase.com/ns/location.location.containedby> <http://www.domain.com/profile/client/kb/0A786E68-1B16-405C-9EA3-B6221619E832> .
<http://www.domain.com/profile/client/kb/148F9D55-482A-4A96-B06F-16E05D44AA15> <http://rdf.freebase.com/ns/location.location.containedby> <http://rdf.freebase.com/ns/m.0154j> .
<http://www.domain.com/profile/client/kb/148F9D55-482A-4A96-B06F-16E05D44AA15> <http://rdf.freebase.com/ns/location.location.containedby.other> <http://rdf.freebase.com/ns/m.0154j> .
<http://www.domain.com/profile/client/kb/148F9D55-482A-4A96-B06F-16E05D44AA15> <http://rdf.freebase.com/ns/location.location.containedby> <http://www.domain.com/profile/client/kb/779C782A-7142-4906-9B06-067D24FA81B6> .
<http://www.domain.com/profile/client/kb/148F9D55-482A-4A96-B06F-16E05D44AA15> <http://rdf.freebase.com/ns/location.location.containedby> <http://rdf.freebase.com/ns/m.013d56> .


text:
require 'json/ld'
require 'rdf/ntriples'

def load_file(file)
  RDF::Graph.new.tap do |g|
    RDF::Reader.for(:content_type => "text/plain").open(file) do |reader|
      g << reader.statements
    end
  end
end

input = JSON.parse(load_file(File.expand_path('../input.nt', __FILE__)).dump(:jsonld))

build_framing = {
  "@context" => {
    "uuid" => "http://www.domain.com/profile/client/resource/",
    "pmcore" => "http://www.domain.com/ontology/pmcore/1.0#",
    "pmaudiovisual" => "http://www.domain.com/ontology/pmaudiovisual/1.0#",
    "pmadditionalsubjects" => "http://www.domain.com/ontology/pmadditionalsubjects/",
    "pmmodel" => "http://www.domain.com/ontology/pmmodel/1.0#",
    "kb" => "http://www.domain.com/profile/client/kb/",
    "rdfs" => "http://www.w3.org/2000/01/rdf-schema#",
    "dc" => "http://purl.org/dc/elements/1.1/",
    "client" => "http://www.domain.com/ontology/client/1.0#",
    "freebase" => "http://rdf.freebase.com/ns/",
    "cents" => "http://www.domain.com/profile/1000cents/resource/",
    "owl" => "http://www.w3.org/2002/07/owl#",
    "skos" => "http://www.w3.org/2008/05/skos#"
  },
  "@id" => "kb:148F9D55-482A-4A96-B06F-16E05D44AA15",
  "@embed" => "@last"
}

puts JSON::LD::API.frame(input, build_framing).to_json(JSON::LD::JSON_STATE)


text:
#!/usr/bin/env ruby
require 'rubygems'
$:.unshift(File.expand_path("../../lib", __FILE__))
require "bundler/setup"
require 'json/ld'
require 'ruby-prof'
require 'getoptlong'

parser_options = {
  base:     nil,
  progress: false,
  profile:  false,
  validate: false,
}

options = {
  parser_options: parser_options,
  output:        STDOUT,
  output_format: :nquads,
  input_format:  :jsonld,
}
input = nil

OPT_ARGS = [
  ["--compact", GetoptLong::NO_ARGUMENT,              "Compact input, using context"],
  ["--context", GetoptLong::REQUIRED_ARGUMENT,        "Context used for compaction"],
  ["--expand", GetoptLong::NO_ARGUMENT,               "Expand input"],
  ["--expanded", GetoptLong::NO_ARGUMENT,             "Input is already expanded"],
  ["--flatten", GetoptLong::NO_ARGUMENT,              "Flatten input"],
  ["--frame", GetoptLong::REQUIRED_ARGUMENT,          "Frame input, option value is frame to use"],
  ["--help", "-?", GetoptLong::NO_ARGUMENT,           "This message"],
  ["--output", "-o", GetoptLong::REQUIRED_ARGUMENT,   "Where to store output (default STDOUT)"],
  ["--uri", GetoptLong::REQUIRED_ARGUMENT,            "Run with argument value as base"],
]

opts = GetoptLong.new(*OPT_ARGS.map {|o| o[0..-2]})

def usage
  STDERR.puts %{Usage: #{$0} [options] file ...}
  width = OPT_ARGS.map do |o|
    l = o.first.length
    l += o[1].length + 2 if o[1].is_a?(String)
    l
  end.max
  OPT_ARGS.each do |o|
    s = "  %-*s  " % [width, (o[1].is_a?(String) ? "#{o[0,2].join(', ')}" : o[0])]
    s += o.last
    STDERR.puts s
  end
  exit(1)
end

opts.each do |opt, arg|
  case opt
  when '--compact'      then options[:compact] = true
  when '--context'      then options[:context] = arg
  when '--expand'       then options[:expand] = true
  when '--expanded'     then options[:expanded] = true
  when '--flatten'      then options[:flatten] = true
  when '--format'       then options[:output_format] = arg.to_sym
  when '--frame'        then options[:frame] = arg
  when "--help"         then usage
  when '--output'       then options[:output] = File.open(arg, "w")
  when '--uri'          then parser_options[:base] = arg
  end
end

doc_cache = {}
la = File.read(File.expand_path("../linked-art.json", __FILE__))
doc_cache["https://linked.art/ns/v1/linked-art.json"] =
  JSON::LD::API::RemoteDocument.new(la,
    documentUrl: "https://linked.art/ns/v1/linked-art.json",
    contentType: "application/ld+json")

options[:documentLoader] = Proc.new do |url, **options, &block|
  raise "Context not pre-cached: #{url}" unless doc_cache.key?(url.to_s)
  block.call doc_cache[url.to_s]
end

all_data = JSON.parse(File.read(File.expand_path("../all_data.json", __FILE__)))

output_dir = File.expand_path("../../doc/profiles/#{File.basename __FILE__, ".rb"}", __FILE__)
FileUtils.mkdir_p(output_dir)
profile = RubyProf::Profile.new
profile.exclude_methods!(Array, :each, :map)
profile.exclude_method!(Hash, :each)
profile.exclude_method!(Kernel, :require)
profile.exclude_method!(Object, :run)
profile.exclude_common_methods!
profile.start
all_data.each do |indata|
  if options[:flatten]
    JSON::LD::API.flatten(indata, options[:context], **options)
  elsif options[:compact]
    JSON::LD::API.compact(indata, options[:context], **options)
  elsif options[:frame]
    JSON::LD::API.frame(indata, options[:frame], **options)
  else
    options[:expandContext] = options[:context]
    JSON::LD::API.expand(indata, **options)
  end
end
result = profile.stop

# Print a graph profile to text
printer = RubyProf::MultiPrinter.new(result)
printer.print(path: output_dir, profile: "profile")
puts "output saved in #{output_dir}"


text:
require_relative 'spec_helper'

unless ENV['CI']
  describe JSON::LD do
    describe "test suite" do
      require_relative 'suite_helper'
      m = Fixtures::SuiteTest::Manifest.open("#{Fixtures::SuiteTest::SUITE}html-manifest.jsonld")
      describe m.name do
        m.entries.each do |t|
          specify "#{t.property('@id')}: #{t.name} unordered#{' (negative test)' unless t.positiveTest?}" do
            t.options[:ordered] = false
            expect { t.run self }.not_to write.to(:error)
          end

          specify "#{t.property('@id')}: #{t.name} ordered#{' (negative test)' unless t.positiveTest?}" do
            t.options[:ordered] = true
            expect { t.run self }.not_to write.to(:error)
          end
        end
      end
    end
  end
end


text:
require_relative 'spec_helper'

unless ENV['CI']
  describe JSON::LD do
    describe "test suite" do
      require_relative 'suite_helper'
      m = Fixtures::SuiteTest::Manifest.open("#{Fixtures::SuiteTest::SUITE}fromRdf-manifest.jsonld")
      describe m.name do
        m.entries.each do |t|
          specify "#{t.property('@id')}: #{t.name} unordered#{' (negative test)' unless t.positiveTest?}" do
            t.options[:ordered] = false
            expect { t.run self }.not_to write.to(:error)
          end

          specify "#{t.property('@id')}: #{t.name} ordered#{' (negative test)' unless t.positiveTest?}" do
            t.options[:ordered] = true
            expect { t.run self }.not_to write.to(:error)
          end
        end
      end
    end
  end
end