cognite-neat 0.77.6__tar.gz → 0.77.8__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.77.6 → cognite_neat-0.77.8}/PKG-INFO +1 -1
- cognite_neat-0.77.8/cognite/neat/_version.py +1 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/issues/importing.py +17 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/models/_types/_field.py +11 -17
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/models/dms/_validation.py +4 -1
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/models/information/_converter.py +75 -51
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/steps/lib/current/rules_exporter.py +0 -1
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/pyproject.toml +1 -1
- cognite_neat-0.77.6/cognite/neat/_version.py +0 -1
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/LICENSE +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/README.md +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/api/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/api/asgi/metrics.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/api/configuration.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/api/context_manager/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/api/context_manager/manager.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/api/data_classes/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/api/data_classes/rest.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/api/explorer.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/api/routers/configuration.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/api/routers/core.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/api/routers/crud.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/api/routers/data_exploration.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/api/routers/metrics.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/api/routers/rules.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/api/routers/workflows.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/api/utils/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/api/utils/data_mapping.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/api/utils/logging.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/api/utils/query_templates.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/main.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/monitoring/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/monitoring/metrics.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/ui/index.html +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/ui/neat-app/.gitignore +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/ui/neat-app/README.md +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/ui/neat-app/build/asset-manifest.json +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/ui/neat-app/build/favicon.ico +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/ui/neat-app/build/img/architect-icon.svg +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/ui/neat-app/build/img/developer-icon.svg +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/ui/neat-app/build/img/sme-icon.svg +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/ui/neat-app/build/index.html +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/ui/neat-app/build/logo192.png +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/ui/neat-app/build/manifest.json +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/ui/neat-app/build/robots.txt +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/ui/neat-app/build/static/css/main.38a62222.css +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/ui/neat-app/build/static/css/main.38a62222.css.map +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/ui/neat-app/build/static/js/main.ec7f72e2.js +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/ui/neat-app/build/static/js/main.ec7f72e2.js.LICENSE.txt +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/ui/neat-app/build/static/js/main.ec7f72e2.js.map +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/ui/neat-app/build/static/media/logo.8093b84df9ed36a174c629d6fe0b730d.svg +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/config.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/constants.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/exceptions.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/graph/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/graph/examples/Knowledge-Graph-Nordic44-dirty.xml +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/graph/examples/Knowledge-Graph-Nordic44.xml +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/graph/examples/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/graph/examples/skos-capturing-sheet-wind-topics.xlsx +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/graph/exceptions.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/graph/extractors/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/graph/extractors/_base.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/graph/extractors/_mock_graph_generator.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/graph/models.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/graph/stores/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/graph/stores/_base.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/graph/stores/_graphdb_store.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/graph/stores/_memory_store.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/graph/stores/_oxigraph_store.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/graph/stores/_oxrdflib.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/graph/stores/_rdf_to_graph.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/examples/Knowledge-Graph-Nordic44-dirty.xml +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/examples/Knowledge-Graph-Nordic44.xml +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/examples/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/examples/skos-capturing-sheet-wind-topics.xlsx +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/exceptions.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/extractors/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/extractors/_base.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/extractors/_dexpi.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/extractors/_graph_capturing_sheet.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/extractors/_mock_graph_generator.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/loaders/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/loaders/_asset_loader.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/loaders/_base.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/loaders/_exceptions.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/loaders/core/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/loaders/core/labels.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/loaders/core/models.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/loaders/core/rdf_to_assets.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/loaders/core/rdf_to_relationships.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/loaders/rdf_to_dms.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/loaders/validator.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/models.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/stores/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/stores/_base.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/stores/_graphdb_store.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/stores/_memory_store.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/stores/_oxigraph_store.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/stores/_oxrdflib.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/stores/_rdf_to_graph.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/transformations/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/transformations/entity_matcher.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/transformations/query_generator/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/transformations/query_generator/sparql.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/transformations/transformer.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/analysis.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/examples/Rules-Nordic44-to-TNT.xlsx +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/examples/Rules-Nordic44-to-graphql.xlsx +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/examples/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/examples/power-grid-containers.yaml +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/examples/power-grid-example.xlsx +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/examples/power-grid-model.yaml +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/examples/rules-template.xlsx +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/examples/sheet2cdf-transformation-rules.xlsx +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/examples/skos-rules.xlsx +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/examples/source-to-solution-mapping-rules.xlsx +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/examples/wind-energy.owl +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/exceptions.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/exporters/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/exporters/_base.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/exporters/_core/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/exporters/_core/rules2labels.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/exporters/_rules2dms.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/exporters/_rules2excel.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/exporters/_rules2graphql.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/exporters/_rules2ontology.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/exporters/_rules2pydantic_models.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/exporters/_rules2rules.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/exporters/_rules2triples.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/exporters/_validation.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/importers/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/importers/_base.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/importers/_dict2rules.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/importers/_dms2rules.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/importers/_graph2rules.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/importers/_json2rules.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/importers/_owl2rules/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/importers/_owl2rules/_owl2classes.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/importers/_owl2rules/_owl2metadata.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/importers/_owl2rules/_owl2properties.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/importers/_owl2rules/_owl2rules.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/importers/_spreadsheet2rules.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/importers/_xsd2rules.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/importers/_yaml2rules.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/models/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/models/_base.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/models/raw_rules.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/models/rdfpath.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/models/rules.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/models/tables.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/models/value_types.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/workflows/examples/Export_DMS/workflow.yaml +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/workflows/examples/Export_Rules_to_Ontology/workflow.yaml +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/workflows/examples/Extract_DEXPI_Graph_and_Export_Rules/workflow.yaml +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/workflows/examples/Extract_RDF_Graph_and_Generate_Assets/workflow.yaml +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/workflows/examples/Import_DMS/workflow.yaml +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/workflows/examples/Ontology_to_Data_Model/workflow.yaml +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/workflows/examples/Validate_Rules/workflow.yaml +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/workflows/examples/Validate_Solution_Model/workflow.yaml +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/workflows/examples/Visualize_Data_Model_Using_Mock_Graph/workflow.yaml +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/workflows/examples/Visualize_Semantic_Data_Model/workflow.yaml +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/py.typed +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/_shared.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/analysis/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/analysis/_base.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/analysis/_information_rules.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/examples/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/examples/wind-energy.owl +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/exceptions.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/exporters/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/exporters/_base.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/exporters/_models.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/exporters/_rules2dms.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/exporters/_rules2excel.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/exporters/_rules2ontology.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/exporters/_rules2yaml.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/exporters/_validation.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/importers/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/importers/_base.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/importers/_dms2rules.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/importers/_dtdl2rules/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/importers/_dtdl2rules/_unit_lookup.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/importers/_dtdl2rules/dtdl_converter.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/importers/_dtdl2rules/dtdl_importer.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/importers/_dtdl2rules/spec.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/importers/_owl2rules/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/importers/_owl2rules/_owl2classes.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/importers/_owl2rules/_owl2metadata.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/importers/_owl2rules/_owl2properties.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/importers/_owl2rules/_owl2rules.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/importers/_spreadsheet2rules.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/importers/_yaml2rules.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/issues/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/issues/base.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/issues/dms.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/issues/fileread.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/issues/formatters.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/issues/spreadsheet.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/issues/spreadsheet_file.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/models/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/models/_base.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/models/_rdfpath.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/models/_types/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/models/_types/_base.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/models/data_types.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/models/dms/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/models/dms/_converter.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/models/dms/_exporter.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/models/dms/_rules.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/models/dms/_rules_input.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/models/dms/_schema.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/models/dms/_serializer.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/models/domain.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/models/entities.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/models/information/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/models/information/_rules.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/models/information/_rules_input.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/models/information/_serializer.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/models/information/_validation.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/models/wrapped_entities.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/utils/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/utils/auxiliary.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/utils/cdf.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/utils/cdf_classes.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/utils/cdf_loaders/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/utils/cdf_loaders/_base.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/utils/cdf_loaders/_data_modeling.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/utils/cdf_loaders/_ingestion.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/utils/cdf_loaders/data_classes.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/utils/exceptions.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/utils/spreadsheet.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/utils/text.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/utils/utils.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/utils/xml.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/_exceptions.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/base.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/cdf_store.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/examples/Export_DMS/workflow.yaml +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/examples/Export_Rules_to_Ontology/workflow.yaml +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/examples/Extract_DEXPI_Graph_and_Export_Rules/workflow.yaml +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/examples/Extract_RDF_Graph_and_Generate_Assets/workflow.yaml +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/examples/Import_DMS/workflow.yaml +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/examples/Ontology_to_Data_Model/workflow.yaml +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/examples/Validate_Rules/workflow.yaml +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/examples/Validate_Solution_Model/workflow.yaml +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/examples/Visualize_Data_Model_Using_Mock_Graph/workflow.yaml +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/examples/Visualize_Semantic_Data_Model/workflow.yaml +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/manager.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/migration/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/migration/steps.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/migration/wf_manifests.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/model.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/steps/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/steps/data_contracts.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/steps/lib/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/steps/lib/current/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/steps/lib/current/graph_extractor.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/steps/lib/current/graph_loader.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/steps/lib/current/graph_store.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/steps/lib/current/rules_importer.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/steps/lib/current/rules_validator.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/steps/lib/io/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/steps/lib/io/io_steps.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/steps/lib/legacy/__init__.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/steps/lib/legacy/graph_contextualization.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/steps/lib/legacy/graph_extractor.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/steps/lib/legacy/graph_loader.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/steps/lib/legacy/graph_store.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/steps/lib/legacy/graph_transformer.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/steps/lib/legacy/rules_exporter.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/steps/lib/legacy/rules_importer.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/steps/step_model.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/steps_registry.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/tasks.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/triggers.py +0 -0
- {cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/workflows/utils.py +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
__version__ = "0.77.8"
|
|
@@ -16,6 +16,7 @@ __all__ = [
|
|
|
16
16
|
"MultipleDataModelsWarning",
|
|
17
17
|
"UnknownPropertyTypeWarning",
|
|
18
18
|
"FailedToInferValueTypeWarning",
|
|
19
|
+
"MoreThanOneNonAlphanumericCharacterWarning",
|
|
19
20
|
"UnknownContainerConstraintWarning",
|
|
20
21
|
"NoDataModelError",
|
|
21
22
|
"ModelImportError",
|
|
@@ -275,6 +276,22 @@ class FailedImportWarning(ModelImportWarning):
|
|
|
275
276
|
return {"identifier": list(self.identifier)}
|
|
276
277
|
|
|
277
278
|
|
|
279
|
+
@dataclass(frozen=True)
|
|
280
|
+
class MoreThanOneNonAlphanumericCharacterWarning(ModelImportWarning):
|
|
281
|
+
description = """This warning is raised when doing regex validation of strings which either represent class ids,
|
|
282
|
+
property ids, prefix, data model name, that contain more than one non-alphanumeric character,
|
|
283
|
+
such as for example '_' or '-'."""
|
|
284
|
+
|
|
285
|
+
field_name: str
|
|
286
|
+
value: str
|
|
287
|
+
|
|
288
|
+
def message(self) -> str:
|
|
289
|
+
return f"Field {self.field_name} with value {self.value} contains more than one non-alphanumeric character!"
|
|
290
|
+
|
|
291
|
+
def dump(self) -> dict[str, str]:
|
|
292
|
+
return {"field_name": self.field_name, "value": self.value}
|
|
293
|
+
|
|
294
|
+
|
|
278
295
|
@dataclass(frozen=True)
|
|
279
296
|
class ModelImportError(NeatValidationError, ABC):
|
|
280
297
|
description = "An error was raised during importing."
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import re
|
|
2
|
+
import warnings
|
|
2
3
|
from collections.abc import Callable
|
|
3
4
|
from typing import Annotated, Any, cast
|
|
4
5
|
|
|
@@ -17,6 +18,7 @@ from pydantic.functional_serializers import PlainSerializer
|
|
|
17
18
|
from pydantic_core import PydanticCustomError
|
|
18
19
|
|
|
19
20
|
from cognite.neat.rules import exceptions
|
|
21
|
+
from cognite.neat.rules.issues.importing import MoreThanOneNonAlphanumericCharacterWarning
|
|
20
22
|
|
|
21
23
|
from ._base import (
|
|
22
24
|
MORE_THAN_ONE_NONE_ALPHANUMERIC_REGEX,
|
|
@@ -50,7 +52,6 @@ StrOrListType = Annotated[
|
|
|
50
52
|
),
|
|
51
53
|
]
|
|
52
54
|
|
|
53
|
-
|
|
54
55
|
StrListType = Annotated[
|
|
55
56
|
list[str],
|
|
56
57
|
BeforeValidator(lambda value: [entry.strip() for entry in value.split(",")] if isinstance(value, str) else value),
|
|
@@ -96,19 +97,12 @@ VersionType = Annotated[
|
|
|
96
97
|
]
|
|
97
98
|
|
|
98
99
|
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
else _raise(
|
|
109
|
-
exceptions.PropertyIDRegexViolation(value, PROPERTY_ID_COMPLIANCE_REGEX).to_pydantic_custom_error()
|
|
110
|
-
)
|
|
111
|
-
)
|
|
112
|
-
)
|
|
113
|
-
),
|
|
114
|
-
]
|
|
100
|
+
def _property_validation(value: str) -> str:
|
|
101
|
+
if not re.match(PROPERTY_ID_COMPLIANCE_REGEX, value):
|
|
102
|
+
_raise(exceptions.PropertyIDRegexViolation(value, PROPERTY_ID_COMPLIANCE_REGEX).to_pydantic_custom_error())
|
|
103
|
+
if re.search(MORE_THAN_ONE_NONE_ALPHANUMERIC_REGEX, value):
|
|
104
|
+
warnings.warn(MoreThanOneNonAlphanumericCharacterWarning("property", value), stacklevel=2)
|
|
105
|
+
return value
|
|
106
|
+
|
|
107
|
+
|
|
108
|
+
PropertyType = Annotated[str, AfterValidator(_property_validation)]
|
|
@@ -57,7 +57,10 @@ class DMSPostValidation:
|
|
|
57
57
|
container_id = container.as_id()
|
|
58
58
|
row_numbers = {prop_no for prop_no, _ in properties}
|
|
59
59
|
value_types = {prop.value_type for _, prop in properties if prop.value_type}
|
|
60
|
-
|
|
60
|
+
# The container type 'direct' is an exception. On a container the type direct can point to any
|
|
61
|
+
# node. The value type is typically set on the view.
|
|
62
|
+
is_all_direct = all(prop.connection == "direct" for _, prop in properties)
|
|
63
|
+
if len(value_types) > 1 and not is_all_direct:
|
|
61
64
|
errors.append(
|
|
62
65
|
issues.spreadsheet.MultiValueTypeError(
|
|
63
66
|
container_id,
|
{cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/rules/models/information/_converter.py
RENAMED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import re
|
|
2
|
-
from collections import defaultdict
|
|
2
|
+
from collections import Counter, defaultdict
|
|
3
|
+
from collections.abc import Collection
|
|
3
4
|
from typing import TYPE_CHECKING, Literal
|
|
4
5
|
|
|
5
6
|
from cognite.neat.rules.models._base import (
|
|
@@ -40,7 +41,6 @@ class _InformationRulesConverter:
|
|
|
40
41
|
self.last_classes = {class_.class_: class_ for class_ in self.rules.last.classes}
|
|
41
42
|
else:
|
|
42
43
|
self.last_classes = {}
|
|
43
|
-
self._created_classes_from: dict[ClassEntity, ClassEntity] = {}
|
|
44
44
|
|
|
45
45
|
def as_domain_rules(self) -> DomainRules:
|
|
46
46
|
raise NotImplementedError("DomainRules not implemented yet")
|
|
@@ -58,11 +58,13 @@ class _InformationRulesConverter:
|
|
|
58
58
|
default_space = self._to_space(info_metadata.prefix)
|
|
59
59
|
metadata = self._convert_metadata_to_dms(info_metadata)
|
|
60
60
|
|
|
61
|
-
properties_by_class: dict[
|
|
61
|
+
properties_by_class: dict[ClassEntity, list[DMSProperty]] = defaultdict(list)
|
|
62
|
+
referenced_containers: dict[ContainerEntity, Counter[ClassEntity]] = defaultdict(Counter)
|
|
62
63
|
for prop in self.rules.properties:
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
64
|
+
dms_property = self._as_dms_property(prop, default_space, default_version)
|
|
65
|
+
properties_by_class[prop.class_].append(dms_property)
|
|
66
|
+
if dms_property.container:
|
|
67
|
+
referenced_containers[dms_property.container][prop.class_] += 1
|
|
66
68
|
|
|
67
69
|
views: list[DMSView] = [
|
|
68
70
|
DMSView(
|
|
@@ -76,41 +78,37 @@ class _InformationRulesConverter:
|
|
|
76
78
|
for cls_ in self.rules.classes
|
|
77
79
|
]
|
|
78
80
|
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
properties: list[DMSProperty] = properties_by_class.get(class_.class_.versioned_id, [])
|
|
82
|
-
if not properties or all(
|
|
83
|
-
isinstance(prop.value_type, ViewPropertyEntity) and prop.connection != "direct" for prop in properties
|
|
84
|
-
):
|
|
85
|
-
classes_without_properties.add(class_.class_.versioned_id)
|
|
81
|
+
last_dms_rules = self.rules.last.as_dms_architect_rules() if self.rules.last else None
|
|
82
|
+
ref_dms_rules = self.rules.reference.as_dms_architect_rules() if self.rules.reference else None
|
|
86
83
|
|
|
87
84
|
containers: list[DMSContainer] = []
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
85
|
+
class_by_entity = {cls_.class_: cls_ for cls_ in self.rules.classes}
|
|
86
|
+
if self.rules.last:
|
|
87
|
+
for cls_ in self.rules.last.classes:
|
|
88
|
+
if cls_.class_ not in class_by_entity:
|
|
89
|
+
class_by_entity[cls_.class_] = cls_
|
|
90
|
+
|
|
91
|
+
existing_containers: set[ContainerEntity] = set()
|
|
92
|
+
for rule_set in [last_dms_rules, ref_dms_rules]:
|
|
93
|
+
if rule_set:
|
|
94
|
+
existing_containers.update({c.container for c in rule_set.containers or []})
|
|
95
|
+
|
|
96
|
+
for container_entity, class_entities in referenced_containers.items():
|
|
97
|
+
if container_entity in existing_containers:
|
|
99
98
|
continue
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
or None,
|
|
112
|
-
)
|
|
99
|
+
constrains = self._create_container_constraint(
|
|
100
|
+
class_entities, default_space, class_by_entity, referenced_containers
|
|
101
|
+
)
|
|
102
|
+
most_used_class_entity = class_entities.most_common(1)[0][0]
|
|
103
|
+
class_ = class_by_entity[most_used_class_entity]
|
|
104
|
+
container = DMSContainer(
|
|
105
|
+
class_=class_.class_,
|
|
106
|
+
container=container_entity,
|
|
107
|
+
name=class_.name,
|
|
108
|
+
description=class_.description,
|
|
109
|
+
constraint=constrains or None,
|
|
113
110
|
)
|
|
111
|
+
containers.append(container)
|
|
114
112
|
|
|
115
113
|
return DMSRules(
|
|
116
114
|
metadata=metadata,
|
|
@@ -119,10 +117,26 @@ class _InformationRulesConverter:
|
|
|
119
117
|
),
|
|
120
118
|
views=SheetList[DMSView](data=views),
|
|
121
119
|
containers=SheetList[DMSContainer](data=containers),
|
|
122
|
-
last=
|
|
123
|
-
reference=
|
|
120
|
+
last=last_dms_rules,
|
|
121
|
+
reference=ref_dms_rules,
|
|
124
122
|
)
|
|
125
123
|
|
|
124
|
+
@staticmethod
|
|
125
|
+
def _create_container_constraint(
|
|
126
|
+
class_entities: Counter[ClassEntity],
|
|
127
|
+
default_space: str,
|
|
128
|
+
class_by_entity: dict[ClassEntity, InformationClass],
|
|
129
|
+
referenced_containers: Collection[ContainerEntity],
|
|
130
|
+
) -> list[ContainerEntity]:
|
|
131
|
+
constrains: list[ContainerEntity] = []
|
|
132
|
+
for entity in class_entities:
|
|
133
|
+
class_ = class_by_entity[entity]
|
|
134
|
+
for parent in class_.parent or []:
|
|
135
|
+
parent_entity = parent.as_container_entity(default_space)
|
|
136
|
+
if parent_entity in referenced_containers:
|
|
137
|
+
constrains.append(parent_entity)
|
|
138
|
+
return constrains
|
|
139
|
+
|
|
126
140
|
@classmethod
|
|
127
141
|
def _convert_metadata_to_dms(cls, metadata: InformationMetadata) -> "DMSMetadata":
|
|
128
142
|
from cognite.neat.rules.models.dms._rules import (
|
|
@@ -211,25 +225,35 @@ class _InformationRulesConverter:
|
|
|
211
225
|
elif (self.is_addition or self.is_reshape) and prop.class_ in self.last_classes:
|
|
212
226
|
# We need to create a new container for the property, as we cannot change
|
|
213
227
|
# the existing container in the last schema
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
self._created_classes_from[class_entity] = prop.class_
|
|
218
|
-
return class_entity.as_container_entity(default_space), prop.property_
|
|
228
|
+
container_entity = prop.class_.as_container_entity(default_space)
|
|
229
|
+
container_entity.suffix = self._bump_suffix(container_entity.suffix)
|
|
230
|
+
return container_entity, prop.property_
|
|
219
231
|
else:
|
|
220
232
|
return prop.class_.as_container_entity(default_space), prop.property_
|
|
221
233
|
|
|
222
|
-
|
|
223
|
-
def _get_view_implements(cls, cls_: InformationClass, metadata: InformationMetadata) -> list[ViewEntity]:
|
|
234
|
+
def _get_view_implements(self, cls_: InformationClass, metadata: InformationMetadata) -> list[ViewEntity]:
|
|
224
235
|
if isinstance(cls_.reference, ReferenceEntity) and cls_.reference.prefix != metadata.prefix:
|
|
225
236
|
# We use the reference for implements if it is in a different namespace
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
237
|
+
if self.rules.reference and cls_.reference.prefix == self.rules.reference.metadata.prefix:
|
|
238
|
+
implements = [
|
|
239
|
+
cls_.reference.as_view_entity(
|
|
240
|
+
self.rules.reference.metadata.prefix, self.rules.reference.metadata.version
|
|
241
|
+
)
|
|
242
|
+
]
|
|
243
|
+
else:
|
|
244
|
+
implements = [
|
|
245
|
+
cls_.reference.as_view_entity(metadata.prefix, metadata.version),
|
|
246
|
+
]
|
|
229
247
|
else:
|
|
230
248
|
implements = []
|
|
231
|
-
|
|
232
|
-
|
|
249
|
+
for parent in cls_.parent or []:
|
|
250
|
+
if self.rules.reference and parent.prefix == self.rules.reference.metadata.prefix:
|
|
251
|
+
view_entity = parent.as_view_entity(
|
|
252
|
+
self.rules.reference.metadata.prefix, self.rules.reference.metadata.version
|
|
253
|
+
)
|
|
254
|
+
else:
|
|
255
|
+
view_entity = parent.as_view_entity(metadata.prefix, metadata.version)
|
|
256
|
+
implements.append(view_entity)
|
|
233
257
|
return implements
|
|
234
258
|
|
|
235
259
|
@staticmethod
|
|
@@ -281,7 +281,6 @@ class RulesToExcel(Step):
|
|
|
281
281
|
value="",
|
|
282
282
|
label="If you chose Dump Format 'reference', the provided ID will be use in the new medata sheet. "
|
|
283
283
|
"Expected format 'sp_space:my_external_id'.",
|
|
284
|
-
options=list(exporters.ExcelExporter.dump_options),
|
|
285
284
|
),
|
|
286
285
|
Configurable(
|
|
287
286
|
name="File path",
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
__version__ = "0.77.6"
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/app/api/context_manager/__init__.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
|
{cognite_neat-0.77.6 → cognite_neat-0.77.8}/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.77.6 → cognite_neat-0.77.8}/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.77.6 → cognite_neat-0.77.8}/cognite/neat/app/ui/neat-app/build/img/sme-icon.svg
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{cognite_neat-0.77.6 → cognite_neat-0.77.8}/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.77.6 → cognite_neat-0.77.8}/cognite/neat/graph/examples/Knowledge-Graph-Nordic44.xml
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/graph/extractors/_mock_graph_generator.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
|
|
File without changes
|
|
File without changes
|
{cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/extractors/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/loaders/_asset_loader.py
RENAMED
|
File without changes
|
|
File without changes
|
{cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/loaders/_exceptions.py
RENAMED
|
File without changes
|
{cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/loaders/core/__init__.py
RENAMED
|
File without changes
|
{cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/loaders/core/labels.py
RENAMED
|
File without changes
|
{cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/loaders/core/models.py
RENAMED
|
File without changes
|
{cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/loaders/core/rdf_to_assets.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/stores/_graphdb_store.py
RENAMED
|
File without changes
|
{cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/stores/_memory_store.py
RENAMED
|
File without changes
|
{cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/stores/_oxigraph_store.py
RENAMED
|
File without changes
|
|
File without changes
|
{cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/stores/_rdf_to_graph.py
RENAMED
|
File without changes
|
{cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/transformations/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/graph/transformations/transformer.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
|
{cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/examples/power-grid-model.yaml
RENAMED
|
File without changes
|
{cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/examples/rules-template.xlsx
RENAMED
|
File without changes
|
|
File without changes
|
{cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/examples/skos-rules.xlsx
RENAMED
|
File without changes
|
|
File without changes
|
{cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/examples/wind-energy.owl
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{cognite_neat-0.77.6 → cognite_neat-0.77.8}/cognite/neat/legacy/rules/exporters/_core/__init__.py
RENAMED
|
File without changes
|