Typedb-ml

Latest version: v0.3.0

Safety actively analyzes 626071 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 1 of 2

0.3.0

Documentation: https://github.com/vaticle/typedb-ml

Distribution

Available through https://pypi.org


pip install -r requirements.txt
pip install typedb-client==0.3.0


{ release notes }

0.2.2

Knowledge Graph Convolutional Networks (KGCNs)

This release updates the KGCN project.

New Features

The new features included in this release are:

- Improvements to the build system used by KGLIB for testing and deployment
- Updates KGLIB to be compatible with Grakn 1.8.0 and client-python 1.8.0

0.2.1

Knowledge Graph Convolutional Networks (KGCNs)
This release adds new features to the KGCN project.
New Features
The new features included in this release are:
- Improvements to learning stability, yielding faster convergence (101). The loss function now:
- Ignores all edges
- Ignores all nodes which are marked as preexisting in the graph
- Continuous numerical Attributes can now be ingested and embedded by the network on a by-type basis (102)
- Gradient clipping for improved model stability (102)
- Tensorboard histograms for easier monitoring (102)
- Graph learning plots no longer include preexisting graph elements (108)
- Updated READMEs to explaing the new approach since version 0.2 (106)
- A significant update to the Diagnosis example to include additional data that can indicate disease and rules that infer risk factors (114)
- Refactoring to improve clarity of the:
- pipeline (109 110 112)
- Diagnosis example (114 117 118)

0.2

Knowledge Graph Convolutional Networks (KGCNs)

This release marks the second major iteration of KGCNs. This new KGCN framework is designed to provide a versatile means of performing learning tasks over a Grakn knowledge graph, including:

- Predicting the existence of new Relations between existing Concepts. These relations can be binary, **ternary** (3-way) or **N-ary**, since Relations in Grakn are graph Hyperedges.
- Predicting the values of Attributes attached to other Concepts
- Predicting a subgraph of Entities, Relations and Attributes to complete a known graph
- Predicting erroneous data in a graph
- Predicting many connections within a graph such that the graph as a whole is optimised to satisfy some criteria
- Creating embeddings for Grakn Concepts

At present, Relation prediction is well-implemented. The other functionalities mentioned here will be tackled in future releases.

Methodology

A KGCN is now a learned message-passing graph algorithm. Neural network components are learned, and are used to transform signals that are passed around the graph. This approach is convolutional due to the fact that the same transformation is applied to all edges and another is applied to all nodes. It may help your understanding to analogise this to convolution over images, where the same transformation is applied over all pixel neighbourhoods.

This approach leverages DeepMind's [Graph Nets](https://github.com/deepmind/graph_nets) framework, detailed in their paper. This work is a generalisation of graph learning approaches, which offers plenty of ways to structure learning tailored to various knowledge graph problems.

Data Generation

This release includes a methodology for automatically generating small Grakn Knowledge Graphs based on a Probability Mass Function. This is used for the KGCN example, and allows us to be certain that the graphs we learn on contain sufficient information for good predictions to be made by the learner.

Example

The KGCN project comes with a full example that acts as a template for users to create a KGCN for their own domain.

Limitations

Presently KGCNs can ingest Entities, Relations and Attributes. However, attribute values can only be ingested if they are categorical in nature, since only categorical embedding components are included. Support for embedding continuous valued attributes will be added in the next release.

0.1

The first release of **kglib** introduces **Knowledge Graph Convolutional Networks**

This release improves upon the prereleases as follows:

- Supports supervised multi-class classification for both single-label and multi-label cases

- Works stably with Grakn Core 1.5.3

- Includes a simplified input data pipeline (which creates the arrays fed to the TensorFlow model)

- Fixes `grakn-client` dependency issue, now depending upon a client release rather than a test server

- Now in CI only end-to-end tests use Grakn 1.5.3 with pre-loaded data, integration and unit tests use the plain Grakn 1.5.3 release

0.1a3

Changes

- Significant refactor of the KGCN codebase. This includes creating an architecture that aims to mirror an explanation of the system components. This includes a revision of the terminology used, aiming to be consistent throughout
- In-line with this refactor, the KGCN README has been enlarged and improved in order to document the system components, addresses 49, 52
- Migrates KGCN towards Grakn 1.5: Grakn commit 20750ca0a46b4bc252ad81edccdfd8d8b7c46caa and Python grakn-client commit 5459d5d88a30631c5ebdac3a9b0d5ea6f184c8ae
- CI changes to use GCP to host Grakn distributions, addresses 40

Page 1 of 2

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.