{"id":13413559,"url":"https://github.com/awsong/MMSEGO","last_synced_at":"2025-03-14T19:32:39.176Z","repository":{"id":3039301,"uuid":"4060051","full_name":"awsong/MMSEGO","owner":"awsong","description":"Chinese word splitting algorithm MMSEG in GO","archived":false,"fork":false,"pushed_at":"2012-04-18T04:18:51.000Z","size":699,"stargazers_count":63,"open_issues_count":1,"forks_count":14,"subscribers_count":5,"default_branch":"darts","last_synced_at":"2024-08-03T23:07:00.521Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/awsong.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}},"created_at":"2012-04-18T04:06:21.000Z","updated_at":"2024-04-01T19:53:44.000Z","dependencies_parsed_at":"2022-09-03T03:33:51.354Z","dependency_job_id":null,"html_url":"https://github.com/awsong/MMSEGO","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/awsong%2FMMSEGO","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/awsong%2FMMSEGO/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/awsong%2FMMSEGO/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/awsong%2FMMSEGO/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/awsong","download_url":"https://codeload.github.com/awsong/MMSEGO/tar.gz/refs/heads/darts","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":221498771,"owners_count":16833059,"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":[],"created_at":"2024-07-30T20:01:43.170Z","updated_at":"2024-10-26T05:31:05.241Z","avatar_url":"https://github.com/awsong.png","language":"Go","readme":"MMSEGO\n=====\nThis is a GO implementation of [MMSEG](http://technology.chtsai.org/mmseg/) which a Chinese word splitting algorithm.\n\nTO DO list\n----------\n* Documentation/comments\n* Benchmark\n\nUsage\n---------\n#Input Dictionary Format\n```sh\nKey\\tFreq\n```\nEach key occupies one line. The file should be utf-8 encoded, please refer to [go-darts](https://github.com/awsong/go-darts)\n\n#Code example\n```go\npackage main\n\nimport (\n    \"fmt\"\n    \"time\"\n    \"os\"\n    \"mmsego\"\n    \"bufio\"\n    \"log\"\n    )\n\nfunc main() {\n    var s = new(mmsego.Segmenter)\n    s.Init(\"darts.lib\")\n    if err != nil {\n\tlog.Fatal(err)\n    }\n\n    t := time.Now()\n    offset := 0\n\n    unifile, _ := os.Open(\"/tmp/a.txt\")\n    uniLineReader := bufio.NewReaderSize(unifile, 4000)\n    line, bufErr := uniLineReader.ReadString('\\n')\n    for nil == bufErr {\n\t//takeWord := func(off int, length int){ fmt.Printf(\"%s \", string(line[off-offset:off-offset+length])) }\n\ttakeWord := func(off, length int){ }\n\ts.Mmseg(line[:], offset, takeWord, nil, false)\n\toffset += len(line)\n\tline, bufErr = uniLineReader.ReadString('\\n')\n    }\n    takeWord := func(off int, length int){ fmt.Printf(\"%s \", string(line[off-offset:off-offset+length])) }\n    s.Mmseg(line, offset, takeWord, nil, true)\n\n    fmt.Printf(\"Duration: %v\\n\", time.Since(t))\n}\n```\nLICENSE\n-----------\nApache License 2.0\n","funding_links":[],"categories":["Natural Language Processing","自然语言处理","Relational Databases","Bot Building","\u003cspan id=\"自然语言处理-natural-language-processing\"\u003e自然语言处理 Natural Language Processing\u003c/span\u003e","Microsoft Office"],"sub_categories":["Tokenizers","暂未分类","Advanced Console UIs","\u003cspan id=\"高级控制台用户界面-advanced-console-uis\"\u003e高级控制台用户界面 Advanced Console UIs\u003c/span\u003e","暂未分类这些库被放在这里是因为其他类别似乎都不适合。","分词器","Strings","Uncategorized"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fawsong%2FMMSEGO","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fawsong%2FMMSEGO","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fawsong%2FMMSEGO/lists"}