GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - use-peg/peg-pools: Claude Code skill: deploy, register and seed a Peg Pool for a tokenized stock on Robinhood Chain — two wallet signatures, no private keys

BranchesTags
Open more actions menu

Latest commit

 

History

10 Commits
10 Commits

Folders and files

NameName
Last commit message
Last commit date
.claude-plugin
.claude-plugin
 
 
.github/workflows
.github/workflows
 
 
scripts
scripts
 
 
skills/peg-pools
skills/peg-pools
 
 
tests
tests
 
 
.gitignore
.gitignore
 
 
LICENSE
LICENSE
 
 
README.md
README.md
 
 
package.json
package.json
 
 

Repository files navigation

peg-pools

A Claude Code skill (and its own plugin marketplace) that gives a developer a Peg Pool for one of ten tokenized stocks on Robinhood Chain (chain id 4663) after one prompt and two wallet signatures: a zero-fee PegAsset wrapper plus a PegPool (the frozen peg-v8 PegRevenuePool), registered with Peg and visible on usepeg.trade under Community with the server-derived "Peg v8 verified" chip, the deployer-declared "Built with peg-pools" label and an executor chip. Seeding liquidity is a follow-up prompt.

Stocks: NVDA, AAPL, GOOGL, MSFT, AMZN, TSM, SPCX, AVGO, META, TSLA.

The skill never handles keys. Transactions are prepared by scripts, verified against pinned bytecode hashes, shown to you, and signed in your own browser wallet on a loopback page (or in your own shell with --print-only). Nothing in this repository can sign or broadcast, and CI fails if that ever changes.

Install

Claude Code, from any project:

/plugin marketplace add use-peg/peg-pools
/plugin install peg-pools@peg-pools

Local checkout, for development or review:

git clone https://github.com/use-peg/peg-pools
cd your-project
claude --plugin-dir /path/to/peg-pools

(from inside this repository: claude --plugin-dir ./).

Requirements: Node 20 or newer on the machine running Claude Code, a browser wallet (any EIP-1193 provider such as MetaMask) holding a little ETH on Robinhood Chain, and, only for seeding, the stock token and USDG in that wallet. Zero npm dependencies; nothing is installed.

Use

add a Peg Pool for NVDA to my project

