Learn how to interpret and apply AI benchmark results. Best practices for analyzing performance, guiding model improvements, and making informed deployment decisions.


Runloop Launches TypeScript and Python Object-Oriented SDKs for General Availability
We're pleased to release a new set of tools to improve developer experience when working with the Runloop platform. Our Python and TypeScript Object-Oriented SDKs allow for a more natural and full-featured experience than previously available. You can get started now with our official packages:
Both packages offer strong typing for all Runloop essential primitives, improving IDE support and helping to avoid costly runtime development errors.
Sophisticated engineering teams expect more from the tools they work with. Runloop's tool set is constantly evolving and expanding to improve the experience for cutting edge development organizations. Our Object-Oriented SDK is our latest effort to improve the ergonomics of our developer SDK.
To demonstrate just how significant of an improvement this is, consider the following code segment that takes a checkpoint of devbox state without interrupting the original devbox. Here's how it looks using the OO-SDK:
// new OO-SDK
import { RunloopSDK } from '@runloop/api-client';
const runloop = new RunloopSDK(); // new SDK initialization
// create a devbox and run touch
const devbox = await runloop.devbox.create();
await devbox.cmd.exec("touch example.txt");
// take a snapshot
const snapshot = await devbox.snapshotDisk();
// start a second devbox from the snapshot and stop the original one
const checkpointedDevbox = await snapshot.createDevbox();
await devbox.shutdown();
Here's the same code using the legacy client:
// legacy ts client
import Runloop from '@runloop/api-client';
const runloop = new Runloop(); // old initialization code
// create a devbox and run touch
const devboxResult = await runloop.devboxes.createAndAwaitRunning()
await runloop.devboxes.executeAndAwaitCompletion(devboxResult.id, { command: "touch example.txt" })
// take a snapshot
const snapshotResult = await runloop.devbox.snapshotDisk(devboxResult.id)
await runloop.devboxes.snapshotDisk(devboxResult.id)
await runloop.snapshots.awaitCompleted(snapshotResult.id)
// start a second devbox from the snapshot and stop the original one
const checkpointedDevbox = await runloop.devbox.createAndAwaitRunning({ snapshot_id: snapshotResult.id})
await runloop.devbox.shutdown(devboxResult.id)
Most obviously, the OO-SDK eliminates the need to manually store and pass identifiers, but there are other subtle improvements too. When creating a snapshot the legacy code required users to await the result of the async snapshot API call and then an additional wait for the snapshot to complete. In contrast, the OO-SDK allows you to simply call await devbox.snapshotDisk() for the same effect. A complete breakdown of all the new features with detailed examples for a variety of use cases is available through our documentation site.
Our goal with this SDK was to replace low-level orchestration with first-class objects that model the platform directly. Some of the more common pain points we wanted to address were making sure that IDEs are aware of type hints so that autocomplete will provide useful suggestions. Similarly, we wanted type errors to surface immediately. All first class primitives have typed support in Runloop in both Python and TypeScript SDKs.
IDEs will automatically detect type hints and mixing incorrect types will now cause failures at build-time:
const shell = devbox.shell("named shell");
const result = await shell.exec("pwd"); // ✅ will auto-complete in your IDE
await shell.shutdown(); // ❌ shutdown is a devbox operation and does not exist on shell type
Exceptions are now typed to grant increased control:
try {
const devbox = await runloop.devbox.create();
const result = await devbox.cmd.exec('invalid-command');
} catch (error) {
if (error instanceof RunloopSDK.APIError) {
console.log('API Error: ', error.status, error.message);
} else if (error instanceof RunloopSDK.APIConnectionError) {
console.log('Connection Error: ', error.message);
} else {
console.log('Something else went wrong: ', error);
}
}
The net result of these changes is that the new SDK interface is more intuitive, less error prone, and just as fast as before. Every part of our SDK has changed for the better: from devbox lifecycle operations using suspend and resume, to creating SSH tunnels, to managing storage and agents.
We can't wait for you to try it out.
You can see full SDK details for each package by following these links:
What will you build?
Do you have suggestions or feedback? We'd love to hear from you.