Documentation
¶
Index ¶
- type GigClient
- func (c *GigClient) AddEntitiesAsLinks(entity *models.Entity, linkEntities []models.Entity) error
- func (c *GigClient) AddEntityAsAttribute(entity models.Entity, attributeName string, attributeEntity models.Entity) (models.Entity, models.Entity, error)
- func (c *GigClient) AddEntityAsLink(entity models.Entity, linkEntity models.Entity) (models.Entity, models.Entity, error)
- func (c *GigClient) AppendToEntity(appendEntity models.UpdateEntity) (models.Entity, error)
- func (c *GigClient) CreateEntities(entities []models.Entity) ([]models.Entity, error)
- func (c *GigClient) CreateEntity(entity models.Entity) (models.Entity, error)
- func (c *GigClient) CreateEntityFromText(textContent string, title string, categories []string, ...) error
- func (c *GigClient) ExtractEntityNames(textContent string) ([]models.NERResult, error)
- func (c *GigClient) GetEntity(title string) (models.Entity, error)
- func (c *GigClient) GetEntityByAttribute(attributeName string, valueString string) (models.Entity, error)
- func (c GigClient) GetRequest(uri string) (string, error)
- func (c *GigClient) NormalizeName(title string) (string, error)
- func (c *GigClient) PostRequest(uri string, data interface{}) (string, error)
- func (c *GigClient) UploadFile(payload models.Upload) error
- type Response
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GigClient ¶
type GigClient struct {
ApiUrl string `json:"api_url" bson:"api_url"`
ApiKey string `json:"api_key" bson:"api_key"`
NerServerUrl string `json:"ner_server_url" bson:"ner_server_url"`
NormalizationServerUrl string `json:"normalization_url" bson:"normalization_url"`
OcrServerUrl string `json:"ocr_server_url" bson:"ocr_server_url"`
}
func (*GigClient) AddEntitiesAsLinks ¶
AddEntitiesAsLinks - Add list of related entities to a given entity
func (*GigClient) AddEntityAsAttribute ¶
func (c *GigClient) AddEntityAsAttribute(entity models.Entity, attributeName string, attributeEntity models.Entity) (models.Entity, models.Entity, error)
AddEntityAsAttribute - Add entity as an attribute to a given entity
func (*GigClient) AddEntityAsLink ¶
func (c *GigClient) AddEntityAsLink(entity models.Entity, linkEntity models.Entity) (models.Entity, models.Entity, error)
AddEntityAsLink - Add entity as a link to a given entity
func (*GigClient) AppendToEntity ¶ added in v0.2.30
AppendToEntity - Append to entity value
func (*GigClient) CreateEntities ¶
CreateEntities - Create a list of new entities and save to GIG
func (*GigClient) CreateEntity ¶
CreateEntity - Create a new entity and save to GIG
func (*GigClient) CreateEntityFromText ¶
func (c *GigClient) CreateEntityFromText(textContent string, title string, categories []string, entityTitles []models.NERResult) error
CreateEntityFromText - create entity from text content
func (*GigClient) ExtractEntityNames ¶
ExtractEntityNames - NER extraction
func (*GigClient) GetEntityByAttribute ¶ added in v0.2.30
func (c *GigClient) GetEntityByAttribute(attributeName string, valueString string) (models.Entity, error)
GetEntityByAttribute - get entity by attribute
func (GigClient) GetRequest ¶
GetRequest - get the response string for a given url
func (*GigClient) NormalizeName ¶
NormalizeName - normalize entity title before appending
func (*GigClient) PostRequest ¶
PostRequest - Post to an url with data