{"id":20663962,"url":"https://github.com/universaldatatool/react-nlp-annotate","last_synced_at":"2025-04-19T16:07:43.508Z","repository":{"id":40890411,"uuid":"191096784","full_name":"UniversalDataTool/react-nlp-annotate","owner":"UniversalDataTool","description":"Interface for making NLP annotations.","archived":false,"fork":false,"pushed_at":"2023-04-14T19:16:23.000Z","size":12348,"stargazers_count":46,"open_issues_count":10,"forks_count":19,"subscribers_count":5,"default_branch":"master","last_synced_at":"2024-10-29T18:54:26.341Z","etag":null,"topics":["classification","entity","entity-relation-labeling","hacktoberfest","nlp","nlp-library","nlp-machine-learning","text","text-classification","text-entities","text-entity-analysis","text-mining"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/UniversalDataTool.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2019-06-10T04:31:17.000Z","updated_at":"2024-09-03T08:20:24.000Z","dependencies_parsed_at":"2022-07-16T01:16:24.436Z","dependency_job_id":null,"html_url":"https://github.com/UniversalDataTool/react-nlp-annotate","commit_stats":{"total_commits":96,"total_committers":5,"mean_commits":19.2,"dds":0.21875,"last_synced_commit":"5e8ce64f8fed290df8882e1c0e5cdd5388915752"},"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/UniversalDataTool%2Freact-nlp-annotate","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/UniversalDataTool%2Freact-nlp-annotate/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/UniversalDataTool%2Freact-nlp-annotate/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/UniversalDataTool%2Freact-nlp-annotate/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/UniversalDataTool","download_url":"https://codeload.github.com/UniversalDataTool/react-nlp-annotate/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":224959473,"owners_count":17398713,"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":["classification","entity","entity-relation-labeling","hacktoberfest","nlp","nlp-library","nlp-machine-learning","text","text-classification","text-entities","text-entity-analysis","text-mining"],"created_at":"2024-11-16T19:21:20.235Z","updated_at":"2024-11-16T19:21:21.061Z","avatar_url":"https://github.com/UniversalDataTool.png","language":"JavaScript","readme":"# React NLP Annotate\n  \n\u003e If you just want to edit NLP data, it's easier to just use the [Universal Data Tool (MIT)](https://github.com/UniversalDataTool/universal-data-tool). This library is a module of the Universal Data Tool for use in custom react applications.\n\nInterface for doing various NLP tasks. [Here's a code playground](https://codesandbox.io/s/react-nlp-annotate-example-0jwms?file=/src/App.js). Please help this repository by adding documentation and issues!\n\n- Audio transcription\n- Text Labeling (Entity, Classification)\n- Entity Relation Labeling\n\n![screenshot 1](https://user-images.githubusercontent.com/1910070/91113515-c5987b00-e653-11ea-92b8-08fa60cf7619.png)\n\n![screenshot 2](https://user-images.githubusercontent.com/1910070/76181462-8d7da880-6197-11ea-908f-96d988a7efc8.png)\n\n![screenshot 3](https://user-images.githubusercontent.com/1910070/76181412-560efc00-6197-11ea-8eba-1f48768f5183.png)\n\n## Installation\n\n`npm install react-nlp-annotate`\n\n## Usage\n\n### Document Classification\n\n```javascript\nimport NLPAnnotator from \"react-nlp-annotate\"\n\nconst MyComponent = () =\u003e (\n  \u003cNLPAnnotator\n    type=\"label-document\"\n    labels={[\n      {\n        \"id\": \"gryffindor\",\n        \"displayName\": \"Gryffindor\",\n        \"description\": \"Daring, strong nerve and chivalry.\"\n      },\n      {\n        \"id\": \"slytherin\",\n        \"displayName\": \"Slytherin\",\n        \"description\": \"Cunning and ambitious. Possibly dark wizard.\"\n      }\n    ]}\n    multipleLabels={false}\n    document=\"Harry\"\n    onChange={(classification) =\u003e {\n      console.log(\"Harry is a \" + classification)\n    }}\n  /\u003e\n)\n```\n\n### Entity Relation Labeling\n\n```javascript\nimport React from \"react\";\nimport NLPAnnotator from \"react-nlp-annotate\";\n\nconst labels = [\n  {\n    id: \"gryffindor\",\n    displayName: \"Gryffindor\",\n    description: \"Daring, strong nerve and chivalry.\"\n  },\n  {\n    id: \"slytherin\",\n    displayName: \"Slytherin\",\n    description: \"Cunning and ambitious. Possibly dark wizard.\"\n  }\n];\n\nexport default () =\u003e (\n    \u003cNLPAnnotator\n      hotkeysEnabled\n      type=\"label-relationships\"\n      labels={labels}\n      multipleLabels={false}\n      document=\"Harry was an honest to god good man\"\n      onChange={(output) =\u003e {\n        console.log(\"Output is...\", output);\n      }}\n      // this is just for label-relationships\n      entityLabels={labels}\n      relationshipLabels={labels}\n    /\u003e\n  \u003c/div\u003e\n);\n```\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Funiversaldatatool%2Freact-nlp-annotate","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Funiversaldatatool%2Freact-nlp-annotate","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Funiversaldatatool%2Freact-nlp-annotate/lists"}