Nodepick Python SDK
A modern Python SDK for interacting with the Nodepick micro-VM orchestration API and executing agent tasks on Guest VM Model Context Protocol (MCP) servers using Post-Quantum Cryptography (PQC) TLS.
Installation
Recommended Method (uv)
Using uv is the recommended fast, reliable way to install the nodepick SDK:
# Install published SDK from PyPI
uv add nodepick
# Or install from local source in development mode
uv pip install -e .
Alternative Method (pip)
# Install from PyPI
pip install nodepick
# Or install local editable SDK
pip install -e .
Features
1. Manage Compute Nodes
Interact with the Nodepick REST API to manage node lifecycles (create, list, reboot, shutdown, delete).
from nodepick import NodePickClient
# Authenticate with Nodepick Developer API Key
client = NodePickClient(api_key="your-developer-api-key", base_url="https://api.nodepick.ai")
with client:
# 1. Create a compute node
node = client.node_create(
memory=1024 * 1024 * 1024,
cpu=2,
network_type="public",
display_name="pqc-agent-sandbox"
)
node_id = node["id"]
print(f"Created node: {node_id}")
# 2. Get node details (including VMM status, SSH options, and MCP configuration)
details = client.node_get_details(node_id)
print("Node details:", details)
# 3. List all active nodes
nodes = client.node_list()
print("My nodes:", nodes)
# 4. Reboot a node
client.node_reboot(node_id)
# 5. Shutdown a node
client.node_shutdown(node_id)
# 6. Delete a node and reclaim resources (polls until fully deleted)
client.node_delete(node_id)
2. Connect to the Guest VM MCP Server
Directly interact with the zero-dependency Guest VM MCP server (mcp) over a secure, Streamable HTTP connection. The client automatically configures TLS to exclusively negotiate post-quantum hybrid groups (X25519MLKEM768).
from nodepick import NodePickClient
async def main():
# 1. Initialize main client
client = NodePickClient(api_key="your-developer-api-key")
# 2. Obtain initialized MCP client directly from the node ID/UUID
mcp_client = client.mcp("node-uuid")
# 3. List available tools
tools = await mcp_client.list_tools()
print("Available tools:")
for tool in tools:
print(f"- {tool['name']}: {tool['description']}")
# 4. Execute a tool inside the Guest VM
res = await mcp_client.call_tool("manage_services", {"action": "status", "service": "nginx"})
print("Tool Output:", res)
3. LLM Agent Loops (Tool Calling)
Integrate LLM models directly with the Guest VM's MCP tools. The SDK exposes an AgentLoop runner with built-in REST client providers for Ollama (local), Google Gemini, Anthropic, and OpenAI.
from nodepick import NodePickClient, AgentLoop, OllamaProvider, GeminiProvider, OpenAIProvider
async def main():
client = NodePickClient(api_key="your-developer-api-key")
# Obtain the Guest VM's MCP client directly from the node
mcp_client = client.mcp("node-uuid")
# Pick an LLM provider:
# A. Local Ollama (zero API keys needed)
provider = OllamaProvider(model="llama3.1")
# B. Google Gemini
# provider = GeminiProvider(api_key="your-gemini-key", model="gemini-1.5-flash")
# C. OpenAI GPT
# provider = OpenAIProvider(api_key="your-openai-key", model="gpt-4o")
# D. Anthropic Claude
# provider = AnthropicProvider(api_key="your-anthropic-key", model="claude-3-5-sonnet-latest")
# Initialize the runner
agent = AgentLoop(provider=provider, mcp_client=mcp_client)
# Run the prompt (the loop executes tool calls recursively until final answer is reached)
result = await agent.run(
prompt="Check if nginx service is running, and if not, try to start it and verify.",
system_instruction="You are a systems administration copilot operating inside the guest VM."
)
print("Agent Final Answer:")
print(result)
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file nodepick-0.1.1.tar.gz.
File metadata
- Download URL: nodepick-0.1.1.tar.gz
- Upload date:
- Size: 11.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via:
uv/0.11.7 {"installer":{"name":"uv","version":"0.11.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
80fe5531d35159b3de00fc233711943ad8ccda13eb7fd97ddefeb2b5a4e03b2c
|
|
| MD5 |
49b9e5e99dd1299bbf6922efb8969a9e
|
|
| BLAKE2b-256 |
0fb3361d9e5b69739eaf3f877522d5b104e76fcf90c5c2ade722d0cf6fe6c316
|
File details
Details for the file nodepick-0.1.1-py3-none-any.whl.
File metadata
- Download URL: nodepick-0.1.1-py3-none-any.whl
- Upload date:
- Size: 10.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via:
uv/0.11.7 {"installer":{"name":"uv","version":"0.11.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
492e4e2a6105ff9e99e32cdac37d23b9778407b298c2473601bc4ece9827a564
|
|
| MD5 |
bf21149a49405f2d72c06c9d0a0b6739
|
|
| BLAKE2b-256 |
439fc1160a5dd4c89580f59488e740e24dc3d56c5248d996c13b3daf07b69bbc
|