{"id":43510334,"url":"https://github.com/cefriel/procedural-kg-llm","last_synced_at":"2026-02-03T12:50:26.884Z","repository":{"id":224889017,"uuid":"764502176","full_name":"cefriel/procedural-kg-llm","owner":"cefriel","description":"Prompt-based pipeline for extracting procedural knowledge graphs from text with LLMs","archived":false,"fork":false,"pushed_at":"2025-07-03T09:54:56.000Z","size":222,"stargazers_count":13,"open_issues_count":0,"forks_count":1,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-09-09T23:48:02.618Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Jupyter Notebook","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/cefriel.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,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2024-02-28T07:35:11.000Z","updated_at":"2025-09-09T13:54:52.000Z","dependencies_parsed_at":"2024-06-21T01:26:04.344Z","dependency_job_id":"22a1460f-c223-415d-a572-e355bb950c79","html_url":"https://github.com/cefriel/procedural-kg-llm","commit_stats":null,"previous_names":["cefriel/procedural-kg-llm"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/cefriel/procedural-kg-llm","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cefriel%2Fprocedural-kg-llm","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cefriel%2Fprocedural-kg-llm/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cefriel%2Fprocedural-kg-llm/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cefriel%2Fprocedural-kg-llm/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cefriel","download_url":"https://codeload.github.com/cefriel/procedural-kg-llm/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cefriel%2Fprocedural-kg-llm/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29046488,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-03T10:09:22.136Z","status":"ssl_error","status_checked_at":"2026-02-03T10:09:16.814Z","response_time":96,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":[],"created_at":"2026-02-03T12:50:25.949Z","updated_at":"2026-02-03T12:50:26.868Z","avatar_url":"https://github.com/cefriel.png","language":"Jupyter Notebook","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Procedural Knowledge Graph extraction  from Text with Large Language Models\nWe propose a **prompt-based pipeline** for extracting **procedural knowledge graphs** from text with LLMs.\n\nThis pipeline extracts **steps**, **actions**, **objects**, **equipment** and **temporal information** from a textual procedure, in order to populate a **Procedural KG** according to a **pre-defined ontology**.\n\n\u003cimg width=\"449\" alt=\"image\" src=\"https://github.com/user-attachments/assets/9e5ffc9b-b692-4a95-92a2-7de21682b838\"\u003e\n\n\n## Experimental setting\nFor our experiments, we:\n- used the [GPT 4o model](https://platform.openai.com/docs/models/gpt-4o)\n- set the temperature parameter to 0\n- rely on the [LangChain framework](https://www.langchain.com/)\n\nProcedures used in the prompt engineering refinement process, and in the evaluation, are selected from [WikiHow](https://wikihow.com/)\n\nWe reuse [this JSON dataset available on GitHub](https://github.com/zharry29/wikihow-goal-step)\n\n## How to navigate this repository\n### pkg-extraction / notebooks\nThis folder contains:\n- **pkg-extraction.ipynb**, the notebook with the pipeline of 2 prompts\n- a subfolder **preliminary-experiments** containing the notebooks with our preliminary experiments\n\nThe repository defines a `docker-compose.yml` file to run the Jupyter notebooks as containers via Docker. \nThe containers can be run all at once or separately.\n\nThe notebooks can be executed running the container, from the folder with the .yml file, with the command:\n```\ndocker-compose up --force-recreate\n```\n\nA `credentials.json` file should be provided in the main folder with a valid key for the OpenAI API.\n\n```\n{\n    \"OPENAI_API_KEY\": \"PUT_HERE_YOUR_KEY\"\n}\n```\n\n### data-results\n- **ontology**: this folder contains the procedural ontology used as reference in the experiments\n- **clean-flat-panel-monitor**, **fix-rubbing-door**, **cook-honey-glazed-parsnips**, **plant-bare-root-tree**: these folders contain input and output data for the 4 procedures\n- **preliminary-experiments**: this folder contains the results of previous experiments during the prompt engineering refinement process\n\n### human-assessment\nThis folder contains:\n- materials and results from the human assessment of the LLM results\n- a subfolder **preliminary-experiments** containing the materials and results from the human assessment of our preliminary experiments\n\n### Contributing\n\nBefore contributing, please read carefully, complete and sign our [Contributor Licence Agreement](https://github.com/cefriel/contributing/blob/main/contributor-license-agreement.pdf). \n\nWhen contributing to this repository, please first discuss the change you wish to make via issue or any other available method with the repository's owners.\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcefriel%2Fprocedural-kg-llm","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcefriel%2Fprocedural-kg-llm","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcefriel%2Fprocedural-kg-llm/lists"}