From 3447b68d60c7bad6df05dc91aac8de65518474e7 Mon Sep 17 00:00:00 2001 From: Wannaphong Phatthiyaphaibun Date: Thu, 16 May 2024 14:11:01 +0700 Subject: [PATCH] Update pythainlp_get_started.ipynb --- source/notebooks/pythainlp_get_started.ipynb | 22 +++++++++++--------- 1 file changed, 12 insertions(+), 10 deletions(-) diff --git a/source/notebooks/pythainlp_get_started.ipynb b/source/notebooks/pythainlp_get_started.ipynb index 694b4fc..167d6e2 100644 --- a/source/notebooks/pythainlp_get_started.ipynb +++ b/source/notebooks/pythainlp_get_started.ipynb @@ -2231,7 +2231,7 @@ }, { "cell_type": "code", - "execution_count": 66, + "execution_count": 1, "metadata": { "colab": { "base_uri": "https://localhost:8080/", @@ -2251,13 +2251,10 @@ " (' ', 'PUNCT', 'O'),\n", " ('2563', 'NUM', 'O'),\n", " (' ', 'PUNCT', 'O'),\n", - " ('ทดสอบ', 'VERB', 'O'),\n", - " ('ระบบ', 'NOUN', 'O'),\n", + " ('ทดสอบระบบ', 'PART', 'O'),\n", " ('เวลา', 'NOUN', 'O'),\n", " (' ', 'PUNCT', 'O'),\n", - " ('6', 'NUM', 'B-TIME'),\n", - " (':', 'PUNCT', 'I-TIME'),\n", - " ('00', 'NUM', 'I-TIME'),\n", + " ('6:00', 'NUM', 'B-TIME'),\n", " (' ', 'PUNCT', 'I-TIME'),\n", " ('น.', 'NOUN', 'I-TIME'),\n", " (' ', 'PUNCT', 'O'),\n", @@ -2281,14 +2278,14 @@ " ('บาท', 'NOUN', 'I-MONEY')]" ] }, - "execution_count": 66, + "execution_count": 1, "metadata": {}, "output_type": "execute_result" } ], "source": [ "#!pip3 install pythainlp[ner]\n", - "from pythainlp.tag.named_entity import ThaiNameTagger\n", + "from pythainlp.tag.thainer import ThaiNameTagger\n", "\n", "ner = ThaiNameTagger()\n", "ner.get_ner(\"24 มิ.ย. 2563 ทดสอบระบบเวลา 6:00 น. เดินทางจากขนส่งกรุงเทพใกล้ถนนกำแพงเพชร ไปจังหวัดกำแพงเพชร ตั๋วราคา 297 บาท\")" @@ -2453,7 +2450,7 @@ "version": "0.3.2" }, "kernelspec": { - "display_name": "Python 3", + "display_name": "Python 3.8.13 ('base')", "language": "python", "name": "python3" }, @@ -2467,7 +2464,12 @@ "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", - "version": "3.8.5" + "version": "3.8.13" + }, + "vscode": { + "interpreter": { + "hash": "a1d6ff38954a1cdba4cf61ffa51e42f4658fc35985cd256cd89123cae8466a39" + } } }, "nbformat": 4,