The Asset Model Module
The Asset Model module provides access to the Ingenuity Neo4j-backed asset model API. See the Assetmodel Tab in Ingenuity to browse the Assetmodel by UI instead.
This API queries ONLY the internal Ingenuity model database, and will not return data configured in a third party model (e.g. Cognite)
See also the Common Menu, which is a more structured API for browsing similar data, including configured third party models.
What This Module Does
Section titled “What This Module Does”- Executes raw Cypher queries against the asset model
- Retrieves measurements associated with assets
- Retrieves documents attached to assets
The Ingenuity Asset Model
Section titled “The Ingenuity Asset Model”In the asset model, code is the primary property that contains an objects ID.
Fsor relations between Assets and timeseries, relations to a tag will always be of type hashistoriantag, with property measurementName denoting measurement and measurement Objects will be of type MeasurementSource
e.g. for a Wellbore A-01, the relation to its DHT guage tag DEMO_02TI301.PV would be
Key Entry Point
Section titled “Key Entry Point”You MUST generate the model client before you can query the Asset Model.
Use get_assetmodel() to create a client:
from eigeningenuity import get_assetmodel, EigenServer
ei = EigenServer("https://demo.eigen.co/")model = get_assetmodel(ei)Common Operations
Section titled “Common Operations”Execute a Cypher Query
Section titled “Execute a Cypher Query”results = model.executeRawQuery("MATCH (n) RETURN n LIMIT 10")Get Measurements for Assets
Section titled “Get Measurements for Assets”measurements = model.getMeasurements(["System_01", "System_02"])Get Documents for Assets
Section titled “Get Documents for Assets”documents = model.getDocuments("System_01")Cypher Query Language
Section titled “Cypher Query Language”For more Information on Cypher itself and how to write querires, please see the Official Cypher Manual
Output Formats
Section titled “Output Formats”Most calls support:
json(default - Remove Api Headers)df(pandas DataFrame)raw(full API response)
Authentication
Section titled “Authentication”For secured environments, configure Azure auth before creating the client. See Authentication.