Complete SkillLite usage examples to quickly get started with all core features and framework integrations.
| Tutorial | Time | Difficulty | Content |
|---|---|---|---|
| 01. Basic Usage | 5 min | ⭐ | Simplest examples, one-line execution |
| 02. Skill Management | 10 min | ⭐⭐ | Create and manage skills |
| 03. Agentic Loop | 15 min | ⭐⭐ | Multi-turn conversations and tool calls |
| 04. LangChain Integration | 15 min | ⭐⭐⭐ | Integration with LangChain framework |
| 05. LlamaIndex Integration | 15 min | ⭐⭐⭐ | RAG + skill execution |
| 06. MCP Server | 10 min | ⭐⭐ | Claude Desktop integration |
| 07. OpenCode Integration | 10 min | ⭐⭐ | OpenCode AI coding agent integration |
# Install SkillLite
pip install skilllite
# Initialize project (sandbox + .skills/)
skilllite init
# Create .env configuration file
cp .env.example .env
# Edit .env and add your API keycd tutorials/01_basic
python hello_world.pyfrom skilllite import chat
result = chat("Help me with this task", skills_dir=".skills")
print(result)from skilllite import run_skill
result = run_skill("./.skills/calculator", '{"operation": "add", "a": 15, "b": 27}')
print(result["text"])pip install langchain-skilllitefrom langchain_skilllite import SkillLiteToolkit
from langgraph.prebuilt import create_react_agent
tools = SkillLiteToolkit.from_directory("./skills")
agent = create_react_agent(llm, tools)
result = agent.invoke({"messages": [("user", "Your request")]})See 05. LlamaIndex Integration for details.
hello_world.py- One-line executiondirect_execution.py- Direct skill executiontool_definitions.py- View tool formats
list_skills.py- List all skillsexecute_skill.py- Execute skills
basic_loop.py- Basic agent loop
basic_tool_setup.py- Tool setupagent_example.py- Agent examples (2 approaches)
basic_usage.py- RAG examples (3 approaches)
mcp_client_test.py- MCP client test
verify_setup.py- Verify OpenCode + SkillLite setup
Create a .env file:
# API Configuration
API_KEY=sk-... # Your API key
BASE_URL=https://api.openai.com/v1 # API endpoint
MODEL=gpt-4 # Model name
# Or use Anthropic Claude
ANTHROPIC_API_KEY=sk-ant-...
# SkillLite Configuration
SKILLLITE_SKILLS_DIR=./skills # Skills directory
SKILLLITE_SANDBOX_LEVEL=3 # Sandbox level (1/2/3)Q: Do I need to install Rust?
A: No, skilllite init will automatically download pre-compiled binaries.
Q: Can I execute skills without an LLM? A: Yes, see 01_basic/direct_execution.py
Q: How do I use it with LangChain? A: See 04_langchain_integration
Q: Which LLMs are supported? A: All OpenAI-compatible APIs + Claude native API