{"id":28412560,"url":"https://github.com/plantfce/text-to-pid","last_synced_at":"2026-05-01T03:37:18.959Z","repository":{"id":295814908,"uuid":"991324944","full_name":"PlantFCE/text-to-pid","owner":"PlantFCE","description":"Text to P\u0026ID: Going from process description to P\u0026ID.","archived":false,"fork":false,"pushed_at":"2025-05-27T13:08:25.000Z","size":7,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-06-09T18:51:51.573Z","etag":null,"topics":["dexpi","digital-transformation","digitisation","digitization","digitization-workflows","neo4j","neo4j-graph","pid","plantfce","python","python3"],"latest_commit_sha":null,"homepage":"https://plantfce.github.io/text-to-pid/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/PlantFCE.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-05-27T13:06:18.000Z","updated_at":"2025-05-27T13:28:26.000Z","dependencies_parsed_at":"2025-05-27T14:25:01.626Z","dependency_job_id":"c4b65c67-386e-44ac-9bb8-6a3331b2ca4f","html_url":"https://github.com/PlantFCE/text-to-pid","commit_stats":null,"previous_names":["plantfce/text-to-pid"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/PlantFCE/text-to-pid","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PlantFCE%2Ftext-to-pid","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PlantFCE%2Ftext-to-pid/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PlantFCE%2Ftext-to-pid/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PlantFCE%2Ftext-to-pid/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/PlantFCE","download_url":"https://codeload.github.com/PlantFCE/text-to-pid/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PlantFCE%2Ftext-to-pid/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":261685450,"owners_count":23194107,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["dexpi","digital-transformation","digitisation","digitization","digitization-workflows","neo4j","neo4j-graph","pid","plantfce","python","python3"],"created_at":"2025-06-02T23:01:05.540Z","updated_at":"2026-05-01T03:37:18.919Z","avatar_url":"https://github.com/PlantFCE.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# \u003ccenter\u003eText to P\u0026ID\u003c/center\u003e\n\nText to P\u0026ID aims to convert a process description to P\u0026ID.\n\n## Overview\nThe process is as follows:\n- Extract equipment/instruments from process description using Natural Language Processing, and understand the relations between them.\n- Store the above as a graph in a DBMS like [Neo4j](http://neo4j.com/).\n- Evaluate different implementations, enumerating the position of equipment, to find the best implementation.\n- Create a [DEXPI](https://dexpi.org/) XML file.\n- Validate a P\u0026ID against a set of rules by running Cypher queries against the Neo4j database.\n\n## Extracting Equipment/Instruments\n\nWe can extract equipment/instruments from the process description using a Natural Language Processing library. This allows us to detect equipment in the process description and understand the interrelations.\n\n## Storing Information as a Graph\nWe use [Neo4j](http://neo4j.com/) as a graph database to store the relational information.\n\nWe can connect to Neo4j using the `py2neo` Python library.\n\nTo install `py2neo`, run:\n```sh\npip install py2neo\n```\n\nThis repo contains an initialization script [(`src/initialize-neo4j.py`)](src/initialize-neo4j.py) which connects to a local instance of Neo4j and adds equipment; instruments; relations between them (`FLOWS_TO` and `MEASURES`).\n\nNeo4j connection configuration can be changed in `src/config.py`.\n\n## Evaluate Different Implementations and Choose Best One\nThis will involve enumerating through different position values such that the generated P\u0026ID complies with the required standards, and is as efficient as possible.\n\n## Create a DEXPI File\n[DEXPI (Data Exchange in the Process Industry)](https://dexpi.org/) is an open standard for data exchange, based on XML, allowing for interoperability between vendors.\n\nBased on the data obtained in the previous steps, we can use the `xml` Python library to create an XML file, in accordance with the DEXPI standard.\n\n## Rule-Based Validation of P\u0026IDs\nWe can define rules using a Cypher statement and query the Neo4j database to ensure that the P\u0026ID is compliant.\n\nAn example of this can be seen in [`src/rule-based-validation.py`](src/rule-based-validation.py).\n\n## License\nThe content of the README is distributed under the [CC0 1.0 Universal license](https://creativecommons.org/publicdomain/zero/1.0/). The code in Text to P\u0026ID is distributed under the [MIT license](LICENSE).\n\n---\n\nWe at [PlantFCE](https://plantfce.com/) are creating a pipeline that enables us to go from process description to P\u0026ID.\n\n\u003e Annotate and digitize your P\u0026IDs with PlantFCE eAI. [Learn more →](https://tryeai.com/)","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fplantfce%2Ftext-to-pid","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fplantfce%2Ftext-to-pid","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fplantfce%2Ftext-to-pid/lists"}