Witness Generation for JSON Schema

02/25/2022
by   Lyes Attouche, et al.
0

JSON Schema is an important, evolving standard schema language for families of JSON documents. It is based on a complex combination of structural and Boolean assertions, and features negation and recursion. The static analysis of JSON Schema documents comprises practically relevant problems, including schema satisfiability, inclusion, and equivalence. These three problems can be reduced to witness generation: given a schema, generate an element of the schema, if it exists, and report failure otherwise. Schema satisfiability, inclusion, and equivalence have been shown to be decidable, by reduction to reachability in alternating tree automata. However, no witness generation algorithm has yet been formally described. We contribute a first, direct algorithm for JSON Schema witness generation. We study its effectiveness and efficiency, in experiments over several schema collections, including thousands of real-world schemas. Our focus is on the completeness of the language, where we only exclude the uniqueItems operator, and on the ability of the algorithm to run in a reasonable time on a large set of real-world examples, despite the exponential complexity of the underlying problem.

READ FULL TEXT

page 1

page 2

page 3

page 4

research
04/30/2021

Not Elimination and Witness Generation for JSON Schema

JSON Schema is an evolving standard for the description of families of J...
research
09/21/2022

Schema-Based Automata Determinization

We propose an algorithm for schema-based determinization of finite autom...
research
04/11/2023

Static Analysis of Graph Database Transformations

We investigate graph transformations, defined using Datalog-like rules b...
research
04/30/2019

Learning Restricted Regular Expressions with Interleaving

The advantages for the presence of an XML schema for XML documents are n...
research
07/19/2021

An Empirical Study on the "Usage of Not" in Real-World JSON Schema Documents (Long Version)

In this paper, we study the usage of negation in JSON Schema data modeli...
research
07/19/2023

Validation of Modern JSON Schema: Formalization and Complexity

JSON Schema is the de-facto standard schema language for JSON data. The ...
research
06/12/2023

Extracting JSON Schemas with Tagged Unions

With data lakes and schema-free NoSQL document stores, extracting a desc...

Please sign up or login with your details

Forgot password? Click here to reset