Agent Skills by ALSEL
汎用ソフトウェア開発⭐ リポ 3品質スコア 76/100

solana-rent-free-dev

Light Protocolのレント無料プリミティブを使用したSolana開発のスキルです。Anchor、ネイティブRust、Pinocchioを含む、クライアント開発(TypeScript、Rust)とプログラム開発(Rust)をカバーしています。DeFiと決済(Light Token、Light-PDA)を重点領域とし、エアドロップやトークン配布(Compressed Token)、支払いとZKアプリケーション向けのユーザー・アプリ状態とnullifierの実装にも対応できます。

description の原文を見る

Skill for Solana development using rent-free primitives from Light Protocol. Covers client development (TypeScript, Rust) and program development (Rust) across Anchor, native Rust, and Pinocchio. Focus areas include DeFi and Payments (Light Token, Light-PDA). Other use cases include airdrops and token distribution (Compressed Token), and user/app state plus nullifiers for payments and ZK applications (Compressed PDA).

SKILL.md 本文

Capabilities

ZK Compression is a framework on Solana for stablecoin payment rails, consumer apps and defi. The Light SDK and APIs let you create mint, token and PDA accounts >99% cheaper with familiar Solana developer experience.

Primitives

PrimitiveUse caseConstraints
Light TokenMost token use cases (launchpads, DeFi, payments). Rent-free mint and token accounts. ~200x cheaper than SPL and more compute-unit efficient on the hot path.
Light-PDADeFi program state such as AMM pools and vaults. ~98% cheaper than PDAs and can be implemented with minimal code changes.
Compressed TokenOnly for Airdrops and token distribution. Prefer Light Token for other purposes. Used by Light Token under the hood for rent-free storage of inactive Light Tokens. Supported by Phantom and Backpack.Do not use for general-purpose token features. Use Light Token instead.
Compressed PDAUser state and app state, nullifiers (payments and ZK applications), DePIN nodes, and stake accounts. Similar to program-derived addresses without a rent-exempt balance.Not for shared state, pool accounts, or config accounts. Use Light-PDA instead

View a complete API comparison to SPL and Solana: https://www.zkcompression.com/api-reference/solana-to-light-comparison.

Creation cost and Compute Unit Consumption

MetricLightStandard Solana
Mint Account~0.00001 SOL~0.0015 SOL
Token Account~0.00001 SOL~0.0029 SOL
PDA (100-byte)~0.0000115 SOL~0.0016 SOL
Associated token account creation4,348 CU14,194 CU
Transfer312 CU4,645 CU
Transfer (rent-free)1,885 CU4,645 CU

Install

Install orchestrator agent skill or view skill.md:

npx skills add https://zkcompression.com

Install or view dedicated agent skills.

npx skills add Lightprotocol/skills

Workflow

  1. Clarify intent
    • Recommend plan mode, if it's not activated
    • Use AskUserQuestion to resolve blind spots
    • All questions must be resolved before execution
  2. Identify references and skills
  3. Write plan file (YAML task format)
    • Use AskUserQuestion for anything unclear — never guess or assume
    • Identify blockers: permissions, dependencies, unknowns
    • Plan must be complete before execution begins
  4. Execute
    • Use Task tool with subagents for parallel research
    • Subagents load skills via Skill tool
    • Track progress with TodoWrite
  5. When stuck: spawn subagent with Read, Glob, Grep, DeepWiki MCP access and load skills/ask-mcp

Skills

Use caseSkill
Skill for payment flows using Light Token APIs for sponsored rent-exemption.payments
For Solana program development with tokens and PDAs, Light is 200x cheaper than SPL/ Solana and has minimal code differenceslight-sdk
For client development with tokens on Solana, Light Token is 200x cheaper than SPL and has minimal changeslight-token-client
For data pipelines, aggregators, or indexers, real-time account state streaming on Solana with light account hot/cold lifecycle trackingdata-streaming
For token distribution on Solana 5000x cheaper than SPL (rewards, airdrops, depins, ...)token-distribution
For custom ZK Solana programs and privacy-preserving applications to prevent double spendingzk-nullifier
For program development on Solana with infrequently accessed state, such as per-user state, DePIN registrations, ...solana-compression
For testing with Light Protocol programs and clients on localnet, devnet, and mainnet validationtesting
For questions about compressed accounts, Light SDK, Solana development, Claude Code features, or agent skillsask-mcp

Context

light-token

A token standard functionally equivalent to SPL that stores mint and token accounts more efficiently.

Mint accounts represent a unique mint and optionally store token-metadata. Functionally equivalent to SPL mints.

