Overview
Commune proposes a pooled, non-custodial vault. Depositors receive shares that track their part of the pool. Autonomous agents allocate the pool's assets across approved lending markets and exchanges, inside limits written into the policy contract.
The proposed allocation process is designed to follow explicit rules. The intended design records each allocation and its inputs. Replayability depends on implementation and availability of the underlying data.
Proposed deposit flow
Illustrative flow only. No live app, contract address or deposit functionality is verified in this release.
- 1Open the app and connect a wallet.
- 2Pick the vault asset and the amount. The app shows the current policy and the last ten decisions before you confirm.
- 3Approve the token, then deposit. Shares arrive in your wallet in the same transaction.
- 4To exit, request a withdrawal. It settles at the end of the current epoch, then you claim the assets.
Key concepts
- Pool
- All deposited assets, held by the vault contract.
- Share
- A token representing a proportional claim on pool assets; its fraction changes as shares are minted or burned.
- Venue
- An approved lending market or exchange where the pool may hold assets.
- Epoch
- One allocation cycle. Withdrawal requests target settlement at its end; deposit timing remains a design choice.
- Policy
- The on-chain list of limits every agent must respect.
- Reserve
- The part of the pool kept idle in the vault to pay withdrawals.
Architecture
The proposed architecture contains five contract components. Asset-moving permissions and policy enforcement must be verified in implementation.
| Contract | What it does | Moves assets |
|---|---|---|
| CommuneVault | Holds the pool, mints and burns shares | yes |
| CommunePolicy | Stores parameters and the timelock queue | no |
| AgentExecutor | Runs agent actions after checking the policy | yes |
| VenueAdapter | One per venue, translates deposits and withdrawals | no |
| DecisionLog | Append-only record of every decision and its inputs | no |
Epoch lifecycle
An epoch lasts six hours under the draft policy. Its steps always run in the same order.
| Offset | Step | Done by |
|---|---|---|
| +00:00 | Snapshot rates, utilization and depth at every venue | Allocator |
| +00:05 | Score venues and compute target weights | Allocator |
| +00:10 | Match deposits against withdrawals | Clearer |
| +00:15 | Move the net amount toward target weights | Allocator |
| +00:20 | Write the decision and its inputs hash | Recorder |
| always | Watch oracles and venue health, pause on breach | Sentinel |
Agent permissions
Each agent holds one role in the executor. Roles are fixed in the contract and cannot be widened by a policy change.
| Agent | Read venues | Move assets | Pause venue | Change policy |
|---|---|---|---|---|
| Allocator | yes | within caps | no | no |
| Sentinel | yes | no | yes | no |
| Clearer | no | vault only | no | no |
| Recorder | yes | no | no | no |
Policy parameters
Values are stored in seconds and basis points. A change is queued with queue(key, value) and can be executed only after the timelock passes.
| Key | Draft value | Meaning |
|---|---|---|
| epoch_length | 21600 | Six hours per epoch |
| max_venue_share | 3500 | Proposed cap per venue: 35% of the pool |
| reserve_floor | 1000 | At least 10% stays idle in the vault |
| oracle_halt | 200 | Pause a venue if two price sources differ by 2% |
| withdraw_queue_max | 1 | Target settlement within one epoch, subject to liquidity |
| timelock | 604800 | Seven days between queueing and executing a change |
Withdrawals and netting
Withdrawal requests are paid first from new deposits arriving in the same epoch, then from the reserve, and only then from venues. Most of the time, only the difference between the two flows reaches the market.
Example epoch
Without netting, 2,100,000 would have moved through venues. Figures are an example, in units of the vault asset.
Fees
Fees are policy parameters, so they follow the same timelock as every other limit. Rates remain unspecified; publish them before any deployment.
| Deposit fee | Not yet published |
| Withdrawal fee | Not yet published |
| Performance fee on yield | Not yet published |
Contracts
Addresses will be listed here after deployment. The proposed interface borrows ERC-4626 conventions and adds asynchronous withdrawal requests. Full standards compliance has not been verified.
| Contract | Address |
|---|---|
| CommuneVault | Not yet published |
| CommunePolicy | Not yet published |
| AgentExecutor | Not yet published |
| DecisionLog | Not yet published |
ICommuneVault.sol, draft
interface ICommuneVault {
function deposit(uint256 assets, address receiver) external returns (uint256 shares);
function requestWithdraw(uint256 shares) external returns (uint256 requestId);
function claim(uint256 requestId) external returns (uint256 assets);
function totalAssets() external view returns (uint256);
function currentEpoch() external view returns (uint64);
}
Events and decision log
Every agent action emits an event. The inputs hash points to the full snapshot the agent used, published alongside, so any decision can be recomputed and compared.
DecisionLog events
event Allocated(uint64 indexed epoch, address indexed venue, int256 delta, bytes32 inputsHash); event Netted(uint64 indexed epoch, uint256 deposits, uint256 withdrawals); event VenuePaused(address indexed venue, uint8 reason); event PolicyQueued(bytes32 indexed key, uint256 value, uint64 eta);
Reading allocations with viem
import { createPublicClient, http, parseAbiItem } from 'viem'
const client = createPublicClient({ transport: http(RPC_URL) })
const logs = await client.getLogs({
address: DECISION_LOG,
event: parseAbiItem(
'event Allocated(uint64 indexed epoch, address indexed venue, int256 delta, bytes32 inputsHash)'
),
fromBlock: 0n,
})
Glossary
- Basis point
- One hundredth of a percent. 3500 bps is 35%.
- Hurdle rate
- The risk-adjusted yield a venue must beat to receive capital.
- Inputs hash
- A fingerprint of the market data an agent used for a decision.
- Netting
- Matching deposits and withdrawals so only the difference moves.
- Timelock
- A required wait between announcing a change and applying it.
- Utilization
- The share of a lending market's supply that is currently borrowed.
FAQ
Can the team move my funds?
The intended design restricts asset movement to policy-checked execution. These permissions and the seven-day timelock still require implementation and verification.
Why can't I withdraw instantly?
Withdrawals settle at the end of the epoch so they can be netted against deposits. One epoch is the target settlement window; actual settlement depends on available liquidity and system health.
What happens if a venue is exploited?
The proposed 35% venue cap limits direct exposure to one venue, not total losses or correlated risks. The Sentinel pauses the venue and no new capital goes in.
Is Commune audited?
Not yet. Audit status and known risks are kept up to date on the security page.