{"id":16359330,"url":"https://github.com/gaborvecsei/machine-learning-inference-with-github-actions","last_synced_at":"2025-10-26T04:31:48.281Z","repository":{"id":40968606,"uuid":"245611718","full_name":"gaborvecsei/Machine-Learning-Inference-With-GitHub-Actions","owner":"gaborvecsei","description":"This repository demonstrated how you can use Github Actions to perform inference with your ML model","archived":false,"fork":false,"pushed_at":"2023-07-06T21:20:43.000Z","size":80,"stargazers_count":6,"open_issues_count":3,"forks_count":3,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-07T14:51:19.370Z","etag":null,"topics":["github-actions","github-actions-docker","inference","iris-dataset","machine-learning","machine-learning-workflow","sklearn"],"latest_commit_sha":null,"homepage":"https://gaborvecsei.github.io","language":"Jupyter Notebook","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/gaborvecsei.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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":"2020-03-07T10:25:13.000Z","updated_at":"2023-11-09T18:48:42.000Z","dependencies_parsed_at":"2025-02-11T08:49:13.040Z","dependency_job_id":null,"html_url":"https://github.com/gaborvecsei/Machine-Learning-Inference-With-GitHub-Actions","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/gaborvecsei/Machine-Learning-Inference-With-GitHub-Actions","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gaborvecsei%2FMachine-Learning-Inference-With-GitHub-Actions","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gaborvecsei%2FMachine-Learning-Inference-With-GitHub-Actions/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gaborvecsei%2FMachine-Learning-Inference-With-GitHub-Actions/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gaborvecsei%2FMachine-Learning-Inference-With-GitHub-Actions/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gaborvecsei","download_url":"https://codeload.github.com/gaborvecsei/Machine-Learning-Inference-With-GitHub-Actions/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gaborvecsei%2FMachine-Learning-Inference-With-GitHub-Actions/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":281059645,"owners_count":26437056,"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","status":"online","status_checked_at":"2025-10-26T02:00:06.575Z","response_time":61,"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":["github-actions","github-actions-docker","inference","iris-dataset","machine-learning","machine-learning-workflow","sklearn"],"created_at":"2024-10-11T02:08:06.617Z","updated_at":"2025-10-26T04:31:47.977Z","avatar_url":"https://github.com/gaborvecsei.png","language":"Jupyter Notebook","readme":"# Machine Learning Inference with GitHub Actions\n\nThis repository demonstrated how you can use *Github Actions* to perform inference with your ML models. In this\nexample scenario a [Random Forest classifier](https://scikit-learn.org/stable/modules/generated/sklearn.ensemble.RandomForestClassifier.html)\nis used to make predictions trained on the [Iris dataset](https://en.wikipedia.org/wiki/Iris_flower_data_set).\n\n\u003cimg src=\"art/issue_comment_prediction.png\" alt=\"sample comment prediction\"\u003e\n\nThe GitHub Actions workflow is triggered when an issue receives a comment. If the comment contains the `/predict`\nprefix, then the `main.py` python file starts to parse the comment, make a prediction and construct the reply to the\noriginal comment with the prediction.\n\nExample (and also valid) comment: `/predict \u003csepal_length\u003e \u003csepal_width\u003e \u003cpetal_length\u003e \u003cpetal_width\u003e`\n(e.g. `/predict 5.6 2.9 3.6 1.3`)\n\n\u003cimg src=\"art/job_steps.png\" alt=\"job steps\"\u003e\n\n## Try it out :sunglasses:\n\nJust go to an issue at this repository and then leave a comment with the `/predict` prefic and then 4 numbers separated\nby spaces. Just like the example above.\n\n\u003e  /predict 5.6 2.9 3.6 1.3\n\n## Files\n\n- `action.yml`: Describes the action which build a Docker image and performs the comment parsing and inference\n- `.github/workflows/main.yaml`: contains the steps which are performed when a comment is received under an issue\n- `Dockerfile`: This is the image which will be built and used for the main action\n- `issue_comment.sh`: With this script you can send a comment with the GitHub Rest API\n- `main.py`: parses the content of the comment, loads model, makes prediction and constructs the reply message\n- `random_forest_model.pkl`: Serialized trained sklearn model which will be used for inference (btw. this file should\nnot be here, as model artifacts should be stored in a storage, but this is just a sample so... :smile:)\n\n## About\n\nGábor Vecsei\n\n- [Website \u0026 Blog](https://gaborvecsei.com)\n- [LinkedIn](https://www.linkedin.com/in/gaborvecsei)\n- [Twitter](https://twitter.com/GAwesomeBE)\n- [Github](https://github.com/gaborvecsei)\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgaborvecsei%2Fmachine-learning-inference-with-github-actions","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgaborvecsei%2Fmachine-learning-inference-with-github-actions","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgaborvecsei%2Fmachine-learning-inference-with-github-actions/lists"}