Inline Structured Data Format

PATTERNS

The Cariochi Patterns service utilizes the Cariochi Inline Structured Data Format, a custom format that seamlessly integrates structured data annotations within unstructured text. This format facilitates easy data extraction and analysis by representing structured information within natural language text.

Format Overview

In the Cariochi Inline Structured Data Format, structured data entities are enclosed within curly braces {} and consist of a class name (starting with @) and its associated field (starting with #).

Syntax

The general syntax of the Cariochi Inline Structured Data Format is as follows:

{@Class: {#Field: value}}
  • {@Class}: Represents the name of the class to which the field and value belong (e.g., @Measurement, @Currency, @Date, etc.).

  • {#Field}: Represents the name of the field or property associated with the class (e.g., #year, #day, #sign, etc.).

  • value: Represents the specific value associated with the field.

Examples

  1. Measurement Entity:

    The room measures {@Measurement: {@Number.Integer: 10} {@Unit: feet}} by {@Measurement: {@Number.Integer: 12} {@Unit: feet}}.

    In this example, the text contains two instances of the @Measurement entity. Each @Measurement entity consists of two nested entities: @Number.Integer representing the numeric value (e.g., 10, 12), and @Unit representing the unit of measurement (feet).

  2. Date Entity:

    The conference is on {@Date: {#month: {@Month.7: July}} {#day: {@Number.Integer: 15}}th, {#year: {@Number.Integer: 2023}}}.

    This example includes a @Date entity representing the conference date. The @Date entity has three fields: #month (e.g., July), #day (e.g., 15), and #year (e.g., 2023). Each field contains other entities, such as @Month.7, @Number.Integer, and @Number.Integer, respectively.

  3. Currency Entity:

    The price of the product is {@Money: {@Currency.USD: $}{@Number.Real: 199.99}}.

    Here, the text contains a @Money entity denoted in USD (US Dollars) with a value of 199.99.

Last updated