Comet Collateral

Configure collateral assets, factors, and supply caps for the Comet V3 protocol.

Updated Jan 28, 2026
One-click install
npx skills add https://github.com/cyotee/compound-V3-comet-skill --skill comet-collateral
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: Comet Collateral
Source: https://github.com/cyotee/compound-V3-comet-skill/tree/main/.opencode/skills/comet-collateral
Command: npx skills add https://github.com/cyotee/compound-V3-comet-skill --skill comet-collateral

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Comet Collateral explains how the V3 collateral system works, including multiple collateral assets, per-asset price feeds, borrow and liquidate factors, asset bit vectors, and supply caps, to ensure safe borrowing and liquidation behavior.

Core Features & Use Cases

  • Asset configuration: per-asset price feed, decimals, borrowCollateralFactor, liquidateCollateralFactor, liquidationFactor, and supplyCap.
  • Collateral accounting: tracks per-user balances and the assetsIn bit vector to determine borrowing power.
  • Safe borrowing and liquidation: provides checks for borrowing collateralization and liquidatability based on configured factors.
  • Efficient storage and retrieval: describes packed asset storage and AssetInfo lookups.

Quick Start

Add AssetConfig entries for your collateral tokens and use getAssetInfo to verify the stored values. Then run test scenarios to validate borrowing and liquidation logic using borrowCollateralFactor and liquidationFactor.

Frequently Asked Questions about Comet Collateral

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I configure multiple collateral assets in Comet V3?

Configuring Comet V3 collateral involves defining AssetConfig structs for each token, specifying price feeds, decimals, borrow and liquidate collateral factors, liquidation factors, and supply caps.

How does Comet V3 track user collateral balances and borrowing power?

Comet V3 tracks user borrowing power by maintaining per-user balances alongside an assetsIn bit vector, which determines the specific collateral assets a user has supplied.

What is the difference between borrowCollateralFactor and liquidateCollateralFactor in Comet?

In Comet, borrowCollateralFactor determines the maximum borrowing power against an asset, while liquidateCollateralFactor sets the collateralization threshold required to trigger liquidation behavior.

How do I retrieve asset configuration details from Comet's packed storage?

Retrieve asset configuration details from Comet's packed storage by using the getAssetInfo function, which unpacks and returns the stored asset configuration values for verification.

Can I validate safe borrowing and liquidation logic using Comet collateral factors?

Yes, you can validate safe borrowing and liquidation logic by running test scenarios that check collateralization and liquidatability based on the configured borrow and liquidate factors.