cognite-neat 0.75.4__tar.gz → 0.75.6__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of cognite-neat might be problematic. Click here for more details.
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/PKG-INFO +1 -1
- cognite_neat-0.75.6/cognite/neat/_version.py +1 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/exporters/_rules2dms.py +4 -4
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/exporters/_rules2excel.py +8 -1
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/importers/_base.py +3 -10
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/importers/_dms2rules.py +3 -7
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/importers/_dtdl2rules/dtdl_importer.py +4 -7
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/importers/_owl2rules/_owl2rules.py +4 -7
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/importers/_spreadsheet2rules.py +10 -20
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/importers/_yaml2rules.py +4 -7
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/models/rules/_dms_architect_rules.py +4 -6
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/models/rules/_domain_rules.py +1 -2
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/models/rules/_information_rules.py +1 -3
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/models/rules/_types/_base.py +1 -1
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/steps/lib/rules_importer.py +3 -12
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/pyproject.toml +1 -1
- cognite_neat-0.75.4/cognite/neat/_version.py +0 -1
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/LICENSE +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/README.md +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/api/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/api/asgi/metrics.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/api/configuration.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/api/context_manager/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/api/context_manager/manager.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/api/data_classes/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/api/data_classes/configuration.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/api/data_classes/rest.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/api/explorer.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/api/routers/configuration.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/api/routers/core.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/api/routers/crud.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/api/routers/data_exploration.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/api/routers/metrics.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/api/routers/rules.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/api/routers/workflows.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/api/utils/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/api/utils/data_mapping.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/api/utils/logging.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/api/utils/query_templates.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/main.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/monitoring/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/monitoring/metrics.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/ui/index.html +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/ui/neat-app/.gitignore +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/ui/neat-app/README.md +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/ui/neat-app/build/asset-manifest.json +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/ui/neat-app/build/favicon.ico +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/ui/neat-app/build/img/architect-icon.svg +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/ui/neat-app/build/img/developer-icon.svg +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/ui/neat-app/build/img/sme-icon.svg +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/ui/neat-app/build/index.html +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/ui/neat-app/build/logo192.png +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/ui/neat-app/build/manifest.json +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/ui/neat-app/build/robots.txt +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/ui/neat-app/build/static/css/main.38a62222.css +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/ui/neat-app/build/static/css/main.38a62222.css.map +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/ui/neat-app/build/static/js/main.4345d42f.js +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/ui/neat-app/build/static/js/main.4345d42f.js.LICENSE.txt +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/ui/neat-app/build/static/js/main.4345d42f.js.map +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/ui/neat-app/build/static/media/logo.8093b84df9ed36a174c629d6fe0b730d.svg +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/config.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/constants.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/exceptions.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/graph/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/graph/examples/Knowledge-Graph-Nordic44-dirty.xml +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/graph/examples/Knowledge-Graph-Nordic44.xml +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/graph/examples/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/graph/examples/skos-capturing-sheet-wind-topics.xlsx +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/graph/exceptions.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/graph/extractors/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/graph/extractors/_base.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/graph/extractors/_mock_graph_generator.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/graph/models.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/graph/stores/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/graph/stores/_base.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/graph/stores/_graphdb_store.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/graph/stores/_memory_store.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/graph/stores/_oxigraph_store.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/graph/stores/_oxrdflib.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/graph/stores/_rdf_to_graph.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/examples/Knowledge-Graph-Nordic44-dirty.xml +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/examples/Knowledge-Graph-Nordic44.xml +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/examples/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/examples/skos-capturing-sheet-wind-topics.xlsx +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/exceptions.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/extractors/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/extractors/_base.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/extractors/_dexpi.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/extractors/_graph_capturing_sheet.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/extractors/_mock_graph_generator.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/loaders/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/loaders/_asset_loader.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/loaders/_base.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/loaders/_exceptions.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/loaders/core/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/loaders/core/labels.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/loaders/core/models.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/loaders/core/rdf_to_assets.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/loaders/core/rdf_to_relationships.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/loaders/rdf_to_dms.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/loaders/validator.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/models.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/stores/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/stores/_base.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/stores/_graphdb_store.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/stores/_memory_store.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/stores/_oxigraph_store.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/stores/_oxrdflib.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/stores/_rdf_to_graph.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/transformations/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/transformations/entity_matcher.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/transformations/query_generator/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/transformations/query_generator/sparql.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/graph/transformations/transformer.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/analysis.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/examples/Rules-Nordic44-to-TNT.xlsx +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/examples/Rules-Nordic44-to-graphql.xlsx +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/examples/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/examples/power-grid-containers.yaml +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/examples/power-grid-example.xlsx +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/examples/power-grid-model.yaml +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/examples/rules-template.xlsx +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/examples/sheet2cdf-transformation-rules.xlsx +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/examples/skos-rules.xlsx +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/examples/source-to-solution-mapping-rules.xlsx +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/examples/wind-energy.owl +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/exceptions.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/exporters/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/exporters/_base.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/exporters/_core/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/exporters/_core/rules2labels.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/exporters/_rules2dms.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/exporters/_rules2excel.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/exporters/_rules2graphql.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/exporters/_rules2ontology.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/exporters/_rules2pydantic_models.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/exporters/_rules2rules.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/exporters/_rules2triples.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/exporters/_validation.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/importers/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/importers/_base.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/importers/_dict2rules.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/importers/_dms2rules.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/importers/_graph2rules.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/importers/_json2rules.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/importers/_owl2rules/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/importers/_owl2rules/_owl2classes.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/importers/_owl2rules/_owl2metadata.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/importers/_owl2rules/_owl2properties.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/importers/_owl2rules/_owl2rules.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/importers/_spreadsheet2rules.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/importers/_xsd2rules.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/importers/_yaml2rules.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/models/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/models/_base.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/models/raw_rules.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/models/rdfpath.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/models/rules.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/models/tables.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/legacy/rules/models/value_types.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/py.typed +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/_shared.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/analysis/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/analysis/_base.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/analysis/_information_rules.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/examples/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/examples/wind-energy.owl +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/exceptions.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/exporters/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/exporters/_base.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/exporters/_models.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/exporters/_rules2ontology.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/exporters/_rules2yaml.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/exporters/_validation.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/importers/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/importers/_dtdl2rules/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/importers/_dtdl2rules/_unit_lookup.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/importers/_dtdl2rules/dtdl_converter.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/importers/_dtdl2rules/spec.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/importers/_owl2rules/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/importers/_owl2rules/_owl2classes.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/importers/_owl2rules/_owl2metadata.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/importers/_owl2rules/_owl2properties.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/issues/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/issues/base.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/issues/dms.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/issues/fileread.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/issues/formatters.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/issues/importing.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/issues/spreadsheet.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/issues/spreadsheet_file.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/models/_entity.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/models/rdfpath.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/models/rules/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/models/rules/_base.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/models/rules/_dms_schema.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/models/rules/_types/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/models/rules/_types/_field.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/models/rules/_types/_value.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/utils/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/utils/auxiliary.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/utils/cdf.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/utils/cdf_loaders/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/utils/cdf_loaders/_base.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/utils/cdf_loaders/_data_modeling.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/utils/cdf_loaders/_ingestion.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/utils/cdf_loaders/data_classes.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/utils/exceptions.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/utils/spreadsheet.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/utils/text.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/utils/utils.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/utils/xml.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/_exceptions.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/base.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/cdf_store.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/examples/Export_DMS/workflow.yaml +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/examples/Export_Rules_to_Ontology/workflow.yaml +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/examples/Extract_DEXPI_Graph_and_Export_Rules/workflow.yaml +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/examples/Extract_RDF_Graph_and_Generate_Assets/workflow.yaml +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/examples/Import_DMS/workflow.yaml +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/examples/Ontology_to_Data_Model/workflow.yaml +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/examples/Validate_Rules/workflow.yaml +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/examples/Validate_Solution_Model/workflow.yaml +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/examples/Visualize_Data_Model_Using_Mock_Graph/workflow.yaml +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/examples/Visualize_Semantic_Data_Model/workflow.yaml +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/manager.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/migration/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/migration/steps.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/migration/wf_manifests.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/model.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/steps/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/steps/data_contracts.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/steps/lib/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/steps/lib/graph_extractor.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/steps/lib/graph_loader.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/steps/lib/graph_store.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/steps/lib/io_steps.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/steps/lib/rules_exporter.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/steps/lib/rules_validator.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/steps/lib/v1/__init__.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/steps/lib/v1/graph_contextualization.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/steps/lib/v1/graph_extractor.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/steps/lib/v1/graph_loader.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/steps/lib/v1/graph_store.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/steps/lib/v1/graph_transformer.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/steps/lib/v1/rules_exporter.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/steps/lib/v1/rules_importer.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/steps/step_model.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/steps_registry.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/tasks.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/triggers.py +0 -0
- {cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/utils.py +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
__version__ = "0.75.6"
|
|
@@ -27,7 +27,7 @@ from cognite.neat.utils.cdf_loaders import (
|
|
|
27
27
|
from ._base import CDFExporter
|
|
28
28
|
from ._models import UploadResult
|
|
29
29
|
|
|
30
|
-
Component: TypeAlias = Literal["all", "spaces", "data_models", "views", "containers"]
|
|
30
|
+
Component: TypeAlias = Literal["all", "spaces", "data_models", "views", "containers", "node_types"]
|
|
31
31
|
|
|
32
32
|
|
|
33
33
|
class DMSExporter(CDFExporter[DMSSchema]):
|
|
@@ -99,7 +99,7 @@ class DMSExporter(CDFExporter[DMSSchema]):
|
|
|
99
99
|
if "all" in self.export_components:
|
|
100
100
|
exclude = set()
|
|
101
101
|
else:
|
|
102
|
-
exclude = {"spaces", "data_models", "views", "containers"} - self.export_components
|
|
102
|
+
exclude = {"spaces", "data_models", "views", "containers", "node_types"} - self.export_components
|
|
103
103
|
return exclude
|
|
104
104
|
|
|
105
105
|
def export(self, rules: Rules) -> DMSSchema:
|
|
@@ -118,12 +118,12 @@ class DMSExporter(CDFExporter[DMSSchema]):
|
|
|
118
118
|
return dms_rules.as_schema(self.export_pipeline, self.instance_space)
|
|
119
119
|
|
|
120
120
|
# This is an extension of an existing model.
|
|
121
|
-
reference_rules = cast(DMSRules, dms_rules.reference).
|
|
121
|
+
reference_rules = cast(DMSRules, dms_rules.reference).model_copy(deep=True)
|
|
122
122
|
reference_schema = reference_rules.as_schema(self.export_pipeline)
|
|
123
123
|
|
|
124
124
|
# Todo Move this to an appropriate location
|
|
125
125
|
# Merging Reference with User Rules
|
|
126
|
-
combined_rules = dms_rules.
|
|
126
|
+
combined_rules = dms_rules.model_copy(deep=True)
|
|
127
127
|
existing_containers = {container.class_ for container in combined_rules.containers or []}
|
|
128
128
|
if combined_rules.containers is None:
|
|
129
129
|
combined_rules.containers = SheetList[DMSContainer](data=[])
|
|
@@ -29,6 +29,11 @@ class ExcelExporter(BaseExporter[Workbook]):
|
|
|
29
29
|
new_model_id: The new model ID to use for the exported spreadsheet. This is only applicable if the input
|
|
30
30
|
rules have 'is_reference' set. If provided, the model ID will be used to automatically create the
|
|
31
31
|
new metadata sheet in the Excel file.
|
|
32
|
+
is_reference: If True, the rules are considered to be a reference model. The exported Excel file will
|
|
33
|
+
then contain empty sheets for the main rules and this data model will be dumped to the reference sheets.
|
|
34
|
+
This is useful when you are building a solution model based on an Enterprise model, then the
|
|
35
|
+
Enterprise model will serve as the reference model. It is also useful when you are extending an existing
|
|
36
|
+
model, then the existing model will serve as the reference model. Defaults to False.
|
|
32
37
|
|
|
33
38
|
The following styles are available:
|
|
34
39
|
|
|
@@ -54,6 +59,7 @@ class ExcelExporter(BaseExporter[Workbook]):
|
|
|
54
59
|
styling: Style = "default",
|
|
55
60
|
output_role: RoleTypes | None = None,
|
|
56
61
|
new_model_id: tuple[str, str, str] | None = None,
|
|
62
|
+
is_reference: bool = False,
|
|
57
63
|
):
|
|
58
64
|
if styling not in self.style_options:
|
|
59
65
|
raise ValueError(f"Invalid styling: {styling}. Valid options are {self.style_options}")
|
|
@@ -61,6 +67,7 @@ class ExcelExporter(BaseExporter[Workbook]):
|
|
|
61
67
|
self._styling_level = self.style_options.index(styling)
|
|
62
68
|
self.output_role = output_role
|
|
63
69
|
self.new_model_id = new_model_id
|
|
70
|
+
self.is_reference = is_reference
|
|
64
71
|
|
|
65
72
|
def export_to_file(self, rules: Rules, filepath: Path) -> None:
|
|
66
73
|
"""Exports transformation rules to excel file."""
|
|
@@ -79,7 +86,7 @@ class ExcelExporter(BaseExporter[Workbook]):
|
|
|
79
86
|
|
|
80
87
|
dumped_rules: dict[str, Any]
|
|
81
88
|
dumped_reference_rules: dict[str, Any] | None = None
|
|
82
|
-
if
|
|
89
|
+
if self.is_reference:
|
|
83
90
|
# Writes empty reference sheets
|
|
84
91
|
dumped_rules = {
|
|
85
92
|
"Metadata": self._create_metadata_sheet_user_rules(rules),
|
|
@@ -20,21 +20,18 @@ class BaseImporter(ABC):
|
|
|
20
20
|
"""
|
|
21
21
|
|
|
22
22
|
@overload
|
|
23
|
-
def to_rules(self, errors: Literal["raise"], role: RoleTypes | None = None
|
|
23
|
+
def to_rules(self, errors: Literal["raise"], role: RoleTypes | None = None) -> Rules:
|
|
24
24
|
...
|
|
25
25
|
|
|
26
26
|
@overload
|
|
27
27
|
def to_rules(
|
|
28
|
-
self, errors: Literal["continue"] = "continue", role: RoleTypes | None = None
|
|
28
|
+
self, errors: Literal["continue"] = "continue", role: RoleTypes | None = None
|
|
29
29
|
) -> tuple[Rules | None, IssueList]:
|
|
30
30
|
...
|
|
31
31
|
|
|
32
32
|
@abstractmethod
|
|
33
33
|
def to_rules(
|
|
34
|
-
self,
|
|
35
|
-
errors: Literal["raise", "continue"] = "continue",
|
|
36
|
-
role: RoleTypes | None = None,
|
|
37
|
-
is_reference: bool = False,
|
|
34
|
+
self, errors: Literal["raise", "continue"] = "continue", role: RoleTypes | None = None
|
|
38
35
|
) -> tuple[Rules | None, IssueList] | Rules:
|
|
39
36
|
"""
|
|
40
37
|
Creates `Rules` object from the data for target role.
|
|
@@ -48,7 +45,6 @@ class BaseImporter(ABC):
|
|
|
48
45
|
issues: IssueList,
|
|
49
46
|
errors: Literal["raise", "continue"] = "continue",
|
|
50
47
|
role: RoleTypes | None = None,
|
|
51
|
-
is_reference: bool = False,
|
|
52
48
|
) -> tuple[Rules | None, IssueList] | Rules:
|
|
53
49
|
"""Converts the rules to the output format."""
|
|
54
50
|
|
|
@@ -61,9 +57,6 @@ class BaseImporter(ABC):
|
|
|
61
57
|
else:
|
|
62
58
|
raise NotImplementedError(f"Role {role} is not supported for {type(rules).__name__} rules")
|
|
63
59
|
|
|
64
|
-
if is_reference:
|
|
65
|
-
output.is_reference = True
|
|
66
|
-
|
|
67
60
|
if errors == "raise":
|
|
68
61
|
return output
|
|
69
62
|
else:
|
|
@@ -82,20 +82,17 @@ class DMSImporter(BaseImporter):
|
|
|
82
82
|
return cls(DMSSchema.from_zip(zip_file))
|
|
83
83
|
|
|
84
84
|
@overload
|
|
85
|
-
def to_rules(self, errors: Literal["raise"], role: RoleTypes | None = None
|
|
85
|
+
def to_rules(self, errors: Literal["raise"], role: RoleTypes | None = None) -> Rules:
|
|
86
86
|
...
|
|
87
87
|
|
|
88
88
|
@overload
|
|
89
89
|
def to_rules(
|
|
90
|
-
self, errors: Literal["continue"] = "continue", role: RoleTypes | None = None
|
|
90
|
+
self, errors: Literal["continue"] = "continue", role: RoleTypes | None = None
|
|
91
91
|
) -> tuple[Rules | None, IssueList]:
|
|
92
92
|
...
|
|
93
93
|
|
|
94
94
|
def to_rules(
|
|
95
|
-
self,
|
|
96
|
-
errors: Literal["raise", "continue"] = "continue",
|
|
97
|
-
role: RoleTypes | None = None,
|
|
98
|
-
is_reference: bool = False,
|
|
95
|
+
self, errors: Literal["raise", "continue"] = "continue", role: RoleTypes | None = None
|
|
99
96
|
) -> tuple[Rules | None, IssueList] | Rules:
|
|
100
97
|
if role is RoleTypes.domain_expert:
|
|
101
98
|
raise ValueError(f"Role {role} is not supported for DMSImporter")
|
|
@@ -210,7 +207,6 @@ class DMSImporter(BaseImporter):
|
|
|
210
207
|
data=[DMSContainer.from_container(container) for container in self.schema.containers]
|
|
211
208
|
),
|
|
212
209
|
views=SheetList[DMSView](data=[DMSView.from_view(view, data_model_view_ids) for view in self.schema.views]),
|
|
213
|
-
is_reference=is_reference,
|
|
214
210
|
)
|
|
215
211
|
output_rules: Rules
|
|
216
212
|
if role is RoleTypes.information_architect:
|
|
@@ -119,20 +119,17 @@ class DTDLImporter(BaseImporter):
|
|
|
119
119
|
return cls(items, zip_file.stem, read_issues=issues)
|
|
120
120
|
|
|
121
121
|
@overload
|
|
122
|
-
def to_rules(self, errors: Literal["raise"], role: RoleTypes | None = None
|
|
122
|
+
def to_rules(self, errors: Literal["raise"], role: RoleTypes | None = None) -> Rules:
|
|
123
123
|
...
|
|
124
124
|
|
|
125
125
|
@overload
|
|
126
126
|
def to_rules(
|
|
127
|
-
self, errors: Literal["continue"] = "continue", role: RoleTypes | None = None
|
|
127
|
+
self, errors: Literal["continue"] = "continue", role: RoleTypes | None = None
|
|
128
128
|
) -> tuple[Rules | None, IssueList]:
|
|
129
129
|
...
|
|
130
130
|
|
|
131
131
|
def to_rules(
|
|
132
|
-
self,
|
|
133
|
-
errors: Literal["raise", "continue"] = "continue",
|
|
134
|
-
role: RoleTypes | None = None,
|
|
135
|
-
is_reference: bool = False,
|
|
132
|
+
self, errors: Literal["raise", "continue"] = "continue", role: RoleTypes | None = None
|
|
136
133
|
) -> tuple[Rules | None, IssueList] | Rules:
|
|
137
134
|
converter = _DTDLConverter(self._read_issues)
|
|
138
135
|
|
|
@@ -161,4 +158,4 @@ class DTDLImporter(BaseImporter):
|
|
|
161
158
|
else:
|
|
162
159
|
raise converter.issues.as_errors()
|
|
163
160
|
|
|
164
|
-
return self._to_output(rules, converter.issues, errors, role
|
|
161
|
+
return self._to_output(rules, converter.issues, errors, role)
|
{cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/importers/_owl2rules/_owl2rules.py
RENAMED
|
@@ -43,20 +43,17 @@ class OWLImporter(BaseImporter):
|
|
|
43
43
|
self.make_compliant = make_compliant
|
|
44
44
|
|
|
45
45
|
@overload
|
|
46
|
-
def to_rules(self, errors: Literal["raise"], role: RoleTypes | None = None
|
|
46
|
+
def to_rules(self, errors: Literal["raise"], role: RoleTypes | None = None) -> Rules:
|
|
47
47
|
...
|
|
48
48
|
|
|
49
49
|
@overload
|
|
50
50
|
def to_rules(
|
|
51
|
-
self, errors: Literal["continue"] = "continue", role: RoleTypes | None = None
|
|
51
|
+
self, errors: Literal["continue"] = "continue", role: RoleTypes | None = None
|
|
52
52
|
) -> tuple[Rules | None, IssueList]:
|
|
53
53
|
...
|
|
54
54
|
|
|
55
55
|
def to_rules(
|
|
56
|
-
self,
|
|
57
|
-
errors: Literal["raise", "continue"] = "continue",
|
|
58
|
-
role: RoleTypes | None = None,
|
|
59
|
-
is_reference: bool = False,
|
|
56
|
+
self, errors: Literal["raise", "continue"] = "continue", role: RoleTypes | None = None
|
|
60
57
|
) -> tuple[Rules | None, IssueList] | Rules:
|
|
61
58
|
graph = Graph()
|
|
62
59
|
try:
|
|
@@ -82,7 +79,7 @@ class OWLImporter(BaseImporter):
|
|
|
82
79
|
components = make_components_compliant(components)
|
|
83
80
|
|
|
84
81
|
rules = InformationRules.model_validate(components)
|
|
85
|
-
return self._to_output(rules, IssueList(), errors, role
|
|
82
|
+
return self._to_output(rules, IssueList(), errors, role)
|
|
86
83
|
|
|
87
84
|
|
|
88
85
|
def make_components_compliant(components: dict) -> dict:
|
{cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/importers/_spreadsheet2rules.py
RENAMED
|
@@ -152,7 +152,7 @@ class ExcelImporter(BaseImporter):
|
|
|
152
152
|
self.filepath = filepath
|
|
153
153
|
|
|
154
154
|
@overload
|
|
155
|
-
def to_rules(self, errors: Literal["raise"], role: RoleTypes | None = None
|
|
155
|
+
def to_rules(self, errors: Literal["raise"], role: RoleTypes | None = None) -> Rules:
|
|
156
156
|
...
|
|
157
157
|
|
|
158
158
|
@overload
|
|
@@ -160,29 +160,23 @@ class ExcelImporter(BaseImporter):
|
|
|
160
160
|
self,
|
|
161
161
|
errors: Literal["continue"] = "continue",
|
|
162
162
|
role: RoleTypes | None = None,
|
|
163
|
-
is_reference: bool = False,
|
|
164
163
|
) -> tuple[Rules | None, IssueList]:
|
|
165
164
|
...
|
|
166
165
|
|
|
167
166
|
def to_rules(
|
|
168
|
-
self,
|
|
169
|
-
errors: Literal["raise", "continue"] = "continue",
|
|
170
|
-
role: RoleTypes | None = None,
|
|
171
|
-
is_reference: bool = False,
|
|
167
|
+
self, errors: Literal["raise", "continue"] = "continue", role: RoleTypes | None = None
|
|
172
168
|
) -> tuple[Rules | None, IssueList] | Rules:
|
|
173
169
|
issue_list = IssueList(title=f"'{self.filepath.name}'")
|
|
174
170
|
if not self.filepath.exists():
|
|
175
171
|
issue_list.append(issues.spreadsheet_file.SpreadsheetNotFoundError(self.filepath))
|
|
176
172
|
return self._return_or_raise(issue_list, errors)
|
|
177
173
|
|
|
178
|
-
user_result
|
|
179
|
-
if
|
|
180
|
-
|
|
181
|
-
if user_result is None or issue_list.has_errors:
|
|
182
|
-
return self._return_or_raise(issue_list, errors)
|
|
174
|
+
user_result = SpreadsheetReader(issue_list, is_reference=False).read(self.filepath)
|
|
175
|
+
if user_result is None or issue_list.has_errors:
|
|
176
|
+
return self._return_or_raise(issue_list, errors)
|
|
183
177
|
|
|
184
178
|
reference_result: ReadResult | None = None
|
|
185
|
-
if
|
|
179
|
+
if (
|
|
186
180
|
user_result
|
|
187
181
|
and user_result.role != RoleTypes.domain_expert
|
|
188
182
|
and user_result.schema == SchemaCompleteness.extended
|
|
@@ -230,7 +224,6 @@ class ExcelImporter(BaseImporter):
|
|
|
230
224
|
issue_list,
|
|
231
225
|
errors=errors,
|
|
232
226
|
role=role,
|
|
233
|
-
is_reference=is_reference,
|
|
234
227
|
)
|
|
235
228
|
|
|
236
229
|
@classmethod
|
|
@@ -246,20 +239,17 @@ class GoogleSheetImporter(BaseImporter):
|
|
|
246
239
|
self.skiprows = skiprows
|
|
247
240
|
|
|
248
241
|
@overload
|
|
249
|
-
def to_rules(self, errors: Literal["raise"], role: RoleTypes | None = None
|
|
242
|
+
def to_rules(self, errors: Literal["raise"], role: RoleTypes | None = None) -> Rules:
|
|
250
243
|
...
|
|
251
244
|
|
|
252
245
|
@overload
|
|
253
246
|
def to_rules(
|
|
254
|
-
self, errors: Literal["continue"] = "continue", role: RoleTypes | None = None
|
|
247
|
+
self, errors: Literal["continue"] = "continue", role: RoleTypes | None = None
|
|
255
248
|
) -> tuple[Rules | None, IssueList]:
|
|
256
249
|
...
|
|
257
250
|
|
|
258
251
|
def to_rules(
|
|
259
|
-
self,
|
|
260
|
-
errors: Literal["raise", "continue"] = "continue",
|
|
261
|
-
role: RoleTypes | None = None,
|
|
262
|
-
is_reference: bool = False,
|
|
252
|
+
self, errors: Literal["raise", "continue"] = "continue", role: RoleTypes | None = None
|
|
263
253
|
) -> tuple[Rules | None, IssueList] | Rules:
|
|
264
254
|
local_import("gspread", "google")
|
|
265
255
|
import gspread # type: ignore[import]
|
|
@@ -284,4 +274,4 @@ class GoogleSheetImporter(BaseImporter):
|
|
|
284
274
|
else:
|
|
285
275
|
raise ValueError(f"Role {role} is not valid.")
|
|
286
276
|
|
|
287
|
-
return self._to_output(output, IssueList(), errors=errors, role=role
|
|
277
|
+
return self._to_output(output, IssueList(), errors=errors, role=role)
|
|
@@ -45,20 +45,17 @@ class YAMLImporter(BaseImporter):
|
|
|
45
45
|
return cls(yaml.safe_load(filepath.read_text()), filepaths=[filepath])
|
|
46
46
|
|
|
47
47
|
@overload
|
|
48
|
-
def to_rules(self, errors: Literal["raise"], role: RoleTypes | None = None
|
|
48
|
+
def to_rules(self, errors: Literal["raise"], role: RoleTypes | None = None) -> Rules:
|
|
49
49
|
...
|
|
50
50
|
|
|
51
51
|
@overload
|
|
52
52
|
def to_rules(
|
|
53
|
-
self, errors: Literal["continue"] = "continue", role: RoleTypes | None = None
|
|
53
|
+
self, errors: Literal["continue"] = "continue", role: RoleTypes | None = None
|
|
54
54
|
) -> tuple[Rules | None, IssueList]:
|
|
55
55
|
...
|
|
56
56
|
|
|
57
57
|
def to_rules(
|
|
58
|
-
self,
|
|
59
|
-
errors: Literal["raise", "continue"] = "continue",
|
|
60
|
-
role: RoleTypes | None = None,
|
|
61
|
-
is_reference: bool = False,
|
|
58
|
+
self, errors: Literal["raise", "continue"] = "continue", role: RoleTypes | None = None
|
|
62
59
|
) -> tuple[Rules | None, IssueList] | Rules:
|
|
63
60
|
if any(issue for issue in self._read_issues if isinstance(issue, NeatValidationError)) or not self.raw_data:
|
|
64
61
|
if errors == "raise":
|
|
@@ -107,4 +104,4 @@ class YAMLImporter(BaseImporter):
|
|
|
107
104
|
else:
|
|
108
105
|
raise issue_list.as_errors()
|
|
109
106
|
|
|
110
|
-
return self._to_output(rules, issue_list, errors, role
|
|
107
|
+
return self._to_output(rules, issue_list, errors, role)
|
{cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/models/rules/_dms_architect_rules.py
RENAMED
|
@@ -282,7 +282,6 @@ class DMSRules(BaseRules):
|
|
|
282
282
|
views: SheetList[DMSView] = Field(alias="Views")
|
|
283
283
|
containers: SheetList[DMSContainer] | None = Field(None, alias="Containers")
|
|
284
284
|
reference: "DMSRules | None" = Field(None, alias="Reference")
|
|
285
|
-
is_reference: bool = False
|
|
286
285
|
|
|
287
286
|
@model_validator(mode="after")
|
|
288
287
|
def set_default_space_and_version(self) -> "DMSRules":
|
|
@@ -583,7 +582,7 @@ class DMSRules(BaseRules):
|
|
|
583
582
|
"The schema is set to 'extended', but no reference rules are provided to validate against"
|
|
584
583
|
)
|
|
585
584
|
# This is an extension of the reference rules, we need to merge the two
|
|
586
|
-
rules = self.
|
|
585
|
+
rules = self.model_copy(deep=True)
|
|
587
586
|
rules.properties.extend(self.reference.properties.data)
|
|
588
587
|
existing_views = {view.view.as_id(False) for view in rules.views}
|
|
589
588
|
rules.views.extend([view for view in self.reference.views if view.view.as_id(False) not in existing_views])
|
|
@@ -666,7 +665,6 @@ class DMSRules(BaseRules):
|
|
|
666
665
|
"Properties" if info.by_alias else "properties": properties,
|
|
667
666
|
"Views" if info.by_alias else "views": views,
|
|
668
667
|
"Containers" if info.by_alias else "containers": containers,
|
|
669
|
-
"is_reference": self.is_reference,
|
|
670
668
|
}
|
|
671
669
|
if self.reference is not None:
|
|
672
670
|
output["Reference" if info.by_alias else "reference"] = self.reference.model_dump(**kwargs)
|
|
@@ -682,7 +680,7 @@ class DMSRules(BaseRules):
|
|
|
682
680
|
return _DMSRulesConverter(self).as_domain_rules()
|
|
683
681
|
|
|
684
682
|
def reference_self(self) -> Self:
|
|
685
|
-
new_rules = self.
|
|
683
|
+
new_rules = self.model_copy(deep=True)
|
|
686
684
|
for prop in new_rules.properties:
|
|
687
685
|
prop.reference = ReferenceEntity(
|
|
688
686
|
prefix=prop.view.prefix, suffix=prop.view.suffix, version=prop.view.version, property_=prop.property_
|
|
@@ -762,7 +760,8 @@ class _DMSExporter:
|
|
|
762
760
|
data_model.space = used_spaces.pop()
|
|
763
761
|
spaces = dm.SpaceApplyList([dm.SpaceApply(space=data_model.space)])
|
|
764
762
|
else:
|
|
765
|
-
|
|
763
|
+
used_spaces.add(metadata.space)
|
|
764
|
+
spaces = dm.SpaceApplyList([dm.SpaceApply(space=space) for space in used_spaces])
|
|
766
765
|
if self.instance_space and self.instance_space not in {space.space for space in spaces}:
|
|
767
766
|
spaces.append(dm.SpaceApply(space=self.instance_space, name=self.instance_space))
|
|
768
767
|
return spaces
|
|
@@ -1135,7 +1134,6 @@ class _DMSRulesConverter:
|
|
|
1135
1134
|
properties=SheetList[InformationProperty](data=properties),
|
|
1136
1135
|
classes=SheetList[InformationClass](data=classes),
|
|
1137
1136
|
reference=self.dms.reference and self.dms.reference.as_information_architect_rules(), # type: ignore[arg-type]
|
|
1138
|
-
is_reference=self.dms.is_reference,
|
|
1139
1137
|
)
|
|
1140
1138
|
|
|
1141
1139
|
@classmethod
|
{cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/models/rules/_domain_rules.py
RENAMED
|
@@ -48,7 +48,6 @@ class DomainRules(RuleModel):
|
|
|
48
48
|
properties: SheetList[DomainProperty] = Field(alias="Properties")
|
|
49
49
|
classes: SheetList[DomainClass] | None = Field(None, alias="Classes")
|
|
50
50
|
reference: "DomainRules | None" = Field(None, alias="Reference")
|
|
51
|
-
is_reference: bool = False
|
|
52
51
|
|
|
53
52
|
@model_serializer(mode="plain", when_used="always")
|
|
54
53
|
def domain_rules_serializer(self, info: SerializationInfo) -> dict[str, Any]:
|
|
@@ -65,4 +64,4 @@ class DomainRules(RuleModel):
|
|
|
65
64
|
|
|
66
65
|
def reference_self(self) -> "DomainRules":
|
|
67
66
|
"""DomainRules does not have reference field, so it returns a copy of itself."""
|
|
68
|
-
return self.
|
|
67
|
+
return self.model_copy(deep=True)
|
{cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/rules/models/rules/_information_rules.py
RENAMED
|
@@ -247,7 +247,6 @@ class InformationRules(RuleModel):
|
|
|
247
247
|
classes: SheetList[InformationClass] = Field(alias="Classes")
|
|
248
248
|
prefixes: dict[str, Namespace] = Field(default_factory=lambda: PREFIXES.copy())
|
|
249
249
|
reference: "InformationRules | None" = Field(None, alias="Reference")
|
|
250
|
-
is_reference: bool = False
|
|
251
250
|
|
|
252
251
|
@field_validator("prefixes", mode="before")
|
|
253
252
|
def parse_str(cls, values: Any) -> Any:
|
|
@@ -355,7 +354,7 @@ class InformationRules(RuleModel):
|
|
|
355
354
|
return _InformationRulesConverter(self).as_dms_architect_rules()
|
|
356
355
|
|
|
357
356
|
def reference_self(self) -> "InformationRules":
|
|
358
|
-
new_self = self.
|
|
357
|
+
new_self = self.model_copy(deep=True)
|
|
359
358
|
for prop in new_self.properties:
|
|
360
359
|
prop.reference = ReferenceEntity(
|
|
361
360
|
prefix=prop.class_.prefix,
|
|
@@ -451,7 +450,6 @@ class _InformationRulesConverter:
|
|
|
451
450
|
views=SheetList[DMSView](data=views),
|
|
452
451
|
containers=SheetList[DMSContainer](data=containers),
|
|
453
452
|
reference=self.information.reference and self.information.reference.as_dms_architect_rules(), # type: ignore[arg-type]
|
|
454
|
-
is_reference=self.information.is_reference,
|
|
455
453
|
)
|
|
456
454
|
|
|
457
455
|
@classmethod
|
{cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/workflows/steps/lib/rules_importer.py
RENAMED
|
@@ -72,7 +72,7 @@ class ExcelToRules(Step):
|
|
|
72
72
|
role_enum = RoleTypes[role]
|
|
73
73
|
|
|
74
74
|
excel_importer = importers.ExcelImporter(rules_file_path)
|
|
75
|
-
rules, issues = excel_importer.to_rules(
|
|
75
|
+
rules, issues = excel_importer.to_rules(errors="continue", role=role_enum)
|
|
76
76
|
|
|
77
77
|
if rules is None:
|
|
78
78
|
output_dir = self.data_store_path / Path("staging")
|
|
@@ -151,7 +151,7 @@ class OntologyToRules(Step):
|
|
|
151
151
|
role_enum = RoleTypes[role]
|
|
152
152
|
|
|
153
153
|
ontology_importer = importers.OWLImporter(filepath=rules_file_path, make_compliant=make_compliant)
|
|
154
|
-
rules, issues = ontology_importer.to_rules(
|
|
154
|
+
rules, issues = ontology_importer.to_rules(errors="continue", role=role_enum)
|
|
155
155
|
|
|
156
156
|
if rules is None:
|
|
157
157
|
output_dir = self.data_store_path / Path("staging")
|
|
@@ -196,13 +196,6 @@ class DMSToRules(Step):
|
|
|
196
196
|
label="For what role Rules are intended?",
|
|
197
197
|
options=["infer", *RoleTypes.__members__.keys()],
|
|
198
198
|
),
|
|
199
|
-
Configurable(
|
|
200
|
-
name="Reference",
|
|
201
|
-
value="false",
|
|
202
|
-
label="Whether the imported rules are a reference model or not. This is "
|
|
203
|
-
"used when you want to extend an existing model and this is the model that is being extended from.",
|
|
204
|
-
options=["true", "false"],
|
|
205
|
-
),
|
|
206
199
|
]
|
|
207
200
|
|
|
208
201
|
def run(self, cdf_client: CogniteClient) -> (FlowMessage, MultiRuleData): # type: ignore[syntax, override]
|
|
@@ -222,8 +215,6 @@ class DMSToRules(Step):
|
|
|
222
215
|
)
|
|
223
216
|
return FlowMessage(error_text=error_text, step_execution_status=StepExecutionStatus.ABORT_AND_FAIL)
|
|
224
217
|
|
|
225
|
-
is_reference = self.configs.get("Reference", "false") == "true"
|
|
226
|
-
|
|
227
218
|
dms_importer = importers.DMSImporter.from_data_model_id(cdf_client, datamodel_entity.as_id())
|
|
228
219
|
|
|
229
220
|
# if role is None, it will be inferred from the rules file
|
|
@@ -232,7 +223,7 @@ class DMSToRules(Step):
|
|
|
232
223
|
if role != "infer" and role is not None:
|
|
233
224
|
role_enum = RoleTypes[role]
|
|
234
225
|
|
|
235
|
-
rules, issues = dms_importer.to_rules(
|
|
226
|
+
rules, issues = dms_importer.to_rules(errors="continue", role=role_enum)
|
|
236
227
|
|
|
237
228
|
if rules is None:
|
|
238
229
|
output_dir = self.data_store_path / Path("staging")
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
__version__ = "0.75.4"
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/api/context_manager/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/api/data_classes/configuration.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/api/routers/data_exploration.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/ui/neat-app/build/asset-manifest.json
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/ui/neat-app/build/img/sme-icon.svg
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/app/ui/neat-app/build/manifest.json
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{cognite_neat-0.75.4 → cognite_neat-0.75.6}/cognite/neat/graph/examples/Knowledge-Graph-Nordic44.xml
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|