Overview
- Skill Key
- acastellana/genlayer-dev
- Author
- acastellana
- Source Repo
- openclaw/skills
- Version
- -
- Source Path
- skills/acastellana/genlayer-dev
- Latest Commit SHA
- 680ef4ede5c3b3f86b3f587e023faf80705fff2c
Stars
0
Installs
0
Status
ACTIVE
Visibility
PUBLIC
直接复制以下提示词,发送给你的 AI 助手即可完成安装。
请先检查是否已安装 SkillHub 商店,若未安装,请根据 https://skillhub-1388575217.cos.ap-guangzhou.myqcloud.com/install/skillhub.md 安装 SkillHub 商店,然后安装 Genlayer Dev 技能。 若已安装,则直接安装 Genlayer Dev 技能。
# GenLayer Intelligent Contracts
GenLayer enables **Intelligent Contracts** - Python smart contracts that can call LLMs, fetch web data, and handle non-deterministic operations while maintaining blockchain consensus.
## Quick Start
### Minimal Contract
```python
# v0.1.0
# { "Depends": "py-genlayer:latest" }
from genlayer import *
class MyContract(gl.Contract):
value: str
def __init__(self, initial: str):
self.value = initial
@gl.public.view
def get_value(self) -> str:
return self.value
@gl.public.write
def set_value(self, new_value: str) -> None:
self.value = new_value
```
### Contract with LLM
```python
# v0.1.0
# { "Depends": "py-genlayer:latest" }
from genlayer import *
import json
class AIContract(gl.Contract):
result: str
def __init__(self):
self.result = ""
@gl.public.write
def analyze(self, text: str) -> None:
prompt = f"Analyze this text and respond with JSON: {text}"
def get_analysis():
return gl.nondet.exec_prompt(prompt)
# All validators must get the same result
self.result = gl.eq_principle.strict_eq(get_analysis)
@gl.public.view
def get_result(self) -> str:
return self.result
```
### Contract with Web Access
```python
# v0.1.0
# { "Depends": "py-genlayer:latest" }
from genlayer import *
class WebContract(gl.Contract):
content: str
def __init__(self):
self.content = ""
@gl.public.write
def fetch(self, url: str) -> None:
url_copy = url # Capture for closure
def get_page():
return gl.nondet.web.render(url_copy, mode="text")
self.content = gl.eq_principle.strict_eq(get_page)
@gl.public.view
def get_content(self) -> str:
return self.content
```
## Core Concepts
### Contract Structure
1. **Version header**: `# v0.1.0` (required)
2. **Dependencies**: `# { "Depends"...
# genlayer-dev-claw-skill
A Claw skill for building GenLayer Intelligent Contracts—Python smart contracts with LLM calls and web access.
## Purpose
This skill helps AI assistants write and deploy Intelligent Contracts:
- SDK API reference
- Code examples and patterns
- CLI commands
- Deployment workflows
- Equivalence principles
**For explaining GenLayer concepts**, use the companion skill: [genlayer-claw-skill](https://github.com/acastellana/genlayer-claw-skill)
## What's Inside
| File | Description |
|------|-------------|
| `SKILL.md` | Quick start, core concepts, common patterns |
| `references/sdk-api.md` | Complete SDK API reference |
| `references/equivalence-principles.md` | Consensus patterns in depth |
| `references/examples.md` | Annotated contract examples |
| `references/deployment.md` | CLI commands, networks, deployment |
| `references/genvm-internals.md` | VM architecture, storage, ABI |
## Quick Example
```python
# v0.1.0
# { "Depends": "py-genlayer:latest" }
from genlayer import *
class MyContract(gl.Contract):
result: str
def __init__(self):
self.result = ""
@gl.public.write
def analyze(self, text: str) -> None:
prompt = f"Analyze: {text}"
def get_analysis():
return gl.nondet.exec_prompt(prompt)
self.result = gl.eq_principle.strict_eq(get_analysis)
@gl.public.view
def get_result(self) -> str:
return self.result
```
## Key Topics Covered
- **Contract structure** — `gl.Contract`, decorators, state types
- **Storage types** — `DynArray`, `TreeMap`, sized integers (`u256`, etc.)
- **Non-deterministic ops** — `gl.nondet.exec_prompt()`, `gl.nondet.web.render()`
- **Equivalence principles** — `strict_eq`, `prompt_comparative`, `prompt_non_comparative`, custom patterns
- **Contract interactions** — Cross-contract calls, EVM interop
- **CLI** — `genlayer deploy`, `genlayer call`, `genlayer write`
- **Networks** — localnet, studionet, test...
heyixuan2
Bambu Lab 3D printer control and automation. Activate when user mentions: printer status, 3D printing, slice, analyze model, generate 3D, AMS filament, print monitor, Bambu Lab, or any 3D printing task. Full pipeline: search → generate → analyze → colorize → preview → open BS → user slice → print → monitor. Supports all 9 Bambu Lab printers (A1 Mini, A1, P1S, P2S, X1C, X1E, H2C, H2S, H2D).
human-pages-ai
Search and hire real humans for tasks — photography, delivery, research, and more
zseven-w
Reusable skill templates for OpenClaw AI agents. Templates for API integration, data processing, web scraping, CLI tools, and file processing.
capt-marbles
Generative Engine Optimization (GEO) for AI search visibility. Optimize content to appear in ChatGPT, Perplexity, Claude, and Google AI Overviews. Use when optimizing websites, pages, or content for LLM discoverability and citation.
cchacons
The job marketplace where bots hire bots. Post FREE or paid $WAGE jobs, with on-chain escrow, faucet rewards, referrals, judge staking, task inbox, smart matching, checkpoints, oversight, webhooks, onboarding, and human owner dashboard.
cchacons
The job marketplace where bots hire bots. Post FREE or paid $WAGE jobs, with on-chain escrow, faucet rewards, referrals, judge staking, task inbox, smart matching, checkpoints, oversight, webhooks, onboarding, and human owner dashboard.