Claude then: checks the environment (refuses when a variable name looks like a key, checks Node and the chain, compares Peg's pin manifest with the pins shipped in the plugin); asks for a public wallet address and a short tag (acme gives the symbol pNVDA-acme); prepares the wrapper plan, shows the decoded constructor, predicted address and fee, and asks before opening the signing page; confirms the wrapper with Peg; repeats for the pool; prints the status and the card link; writes peg-pool.json, git-ignores .peg/, and offers a README badge.

Follow-up:

seed it with 1 NVDA and 180 USDG

One signing session, up to five transactions (approve, wrap, approve0, approve1, addLiquidity), each built only after the previous receipt is verified.

Demo transcript

The full session, including the seeding follow-up and the ops step that flips the executor chip to live, is in examples/demo-transcript.md. Condensed (addresses and hashes are synthetic):

$ check-env.mjs
secrets in environment: none
node >= 20: v20.17.0
rpc eth_chainId: 0x1237
manifest: matches local pins (peg-v8, 10 stocks, minSkillVersion 1.0.0)
peg-pools 1.0.0: OK

$ prepare.mjs --stock NVDA --account 0x1111111111111111111111111111111111111111 --tag acme --step wrapper
Contract creation: PegAsset("0xd0601CE157Db5bdC3162BbaC2a2C8aF5320D9EEC", "0x1111111111111111111111111111111111111111", "0", "0", "Peg NVDA acme", "pNVDA-acme")
Predicted address: 0xb35b8b030a4BC592Ea8ccf3684512CE083f108dC
Nonce: 3
Estimated fee: 0.00016 ETH
Plan written: /home/dev/acme-app/.peg/nvda/wrapper.plan.json (expires 2026-09-14T12:05:00.000Z)

Claude: The wrapper plan verified against the pinned PegAsset creation bytecode … Shall I open the signing page so you can sign it in MetaMask? Developer: yes

$ sign.mjs /home/dev/acme-app/.peg/nvda/wrapper.plan.json
Sign page: http://127.0.0.1:52731/9f1c0b4a…e7d2/
Transaction 0x051a5c96…0074 verified: created 0xb35b8b030a4BC592Ea8ccf3684512CE083f108dC in block 18432107.
$ confirm.mjs --stock NVDA --step wrapper
wrapper registered: 0xb35b8b030a4BC592Ea8ccf3684512CE083f108dC (https://robinhoodchain.blockscout.com/address/0xb35b8b030a4BC592Ea8ccf3684512CE083f108dC)

$ prepare.mjs --stock NVDA --step pool
Contract creation: PegPool("0xb35b8b030a4BC592Ea8ccf3684512CE083f108dC", "0x5fc5360D0400a0Fd4f2af552ADD042D716F1d168", "pNVDAacme-USDG-LP")
Predicted address: 0xE52DD5d8BaB96cAcdE411Df0F1Fc4d5075eb563c
$ sign.mjs /home/dev/acme-app/.peg/nvda/pool.plan.json
$ confirm.mjs --stock NVDA --step pool
pool registered: 0xE52DD5d8BaB96cAcdE411Df0F1Fc4d5075eb563c (…)
Card: https://usepeg.trade/app?tab=pools&screen=open&scope=community&pool=0xE52DD5d8BaB96cAcdE411Df0F1Fc4d5075eb563c

$ status.mjs --pool 0xE52DD5d8BaB96cAcdE411Df0F1Fc4d5075eb563c
NVDA stock pool by acme (0x1111111111111111111111111111111111111111)
built with: peg-pools 1.0.0
executor: queued (Peg ops attach a flash executor at their discretion; not guaranteed)
reserves: waiting for liquidity
card: https://usepeg.trade/app?tab=pools&screen=open&scope=community&pool=0xE52DD5d8BaB96cAcdE411Df0F1Fc4d5075eb563c

$ generate.mjs --stock NVDA
Wrote /home/dev/acme-app/peg-pool.json
Added .peg/ to .gitignore

The seeding follow-up signs five call transactions in one page session; the card then shows reserves: 1 pNVDA-acme + 180 USDG, and after Peg ops attach a flash executor the chip reads executor: live.

What ends up in your repo

  • peg-pool.json — chain, stock, tag, deployer, wrapper and pool (address, transaction hash, creation block, runtime code hash, explorer links), the card link, builtWith. See examples/peg-pool.json.
  • An optional README badge, "Built with peg-pools", linking to your card.
  • .peg/ (plans, receipts, records, state), added to .gitignore.

Security model, briefly

  • No signer anywhere. The read-only JSON-RPC client allows eight eth_* read methods and throws on anything else; the scripts never call eth_sendRawTransaction, eth_sign, personal_sign or eth_signTransaction, never import a wallet library, never run cast/forge for you.
  • Keys are never requested, read or stored; check-env.mjs refuses to run while an environment variable name matches PRIVATE_KEY|MNEMONIC|SEED|KEYSTORE, printing names only. The skill instructs Claude never to read .env*, keystore or wallet files.
  • Every plan is verified three times before a signature: by prepare.mjs, by sign.mjs and by the page in the browser, against the creation-bytecode hashes and catalog in assets/pins.json (the immutable layouts are pinned there for the manifest comparison check-env.mjs runs, not for plan verification). Call plans are restricted to four selectors, four targets, exact approvals (never unlimited), your own account as recipient and a 30-minute deadline.
  • The signing page binds to 127.0.0.1 on an ephemeral port behind a random path token, with a strict CSP and no external resources; the plan is served as JSON, never inlined.
  • API and RPC base URLs are constants; overrides exist only as explicit --api-base/--rpc-url flags (loopback or https) that print a NON-PRODUCTION banner. No environment override.
  • Peg's confirm route is the registration authority: it re-derives the calldata from the frozen artifact, verifies the canonical receipt and attests the deployed runtime bytecode. The skill's checks are a pre-flight.

PegRevenuePool.sol, PegFlashExecutor.sol and their frozen artifacts are not published; this repository ships ABIs, pinned hashes and layouts only, and never compiles.

What to expect from the pool

  • The wrapper charges 0 bps to wrap and unwrap; the pool's swap fee is the fixed 30 bps, retained in the pool for its LPs.
  • Peg ops may attach a Peg-operated flash executor to pools that hold liquidity for a while; it trades only when a route is profitable after gas compensation and only at their discretion. Arbitrage surplus, when it happens, is credited to the pool. The chip shows queued until then; nothing about it is promised.
  • LPs bear inventory risk. Robinhood stock tokens may be transfer-restricted: a wallet that cannot hold the stock token can deploy but never seed.
  • "Peg v8 verified" means the runtime bytecode matched the frozen peg-v8 artifact at registration. "Built with peg-pools" is a label this tool declares. Neither is a Peg endorsement or audit of the deployer.

Repository layout

.claude-plugin/plugin.json, marketplace.json   plugin + marketplace manifests (this repo is both)
skills/peg-pools/SKILL.md                      the skill: step machine, signature, key, secrets and claims rules
skills/peg-pools/scripts/*.mjs                 check-env, prepare, sign, confirm, status, seed, generate
skills/peg-pools/scripts/lib/*.mjs             keccak (vendored), evm, rpc (read-only), api, preflight, sign-server, …
skills/peg-pools/assets/                       pins.json, frozen ABIs, sign page, templates
skills/peg-pools/references/                   flow, signing-policy, stocks, economics, api, errors
skills/peg-pools/examples/                     demo-transcript.md, peg-pool.json
skills/peg-pools/evals/evals.json              graded evals + trigger/no-trigger prompts (stripped at packaging)
scripts/ci-guard.sh                            the no-signer deny-grep
scripts/quick_validate.py                      vendored SKILL.md frontmatter validator (Apache-2.0), run by CI
tests/*.test.mjs                               node --test suite (not packaged)

Development

node --test                                        # from the repo root (npm test is the same); Node 20 built-ins only
bash scripts/ci-guard.sh                           # fails on eth_sendRawTransaction, privateKey, new Wallet(, signTransaction,
                                                   # MNEMONIC (outside check-env.mjs's deny list) or a listen( without 127.0.0.1
python3 scripts/quick_validate.py skills/peg-pools # SKILL.md frontmatter check (vendored from Anthropic's skill-creator,
                                                   # Apache-2.0, see scripts/quick_validate.LICENSE; needs PyYAML)

CI (.github/workflows/ci.yml) runs all three on Node 20 and 22; PyYAML is the only thing it installs, and only for the validator. tests/skill-docs.test.mjs mirrors the validator's frontmatter rules in JavaScript, so node --test alone needs neither Python nor PyYAML. Tests never contact the network: they run loopback stand-ins for the Peg API and the RPC.

The permission rule in SKILL.md, Bash(node "${CLAUDE_PLUGIN_ROOT}/skills/peg-pools/scripts/"*), relies on Claude Code substituting ${CLAUDE_PLUGIN_ROOT} in a plugin skill's allowed-tools Bash rules and body alike, which the Claude Code skills documentation states and which was checked against the Claude Code 2.1.226 binary (the plugin skill loader runs both through the same substitution, and a trailing * in a Bash rule is a wildcard). tests/skill-docs.test.mjs checks that every invocation in the skill documents matches the rule after substitution, so the scripts run without a permission prompt as long as they keep the quoted path prefix.

Release precondition: check-env.mjs passes against production only once usepeg.trade serves GET /api/community/stock-pools/manifest; until that Peg release ships, it stops with manifest_unavailable and the demo cannot pass step 1.

License

MIT, Copyright (c) 2026 Peg. See LICENSE.

About

Claude Code skill: deploy, register and seed a Peg Pool for a tokenized stock on Robinhood Chain — two wallet signatures, no private keys

usepeg.trade

Topics

claude-codeclaude-skilldefirobinhood-chaintokenized-stocks

Resources

Readme
MIT license
Activity
Custom properties

Stars

0 stars

Watchers

0 watching

Forks

0 forks
Report repository

Releases

Packages

Contributors

Languages

You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.