Smart Contracts¶
The Vault-K-NO system consists of three contract types. Each is fully specified in this section.
Contract Summary¶
| Contract | Instances | Role |
|---|---|---|
LiquidityVault |
1 | User-facing vault. All state, pricing, and redemption logic. |
MarketAdapter |
0–4 active | Per-market adapter. Venue-specific buy/sell/settle logic. |
HouseBuffer |
1 shared | Fee collector and reserve float provider. |
Deployment Addresses¶
Deployment details are provided in the Deployment section.
Interface Overview¶
LiquidityVault¶
// Investor functions
function deposit(uint256 assets, address receiver) external;
function requestWithdraw(uint256 shares, address receiver) external returns (uint256 requestId);
function cancelWithdraw(uint256 requestId) external;
// Keeper function
function processWithdrawals(uint256 maxCount) external;
// Governance functions
function openPosition(uint256 slotIndex, address adapter, uint256 assets, uint256 entryPrice, uint256 maturity) external;
function closePosition(uint256 slotIndex) external;
function writeOff(uint256 slotIndex) external;
function rebasePosition(uint256 slotIndex, uint256 newEntryPrice, uint256 newMaturity) external;
function reclaimSlot(uint256 slotIndex) external;
function emergencyLiquidate(uint256 slotIndex, uint256 maxShares) external;
// View functions
function totalManagedAssets() external view returns (uint256);
function sharePrice() external view returns (uint256);
function marketSharePrice() external view returns (uint256);
function paused() external view returns (bool);
function remainingDailyLiquidity() external view returns (uint256);
function positionInfo(uint256 slot) external view returns (Position memory);
function getRequest(uint256 requestId) external view returns (Request memory);
function queueDepth() external view returns (uint256);
MarketAdapter¶
function buyNoShares(uint256 assets) external returns (uint256);
function sellNoShares(uint256 shares) external returns (uint256);
function claimSettlement() external returns (uint256);
function currentPrice() external view returns (uint256);
function positionValue() external view returns (uint256);
function positionSize() external view returns (uint256);
function isSettled() external view returns (bool);