Scriptling Libraries
Scriptling-specific libraries that provide functionality not available in Python’s standard library. They use the scriptling. namespace prefix.
AI & LLM
| Library | Description |
|---|---|
| scriptling.ai | AI and LLM functions for OpenAI-compatible APIs |
| scriptling.ai.agent | Agentic AI loop with automatic tool execution |
MCP Protocol
| Library | Description |
|---|---|
| scriptling.mcp | MCP (Model Context Protocol) tool interaction |
Runtime
| Library | Description |
|---|---|
| scriptling.runtime | Background tasks and async execution |
| scriptling.runtime.http | HTTP route registration and response helpers |
| scriptling.runtime.kv | Thread-safe key-value store |
| scriptling.runtime.sync | Named cross-environment concurrency primitives |
| scriptling.runtime.sandbox | Isolated script execution environments |
Utilities
| Library | Description |
|---|---|
| scriptling.console | Console input/output functions |
| scriptling.toon | TOON (Token-Oriented Object Notation) encoding/decoding |
Usage
import scriptling.ai as ai
response = ai.chat("gpt-4", "Hello!")
print(response)