{"id":20144266,"url":"https://github.com/made2591/go-cpt","last_synced_at":"2025-07-19T12:36:39.904Z","repository":{"id":71122836,"uuid":"158267951","full_name":"made2591/go-cpt","owner":"made2591","description":"A Go implementation of Compact Prediction Tree. A blog post related is available (see README.md)","archived":false,"fork":false,"pushed_at":"2018-12-01T12:02:45.000Z","size":2614,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-01-13T10:50:14.330Z","etag":null,"topics":["cpt","go","golang","ml","prediction","sequence","unik","unikernel"],"latest_commit_sha":null,"homepage":"https://made2591.github.io/blog/compact-prediction-tree","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/made2591.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":"2018-11-19T17:53:18.000Z","updated_at":"2018-12-01T12:02:47.000Z","dependencies_parsed_at":"2023-03-11T09:57:24.164Z","dependency_job_id":null,"html_url":"https://github.com/made2591/go-cpt","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/made2591%2Fgo-cpt","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/made2591%2Fgo-cpt/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/made2591%2Fgo-cpt/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/made2591%2Fgo-cpt/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/made2591","download_url":"https://codeload.github.com/made2591/go-cpt/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241587914,"owners_count":19986627,"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":["cpt","go","golang","ml","prediction","sequence","unik","unikernel"],"created_at":"2024-11-13T22:09:28.545Z","updated_at":"2025-03-02T23:44:17.636Z","avatar_url":"https://github.com/made2591.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# go-cpt\n\nA Go implementation of Compact Prediction Tree. A blog post related is [available](https://made2591.github.io/posts/compact-prediction-tree).\n\n## Instructions\n\nTo install:\n\n```\ngit clone https://github.com/made2591/go-cpt\ncd go-cpt\ngo run main.go\n```\n\n## Build UniK image\n\nAssuming you already installed UniK correctly, then with a daemon running in a terminal open another shell and run:\n\n```\nunik build --name go-cpt-image --path ./ --base rump --language go --provider virtualbox --force\nunik run --instanceName go-cpt-instance --imageName go-cpt-image\n```\n\nTo retrieve the running instances:\n```\nunik instances\n```\nYou can see IP assigned to instances in the last column of the output\n\n![](./unik.png)\n\nTo see the logs of the running instances run:\n```\nunik logs --instance go-cpt-instance\n```\n\nWhat this image does is actually expose the different endpoint to initialize training and make prediction by rest api - ```it's only a draft```:\n\nA sample file are already uploaded into the upload folder: you can modify the ```main.go``` root of the project to avoid cutting the training and testing set. Otherwise, to see the run you can both execute the code locally or\n```\ncurl http://\u003cYOUR_RUNNING_INSTANCES\u003e:8080/initcpt\n```\n\nYou should see predictions for the first 10 sequences :-)\n![](./predictions.png)\n\n## Author\n\n* **Matteo Madeddu** - *[here](https://made2591.github.io) is my github personal page* -\n\n## Credits\n\n- [UniK contributors](https://github.com/solo-io/unik/graphs/contributors)\n- [NeerajSarwan](https://github.com/NeerajSarwan)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmade2591%2Fgo-cpt","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmade2591%2Fgo-cpt","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmade2591%2Fgo-cpt/lists"}