Deploy and interact with Cap Staking contracts to let $CAP holders lock tokens and earn proportional rewards based on lock duration
Convert $CAP into sCAP and then CAPU to grant yourself daily AI compute credits on the Capminal platform
Study the streaming reward distribution mechanism for a real-world upgradeable vault implementation in Solidity
Fork the monorepo structure as a starting point for a multi-module Foundry + OpenZeppelin smart contract project
Requires Foundry toolchain and familiarity with Base blockchain deployment, $CAP token interaction needs a funded wallet on Base mainnet.
This repository contains the open-source smart contracts for the Capminal protocol. Smart contracts are programs that run on a blockchain network and execute automatically according to their written rules. Capminal is built on the Base blockchain network and revolves around a token called $CAP. The repository has two main modules. The first is Cap Staking, which lets holders lock up their $CAP tokens for a chosen period of time. Longer lock durations earn a larger share of rewards, with a multiplier that ranges from 1x for short locks up to 5x for longer commitments. The actual reward distribution happens off-chain, with the on-chain contract tracking each person's share. The second module is the CAPU Vault, which introduces a two-step process to convert $CAP into AI compute credits. First, you stake $CAP and receive sCAP in return, a non-transferable receipt token that represents your locked position. Then you lock sCAP to mint CAPU, a compute asset that grants $1 per day of AI access credits on the Capminal platform. The contracts also distribute $CAP rewards to sCAP holders using a streaming mechanism. The vault contracts are designed to be upgradeable over time without redeploying. The project is organized as a monorepo where each module lives in its own folder with its own build configuration. Building and testing uses a Solidity development tool called Foundry. Dependencies come from well-known open-source libraries including OpenZeppelin. The $CAP token is already deployed on Base mainnet. The repository is published under the MIT license.
← capminal on gitmyhub — every repo by this author, as a profile.
Verify against the repo before relying on details.