{"id":18841516,"url":"https://github.com/subvisual/space-warp-hackathon","last_synced_at":"2026-01-30T11:30:16.815Z","repository":{"id":104933739,"uuid":"591043310","full_name":"subvisual/space-warp-hackathon","owner":"subvisual","description":"Cosmic Chicken repo for the FVM Space Warp hackathon","archived":false,"fork":false,"pushed_at":"2023-02-27T10:46:12.000Z","size":61,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2024-12-30T10:43:32.190Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://cosmic-chicken.finiam.com","language":"Solidity","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/subvisual.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}},"created_at":"2023-01-19T19:53:37.000Z","updated_at":"2023-07-31T11:34:40.000Z","dependencies_parsed_at":null,"dependency_job_id":"e6b9bb17-d1c3-4bdc-bcea-7853e23be0d3","html_url":"https://github.com/subvisual/space-warp-hackathon","commit_stats":null,"previous_names":["subvisual/space-warp-hackathon"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/subvisual%2Fspace-warp-hackathon","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/subvisual%2Fspace-warp-hackathon/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/subvisual%2Fspace-warp-hackathon/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/subvisual%2Fspace-warp-hackathon/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/subvisual","download_url":"https://codeload.github.com/subvisual/space-warp-hackathon/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239780122,"owners_count":19695734,"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-11-08T02:51:39.098Z","updated_at":"2026-01-30T11:30:16.765Z","avatar_url":"https://github.com/subvisual.png","language":"Solidity","readme":"# [Cosmic Chicken](https://cosmic-chicken.finiam.com)\n\n![image](https://user-images.githubusercontent.com/2940022/217004391-0823b9ca-8d0a-44ed-ab63-512f36391052.png)\n\n\n## Motivation\n\nOne of the current challenges in the Filecoin network is the lack of lending options.\nThis is particularly relevant for the onboarding of new Storage Providers (SPs) to the network.\n\nIn order for a Storage provider to be accepted into the network, it first needs to deposit a large amount of collateral.\nThe collateral needed is directly related to how much storage a new SP aims to provide to the network. The more storage, the higher\nthe collateral needed. \n\nAlso, the Filecoin network has a large base of long-term token holders that are willing to lend their FIL to reputable and growth-oriented SPs.\nIn the past, some lending partners have stepped up in order to provide this collateral but they are not able to service everyone.\n\nWith undercollateralized lending, lenders can help provide the collateral needed for the onboarding of a storage provider, while being exposed\nto the opportunity of getting some yield on their loan. This yield comes from mining new blocks by the storage providers. The rewards from that\nare sent to our protocol until the storage providers have repaid their loan.\n\nLastly, [Chicken Bonds](https://www.chickenbonds.org/) can help provide liquidity to a new protocol. This can be used as a way to bootstrap the\nprotocol liquidity.\n\nWith the Cosmic Chicken project we aim to solve this issue by applying the use of the novel Chicken Bonds mechanism to the Filecoin network\nas a way to kickstart the Filecoin lending ecosystem.\n\n## How it works\n\nStorage providers can borrow collateral from the Pool\n\nLenders can provide liquidity to the Pool by minting a bond\n\nIn order to request a loan, an SP first needs to deposit 50% of the full amount needed to the Cosmic Chicken Staking Pool.\nOur protocol will lock the future income coming from the block rewards until the storage provider have repaid their loan.\nAfter that, our protocol deposits the full amount needed by the SP on its behalf.\n\n![image](https://user-images.githubusercontent.com/2940022/217022584-609abbdc-1bfc-4ca1-ba6a-1deb98bce63b.png)\n\n### Cosmic Chicken Bond\n\n- Standard ERC-721 token, that represents a loan by the lender.\n- Lenders can decide to `Chicken In`, by relinquishing the initial capital and getting the yield generated by the protocol\n- Lenders can also `Chicken Out`, by relinquishing the accumulated yield and getting the initial capital back\n- The rewards generated from the mining of new blocks from the Storage Providers are sent to the Pool, generating yield.\n\n![image](https://user-images.githubusercontent.com/2940022/217019616-a851e092-1a97-46c5-94f1-04658a4bed13.png)\n\n### Cosmic Chicken internal logic\n\n- All funds deposited by lenders are stored in the `Pending Bucket`\n- The `Permanent Bucket` stores the funds acquired by the protocol from users that have `Chicken In` or `Chicken Out`\n- `Reserve Bucket` keeps the yield generated from `Pending` and `Permanent` buckets\n- `$vbFIL` is the virtual balance representing a claim of the `Reserve Bucket`\n- `$bFIL` is the token minted that can claim ETH from the `Reserve Bucket` at a redemption price\n\n## How we made it\n\n### Smart contracts\n\nWe used a [Foundry](https://github.com/foundry-rs/foundry) project in order to develop the smart contracts needed for this project.\n\nYou can check the deployed contracts in Hyperspace here:\n\nBond: `0xdB1819F57d9023a948da930C10dea248CdBfdad8`\n\nPool: `0x7c75BCC74204696f513A3412a4A039f6D319b6C6`\n\nbFIL: `0x7cb38f2139Eb8830DEb7aB9650Cf655CE48d8D2F`\n\nChickenBondManager: `0x60361121F74cE943D5cAFe0FBb98315A2eb2095b`\n\n### Frontend\n\nFor the frontend, we created a [Next.js](https://github.com/vercel/next.js/) app. We used `ethers.js` and `wagmi` for the \nsmart contract and wallet interactions needed\n\nThe repo for the frontend is in the `frontend` folder as a submodule but also [here](https://github.com/finiam/cosmic-chicken-frontend) \nas its own project.\n\nIt is deployed using [Netfliy](https://netlify.com) and you can check it at https://cosmic-chicken.finiam.com\n\n### NFT.Storage\n\nFor the visual representation of NFTs for Chicken Bonds, we used [NFT.Storage](https://nft.storage) in order to host the assets\n\n---\n\n\nProject for the [FVM Space Warp hackathon](https://ethglobal.com/events/spacewarp) by ETHGlobal\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsubvisual%2Fspace-warp-hackathon","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsubvisual%2Fspace-warp-hackathon","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsubvisual%2Fspace-warp-hackathon/lists"}