Skip to content

LeoYeAI/agent-master-skills / skills/aavegotchi-gbm-skill

aavegotchi-gbm-skill

Verified

View, create, cancel, bid, and claim Aavegotchi GBM auctions on Base mainnet (8453). Subgraph-first discovery (Goldsky), with onchain verification + execution via Foundry cast. Safety-first: DRY_RUN defaults to 1 (simulate with cast call; only broadcast with cast send when DRY_RUN=0 and explicitly instructed).

FileKindSize
SKILL.mdskill md16.3 KB
_meta.jsonconfig299 B
references/addresses.mdmarkdown1.7 KB
references/bid-math.mdmarkdown1.8 KB
references/logs.mdmarkdown1.7 KB
references/presets.mdmarkdown1.1 KB
references/recipes.mdmarkdown3.8 KB
references/subgraph.mdmarkdown3.3 KB
references/swap-math.mdmarkdown2.8 KB

references/bid-math.md

View on GitHub
# Bid Math (Minimum Next Bid)

When bidding (`commitBid` / `swapAndCommitBid`), you must:
- Pass the exact current onchain `highestBid` as the `_highestBid` argument (else revert `UnmatchedHighestBid`).
- Bid at or above the contract's effective minimum step, based on preset `stepMin` and `bidDecimals`.

## Effective Minimum Next Bid (Matches Onchain Behavior)

The incentives math uses:
```
baseBid = highestBid * (bidDecimals + stepMin) / bidDecimals
```

If `newBid < baseBid`, the incentives calculation underflows and the bid reverts.

Additionally, if the auction has `startingBid` set, the bid must be:
- `bidAmount >= startingBid`

So the safe minimum is:
```
minNextBid = max(startingBid, baseBid)   (and baseBid is forced to >= 1 when highestBid is 0)
```

### Python Helper (Recommended)

Provide:
- `highestBid` (from onchain `getAuctionHighestBid`)
- `startingBid` (from onchain `getAuctionInfo`, or from subgraph `startBidPrice`)
- `bidDecimals` and `stepMin` (from onchain getters or subgraph fields)

```bash
python3 - <<'PY'
highest_bid = int("<HIGHEST_BID_GHST_WEI>")     # replace
starting_bid = int("<STARTING_BID_GHST_WEI>")   # replace (0 if none)
bid_decimals = int("<BID_DECIMALS>")            # e.g. 100000
step_min = int("<STEP_MIN>")                    # e.g. 5000

base_bid = (highest_bid * (bid_decimals + step_min)) // bid_decimals
if base_bid == 0:
    base_bid = 1

min_next = max(starting_bid, base_bid)
print("minNextBid (GHST wei):", min_next)
PY
```

## Interpreting Presets (Rule of Thumb)

On Base mainnet, presets typically use:
- `bidDecimals = 100000`
- `stepMin` of `1000`, `5000`, or `10000`

This corresponds to a minimum step of roughly:
- `1%`, `5%`, or `10%` (because `stepMin / bidDecimals`)

Verify per-auction via subgraph fields or onchain getters:
- `getAuctionBidDecimals(auctionId)(uint256)`
- `getAuctionStepMin(auctionId)(uint64)`
reverse-engineer-anythingmorluto/reaReverse engineer native, managed, Electron/JavaScript, packaged, firmware, and browser targets with REA, and build agent environments (AgentEnv bundles) of web applications from a live instance or a capture, and of Linux desktop apps with a task from a request. Use shipped-artifact or requested runtime evidence to explain features, compare versions, decompile code, or guide a reconstruction. Skip REA for ordinary source-repository architecture analysis.Stars: 472kUpdated Claude CodeCodexVerifiedInstall
diagnosing-superpowersobra/superpowersUse when a superpowers session went wrong and your human partner wants to know why — repeated work, ignored plans, stumbles, poor results, a skill that didn't fire, "it took too long", "why is it so expensive", "what is it doing" — or wants to build a bug report for the superpowers maintainers, for the current session or a past one identified by id or path, on any harness.Stars: 322kUpdated Claude CodeCodexVerifiedInstall
dispatching-parallel-agentsobra/superpowersUse when facing 2+ independent tasks that can be worked on without shared state or sequential dependenciesStars: 322kUpdated Claude CodeCodexVerifiedInstall
executing-plansobra/superpowersUse when executing an implementation plan in the current session as the implementer yourself — your human partner chose inline execution, or no subagent tool is availableStars: 322kUpdated Claude CodeCodexVerifiedInstall