Token accounts hold balances from any light, SPL, or Token-2022 mint, without paying rent-exemption.

The token program pays rent-exemption cost for you. When an account has no remaining sponsored rent, the account is automatically compressed. Your tokens are cryptographically preserved as a compressed token account (rent-free). The account is loaded into hot account state in-flight when someone interacts with it again.

Use for: Stablecoin Orchestration, Cards, Agent Commerce, Defi, ... .

light-PDA

The Light-SDK pays rent-exemption for your PDAs, token accounts, and mints (98% cost savings). Your program logic stays the same.

After extended inactivity (multiple epochs without writes), accounts auto-compress to cold state. Your program only interacts with hot accounts. Clients load cold accounts back on-chain via create_load_instructions.

AreaChange
State structDerive LightAccount, add compression_info: CompressionInfo
Accounts structDerive LightAccounts, add #[light_account] on init accounts
Program moduleAdd #[light_program] above #[program]
InstructionsNo changes

Use for: DeFi program state, AMM pools, vaults.

Compressed token (only use for token distribution)

Compressed token accounts store token balance, owner, and other information of tokens like SPL and light-tokens. Compressed token accounts are rent-free. Any light-token or SPL token can be compressed/decompressed at will. Supported by Phantom and Backpack.

Only use for: airdrops, token distribution without paying upfront rent per recipient.

Compressed PDA

Compressed PDAs are derived using a specific program address and seed, like regular PDAs. Custom programs invoke the Light System program to create and update accounts, instead of the System program.

Persistent unique identification. Program ownership. CPI between compressed and regular PDAs.

Use rent-free PDAs for: user state, app state, nullifiers for payments, DePIN node accounts, stake accounts, nullifiers for zk applications. Not for shared state, pool, and config accounts.

Guidelines

  • light-token ≠ compressed token. light-token is a Solana account in hot state. Compressed token is a compressed account, always compressed, rent-free.
  • light-PDA ≠ compressed PDA. light-PDA is a Solana PDA that transitions to compressed state when inactive. Compressed PDA is always compressed, derived like a PDA and requires a validity proof.
  • light-token accounts hold SPL and Token-2022 balances, not just light-mint balances.
  • When sponsored rent on a light-token or light-PDA runs out, the account compresses. It decompresses on next interaction.

Payment Flows

NameDescriptionDocsExamples
OverviewLearn how the Light Token APIs reduce account creation cost for stablecoin payment infrastructure by 99% with similar developer experience to SPL / Token 2022.overview
Basic paymentSend a single token transfer with Light Token APIs for stablecoin payments with comparison to SPL.basic-paymentbasic-send-action | basic-send-instruction
Batch paymentsSend payments to multiple recipients in a single transaction or sequentially.batch-paymentsbatch-send
Payment with memoAttach invoice IDs, payment references, or notes to Light Token transfers using Solana's memo program. The memo is recorded in the transaction logs for reconciliation.payment-with-memopayment-with-memo
Receive paymentsPrepare to receive token payments by loading cold accounts and sharing your associated token account address.receive-paymentsreceive
Verify paymentsQuery token balances and transaction history to verify incoming payments.verify-paymentsget-balance | get-history
Verify addressVerify recipient addresses before sending payments. Address validation prevents sending tokens to invalid or unexpected account types.verify-recipient-addressverify-address
Wrap and unwrapMove tokens between SPL / Token 2022 and Light Token accounts for interoperability with applications that don't support Light Token yet.wrap-unwrapwrap | unwrap
Spend permissionsDelegate token spending to a third party with an amount cap. The delegate can transfer tokens on behalf of the owner up to the approved amount, without the owner signing each transaction.spend-permissionsdelegate-full-flow
Nullifier PDAsCreate rent-free nullifier PDAs to prevent duplicate actions.nullifier-pda
Production readinessNon-exhaustive checklist for deploying Light Token payment flows to production, including RPC infrastructure, error handling, and security.production-readiness
Wallet integrationGuide for Wallet Applications to add Light-token support.wallets/overview
Sign with PrivyIntegrate light-token with Privy embedded wallets for rent-free token accounts and transfers.privysign-with-privy
Sign with Wallet AdapterIntegrate light-token with Solana Wallet Adapter for rent-free token accounts and transfers.wallet-adaptersign-with-wallet-adapter
Gasless transactionsAbstract SOL fees so users never hold SOL. Sponsor top-ups and transaction fees by setting your application as the fee payer.gasless-transactionsgasless-transactions

Examples

