{"id":17017259,"url":"https://github.com/kidneyweakx/gohan-layer","last_synced_at":"2025-07-11T00:33:16.058Z","repository":{"id":237903293,"uuid":"795461291","full_name":"kidneyweakx/gohan-layer","owner":"kidneyweakx","description":"A proof generate reward system","archived":false,"fork":false,"pushed_at":"2024-05-04T16:42:26.000Z","size":17309,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-22T15:36:09.201Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://gohan-layer.pages.dev","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/kidneyweakx.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":"2024-05-03T10:31:57.000Z","updated_at":"2024-05-04T16:42:29.000Z","dependencies_parsed_at":"2024-05-03T14:50:49.871Z","dependency_job_id":"75b95e39-baa3-481f-99d7-5fc2e5def48b","html_url":"https://github.com/kidneyweakx/gohan-layer","commit_stats":null,"previous_names":["kidneyweakx/gohan-layer"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/kidneyweakx/gohan-layer","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kidneyweakx%2Fgohan-layer","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kidneyweakx%2Fgohan-layer/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kidneyweakx%2Fgohan-layer/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kidneyweakx%2Fgohan-layer/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/kidneyweakx","download_url":"https://codeload.github.com/kidneyweakx/gohan-layer/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kidneyweakx%2Fgohan-layer/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":264697543,"owners_count":23650954,"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-10-14T06:36:08.032Z","updated_at":"2025-07-11T00:33:15.977Z","avatar_url":"https://github.com/kidneyweakx.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# \n\n\u003cdiv align=\"center\"\u003e\n\u003ch1\u003eGohan Layer\u003c/h1\u003e\n\u003cp\u003eA future proof generate reward system\u003c/p\u003e\n\u003cimg src=\"./apps/web/src/assets/logo.png\" width=\"50%\" height=\"50%\"\u003e\u003c/img\u003e\n\n[![License: ](https://img.shields.io/github/license/kidneyweakx/gohan-layer\n)](./LICENSE)\n\u003c/div\u003e\n\n### Demo Page\n- WebPage: [gohan-layer.page.dev](https://gohan-layer.pages.dev/)\n- Contract Address\n  + Base: https://sepolia.basescan.org/address/0x47f2b8e6483Cb8FCcd937d8bCC70390a5d334e77#code\n  + Mantle: https://explorer.sepolia.mantle.xyz/address/0x47f2b8e6483Cb8FCcd937d8bCC70390a5d334e77#code\n  + Polygon Cardona https://cardona-zkevm.polygonscan.com/address/0xe3a6b8Da8932354592E7F3f6199b82D6E2bdBDb2#code\n  + OP Avail: https://op-avail-sepolia-explorer.alt.technology/address/0x8E42aB07232757CC0DA117d2846ff981E3eDCbdF#code\n- Token Contract Address: [packages/contract/README.md](./packages/contract/README.md)\n\n\n### Abstract\nGohan-Layer is a liquidity pool leveraging a Data Availability Layer (DA) to generate and validate transaction proofs.\n\n- Problem Settlement:\n  + **Lack of liquidity**: current DeFi solutions struggle with seamless operations across different layer 2.\n  + **Lack of transparency**: Lots of people rely on Exchange to swap their token.\n  + **High entry barriers in new chain**: New chain and learn new token.\n- Soultion:\n  + **Avail DA(Enhanced transparency )**: Using DA as our proof storage, everyone can verify it.\n  + **SP1 ZKVM(Enhanced Safety)**: Use ZK to prove the actions on chain make it more secure.\n  + **Lower Barriers**: miner will send money to your other chain account, it can be the chain expert in the fastest time!\n   \n### Build \u0026 Installation\n| GohanLayer is a monorepo managed using `turbo`. You can find the source code for each package in the `apps` and `packages` directory.\n- apps`\n  + `apps/circuits` is the SP1 ZK circuits use for eigenlayer withdraw proof and also publish to DA\n  + `apps/web` is the web frontend. It built by frontend template, `wagmi` and `vite`\n- `packages`\n  + `packages/contract` is the miner register contract and the test ERC20 token for test.\n\n### Step By Step\n1. Install all peer dependencies\n```bash\npnpm install\n```\n\n2. Build only frontend\n```bash\npnpm build --filter web\n```\n\n3. Deploy Contract\n```bash\ncd packages/contract\npnpm deploy:token --networks \u003cYOUR_NETWORK\u003e\npnpm deploy:miner --networks \u003cYOUR_NETWORK\u003e\n```\n\n4. Run the ZK Circuits\n```bash\ncd apps/circuits/script\ncargo clean \u0026 cargo update\nRUST_LOG=info cargo run --release\n```\n### Sequence Diagram\n```mermaid\nsequenceDiagram\n    actor U as User\n    actor M as Miner\n    participant C as MinerToken\n    participant L as LendingPool\n    participant S as SP1-ZKvm\n    participant DA as Avail-DA\n\n    %% User \n    U -\u003e\u003e+ L: Stake some collateral into pool\n    L --\u003e\u003e- M: Listen event and get tx hash\n    \n    %% Contract\n    M -\u003e\u003e C: Register as a miner (stake token)\n    M -\u003e\u003e+ S: use SP1 to generate zk proof (withdraw)\n    S -\u003e\u003e+ DA: Submit Compress zkProof to DA\n    DA --\u003e\u003e- M: Query Proof data and can let everyone verify\n    M -\u003e\u003e+ L: Send Proof and avail hash for verify\n    \n    %% Withdraw\n    U -\u003e\u003e L: After prove collateral can lend money in other pool according collateral\n```\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkidneyweakx%2Fgohan-layer","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkidneyweakx%2Fgohan-layer","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkidneyweakx%2Fgohan-layer/lists"}