GIG Python Library

Installation

pip install gig-python

Prerequisites

Initialization

from gig-python import Server as GIG_Server
from gig-python import Entity

server = GIG_Server("http://localhost:9000/")

API Functions

entity = server.get("Sri Lanka")
entities = server.search("sri lanka", attributes_list=["title"])
results = server.normalize_name("sri lanka")
results = server.normalize_location("colombo")
entities = server.get_links("Person A")
entities = server.get_relations("Sri Lanka")
entity = Entity()
entity.title = "LDF Test Entity"
result = server.add(entity)
entity = Entity()
entity.title = "LDF Batch"
result = server.add_all([entity])
entity = Entity()
entity.title = "LDF Test Entity"
entity.source_date = "2021-01-02T15:04:05-07:00"
entity.source = "python-lib"
result = server.terminate(entity)

References

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store