genlayer-dev
acastellana 제작
Web & Frontend Development요약
Build GenLayer Intelligent Contracts - Python smart contracts with LLM calls and web access.
설명
이 스킬이 하는 일
GenLayer Intelligent Contracts are Python smart contracts that call LLMs and fetch live web data while maintaining blockchain consensus. Contracts use equivalence principles to reconcile non-deterministic outputs from AI and web sources across validators. The skill covers writing, deploying, and interacting with contracts using the GenLayer SDK and CLI.
Handles non-deterministic LLM and web results inside smart contracts without requiring custom off-chain infrastructure or oracles.
사용 시점
- Writing a contract that classifies user-submitted text using an LLM
- Fetching live webpage content into on-chain state
- Deploying contracts to a local or testnet network via CLI
- Building a prediction market resolved by AI judgment
- Calling EVM token contracts from a GenLayer contract
예시 워크플로
User asks: Write a contract that fetches a URL and stores the page text on-chain
- 1
Scaffolds a Python contract extending gl.Contract with a str state field
- 2
Adds a @gl.public.write method that captures the URL in a closure
- 3
Calls gl.nondet.web.render inside gl.eq_principle.strict_eq to fetch and agree on page content
- 4
Stores the result to contract state
- 5
Provides genlayer CLI commands to deploy and invoke the fetch method
A complete Python contract file with deploy and write interaction commands
요구 사항
- genlayer CLI (npm install -g genlayer)
설치
clawhub install acastellana/genlayer-devCLI 명령을 실행하거나, 프롬프트를 Claude Code, Cursor, Codex 등 사용하는 코딩 에이전트에 붙여넣으세요.