{"id":39534145,"url":"https://github.com/zituocn/dean","last_synced_at":"2026-01-18T06:31:55.079Z","repository":{"id":99432788,"uuid":"608455283","full_name":"zituocn/dean","owner":"zituocn","description":"Task flow framework for data processing","archived":false,"fork":false,"pushed_at":"2023-09-26T10:50:14.000Z","size":4,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-06-20T10:14:39.080Z","etag":null,"topics":["data","golang","task"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/zituocn.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}},"created_at":"2023-03-02T03:35:01.000Z","updated_at":"2023-03-13T08:12:40.000Z","dependencies_parsed_at":"2023-10-01T16:10:54.422Z","dependency_job_id":null,"html_url":"https://github.com/zituocn/dean","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/zituocn/dean","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zituocn%2Fdean","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zituocn%2Fdean/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zituocn%2Fdean/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zituocn%2Fdean/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/zituocn","download_url":"https://codeload.github.com/zituocn/dean/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zituocn%2Fdean/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28531997,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-18T00:39:45.795Z","status":"online","status_checked_at":"2026-01-18T02:00:07.578Z","response_time":98,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":["data","golang","task"],"created_at":"2026-01-18T06:31:54.842Z","updated_at":"2026-01-18T06:31:55.058Z","avatar_url":"https://github.com/zituocn.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Dean\n\n一个数据处理、数据清洗的任务流框架\n\n\n\n### 安装\n\n```shell\ngo get github.com/zituocn/dean\n```\n\n### 使用demo\n\n```go\npackage main\n\nimport (\n\t\"fmt\"\n\t\"github.com/zituocn/dean\"\n)\n\nfunc main() {\n\n\t// 原始数据\n\tds := loadData()\n\n\t//创建作业\n\tjob := dean.NewJob(ds)\n\n\t//添加任务实现\n\tjob.AddTask(new(SomeTask)).\n\t\tAddTask(new(OtherTask))\n\n\t// 执行作业\n\tjob.Do()\n\n\t// 返回最终数据\n\tresult := job.GetData()\n\n\tfor _, item := range result {\n\t\tfmt.Println(item)\n\t}\n}\n\n/*\ntask 1\n*/\n\ntype SomeTask struct {\n\tds dean.DataSet\n}\n\nfunc (m *SomeTask) LoadData(ds dean.DataSet) {\n\tfmt.Println(\"load data\")\n\tm.ds = ds\n}\n\nfunc (m *SomeTask) Process() error {\n\tfmt.Println(\"Process\")\n\tm.ds[0][\"name\"] = \"四川大学\"\n\treturn nil\n}\n\nfunc (m *SomeTask) Result() dean.DataSet {\n\tfmt.Println(\"result\")\n\treturn m.ds\n}\n\n/*\ntask 2\n*/\n\ntype OtherTask struct {\n\tds dean.DataSet\n}\n\nfunc (m *OtherTask) LoadData(ds dean.DataSet) {\n\tfmt.Println(\"other load data\")\n\tm.ds = ds\n}\n\nfunc (m *OtherTask) Process() error {\n\tfmt.Println(\"other Process\")\n\tm.ds[5][\"major_name\"] = \"计算机科学与技术(工科实验班)\"\n\treturn nil\n}\n\nfunc (m *OtherTask) Result() dean.DataSet {\n\tfmt.Println(\"other result\")\n\treturn m.ds\n}\n\nfunc loadData() (ds dean.DataSet) {\n\tfor i := 0; i \u003c 100; i++ {\n\t\tdataLine := dean.DataLine{\n\t\t\t\"name\":          \"清华大学\",\n\t\t\t\"prov_id\":       \"51\",\n\t\t\t\"major_name\":    \"工业设计\",\n\t\t\t\"number\":        \"43\",\n\t\t\t\"min_score\":     \"664\",\n\t\t\t\"min_score_def\": \"166\",\n\t\t\t\"avg_score\":     \"665\",\n\t\t\t\"max_score\":     \"669\",\n\t\t}\n\t\tds = append(ds, dataLine)\n\t}\n\n\treturn ds\n}\n\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzituocn%2Fdean","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fzituocn%2Fdean","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzituocn%2Fdean/lists"}