{"id":13566705,"url":"https://github.com/BlockTrainBuilders/BlockTrain","last_synced_at":"2025-04-04T00:32:01.898Z","repository":{"id":198861328,"uuid":"701333978","full_name":"BlockTrainBuilders/BlockTrain","owner":"BlockTrainBuilders","description":null,"archived":false,"fork":false,"pushed_at":"2024-04-08T15:08:56.000Z","size":273,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"main","last_synced_at":"2024-08-01T13:36:50.778Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","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/BlockTrainBuilders.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":"2023-10-06T12:26:07.000Z","updated_at":"2023-10-07T12:35:08.000Z","dependencies_parsed_at":null,"dependency_job_id":"7e9a6872-24ba-4af0-b837-ea62db8e773a","html_url":"https://github.com/BlockTrainBuilders/BlockTrain","commit_stats":null,"previous_names":["blocktrainbuilders/blocktrain"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BlockTrainBuilders%2FBlockTrain","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BlockTrainBuilders%2FBlockTrain/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BlockTrainBuilders%2FBlockTrain/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BlockTrainBuilders%2FBlockTrain/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/BlockTrainBuilders","download_url":"https://codeload.github.com/BlockTrainBuilders/BlockTrain/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":223075370,"owners_count":17083506,"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-08-01T13:02:15.032Z","updated_at":"2024-11-04T21:30:50.330Z","avatar_url":"https://github.com/BlockTrainBuilders.png","language":"TypeScript","funding_links":[],"categories":["TypeScript"],"sub_categories":[],"readme":"# Blocktrain Builders - Project Overview\n![BlockTrain](https://github.com/BlockTrainBuilders/BlockTrain/assets/80094928/8c1f52ab-23c6-407a-a393-8dd67bf99dcb)\n\n## BlockTrain enhances transparency and monetization in AI by embedding data ownership and revenue-sharing smart contracts on OKP4, coupled with controlled model access and insights into training data, leveraging Prolog and integrating with Akash for streamlined deployment.\n\n## Value Proposition\n\n### Transparency in Data Ownership:\nLeveraging Prolog within OKP4, BlockTrain aims to exhibit clear ownership of datasets. Each dataset is associated with a distinct identity, demonstrating who owns the dataset. This transparency is a significant shift from conventional models where data ownership and origins are often opaque. It provides users with a clearer understanding of data lineage and ownership.\n\n### Revenue Sharing through Smart Contracts:\nDataset owners have the opportunity to monetize their datasets by charging users who wish to utilize models trained on their data. Smart contracts on OKP4 manage the revenue-sharing agreements. This ensures that payments are automated, transparent, and fair, fostering a new economic ecosystem around AI and data.\n\n### Controlled Access to Models:\nBy utilizing Prolog rules on OKP4, BlockTrain governs who can access a particular AI model. Access control is managed via smart contracts, ensuring that only authorized individuals or entities can use the model. This approach secures the models and datasets against unauthorized access.\n\n### Insight into Model Training Data:\nBlockTrain offers users a \"look under the hood\" of the models, allowing them to understand the data on which they are trained. This initiative is a step towards more transparent AI. It enables users to have better insight into model behavior and biases, which is often missing in today's consumer AI implementations.\n\n### Akash Integration and Ease of Deployment:\nBlockTrain is integrated with Akash, ensuring a seamless and efficient deployment process. The integration facilitates easy deployment of AI models and datasets on the decentralized cloud. Moreover, BlockTrain provides code for automated orchestration, simplifying the deployment process and reducing manual intervention.\n\n## Repository Structure\n\n- **TrainingApp**: This directory contains Python scripts related to training models.\n  - `app.py`: A Python script for the training application.\n  - `train.py`: A Python script dedicated to training processes.\n  \n- **orchestrator**: Contains TypeScript source files for orchestrating various processes.\n  - `src/app.ts`: A TypeScript file for the orchestrator application.\n  \n- **src**: Contains the main source files for the application.\n  - `App.tsx`: A TypeScript React file for the main application.\n\n## Deployed Frontend\n\nhttps://block-train-rouge.vercel.app/ \n\n## How to run\n\n### A. to run AI container locally\n\n```text\n% source env.development.blocktrain.sh\n% make dev\n```\n\n### B. Building the Image and Deploying to Akash\n\n#### Setting Up GitHub Token\n\nBefore deploying to Akash, ensure you have set up a GitHub token for access to write to the container registry. Follow the instructions provided in the [GitHub documentation](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/managing-your-personal-access-tokens) to generate and manage your personal access tokens.\n\nOnce you have your token, log in using the following command:\n\n```text\n\necho \u003cTOKEN\u003e | docker login ghcr.io -u blocktrainbuilders --password-stdin\n\n```\n\n\n#### Setting Up Akash Wallet for Testing\n\nEnsure that your Akash wallet has a balance of more than 5AKT. Follow the steps below to set up your wallet:\n\nUse the mnemonic phrase of your wallet, Then, generate and publish the client certificate:\n\n\n```text\n\nprovider-services tx cert generate client --from blocktrain\nprovider-services tx cert publish client --from blocktrain\n\n```\nTo deploy to Akash, source the environment and deploy:\n```text\n\nsource env.staging.blocktrain.sh\nmake deploy-staging\n\n\n```\n\n\n## Functionality of the Image (app.py)\n\nThe image performs the following tasks:\n\n1. Processes environment variables.\n2. Queries OKP4 to check authentication (validates against environment variables) and retrieves data paths and training parameters.\n3. Retrieves the necessary data.\n4. Trains the AI model.\n5. Makes the trained model publicly available via ports 5000 and 80.\n\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FBlockTrainBuilders%2FBlockTrain","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FBlockTrainBuilders%2FBlockTrain","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FBlockTrainBuilders%2FBlockTrain/lists"}