TypeScript client (@lightprotocol/compressed-token)

OperationDocs guideGitHub example
createMintInterfacecreate-mintaction | instruction
createAtaInterfacecreate-ataaction | instruction
mintToInterfacemint-toaction | instruction
transferInterfacetransfer-interfaceaction | instruction
approveapprove-revokeaction
revokeapprove-revokeaction
delegateTransfertransfer-delegatedaction
wrapwrap-unwrapaction | instruction
unwrapwrap-unwrapaction | instruction
loadAtaload-ataaction | instruction
createAtaExplicitRentSponsoraction
createSplInterfaceadd-interface-pdaaction | instruction
createSplMintcreate-mintaction | instruction
createT22Mintcreate-mintaction | instruction
createTokenPoolinstruction

Rust client (light-token-client)

OperationDocs guideGitHub example
CreateMintcreate-mintaction | instruction
CreateAtacreate-ataaction | instruction
CreateTokenAccountcreate-token-accountinstruction
MintTomint-toaction | instruction
TransferInterfacetransfer-interfaceaction | instruction
TransferCheckedtransfer-checkedaction | instruction
Approveapprove-revokeaction | instruction
Revokeapprove-revokeaction | instruction
Burnburninstruction
BurnCheckedburninstruction
Freezefreeze-thawinstruction
Thawfreeze-thawinstruction
Closeclose-token-accountinstruction
Wrapwrap-unwrapaction
Unwrapwrap-unwrapaction
MintToCheckedmint-toinstruction
SplToLightTransferinstruction

Program examples (light_token)

Description
escrowPeer-to-peer light-token swap with offer/accept flow
fundraiserToken fundraiser with target, deadline, and refunds
light-token-minterCreate light-mints with metadata, mint tokens
token-swapAMM with liquidity pools and swaps (Anchor)
cp-swap-referenceFork of Raydium AMM that creates markets without paying rent-exemption
pinocchio-swapAMM with liquidity pools and swaps (Pinocchio)
create-and-transferCreate account via macro and transfer via CPI

Program macros (light_token)

Description
counterCreate PDA with sponsored rent-exemption
create-ataCreate associated light-token account
create-mintCreate light-token mint
create-token-accountCreate light-token account

CPI instructions (light_token)

CPI calls can be combined with existing and/or light macros. The API is a superset of SPL-token.

OperationDocs guideGitHub example
CreateAssociatedAccountCpicreate-atasrc
CreateTokenAccountCpicreate-token-accountsrc
CreateMintCpicreate-mintsrc
MintToCpimint-tosrc
MintToCheckedCpimint-tosrc
BurnCpiburnsrc
TransferCheckedCpitransfer-checkedsrc
TransferInterfaceCpitransfer-interfacesrc
ApproveCpiapprove-revokesrc
RevokeCpiapprove-revokesrc
FreezeCpifreeze-thawsrc
ThawCpifreeze-thawsrc
CloseAccountCpiclose-token-accountsrc

SDK references

TypeScript packages

Packagenpm
@lightprotocol/stateless.jsnpm
@lightprotocol/compressed-tokennpm

Rust crates

Cratedocs.rs
light-sdkdocs.rs/light-sdk
light-sdk-pinocchiodocs.rs/light-sdk-pinocchio
light-tokendocs.rs/light-token
light-token-clientdocs.rs/light-token-client
light-compressed-token-sdkdocs.rs/light-compressed-token-sdk
light-clientdocs.rs/light-client
light-program-testdocs.rs/light-program-test
light-account-pinocchiodocs.rs/light-account-pinocchio
light-token-pinocchiodocs.rs/light-token-pinocchio
light-hasherdocs.rs/light-hasher
light-accountdocs.rs/light-account

For additional documentation and navigation, see: https://www.zkcompression.com/llms.txt For additional skills, see: https://github.com/Lightprotocol/skills

ライセンス: MIT(寛容ライセンスのため全文を引用しています) · 原本リポジトリ

詳細情報

作者
Lightprotocol
リポジトリ
Lightprotocol/docs-v2
ライセンス
MIT
最終更新
2026/4/7

Source: https://github.com/Lightprotocol/docs-v2 / ライセンス: MIT

本サイトは GitHub 上で公開されているオープンソースの SKILL.md ファイルをクロール・インデックス化したものです。 各スキルの著作権は原作者に帰属します。掲載に問題がある場合は info@alsel.co.jp または /takedown フォームよりご連絡ください。
原作者: Lightprotocol · Lightprotocol/docs-v2 · ライセンス: MIT