
{"id":7016,"date":"2019-03-31T19:06:27","date_gmt":"2019-03-31T10:06:27","guid":{"rendered":"https:\/\/tetraup.com\/news_topics\/archives\/7016"},"modified":"2025-02-26T20:05:16","modified_gmt":"2025-02-26T11:05:16","slug":"basic-nlp-sentiment-analysis","status":"publish","type":"post","link":"https:\/\/tetraup.com\/news_topics\/column\/basic-nlp-sentiment-analysis\/","title":{"rendered":"\u3010\u8d85\u5165\u9580\u3011\u81ea\u7136\u8a00\u8a9e\u51e6\u7406\u3067\u30cd\u30ac\u30dd\u30b8\u5224\u5b9a\u3057\u3066\u307f\u3088\u3046!"},"content":{"rendered":"\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"768\" src=\"https:\/\/tetraup.com\/news_topics\/wp-content\/uploads\/2019\/03\/IMG_6281-1024x768-1.jpg\" alt=\"\" class=\"wp-image-8946\"\/><\/figure>\n\n\n\n<p><strong>\u300c\u81ea\u7136\u8a00\u8a9e\u51e6\u7406\u300d<\/strong>\u3068\u3044\u3046\u8a00\u8449\u3092\u805e\u3044\u3066\u3001\u7686\u3055\u3093\u306f\u3069\u306e\u3088\u3046\u306a\u30a4\u30e1\u30fc\u30b8\u3092\u6301\u305f\u308c\u308b\u3067\u3057\u3087\u3046\u304b\uff1f\u6a5f\u68b0\u5b66\u7fd2\u3092\u5b66\u3093\u3060\u3053\u3068\u304c\u306a\u3044\u5834\u5408\u3001\u300c\u805e\u3044\u305f\u3053\u3068\u306f\u3042\u308b\u304c\u3069\u306e\u3088\u3046\u306a\u3082\u306e\u306a\u306e\u304b\u306f\u308f\u304b\u3063\u3066\u3044\u306a\u3044\u300d\u3001\u300c\u306a\u3093\u3068\u306a\u304f\u96e3\u3057\u305d\u3046\u300d\u7b49\u306e\u30a4\u30e1\u30fc\u30b8\u3092\u6301\u305f\u308c\u308b\u65b9\u304c\u591a\u3044\u306e\u3067\u306f\u306a\u3044\u304b\u3068\u601d\u3044\u307e\u3059\u3002\u4eca\u56de\u306f<strong>\u81ea\u7136\u8a00\u8a9e\u51e6\u7406\u304c\u5b9f\u969b\u306b\u3069\u306e\u3088\u3046\u306b\u4f7f\u308f\u308c\u3066\u3044\u308b\u304b<\/strong>\u3068\u3044\u3046\u3068\u3053\u308d\u304b\u3089\u3001<strong>\u81ea\u7136\u8a00\u8a9e\u51e6\u7406\u3092\u7528\u3044\u3066\u30c6\u30ad\u30b9\u30c8\u306e\u30cd\u30ac\u30c6\u30a3\u30d6\u30fb\u30dd\u30b8\u30c6\u30a3\u30d6\u5ea6\u3092\u6570\u5024\u5316\u3059\u308b<\/strong>\u3068\u3053\u308d\u307e\u3067\u3092\u307e\u3068\u3081\u3066\u3044\u304d\u305f\u3044\u3068\u601d\u3044\u307e\u3059\u3002\u30b3\u30fc\u30c9\u306fpython\u3067\u66f8\u3044\u3066\u3044\u304d\u307e\u3059\u3002<\/p>\n\n\n\n<p><a href=\"https:\/\/tetraup.com\/education\/contact\" title=\"\">>>WEB\u88fd\u4f5c\u30fb\u30b7\u30b9\u30c6\u30e0\u958b\u767a\u306e\u304a\u554f\u3044\u5408\u308f\u305b\u306f\u30b3\u30c1\u30e9<\/a><\/p>\n\n\n\n<br><div class=\"wp-block-button\"><a class=\"wp-block-button__link has-very-dark-gray-color has-light-green-cyan-background-color has-text-color has-background wp-element-button\" href=\"https:\/\/tetraup.com\/education\/trial-form\" style=\"border-radius:3px\" target=\"_blank\" rel=\"noreferrer noopener\">\u7121\u6599\u4f53\u9a13\u6388\u696d\u306e\u304a\u7533\u8fbc\u307f\u306f\u30b3\u30c1\u30e9<\/a><\/div><br>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"sec1\">\u81ea\u7136\u8a00\u8a9e\u51e6\u7406\u3092\u306a\u3093\u3068\u306a\u304f\u7406\u89e3\u3057\u3088\u3046<\/h2>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"sec1-1\">\u305d\u3082\u305d\u3082\u81ea\u7136\u8a00\u8a9e\u51e6\u7406\u3068\u306f\uff1f<\/h3>\n\n\n\n<p>\u305d\u3082\u305d\u3082\u81ea\u7136\u8a00\u8a9e\u51e6\u7406\u3068\u306f\u3069\u306e\u3088\u3046\u306a\u3082\u306e\u306a\u306e\u3067\u3057\u3087\u3046\u304b\u3002<\/p>\n\n\n\n<p>Wikipedia\u306b\u306f<\/p>\n\n\n\n<p><strong>\u300c\u81ea\u7136\u8a00\u8a9e\u51e6\u7406\uff08\u3057\u305c\u3093\u3052\u3093\u3054\u3057\u3087\u308a\u3001\u82f1\u8a9e: natural language processing\u3001\u7565\u79f0\uff1aNLP\uff09\u306f\u3001\u4eba\u9593\u304c\u65e5\u5e38\u7684\u306b\u4f7f\u3063\u3066\u3044\u308b\u81ea\u7136\u8a00\u8a9e\u3092\u30b3\u30f3\u30d4\u30e5\u30fc\u30bf\u306b\u51e6\u7406\u3055\u305b\u308b\u4e00\u9023\u306e\u6280\u8853\u3067\u3042\u308a\u3001\u4eba\u5de5\u77e5\u80fd\u3068\u8a00\u8a9e\u5b66\u306e\u4e00\u5206\u91ce\u3067\u3042\u308b\u3002\u300d<\/strong><\/p>\n\n\n\n<p>\u3068\u3042\u308a\u307e\u3059\u3002\u3057\u304b\u3057\u3001\u300c\u81ea\u7136\u8a00\u8a9e\u3092\u30b3\u30f3\u30d4\u30e5\u30fc\u30bf\u306b\u51e6\u7406\u3055\u305b\u308b\u300d\u3068\u8a00\u308f\u308c\u3066\u3082\u306a\u304b\u306a\u304b\u30d4\u30f3\u3068\u3053\u306a\u3044\u3068\u601d\u3044\u307e\u3059\u3002\u3053\u3053\u3067\u8a00\u308f\u308c\u3066\u3044\u308b\u51e6\u7406\u3068\u3044\u3046\u306e\u306f\u3001<strong class=\"marker\">\u30c6\u30ad\u30b9\u30c8\u30c7\u30fc\u30bf\u3092\u5358\u8a9e\u5358\u4f4d\u306b\u5206\u5272\u3057\u305f\u308a\u3001\u5927\u91cf\u306e\u30c6\u30ad\u30b9\u30c8\u30c7\u30fc\u30bf\u3092\u5b66\u7fd2\u3057\u3066\u5358\u8a9e\u540c\u58eb\u306e\u95a2\u4fc2\u3092\u63a8\u6e2c\u3057\u305f\u308a\u3059\u308b\u3053\u3068\u3067\u3059\u3002<\/strong>\u4eca\u56de\u884c\u3063\u3066\u3044\u304f\u30cd\u30ac\u30dd\u30b8\u5224\u5b9a\u3067\u306f\u3001\u30cd\u30ac\u30c6\u30a3\u30d6\u306a\u30ef\u30fc\u30c9\u3068\u30dd\u30b8\u30c6\u30a3\u30d6\u306a\u30ef\u30fc\u30c9\u306e\u8f9e\u66f8\u3092\u4f5c\u308a\u3001\u5224\u5b9a\u3059\u308b\u30c7\u30fc\u30bf\u304c\u3069\u308c\u3060\u3051\u8f9e\u66f8\u306b\u3042\u308b\u5358\u8a9e\u3092\u542b\u3093\u3067\u3044\u308b\u304b\u3092\u8abf\u3079\u3066\u70b9\u6570\u3092\u3064\u3051\u3066\u3044\u304d\u307e\u3059\u3002\u3053\u306e\u3088\u3046\u306a\u51e6\u7406\u3092\u30b3\u30f3\u30d4\u30e5\u30fc\u30bf\u306b\u547d\u4ee4\u3057\u3066\u51e6\u7406\u3055\u305b\u308b\u306e\u304c\u81ea\u7136\u8a00\u8a9e\u51e6\u7406\u3067\u3059\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"sec1-2\">\u3053\u3093\u306a\u3068\u3053\u308d\u3067\u4f7f\u308f\u308c\u3066\u3044\u308b\uff01<\/h3>\n\n\n\n<p>\u4ee3\u8868\u7684\u306a\u3082\u306e\u306bGoogle\u7ffb\u8a33\u306a\u3069\u306e\u81ea\u52d5\u7ffb\u8a33\u3084\u3001\u30a2\u30ec\u30af\u30b5\u3001GoogleHome\u7b49\u306e\u30b9\u30de\u30fc\u30c8\u30b9\u30d4\u30fc\u30ab\u30fc\u3001Twitter\u3084LINE\u306e\u30c1\u30e3\u30c3\u30c8\u30dc\u30c3\u30c8\u306a\u3069\u304c\u6319\u3052\u3089\u308c\u307e\u3059\u3002\u8eab\u8fd1\u306a\u696d\u52d9\u3078\u306e\u5fdc\u7528\u3068\u3057\u3066\u306f\u3001\u304a\u5ba2\u69d8\u304b\u3089\u306e\u554f\u3044\u5408\u308f\u305b\u306e\u5bfe\u5fdc\u3092\u81ea\u52d5\u5316\u3057\u305f\u308a\u3001\u53d7\u4fe1\u3057\u305f\u30e1\u30fc\u30eb\u3092\u30ab\u30c6\u30b4\u30ea\u3084\u76ee\u7684\u5225\u306b\u81ea\u52d5\u3067\u632f\u308a\u5206\u3051\u305f\u308a\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n\n\n\n<p><a href=\"https:\/\/tetraup.com\/education\/contact\" title=\"\">>>WEB\u88fd\u4f5c\u30fb\u30b7\u30b9\u30c6\u30e0\u958b\u767a\u306e\u304a\u554f\u3044\u5408\u308f\u305b\u306f\u30b3\u30c1\u30e9<\/a><\/p>\n\n\n\n<br><div class=\"wp-block-button\"><a class=\"wp-block-button__link has-very-dark-gray-color has-light-green-cyan-background-color has-text-color has-background wp-element-button\" href=\"https:\/\/tetraup.com\/education\/trial-form\" style=\"border-radius:3px\" target=\"_blank\" rel=\"noreferrer noopener\">\u7121\u6599\u4f53\u9a13\u6388\u696d\u306e\u304a\u7533\u8fbc\u307f\u306f\u30b3\u30c1\u30e9<\/a><\/div><br>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"sec2\">\u6a5f\u68b0\u5b66\u7fd2\u3092\u4f7f\u308f\u306a\u3044\u30cd\u30ac\u30dd\u30b8\u5224\u5b9a\u3067\u81ea\u7136\u8a00\u8a9e\u51e6\u7406\u5165\u9580\u3059\u308b\uff01<\/h2>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"sec2-1\">\u5de5\u7a0b\u3092\u78ba\u8a8d\u3057\u3088\u3046\uff01<\/h3>\n\n\n\n<p>\u81ea\u7136\u8a00\u8a9e\u51e6\u7406\u304c\u3069\u306e\u3088\u3046\u306a\u3082\u306e\u306a\u306e\u304b\u3001\u3056\u3063\u304f\u308a\u3068\u7406\u89e3\u3067\u304d\u305f\u3068\u3053\u308d\u3067\u65e9\u901f\u81ea\u7136\u8a00\u8a9e\u51e6\u7406\u306b\u5165\u9580\u3057\u3066\u3044\u304d\u307e\u3057\u3087\u3046\u3002\u4eca\u56de\u306f\u30c6\u30ad\u30b9\u30c8\u306e\u30cd\u30ac\u30c6\u30a3\u30d6\u30fb\u30dd\u30b8\u30c6\u30a3\u30d6\u306e\u5224\u5b9a\u3092\u3057\u3066\u3044\u304d\u307e\u3059\u3002\u3053\u308c\u306f\u81ea\u7136\u8a00\u8a9e\u51e6\u7406\u306e\u4e16\u754c\u3067\u306f<strong>\u300c\u611f\u60c5\u5206\u6790\u300d<\/strong>\u3068\u3044\u3046\u5206\u91ce\u306b\u5165\u308a\u307e\u3059\u3002\u4e00\u822c\u7684\u306b\u81ea\u7136\u8a00\u8a9e\u51e6\u7406\u306f\u6a5f\u68b0\u5b66\u7fd2\u3092\u7528\u3044\u3066\u884c\u3044\u307e\u3059\u304c\u3001\u4eca\u56de\u306f\u8d85\u5165\u9580\u7de8\u3068\u3044\u3046\u3053\u3068\u3067\u6a5f\u68b0\u5b66\u7fd2\u306f\u305b\u305a\u306b\u57fa\u672c\u7684\u306a\u51e6\u7406\u306e\u307f\u3067\u884c\u3063\u3066\u3044\u304d\u307e\u3059\u3002<\/p>\n\n\n\n<p>\u3053\u308c\u304b\u3089\u884c\u3046\u5de5\u7a0b\u3092\u307e\u3068\u3081\u308b\u3068\u3001<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>\u2460 \u30cd\u30ac\u30c6\u30a3\u30d6\u3001\u30dd\u30b8\u30c6\u30a3\u30d6\u306a\u30ef\u30fc\u30c9\u306e\u5358\u8a9e\u8f9e\u66f8\u3092\u4f5c\u308b<\/li>\n\n\n\n<li>\u2461 \u8a55\u4fa1\u3059\u308b\u5bfe\u8c61\u306b\u306a\u308b\u30c7\u30fc\u30bf\u3092\u7528\u610f\u3059\u308b<\/li>\n\n\n\n<li>\u2462 \u8a55\u4fa1\u5bfe\u8c61\u306e\u30c7\u30fc\u30bf\u3092\u51e6\u7406\u3057\u3001\u8a55\u4fa1\u3059\u308b<\/li>\n\n\n\n<li><\/li>\n<\/ul>\n\n\n\n<p>\u3068\u3044\u3046\u6d41\u308c\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"sec2-1\">\u5224\u5b9a\u306b\u4f7f\u3046\u8f9e\u66f8\u3092\u4f5c\u308d\u3046!<\/h3>\n\n\n\n<p>\u4eca\u56de\u306f\u6771\u5317\u5927\u5b66 \u4e7e\u30fb\u5ca1\u5d0e\u7814\u7a76\u5ba4\u304c\u516c\u958b\u3057\u3066\u3044\u308b\u300c\u65e5\u672c\u8a9e\u8a55\u4fa1\u6975\u6027\u8f9e\u66f8\uff08\u7528\u8a00\u7de8\uff09\u300d\u3068\u300c\u65e5\u672c\u8a9e\u8a55\u4fa1\u6975\u6027\u8f9e\u66f8\uff08\u540d\u8a5e\u7de8\uff09\u300d\u3092\u4f7f\u3044\u307e\u3059\u3002\u30cd\u30ac\u30c6\u30a3\u30d6\u306a\u30ef\u30fc\u30c9\u306f\u300cn\u300d\u3001\u30dd\u30b8\u30c6\u30a3\u30d6\u306a\u30ef\u30fc\u30c9\u306f\u300cp\u300d\u3001\u30cb\u30e5\u30fc\u30c8\u30e9\u30eb\u306a\u30ef\u30fc\u30c9\u306f\u300ce\u300d\u3067\u8868\u73fe\u3057\u3066\u3044\u304d\u307e\u3059\u3002<\/p>\n\n\n\n<blockquote class=\"wp-block-quote\">\n\n<a href=\"http:\/\/www.cl.ecei.tohoku.ac.jp\/index.php?Open%20Resources%2FJapanese%20Sentiment%20Polarity%20Dictionary\"> \n   <p style=\"color:blue;\">\u300c\u65e5\u672c\u8a9e\u8a55\u4fa1\u6975\u6027\u8f9e\u66f8\uff08\u7528\u8a00\u7de8\uff09\u300d, \u300c\u65e5\u672c\u8a9e\u8a55\u4fa1\u6975\u6027\u8f9e\u66f8\uff08\u540d\u8a5e\u7de8\uff09\u300d<\/p>\n<\/a>\n\n<\/blockquote>\n\n\n\n<p><\/p>\n\n\n\n<p>\u3053\u306e\u8f9e\u66f8\u3092\u5224\u5b9a\u306b\u4f7f\u3046\u305f\u3081\u306b\u6574\u5f62\u3057\u3066\u3044\u304d\u307e\u3059\u3002\u4f8b\u3048\u3070\u540d\u8a5e\u306e\u65b9\u3092\u898b\u308b\u3068\u3001\u5404\u30ef\u30fc\u30c9\u306b\u6d3b\u7528\u5f62\u3084\u8aac\u660e\u304c\u66f8\u304b\u308c\u3066\u3044\u307e\u3059\u3002\u4eca\u56de\u306f\u300c\u60b2\u3057\u3044,n\u300d\u3001\u300c\u697d\u3057\u3044,p\u300d\u306e\u3088\u3046\u306a\u5f62\u306e\u8f9e\u66f8\u3092\u4f5c\u3063\u3066\u3044\u304d\u305f\u3044\u306e\u3067\u3053\u308c\u3089\u306f\u30ab\u30c3\u30c8\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<figure class=\"wp-block-image size-full is-resized\"><img loading=\"lazy\" decoding=\"async\" width=\"538\" height=\"570\" src=\"https:\/\/tetraup.com\/news_topics\/wp-content\/uploads\/2019\/03\/\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8-2019-03-31-19.50.49.png\" alt=\"\" class=\"wp-image-8948\" style=\"width:277px;height:auto\"\/><figcaption class=\"wp-element-caption\">\u6574\u5f62\u524d\u306e\u540d\u8a5e\u306e\u8f9e\u66f8<\/figcaption><\/figure>\n\n\n\n<p>\u7528\u8a00\u306e\u65b9\u306f\u300cn,\u75b2\u308c\u308b\u300d\u306e\u4ed6\u306b\u300cn,\u75b2\u308c,\u304c,\u3042\u308b\u300d\u3068\u3044\u3046\u5185\u5bb9\u3082\u542b\u307e\u308c\u3066\u3057\u307e\u3063\u3066\u3044\u307e\u3059\u3002\u3053\u308c\u306f\u3069\u3046\u51e6\u7406\u3059\u3079\u304d\u304b\u60a9\u307e\u3057\u3044\u3068\u3053\u308d\u3067\u3059\u304c\u3001\u4eca\u56de\u306f\u8a55\u4fa1\u3059\u308b\u30c6\u30ad\u30b9\u30c8\u304c\u3069\u308c\u3060\u3051\u8f9e\u66f8\u306b\u3042\u308b\u5358\u8a9e\u3092\u542b\u3093\u3067\u3044\u308b\u306e\u304b\u3092\u8abf\u3079\u305f\u3044\u306e\u3067\u3001\u52a9\u8a5e\u3084\u52a9\u52d5\u8a5e\u306e\u90e8\u5206\u306f\u30ab\u30c3\u30c8\u3057\u3066\u300cn, \u75b2\u308c\u300d\u3068\u3044\u3046\u3088\u3046\u306b\u6574\u5f62\u3057\u307e\u3059\u3002\u3053\u306e\u3088\u3046\u306b\u6574\u5f62\u3057\u3066\u3044\u304f\u3068\u300cn,\u53ef\u54c0\u76f8,\u3060\u300d\u3068\u300cn,\u53ef\u54c0\u76f8,\u3067\u3059\u300d\u304c\u3069\u3061\u3089\u3082\u300cn, \u53ef\u54c0\u76f8\u300d\u306b\u306a\u3063\u3066\u3057\u307e\u3046\u306e\u3067\u3001\u540d\u8a5e\u306e\u8f9e\u66f8\u3068\u7d50\u5408\u3057\u305f\u5f8c\u306b\u91cd\u8907\u3057\u3066\u3044\u308b\u5358\u8a9e\u3092\u524a\u9664\u3057\u307e\u3059\u3002\u3053\u308c\u3067\u8f9e\u66f8\u306f\u5b8c\u6210\u3067\u3059\uff01<\/p>\n\n\n\n<figure class=\"wp-block-image size-full is-resized\"><img loading=\"lazy\" decoding=\"async\" width=\"538\" height=\"570\" src=\"https:\/\/tetraup.com\/news_topics\/wp-content\/uploads\/2019\/03\/\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8-2019-03-31-20.12.21.png\" alt=\"\" class=\"wp-image-8949\" style=\"width:289px;height:auto\"\/><figcaption class=\"wp-element-caption\">\u6574\u5f62\u524d\u306e\u7528\u8a00\u306e\u8f9e\u66f8<\/figcaption><\/figure>\n\n\n\n<figure class=\"wp-block-image size-full is-resized\"><img loading=\"lazy\" decoding=\"async\" width=\"624\" height=\"656\" src=\"https:\/\/tetraup.com\/news_topics\/wp-content\/uploads\/2019\/03\/\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8-2019-03-31-21.01.40.png\" alt=\"\" class=\"wp-image-8950\" style=\"width:297px;height:auto\"\/><figcaption class=\"wp-element-caption\">\u5b8c\u6210\u3057\u305f\u8f9e\u66f8<\/figcaption><\/figure>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"sec2-2\">\u8a55\u4fa1\u3059\u308b\u30c7\u30fc\u30bf\u3092\u7528\u610f\u3057\u3088\u3046\uff01<\/h3>\n\n\n\n<p>\u6b21\u306b\u8a55\u4fa1\u3059\u308b\u30c7\u30fc\u30bf\u3092\u7528\u610f\u3057\u307e\u3059\u3002\u4eca\u56de\u306e\u3088\u3046\u306a\u7df4\u7fd2\u76ee\u7684\u306e\u5834\u5408\u306f\u30aa\u30fc\u30d7\u30f3\u30bd\u30fc\u30b9\u306e\u30c6\u30ad\u30b9\u30c8\u3084\u3001Twitter\u304b\u3089\u53d6\u5f97\u3057\u305f\u30c4\u30a4\u30fc\u30c8\u306a\u3069\u3092\u5229\u7528\u3059\u308b\u306e\u304c\u304a\u3059\u3059\u3081\u3067\u3059\u3002\u4eca\u56de\u306f\u81ea\u5206\u3067\u9069\u5f53\u306a\u30c6\u30ad\u30b9\u30c8\u3092\u7528\u610f\u3057\u3001\u4ee5\u4e0b\u306e\u3088\u3046\u306a\u914d\u5217\u306b\u3057\u3066\u304a\u304d\u307e\u3059\u3002<\/p>\n\n\n\n<div class=\"wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers\" data-code-block-pro-font-family=\"Code-Pro-JetBrains-Mono\" style=\"font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#D4D4D4;--cbp-line-number-width:calc(1 * 0.6 * .875rem);line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)\"><span style=\"display:block;padding:16px 0 0 16px;margin-bottom:-1px;width:100%;text-align:left;background-color:#1E1E1E\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"54\" height=\"14\" viewBox=\"0 0 54 14\"><g fill=\"none\" fill-rule=\"evenodd\" transform=\"translate(1 1)\"><circle cx=\"6\" cy=\"6\" r=\"6\" fill=\"#FF5F56\" stroke=\"#E0443E\" stroke-width=\".5\"><\/circle><circle cx=\"26\" cy=\"6\" r=\"6\" fill=\"#FFBD2E\" stroke=\"#DEA123\" stroke-width=\".5\"><\/circle><circle cx=\"46\" cy=\"6\" r=\"6\" fill=\"#27C93F\" stroke=\"#1AAB29\" stroke-width=\".5\"><\/circle><\/g><\/svg><\/span><span role=\"button\" tabindex=\"0\" data-code=\"texts= [&quot;\u4eca\u65e5\u306f\u697d\u3057\u304f\u3066\u826f\u3044\u4e00\u65e5\u3060\u3063\u305f\u3002\u30e9\u30f3\u30c1\u306b\u884c\u3063\u305f\u304a\u5e97\u304c\u3068\u3066\u3082\u7f8e\u5473\u3057\u304b\u3063\u305f\u3002&quot;, &quot;\u4eca\u65e5\u306f\u5929\u6c17\u304c\u60aa\u304f\u3066\u5927\u5909\u3060\u3063\u305f\u3002\u3068\u3066\u3082\u75b2\u308c\u305f\u3002&quot;, &quot;\u4eca\u65e5\u306f\u5929\u6c17\u304c\u60aa\u304b\u3063\u305f\u304b\u3089\u3001\u5bb6\u3067\u8aad\u66f8\u3092\u3057\u305f\u3002\u3053\u3046\u3044\u3046\u65e5\u3082\u60aa\u304f\u306a\u3044\u3002&quot;]\" style=\"color:#D4D4D4;display:none\" aria-label=\"Copy\" class=\"code-block-pro-copy-button\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" style=\"width:24px;height:24px\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\" stroke-width=\"2\"><path class=\"with-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4\"><\/path><path class=\"without-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2\"><\/path><\/svg><\/span><pre class=\"shiki dark-plus\" style=\"background-color: #1E1E1E\" tabindex=\"0\"><code><span class=\"line\"><span style=\"color: #D4D4D4\">texts= [<\/span><span style=\"color: #CE9178\">&quot;\u4eca\u65e5\u306f\u697d\u3057\u304f\u3066\u826f\u3044\u4e00\u65e5\u3060\u3063\u305f\u3002\u30e9\u30f3\u30c1\u306b\u884c\u3063\u305f\u304a\u5e97\u304c\u3068\u3066\u3082\u7f8e\u5473\u3057\u304b\u3063\u305f\u3002&quot;<\/span><span style=\"color: #D4D4D4\">, <\/span><span style=\"color: #CE9178\">&quot;\u4eca\u65e5\u306f\u5929\u6c17\u304c\u60aa\u304f\u3066\u5927\u5909\u3060\u3063\u305f\u3002\u3068\u3066\u3082\u75b2\u308c\u305f\u3002&quot;<\/span><span style=\"color: #D4D4D4\">, <\/span><span style=\"color: #CE9178\">&quot;\u4eca\u65e5\u306f\u5929\u6c17\u304c\u60aa\u304b\u3063\u305f\u304b\u3089\u3001\u5bb6\u3067\u8aad\u66f8\u3092\u3057\u305f\u3002\u3053\u3046\u3044\u3046\u65e5\u3082\u60aa\u304f\u306a\u3044\u3002&quot;<\/span><span style=\"color: #D4D4D4\">]<\/span><\/span><\/code><\/pre><\/div>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"sec2-3\">\u8a55\u4fa1\u3057\u3066\u307f\u3088\u3046\uff01<\/h3>\n\n\n\n<p>\u3067\u306f\u3044\u3088\u3044\u3088\u30c6\u30ad\u30b9\u30c8\u3092\u8a55\u4fa1\u3057\u3066\u3044\u304d\u307e\u3059\u3002\u8a55\u4fa1\u65b9\u6cd5\u306f\u3044\u305f\u3063\u3066\u30b7\u30f3\u30d7\u30eb\u3067\u3001\u8a55\u4fa1\u3059\u308b\u30c6\u30ad\u30b9\u30c8\u3092\u5358\u8a9e\u5358\u4f4d\u306b\u5206\u5272\u3057\u3001\u5358\u8a9e\u306e\u539f\u578b\u3092\u53d6\u5f97\u3057\u307e\u3059\u3002\u3055\u3089\u306b\u52a9\u52d5\u8a5e\u3068\u52a9\u8a5e\u3092\u9664\u3044\u3066\u52d5\u8a5e\u30fb\u540d\u8a5e\u30fb\u5f62\u5bb9\u8a5e\u306e\u307f\u3092\u6b8b\u3057\u307e\u3059\u3002\u6b8b\u3063\u305f\u5358\u8a9e\u304c\u8f9e\u66f8\u306b\u542b\u307e\u308c\u3066\u3044\u308b\u304b\u3092\u8abf\u3079\u3066\u3001\u30cd\u30ac\u30c6\u30a3\u30d6\u306a\u5358\u8a9e\u306e\u5834\u5408-1\u70b9\u3001\u30dd\u30b8\u30c6\u30a3\u30d6\u306a\u5358\u8a9e\u306e\u5834\u5408+1\u70b9\u3001\u30cb\u30e5\u30fc\u30c8\u30e9\u30eb\u306a\u5358\u8a9e\u306e\u5834\u54080\u70b9\u3067\u70b9\u6570\u3092\u8a08\u7b97\u3057\u307e\u3059\u3002\u3053\u306e\u3088\u3046\u306b\u30c6\u30ad\u30b9\u30c8\u3092\u5358\u8a9e\u304c\u610f\u5473\u3092\u6301\u3064\u6700\u5c0f\u306e\u5358\u4f4d\u306b\u5206\u89e3\u3057\u3066\u89e3\u6790\u3059\u308b\u3053\u3068\u3092<strong>\u300c\u5f62\u614b\u7d20\u89e3\u6790\u300d<\/strong>\u3068\u8a00\u3044\u307e\u3059\u3002\u5f62\u614b\u7d20\u89e3\u6790\u3092\u884c\u3046\u969b\u306b\u975e\u5e38\u306b\u3088\u304f\u4f7f\u308f\u308c\u308b\u306e\u304c<strong>MeCab<\/strong>\u3068\u3044\u3046\u5f62\u614b\u7d20\u89e3\u6790\u30a8\u30f3\u30b8\u30f3\u3067\u3059\u3002<strong class=\"marker\">\u81ea\u7136\u8a00\u8a9e\u51e6\u7406\u306e\u4e16\u754c\u3067\u306f\u77e5\u3089\u306a\u3044\u4eba\u306f\u3044\u306a\u3044\u3068\u8a00\u3063\u3066\u3082\u904e\u8a00\u3067\u306f\u306a\u3044\u304f\u3089\u3044\u30e1\u30b8\u30e3\u30fc\u306a\u30c4\u30fc\u30eb\u3067\u3001<\/strong>\u4eca\u56de\u3082MeCab\u3092\u4f7f\u3063\u3066\u30c6\u30ad\u30b9\u30c8\u3092\u5206\u89e3\u3057\u3066\u3044\u304d\u307e\u3059\u3002<\/p>\n\n\n\n<p>\u3067\u306f\u5148\u307b\u3069\u7528\u610f\u3057\u305f\u8a55\u4fa1\u7528\u30c7\u30fc\u30bf\u3092MeCab\u3092\u4f7f\u3063\u3066\u5358\u8a9e\u5358\u4f4d\u306b\u5206\u89e3\u3057\u3066\u307f\u307e\u3059\u3002<\/p>\n\n\n\n<div class=\"wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers\" data-code-block-pro-font-family=\"Code-Pro-JetBrains-Mono\" style=\"font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#D4D4D4;--cbp-line-number-width:calc(2 * 0.6 * .875rem);line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)\"><span style=\"display:block;padding:16px 0 0 16px;margin-bottom:-1px;width:100%;text-align:left;background-color:#1E1E1E\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"54\" height=\"14\" viewBox=\"0 0 54 14\"><g fill=\"none\" fill-rule=\"evenodd\" transform=\"translate(1 1)\"><circle cx=\"6\" cy=\"6\" r=\"6\" fill=\"#FF5F56\" stroke=\"#E0443E\" stroke-width=\".5\"><\/circle><circle cx=\"26\" cy=\"6\" r=\"6\" fill=\"#FFBD2E\" stroke=\"#DEA123\" stroke-width=\".5\"><\/circle><circle cx=\"46\" cy=\"6\" r=\"6\" fill=\"#27C93F\" stroke=\"#1AAB29\" stroke-width=\".5\"><\/circle><\/g><\/svg><\/span><span role=\"button\" tabindex=\"0\" data-code=\"import MeCab\n\n#MeCab\u6e96\u5099\ntagger = MeCab.Tagger()\n\n#\u7528\u610f\u3057\u305f\u8a55\u4fa1\u7528\u30c6\u30ad\u30b9\u30c8\ntexts= [&quot;\u4eca\u65e5\u306f\u697d\u3057\u304f\u3066\u826f\u3044\u4e00\u65e5\u3060\u3063\u305f\u3002\u30e9\u30f3\u30c1\u306b\u884c\u3063\u305f\u304a\u5e97\u304c\u3068\u3066\u3082\u7f8e\u5473\u3057\u304b\u3063\u305f\u3002&quot;, &quot;\u4eca\u65e5\u306f\u5929\u6c17\u304c\u60aa\u304f\u3066\u5927\u5909\u3060\u3063\u305f\u3002\u3068\u3066\u3082\u75b2\u308c\u305f\u3002&quot;, &quot;\u4eca\u65e5\u306f\u5929\u6c17\u304c\u60aa\u304b\u3063\u305f\u304b\u3089\u3001\u5bb6\u3067\u8aad\u66f8\u3092\u3057\u305f\u3002\u3053\u3046\u3044\u3046\u65e5\u3082\u60aa\u304f\u306a\u3044\u3002&quot;]\n\n#\u30eb\u30fc\u30d7\u3067\uff11\u3064\u305a\u3064\u51e6\u7406\nfor text in texts:\n#     MeCab\u306eTagger\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\n    mecab_result = tagger.parse(text)\n    print(mecab_result)\n    print(&quot;-------------------------------------------------------------------------------------------------------&quot;)\" style=\"color:#D4D4D4;display:none\" aria-label=\"Copy\" class=\"code-block-pro-copy-button\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" style=\"width:24px;height:24px\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\" stroke-width=\"2\"><path class=\"with-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4\"><\/path><path class=\"without-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2\"><\/path><\/svg><\/span><pre class=\"shiki dark-plus\" style=\"background-color: #1E1E1E\" tabindex=\"0\"><code><span class=\"line\"><span style=\"color: #C586C0\">import<\/span><span style=\"color: #D4D4D4\"> MeCab<\/span><\/span>\n<span class=\"line\"><\/span>\n<span class=\"line\"><span style=\"color: #6A9955\">#MeCab\u6e96\u5099<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">tagger = MeCab.Tagger()<\/span><\/span>\n<span class=\"line\"><\/span>\n<span class=\"line\"><span style=\"color: #6A9955\">#\u7528\u610f\u3057\u305f\u8a55\u4fa1\u7528\u30c6\u30ad\u30b9\u30c8<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">texts= [<\/span><span style=\"color: #CE9178\">&quot;\u4eca\u65e5\u306f\u697d\u3057\u304f\u3066\u826f\u3044\u4e00\u65e5\u3060\u3063\u305f\u3002\u30e9\u30f3\u30c1\u306b\u884c\u3063\u305f\u304a\u5e97\u304c\u3068\u3066\u3082\u7f8e\u5473\u3057\u304b\u3063\u305f\u3002&quot;<\/span><span style=\"color: #D4D4D4\">, <\/span><span style=\"color: #CE9178\">&quot;\u4eca\u65e5\u306f\u5929\u6c17\u304c\u60aa\u304f\u3066\u5927\u5909\u3060\u3063\u305f\u3002\u3068\u3066\u3082\u75b2\u308c\u305f\u3002&quot;<\/span><span style=\"color: #D4D4D4\">, <\/span><span style=\"color: #CE9178\">&quot;\u4eca\u65e5\u306f\u5929\u6c17\u304c\u60aa\u304b\u3063\u305f\u304b\u3089\u3001\u5bb6\u3067\u8aad\u66f8\u3092\u3057\u305f\u3002\u3053\u3046\u3044\u3046\u65e5\u3082\u60aa\u304f\u306a\u3044\u3002&quot;<\/span><span style=\"color: #D4D4D4\">]<\/span><\/span>\n<span class=\"line\"><\/span>\n<span class=\"line\"><span style=\"color: #6A9955\">#\u30eb\u30fc\u30d7\u3067\uff11\u3064\u305a\u3064\u51e6\u7406<\/span><\/span>\n<span class=\"line\"><span style=\"color: #C586C0\">for<\/span><span style=\"color: #D4D4D4\"> text <\/span><span style=\"color: #C586C0\">in<\/span><span style=\"color: #D4D4D4\"> texts:<\/span><\/span>\n<span class=\"line\"><span style=\"color: #6A9955\">#     MeCab\u306eTagger\u30aa\u30d6\u30b8\u30a7\u30af\u30c8<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">    mecab_result = tagger.parse(text)<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">    <\/span><span style=\"color: #DCDCAA\">print<\/span><span style=\"color: #D4D4D4\">(mecab_result)<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">    <\/span><span style=\"color: #DCDCAA\">print<\/span><span style=\"color: #D4D4D4\">(<\/span><span style=\"color: #CE9178\">&quot;-------------------------------------------------------------------------------------------------------&quot;<\/span><span style=\"color: #D4D4D4\">)<\/span><\/span><\/code><\/pre><\/div>\n\n\n\n<p>\u3053\u3053\u3067\u306f\u6587\u7ae0\u3092\u5358\u8a9e\u5358\u4f4d\u306b\u5206\u5272\u3059\u308b\u969b\u306b\u4fbf\u5229\u306aTagger\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u3092\u4f7f\u3063\u3066\u3044\u307e\u3059\u3002\u4ee5\u4e0b\u306e\u753b\u50cf\u304c\u3072\u3068\u3064\u3081\u306e\u8a55\u4fa1\u7528\u30c6\u30ad\u30b9\u30c8\u306e\u5b9f\u884c\u7d50\u679c\u3067\u3059\u3002<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"1076\" height=\"764\" src=\"https:\/\/tetraup.com\/news_topics\/wp-content\/uploads\/2019\/03\/\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8-2019-03-31-21.56.57.png\" alt=\"\" class=\"wp-image-8951\"\/><figcaption class=\"wp-element-caption\">\u5f62\u614b\u7d20\u89e3\u6790\u306e\u7d50\u679c<\/figcaption><\/figure>\n\n\n\n<p>\u3053\u3053\u304b\u3089\u5358\u8a9e\u306e\u539f\u578b\u3068\u54c1\u8a5e\u3092\u53d6\u5f97\u3057\u3001\u5148\u307b\u3069\u8aac\u660e\u3057\u305f\u8a55\u4fa1\u65b9\u6cd5\u306b\u5f93\u3063\u3066\u70b9\u6570\u3092\u3064\u3051\u3066\u3044\u304d\u307e\u3059\u3002<\/p>\n\n\n\n<div class=\"wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers\" data-code-block-pro-font-family=\"Code-Pro-JetBrains-Mono\" style=\"font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#D4D4D4;--cbp-line-number-width:calc(2 * 0.6 * .875rem);line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)\"><span style=\"display:block;padding:16px 0 0 16px;margin-bottom:-1px;width:100%;text-align:left;background-color:#1E1E1E\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"54\" height=\"14\" viewBox=\"0 0 54 14\"><g fill=\"none\" fill-rule=\"evenodd\" transform=\"translate(1 1)\"><circle cx=\"6\" cy=\"6\" r=\"6\" fill=\"#FF5F56\" stroke=\"#E0443E\" stroke-width=\".5\"><\/circle><circle cx=\"26\" cy=\"6\" r=\"6\" fill=\"#FFBD2E\" stroke=\"#DEA123\" stroke-width=\".5\"><\/circle><circle cx=\"46\" cy=\"6\" r=\"6\" fill=\"#27C93F\" stroke=\"#1AAB29\" stroke-width=\".5\"><\/circle><\/g><\/svg><\/span><span role=\"button\" tabindex=\"0\" data-code=\"import pickle\nimport MeCab\n\n# \u8f9e\u66f8\u8aad\u307f\u8fbc\u3080\nword_dic = pickle.load(open(&quot;word_dic.pickle&quot;, &quot;rb&quot;))\n#MeCab\u6e96\u5099\ntagger = MeCab.Tagger()\n\n#\u30d5\u30a1\u30a4\u30eb\u8aad\u307f\u8fbc\u3080\ntexts= [&quot;\u4eca\u65e5\u306f\u697d\u3057\u304f\u3066\u826f\u3044\u4e00\u65e5\u3060\u3063\u305f\u3002\u30e9\u30f3\u30c1\u306b\u884c\u3063\u305f\u304a\u5e97\u304c\u3068\u3066\u3082\u7f8e\u5473\u3057\u304b\u3063\u305f\u3002&quot;, &quot;\u4eca\u65e5\u306f\u5929\u6c17\u304c\u60aa\u304f\u3066\u5927\u5909\u3060\u3063\u305f\u3002\u3068\u3066\u3082\u75b2\u308c\u305f\u3002&quot;, &quot;\u4eca\u65e5\u306f\u5929\u6c17\u304c\u60aa\u304b\u3063\u305f\u304b\u3089\u3001\u5bb6\u3067\u8aad\u66f8\u3092\u3057\u305f\u3002\u3053\u3046\u3044\u3046\u65e5\u3082\u60aa\u304f\u306a\u3044\u3002&quot;]\nfor text in texts:\n    print(&quot;\u8a55\u4fa1\u3059\u308b\u30c6\u30ad\u30b9\u30c8\uff1a&quot;, text)\n    point = 0\n#     MeCab\n    s = tagger.parse(text)\n    \n#         \u30b9\u30da\u30fc\u30b9\u3067\u5206\u5272\u3057\u3066\u54c1\u8a5e\u5074\u3092\u53d6\u5f97\n    for line in s.split(&quot;n&quot;):\n#         EOS\u3060\u3063\u305f\u3089\u30eb\u30fc\u30d7\u3092\u629c\u3051\u308b\n        if line == &quot;EOS&quot;: break\n#         \u3055\u3089\u306b\u30ab\u30f3\u30de\u3067\u5206\u5272\n        params = line.split(&quot;t&quot;)[1].split(&quot;,&quot;)\n#         \u54c1\u8a5e\u3092\u53d6\u5f97\n        hinshi = params[0]\n#         \u5358\u8a9e\u306e\u539f\u578b\u3092\u53d6\u5f97\n        word = params[6] \n        if not (hinshi in ['\u540d\u8a5e', '\u52d5\u8a5e', '\u5f62\u5bb9\u8a5e']): continue\n#             \u53d6\u5f97\u3057\u305f\u5358\u8a9e\u306e\u539f\u578b\u304c\u8f9e\u66f8\u306b\u542b\u307e\u308c\u3066\u3044\u308b\u304b\u8abf\u3079\u3066\u70b9\u6570\u3092\u3064\u3051\u308b\n        if word in word_dic:\n            negaposi = word_dic[word]\n            if negaposi == 'n':\n                point -= 1\n            elif negaposi == 'p':\n                point += 1\n            else:\n                point += 0\n            print(word, negaposi)\n    \n    print(&quot;score:&quot;, point)\n    print(&quot;\u5f62\u614b\u7d20\u89e3\u6790\u7d50\u679c&quot;)\n    print(s)\n    print(&quot;---------------------------------------------------------------------------------------------------------&quot;)\n\" style=\"color:#D4D4D4;display:none\" aria-label=\"Copy\" class=\"code-block-pro-copy-button\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" style=\"width:24px;height:24px\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\" stroke-width=\"2\"><path class=\"with-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4\"><\/path><path class=\"without-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2\"><\/path><\/svg><\/span><pre class=\"shiki dark-plus\" style=\"background-color: #1E1E1E\" tabindex=\"0\"><code><span class=\"line\"><span style=\"color: #C586C0\">import<\/span><span style=\"color: #D4D4D4\"> pickle<\/span><\/span>\n<span class=\"line\"><span style=\"color: #C586C0\">import<\/span><span style=\"color: #D4D4D4\"> MeCab<\/span><\/span>\n<span class=\"line\"><\/span>\n<span class=\"line\"><span style=\"color: #6A9955\"># \u8f9e\u66f8\u8aad\u307f\u8fbc\u3080<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">word_dic = pickle.load(<\/span><span style=\"color: #DCDCAA\">open<\/span><span style=\"color: #D4D4D4\">(<\/span><span style=\"color: #CE9178\">&quot;word_dic.pickle&quot;<\/span><span style=\"color: #D4D4D4\">, <\/span><span style=\"color: #CE9178\">&quot;rb&quot;<\/span><span style=\"color: #D4D4D4\">))<\/span><\/span>\n<span class=\"line\"><span style=\"color: #6A9955\">#MeCab\u6e96\u5099<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">tagger = MeCab.Tagger()<\/span><\/span>\n<span class=\"line\"><\/span>\n<span class=\"line\"><span style=\"color: #6A9955\">#\u30d5\u30a1\u30a4\u30eb\u8aad\u307f\u8fbc\u3080<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">texts= [<\/span><span style=\"color: #CE9178\">&quot;\u4eca\u65e5\u306f\u697d\u3057\u304f\u3066\u826f\u3044\u4e00\u65e5\u3060\u3063\u305f\u3002\u30e9\u30f3\u30c1\u306b\u884c\u3063\u305f\u304a\u5e97\u304c\u3068\u3066\u3082\u7f8e\u5473\u3057\u304b\u3063\u305f\u3002&quot;<\/span><span style=\"color: #D4D4D4\">, <\/span><span style=\"color: #CE9178\">&quot;\u4eca\u65e5\u306f\u5929\u6c17\u304c\u60aa\u304f\u3066\u5927\u5909\u3060\u3063\u305f\u3002\u3068\u3066\u3082\u75b2\u308c\u305f\u3002&quot;<\/span><span style=\"color: #D4D4D4\">, <\/span><span style=\"color: #CE9178\">&quot;\u4eca\u65e5\u306f\u5929\u6c17\u304c\u60aa\u304b\u3063\u305f\u304b\u3089\u3001\u5bb6\u3067\u8aad\u66f8\u3092\u3057\u305f\u3002\u3053\u3046\u3044\u3046\u65e5\u3082\u60aa\u304f\u306a\u3044\u3002&quot;<\/span><span style=\"color: #D4D4D4\">]<\/span><\/span>\n<span class=\"line\"><span style=\"color: #C586C0\">for<\/span><span style=\"color: #D4D4D4\"> text <\/span><span style=\"color: #C586C0\">in<\/span><span style=\"color: #D4D4D4\"> texts:<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">    <\/span><span style=\"color: #DCDCAA\">print<\/span><span style=\"color: #D4D4D4\">(<\/span><span style=\"color: #CE9178\">&quot;\u8a55\u4fa1\u3059\u308b\u30c6\u30ad\u30b9\u30c8\uff1a&quot;<\/span><span style=\"color: #D4D4D4\">, text)<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">    point = <\/span><span style=\"color: #B5CEA8\">0<\/span><\/span>\n<span class=\"line\"><span style=\"color: #6A9955\">#     MeCab<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">    s = tagger.parse(text)<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">    <\/span><\/span>\n<span class=\"line\"><span style=\"color: #6A9955\">#         \u30b9\u30da\u30fc\u30b9\u3067\u5206\u5272\u3057\u3066\u54c1\u8a5e\u5074\u3092\u53d6\u5f97<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">    <\/span><span style=\"color: #C586C0\">for<\/span><span style=\"color: #D4D4D4\"> line <\/span><span style=\"color: #C586C0\">in<\/span><span style=\"color: #D4D4D4\"> s.split(<\/span><span style=\"color: #CE9178\">&quot;n&quot;<\/span><span style=\"color: #D4D4D4\">):<\/span><\/span>\n<span class=\"line\"><span style=\"color: #6A9955\">#         EOS\u3060\u3063\u305f\u3089\u30eb\u30fc\u30d7\u3092\u629c\u3051\u308b<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">        <\/span><span style=\"color: #C586C0\">if<\/span><span style=\"color: #D4D4D4\"> line == <\/span><span style=\"color: #CE9178\">&quot;EOS&quot;<\/span><span style=\"color: #D4D4D4\">: <\/span><span style=\"color: #C586C0\">break<\/span><\/span>\n<span class=\"line\"><span style=\"color: #6A9955\">#         \u3055\u3089\u306b\u30ab\u30f3\u30de\u3067\u5206\u5272<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">        params = line.split(<\/span><span style=\"color: #CE9178\">&quot;t&quot;<\/span><span style=\"color: #D4D4D4\">)[<\/span><span style=\"color: #B5CEA8\">1<\/span><span style=\"color: #D4D4D4\">].split(<\/span><span style=\"color: #CE9178\">&quot;,&quot;<\/span><span style=\"color: #D4D4D4\">)<\/span><\/span>\n<span class=\"line\"><span style=\"color: #6A9955\">#         \u54c1\u8a5e\u3092\u53d6\u5f97<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">        hinshi = params[<\/span><span style=\"color: #B5CEA8\">0<\/span><span style=\"color: #D4D4D4\">]<\/span><\/span>\n<span class=\"line\"><span style=\"color: #6A9955\">#         \u5358\u8a9e\u306e\u539f\u578b\u3092\u53d6\u5f97<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">        word = params[<\/span><span style=\"color: #B5CEA8\">6<\/span><span style=\"color: #D4D4D4\">] <\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">        <\/span><span style=\"color: #C586C0\">if<\/span><span style=\"color: #D4D4D4\"> <\/span><span style=\"color: #569CD6\">not<\/span><span style=\"color: #D4D4D4\"> (hinshi <\/span><span style=\"color: #569CD6\">in<\/span><span style=\"color: #D4D4D4\"> [<\/span><span style=\"color: #CE9178\">&#39;\u540d\u8a5e&#39;<\/span><span style=\"color: #D4D4D4\">, <\/span><span style=\"color: #CE9178\">&#39;\u52d5\u8a5e&#39;<\/span><span style=\"color: #D4D4D4\">, <\/span><span style=\"color: #CE9178\">&#39;\u5f62\u5bb9\u8a5e&#39;<\/span><span style=\"color: #D4D4D4\">]): <\/span><span style=\"color: #C586C0\">continue<\/span><\/span>\n<span class=\"line\"><span style=\"color: #6A9955\">#             \u53d6\u5f97\u3057\u305f\u5358\u8a9e\u306e\u539f\u578b\u304c\u8f9e\u66f8\u306b\u542b\u307e\u308c\u3066\u3044\u308b\u304b\u8abf\u3079\u3066\u70b9\u6570\u3092\u3064\u3051\u308b<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">        <\/span><span style=\"color: #C586C0\">if<\/span><span style=\"color: #D4D4D4\"> word <\/span><span style=\"color: #569CD6\">in<\/span><span style=\"color: #D4D4D4\"> word_dic:<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">            negaposi = word_dic[word]<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">            <\/span><span style=\"color: #C586C0\">if<\/span><span style=\"color: #D4D4D4\"> negaposi == <\/span><span style=\"color: #CE9178\">&#39;n&#39;<\/span><span style=\"color: #D4D4D4\">:<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">                point -= <\/span><span style=\"color: #B5CEA8\">1<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">            <\/span><span style=\"color: #C586C0\">elif<\/span><span style=\"color: #D4D4D4\"> negaposi == <\/span><span style=\"color: #CE9178\">&#39;p&#39;<\/span><span style=\"color: #D4D4D4\">:<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">                point += <\/span><span style=\"color: #B5CEA8\">1<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">            <\/span><span style=\"color: #C586C0\">else<\/span><span style=\"color: #D4D4D4\">:<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">                point += <\/span><span style=\"color: #B5CEA8\">0<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">            <\/span><span style=\"color: #DCDCAA\">print<\/span><span style=\"color: #D4D4D4\">(word, negaposi)<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">    <\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">    <\/span><span style=\"color: #DCDCAA\">print<\/span><span style=\"color: #D4D4D4\">(<\/span><span style=\"color: #CE9178\">&quot;score:&quot;<\/span><span style=\"color: #D4D4D4\">, point)<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">    <\/span><span style=\"color: #DCDCAA\">print<\/span><span style=\"color: #D4D4D4\">(<\/span><span style=\"color: #CE9178\">&quot;\u5f62\u614b\u7d20\u89e3\u6790\u7d50\u679c&quot;<\/span><span style=\"color: #D4D4D4\">)<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">    <\/span><span style=\"color: #DCDCAA\">print<\/span><span style=\"color: #D4D4D4\">(s)<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D4D4D4\">    <\/span><span style=\"color: #DCDCAA\">print<\/span><span style=\"color: #D4D4D4\">(<\/span><span style=\"color: #CE9178\">&quot;---------------------------------------------------------------------------------------------------------&quot;<\/span><span style=\"color: #D4D4D4\">)<\/span><\/span>\n<span class=\"line\"><\/span><\/code><\/pre><\/div>\n\n\n\n<p>\u3072\u3068\u3064\u3081\u306e\u30c6\u30ad\u30b9\u30c8\u306e\u7d50\u679c\u304c\u3053\u3061\u3089\u3002<\/p>\n\n\n\n<p>score\u304c\uff12\u306a\u306e\u3067\u30dd\u30b8\u30c6\u30a3\u30d6\u306a\u6587\u7ae0\u3060\u3068\u8a55\u4fa1\u3055\u308c\u3066\u3044\u308b\u3068\u8a00\u3048\u307e\u3059\u3002<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"1126\" height=\"990\" src=\"https:\/\/tetraup.com\/news_topics\/wp-content\/uploads\/2019\/03\/\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8-2019-03-31-22.11.35.png\" alt=\"\" class=\"wp-image-8953\"\/><figcaption class=\"wp-element-caption\">\u8a55\u4fa1\u7d50\u679c\u305d\u306e\uff11<\/figcaption><\/figure>\n\n\n\n<p>\u3075\u305f\u3064\u3081\u306e\u30c6\u30ad\u30b9\u30c8\u306e\u7d50\u679c\u304c\u3053\u3061\u3089\u3002<\/p>\n\n\n\n<p>score\u304c-3\u306a\u306e\u3067\u30cd\u30ac\u30c6\u30a3\u30d6\u306a\u6587\u7ae0\u3060\u3068\u5224\u5b9a\u3055\u308c\u3066\u3044\u308b\u3068\u8a00\u3048\u307e\u3059\u3002<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"1118\" height=\"732\" src=\"https:\/\/tetraup.com\/news_topics\/wp-content\/uploads\/2019\/03\/\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8-2019-03-31-22.12.27.png\" alt=\"\" class=\"wp-image-8954\"\/><figcaption class=\"wp-element-caption\">\u8a55\u4fa1\u7d50\u679c\u305d\u306e\uff12<\/figcaption><\/figure>\n\n\n\n<p>\u3057\u304b\u3057\u554f\u984c\u306a\u306e\u304c\uff13\u3064\u3081\u306e\u30c6\u30ad\u30b9\u30c8\u3067\u3059\u3002<strong class=\"marker\">\u6587\u7ae0\u81ea\u4f53\u306e\u30cb\u30e5\u30a2\u30f3\u30b9\u306f\u30dd\u30b8\u30c6\u30a3\u30d6\u306b\u8fd1\u3044\u306b\u3082\u95a2\u308f\u3089\u305a\u3001\u300c\u60aa\u3044\u300d\u3068\u3044\u3046\u30ef\u30fc\u30c9\u304c\u591a\u3044\u305f\u3081\u306bscore\u304c-2\u306b\u306a\u3063\u3066\u3057\u307e\u3063\u3066\u3044\u307e\u3059\u3002<\/strong><\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"1118\" height=\"914\" src=\"https:\/\/tetraup.com\/news_topics\/wp-content\/uploads\/2019\/03\/\u30b9\u30af\u30ea\u30fc\u30f3\u30b7\u30e7\u30c3\u30c8-2019-03-31-22.12.36.png\" alt=\"\" class=\"wp-image-8955\"\/><figcaption class=\"wp-element-caption\">\u8a55\u4fa1\u7d50\u679c\u305d\u306e\uff13<\/figcaption><\/figure>\n\n\n\n<p>\u3053\u306e\u3088\u3046\u306a\u5c11\u3057\u8907\u96d1\u306a\u8868\u73fe\u304c\u3055\u308c\u3066\u3044\u308b\u30c6\u30ad\u30b9\u30c8\u306f\u6a5f\u68b0\u5b66\u7fd2\u3067\u5927\u91cf\u306e\u30c6\u30ad\u30b9\u30c8\u30c7\u30fc\u30bf\u3092\u5b66\u7fd2\u3057\u3066\u6027\u80fd\u306e\u826f\u3044\u30e2\u30c7\u30eb\u3092\u4f5c\u3063\u305f\u308a\u3001\u52a9\u52d5\u8a5e\u307e\u3067\u52a0\u5473\u3057\u3066\u8a55\u4fa1\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"sec3\">\u307e\u3068\u3081<\/h2>\n\n\n\n<p>\u3044\u304b\u304c\u3067\u3057\u305f\u3067\u3057\u3087\u3046\u304b\u3002\u81ea\u7136\u8a00\u8a9e\u51e6\u7406\u306f\u96e3\u3057\u3044\u3082\u306e\u306e\u3088\u3046\u306a\u30a4\u30e1\u30fc\u30b8\u3092\u6301\u305f\u308c\u304c\u3061\u3067\u3059\u304c\u3001\u5b9f\u306f\u4eca\u56de\u306e\u3088\u3046\u306a\u57fa\u672c\u7684\u306a\u4f5c\u696d\u3060\u3051\u3067\u3082\u611f\u60c5\u5206\u6790\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n\n\n\n<p>\u3053\u308c\u3092\u6a5f\u306b\u81ea\u7136\u8a00\u8a9e\u51e6\u7406\u306e\u4e16\u754c\u306b\u5c11\u3057\u3067\u3082\u8208\u5473\u3092\u6301\u3063\u3066\u3044\u305f\u3060\u3051\u308b\u3068\u5b09\u3057\u3044\u3067\u3059\u3002<\/p>\n\n\n\n<p>\u5f53\u6559\u5ba4<a href=\"https:\/\/tetraup.com\/\" title=\"\">TETRA UP<\/a>\u3067\u306f\u3001\u4ed6\u306b\u3082\u30d7\u30ed\u30b0\u30e9\u30df\u30f3\u30b0\u306e\u57fa\u790e\u3092\u5b66\u3079\u308b<a href=\"https:\/\/tetraup.com\/education\/course\/scratch\">Scratch\u30b3\u30fc\u30b9<\/a>\u3001\u3082\u306e\u3065\u304f\u308a\u3068\u30d7\u30ed\u30b0\u30e9\u30df\u30f3\u30b0\u3092\u5b9f\u969b\u89e6\u3063\u3066\u5b66\u3079\u308b<a href=\"https:\/\/tetraup.com\/education\/course\/robot\">\u30ed\u30dc\u30c3\u30c8\u30b3\u30fc\u30b9<\/a>\u3001\u305d\u3057\u3066\u672c\u683c\u7684\u306a\u30d7\u30ed\u30b0\u30e9\u30df\u30f3\u30b0\u3092\u7fd2\u5f97\u3067\u304d\u308b<a href=\"https:\/\/tetraup.com\/education\/course\/unity\">unity\u30b3\u30fc\u30b9<\/a>\u3001\u305d\u3057\u3066\u7dcf\u30e6\u30fc\u30b6\u30fc\u6570\u7d044\u5104\u4eba\u306e<a href=\"https:\/\/tetraup.com\/education\/course\/roblox\" title=\"\">Roblox\u30b3\u30fc\u30b9<\/a>\u3082\u5c55\u958b\u3057\u3066\u304a\u308a\u307e\u3059\u3002\u30aa\u30f3\u30e9\u30a4\u30f3\u3067\u3082\u53d7\u3051\u4ed8\u3051\u3066\u304a\u308a\u307e\u3059\u306e\u3067\u3001\u3053\u306e\u6a5f\u4f1a\u306b\u30b3\u30c1\u30e9\u3088\u308a\u4f53\u9a13\u3057\u3066\u307f\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n\n\n\n<p><a href=\"https:\/\/tetraup.com\/education\/contact\" title=\"\">>>WEB\u88fd\u4f5c\u30fb\u30b7\u30b9\u30c6\u30e0\u958b\u767a\u306e\u304a\u554f\u3044\u5408\u308f\u305b\u306f\u30b3\u30c1\u30e9<\/a><\/p>\n\n\n\n<br><div class=\"wp-block-button\"><a class=\"wp-block-button__link has-very-dark-gray-color has-light-green-cyan-background-color has-text-color has-background wp-element-button\" href=\"https:\/\/tetraup.com\/education\/trial-form\" style=\"border-radius:3px\" target=\"_blank\" rel=\"noreferrer noopener\">\u7121\u6599\u4f53\u9a13\u6388\u696d\u306e\u304a\u7533\u8fbc\u307f\u306f\u30b3\u30c1\u30e9<\/a><\/div><br>\n","protected":false},"excerpt":{"rendered":"<p>\u300c\u81ea\u7136\u8a00\u8a9e\u51e6\u7406\u300d\u3068\u3044\u3046\u8a00\u8449\u3092\u805e\u3044\u3066\u3001\u7686\u3055\u3093\u306f\u3069\u306e\u3088\u3046\u306a\u30a4\u30e1\u30fc\u30b8\u3092\u6301\u305f\u308c\u308b\u3067\u3057\u3087\u3046\u304b\uff1f\u6a5f\u68b0\u5b66\u7fd2\u3092\u5b66\u3093\u3060\u3053\u3068\u304c\u306a\u3044\u5834\u5408\u3001\u300c\u805e\u3044\u305f\u3053\u3068\u306f\u3042\u308b\u304c\u3069\u306e\u3088\u3046\u306a\u3082\u306e\u306a\u306e\u304b\u306f\u308f\u304b\u3063\u3066\u3044\u306a\u3044\u300d\u3001\u300c\u306a\u3093\u3068\u306a\u304f\u96e3\u3057\u305d\u3046\u300d\u7b49\u306e\u30a4\u30e1\u30fc\u30b8\u3092\u6301\u305f\u308c\u308b [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":8947,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"om_disable_all_campaigns":false,"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"footnotes":""},"categories":[37],"tags":[113,101],"class_list":["post-7016","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-column","tag-python","tag-beginner"],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/tetraup.com\/news_topics\/wp-json\/wp\/v2\/posts\/7016","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/tetraup.com\/news_topics\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/tetraup.com\/news_topics\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/tetraup.com\/news_topics\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/tetraup.com\/news_topics\/wp-json\/wp\/v2\/comments?post=7016"}],"version-history":[{"count":6,"href":"https:\/\/tetraup.com\/news_topics\/wp-json\/wp\/v2\/posts\/7016\/revisions"}],"predecessor-version":[{"id":9832,"href":"https:\/\/tetraup.com\/news_topics\/wp-json\/wp\/v2\/posts\/7016\/revisions\/9832"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/tetraup.com\/news_topics\/wp-json\/wp\/v2\/media\/8947"}],"wp:attachment":[{"href":"https:\/\/tetraup.com\/news_topics\/wp-json\/wp\/v2\/media?parent=7016"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/tetraup.com\/news_topics\/wp-json\/wp\/v2\/categories?post=7016"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/tetraup.com\/news_topics\/wp-json\/wp\/v2\/tags?post=7016"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}