Giter VIP home page Giter VIP logo

selrestr_maker's Introduction

Selectional Restrictions Extractor

These Python scripts empirically determine the types of frame roles based on the knowledge graphs given in input and create new domain-specific axioms in OWLStar.
The pipeline can be described as a multi-step approach:

  1. Roles identification: obtain <frame_type, role, object_type> triples, where frame_type and object_type are the types of the frame and the class covering role respectively.
  2. Type estimation: empirically estimate the probability of having a certain class as the type of the argument of frame roles
  3. Type generalization: obtain general types through WordNet mappings​
  4. Ontology creation: mapping of triples to OWLStar

This module has been developed specifically for dealing with MUSICBO ontologies for the Polifonia project.

Prerequisites

The scripts have been developed and tested with the following packages and their respective versions:

  • python3: 3.9.7
  • rdflib: 6.2.0
  • SPARQLWrapper: 2.0.0

Usage

Run the following command

python3 selrestr_maker.py -d [KG_DIR]

where [KG_DIR] is the directory where the .nq files are stored.

It is also possible to run a OWLStar to OWL parser:

python3 owlstar2owl.py -i [INPUT_TTL] -o [OUTPUT_TTL]

As of now, the tool is only able to produce .ttl files

More info about selectional restrictions

selrestr_maker's People

Contributors

lucacontalbo avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.