By emrestay
Skills for invoking Somnia Agents — JSON API Request, LLM Inference, LLM Parse Website — from any AI coding tool that supports the Agent Skills standard.
Invoke any Somnia Agent from the CLI without writing a contract. Builds the ABI-encoded payload, sizes the deposit correctly (operations reserve + per-agent price × subcommittee size), submits createRequest / createAdvancedRequest to the platform contract, and waits for RequestFinalized to decode the result. Also fetches off-chain receipts. Use for one-off testing, exploration, prototyping, or scripting agent calls without a wrapper contract.
Deep-dive reference for the JSON API Request agent on Somnia — fetch values from any public JSON API and bring them on-chain. Covers the 6 fetch functions (string / uint / int / bool / arrays), selector path syntax, decimal scaling, and Solidity / JS examples. Use when building price feeds, weather oracles, sports-score markets, or any contract that needs data from a REST API.
Deep-dive reference for the LLM Inference agent on Somnia — invoke a deterministic on-chain LLM (Qwen3-30B) from smart contracts. Covers the 4 functions (inferString, inferNumber, inferChat, inferToolsChat), MCP tool calling, on-chain tool yield/resume pattern, allowed-values constraints, and chain-of-thought. Use when building AI moderation, classification, summarization, sentiment scoring, or agentic DeFi bots that need an LLM to decide which on-chain calls to make.
Deep-dive reference for the LLM Parse Website agent on Somnia — search a domain (or directly scrape a URL) with a real browser and extract structured data using the on-chain LLM. Covers ExtractString and ExtractANumber, search-vs-direct mode, multi-page extraction, and the auto-injected reasoning / confidence fields. Use when the data lives on a webpage rather than a JSON API — sports scores from news sites, awards results, e-commerce prices, content not exposed via an API.
Comprehensive Somnia Agents knowledge — invoke decentralized AI / oracle / web-extraction agents from smart contracts via the SomniaAgents platform. Covers the request lifecycle, two-pot gas model, Majority vs Threshold consensus, callback handling, receipts, and the 3 base agents (JSON API Request, LLM Inference, LLM Parse Website). Use when writing contracts that call agents, sizing deposits, decoding responses, or debugging stuck requests.
Own this plugin?
Verify ownership to unlock analytics, metadata editing, and a verified badge. GitHub access is read-only (username + org membership).
Sign in to claimOwn this plugin?
Verify ownership to unlock analytics, metadata editing, and a verified badge. GitHub access is read-only (username + org membership).
Sign in to claimBased on adoption, maintenance, documentation, and repository signals. Not a security audit or endorsement.
Skills that teach AI coding tools how to invoke Somnia Agents — Somnia's on-chain platform for decentralized, auditable compute jobs (oracles, deterministic LLMs, structured web extraction).
Built on the Agent Skills open standard — works with Claude Code, Cursor, VS Code/Copilot, Windsurf, Gemini CLI, Amp, Goose, Roo Code, and any other tool that supports the standard.
Use the skills interactively to invoke any base agent and read receipts — or ask your AI to write a Solidity contract that requests price feeds, runs deterministic LLM classification, or extracts structured data from a webpage on-chain.
Knowledge skills (domain context the AI uses when writing code):
somnia-agents — comprehensive reference: request lifecycle, two-pot gas model, Majority vs Threshold consensus, callback handling, receiptssomnia-agents-json-fetch — the JSON API Request agent: 6 fetch functions, selector syntax, decimal scalingsomnia-agents-llm-inference — the LLM Inference agent: 4 functions, MCP + on-chain tool calling, yield/resume patternsomnia-agents-llm-parse-website — the LLM Parse Website agent: search vs direct mode, structured extractionAction skill (interactive command):
somnia-agents-invoke — invoke any base agent from the CLI, wait for finalisation, read off-chain receipts — without writing a contractnpm install
cp .env.example .env
Edit .env and set PRIVATE_KEY to a funded Somnia wallet. Get testnet STT from the Somnia Faucet.
Add the local marketplace, then install the plugin (persists across sessions and projects):
claude plugin marketplace add /path/to/somnia-agents-skills
claude plugin install somnia-agents-skills@somnia-agents-skills --scope user
In VS Code, you can also install via the /plugins UI in the Claude panel.
Alternatively, symlink individual skills into ~/.claude/skills/:
ln -sf /path/to/somnia-agents-skills/skills/*/ ~/.claude/skills/
For local development, use the session-only flag instead:
claude --plugin-dir /path/to/somnia-agents-skills
Add as a skill source via Settings → Features → Agent, or through the marketplace.
Any tool supporting the Agent Skills standard can load these skills. Each skill is a SKILL.md file in a subdirectory under skills/.
Once PRIVATE_KEY is set, fire a one-off agent call from the terminal:
# Fetch BTC/USD price as uint256 (8 decimals)
npx tsx skills/somnia-agents-invoke/scripts/invoke.ts \
--agent json-fetch --function fetchUint \
--args '["https://api.coingecko.com/api/v3/simple/price?ids=bitcoin&vs_currencies=usd","bitcoin.usd",8]'
# Single-turn LLM classification with allowed values
npx tsx skills/somnia-agents-invoke/scripts/invoke.ts \
--agent llm-inference --function inferString \
--args '["Classify: I love this product!", "You are a sentiment classifier. Reply with one word.", false, ["positive","negative","neutral"]]'
# Web extraction in direct mode
npx tsx skills/somnia-agents-invoke/scripts/invoke.ts \
--agent llm-parse-website --function ExtractString \
--args '["best_drama","Title of the film that won Best Motion Picture - Drama.",[],"Best Picture winners at the 2026 Golden Globe Awards","goldenglobes.com",true,3]'
The script handles deposit sizing automatically — see skills/somnia-agents-invoke/SKILL.md for the full flag list and patterns.
Once the skills are loaded, describe what you want and the AI writes the code — it has full knowledge of the agent ABIs, the platform contract, deposit math, and the callback pattern. Examples:
safe or unsafe and reverts on unsafe."inferToolsChat — the LLM decides which DEX swap to execute and yields the calldata back to my contract."Both networks share the same agent IDs. Only the platform contract address differs.
npx claudepluginhub emrestay/somnia-agents-skills --plugin somnia-agents-skillsDesign fluency for frontend development. 1 skill with 23 commands (/impeccable polish, /impeccable audit, /impeccable critique, etc.) and curated anti-pattern detection.
Behavioral guidelines to reduce common LLM coding mistakes, derived from Andrej Karpathy's observations on LLM coding pitfalls
Comprehensive skill pack with 66 specialized skills for full-stack developers: 12 language experts (Python, TypeScript, Go, Rust, C++, Swift, Kotlin, C#, PHP, Java, SQL, JavaScript), 10 backend frameworks, 6 frontend/mobile, plus infrastructure, DevOps, security, and testing. Features progressive disclosure architecture for 50% faster loading.
Access thousands of AI prompts and skills directly in your AI coding assistant. Search prompts, discover skills, save your own, and improve prompts with AI.
Develop, test, build, and deploy Godot 4.x games with Claude Code. Includes GdUnit4 testing, web/desktop exports, CI/CD pipelines, and deployment to Vercel/GitHub Pages/itch.io.
Complete developer toolkit for Claude Code