Cline releases Cline SDK: an open source agent runtime that now powers CLI and Kanban, with IDE extensions migrated


Klein became an “agent” before it was cool, but building on the bleeding edge usually leads to some structural debt. Over time, the agent loop and VS Code extension became a package deal, making it difficult to maintain or migrate to new environments. It’s difficult to maintain layered features on a solid core. Cline, the open source AI coding proxy used by millions of developers, shipped a major architectural change this week: it has distilled its internal proxy harness into a standalone, open source TypeScript SDK called @cline/sdkand is rebuilding all of its own products on top of it.

Instead of adding another layer on top of that structure, Klein’s team chose to rebuild the foundation.

What is an SDK and how is it organized

The core agent toolkit is summarized in a pluggable agent SDK (@cline/sdk). It now runs Cline across VS Code, JetBrains, and the CLI, and is open source so any team can build on it. Key behavioral benefits of this redesign are: long-running work no longer stops with UI restarts, and sessions can move across surfaces – the proxy loop remains stateless and reusable while the runtime surrounding it becomes durable, portable, and product-agnostic.

The SDK is a layered TypeScript stack where each layer has a single responsibility and dependencies flow strictly downward.

From bottom to top:

@cline/shared It is the basic package that holds types, schemas, widget helpers, hook contracts, and extension logging tools – there are no higher layer dependencies. @cline/llms It sits on top of it, and has the provider portal and template catalogs. It covers Anthropic, OpenAI, Google, AWS Bedrock, Mistral, LiteLLM, and any OpenAI-compatible endpoint like vLLM, Together, and Fireworks, keeping all provider logic outside the proxy loop, so switching providers is a configuration change, not a code change. @cline/agents On top of that, it acts as a stateless, browser-compatible proxy execution loop, handling recursion, tool coordination, and event emission – and, most importantly, it doesn’t have session storage, built-in file/shell tools, or node-specific formatting, which makes it embeddable in browser environments. At the top he sits @cline/corethe node runtime/orchestration layer responsible for sessions, storage, embedded tools, coaxial and remote transport, automation, scheduling, telemetry, and loading of plugins/extensions.

@cline/sdk Itself a public surface from which everything is re-exported @cline/core. For engineers who want a smaller space, the packages are individually installable: you just pull them out @cline/llms For an LLM agent, or only @cline/agents For a stateless loop in a serverless or browser environment, without having to pull the entire node runtime stack.

The Cline team also reports that the new command-line interface completes the same tasks faster and at a lower nominal cost than the old one on internal runs.

Rebuilt utility with measurable benchmark results

With Cline 2.0, the team rewrote the prompts, simplified the loop, tightened context management, improved feedback loops and error handling, and rethought how tools were defined and highlighted in the form.

The Cline team has published results for Terminal Benchmark 2.0 (tbench.ai) to support this. In border models, Cline CLI works claude-opus-4.7 It received a score of 74.2%, compared to Anthropic’s published score of 69.4% for CloudCode on the same model. on claude-opus-4.6Cline CLI received a score of 71.9% compared to 65.4% posted by Cloud Code. In the open-weight models, Klein recorded 55.1%. kimi-k2.6compared to 37.1% for OpenCode and 45.5% for Pi-Code on the same model, with those operations performed by the Cline team using the pass@1 registry as of May 8, 2026.

https://cline.bot/blog/introducing-cline-sdk-the-upgraded-agent-runtime

Plugin system and expansion layer

One practical addition for development teams that rely on the SDK is the plugin architecture. The plugin can record tools, monitor lifecycle events, add rules and commands, and shape what the agent sees. Plugins can be loaded from configured paths or workspace locations, and can be started as local components .ts or .js module, which later became the package manual with an extension cline.plugins Clear so teams can create prototypes locally and package reusable capabilities when they’re ready.

In addition to plug-ins, the SDK provides additional expansion points including custom tools, MCP connectors, and skills. To add a new custom provider, you must execute ApiHandler And register it using @cline/llms Registration – List of architectural documents registerProvider and registerModel As the correct exported functions of the registry extension at runtime.

Native multi-agent support

One notable design decision is that multi-agent orchestration does not require a separate orchestration layer. The SDK includes agent and sub-agent teams locally, so a session can delegate specialists, track progress, and exchange delivery notes, all in the same core runtime. Sub-agents work with their own form, tools, and prompts.

Scheduled CRON jobs, checkpoints, web searches, and MCP connectors are handled natively out of the box.

Never

The SDK requires Node.js version 22 or later.

 Install the SDK
npm install @cline/sdk

 Install the CLI globally
npm i -g @cline

 Or give your agent the Cline SDK skill
npx skills add cline/sdk-skill

Documentation is available at docs.cline.bot/sdk. Practical examples – including examples of plug-ins and multiple application versions – are provided in sdk/apps/examples and sdk/examples Cline GitHub Repository Directories. The version is licensed under Apache 2.0.

Visual explanation of Marktechpost

Instructional guide
Klein SDK – Getting Started

01 / 09summary

What is it Klein SDK?

The same agent runtime that powers Cline’s VS Code, JetBrains, and CLI – now open for anyone to build on top of.
@cline/sdk Handles the complete agent loop: LLM calls, tool coordination, session persistence, multi-agent coordination, and scheduling. Instead of connecting it all yourself, you can import the SDK and focus on what your agent actually needs to do.

Typescript
Apache 2.0
Node.js 22+
Loop is browser compatible
Multi-provider
Plugin first

Who is this for? AI engineers, software engineers, and data scientists who want to create or embed codecs without rebuilding the infrastructure from scratch.

02/09Basic requirements

Before you Steady

Four things to check before running an npm install.

  • 01

    Node.js 22 or later
    Being node --version. If version is lower than version 22, update via nvm: nvm install 22 andamp;andamp; nvm use 22

  • 02

    npm or a compatible package manager
    npm, yarn, pnpm, or cake all work. This directory uses npm.

  • 03

    API key from at least one LLM provider
    Anthropic, OpenAI, Google Gemini, AWS Bedrock, Mistral, or any OpenAI compatible endpoint. Pass the key at runtime – never hard-code it.

  • 04

    TypeScript project (recommended)
    The SDK ships full TypeScript types. Plain JS works too, but you lose type safety in widget definitions and event payloads.

03/09stabilizing

Steady SDK

One package for the complete stack. Individual packages for small surfaces.

 Full SDK - recommended starting point
npm install @cline/sdk

 CLI globally (terminal-first usage)
npm i -g @cline

 Add the SDK skill to your coding agent
npx skills add cline/sdk-skill

If you only need a subset, install the individual packages directly:

 Browser-compatible stateless loop only
npm install @cline/agents @cline/shared @cline/llms

 Just the provider layer (LLM proxy use case)
npm install @cline/llms @cline/shared

SDK skill: npx skills add cline/sdk-skill Claude gives Code, Codex, or Cline full context on the SDK’s APIs so it can support agents and connect plugins for you.

04/09Build

the Stack layer

Four packages. One responsibility for each. Dependencies trickle down strictly.

@cline/core
Node runtime layer. Sessions, storage, embedded tools, coaxial and remote transport, automation, scheduling, telemetry, and plugin loading. That’s what @cline/sdk Re-export.

@cline/agents
A browser-compatible stateless proxy execution loop. It handles recursion, tool coordination, and event emission. There are no node-specific dependencies.

@cline/llms
Provider portal and model catalogs. All the provider logic is here, not in the proxy loop. Switching providers is a configuration change.

@cline/shared
institution. Types, charts, tool auxiliaries, hook contracts and extension contracts. There are no higher layer dependencies.

05/09Your first agent

Run your First agent

Import agent, subscribe to events, call run().

import { Agent } from "@cline/sdk"

const agent = new Agent({
  providerId:    "anthropic",
  modelId:       "claude-sonnet-4-6",
  apiKey:        process.env.ANTHROPIC_API_KEY,
  maxIterations: 10,
})

agent.subscribe((event) =andgt; {
  if (event.type === "assistant-text-delta")
    process.stdout.write(event.text ?? "")
})

const result = await agent.run(
  "Write a Python fn to check if a number is prime."
)

Agent runtime methods: run() continue() abort() subscribe() restore() snapshot()Agent It is a pseudonym for AgentRuntime.

06/09Service providers

Switch Service providers

The provider logic is in @cline/llms, not in the proxy loop. A switch is a single line configuration change.

Anthropic
OpenAI
Google
AWS foundation
Mistral
LiteLLM
vLLM
together
fireworks
// Anthropic
{ providerId: "anthropic", modelId: "claude-sonnet-4-6" }

// OpenAI
{ providerId: "openai",    modelId: "gpt-4o"            }

// Any OpenAI-compatible endpoint
{ providerId: "openai",    baseUrl: "https://your-vllm/v1" }

Dedicated provider: to implement ApiHandler And register it using registerProvider from @cline/llms. Add new models with registerModel.

07/09Extras

stretch with Extras

Add domain-specific behavior without runtime branching.
The plugin can record tools, monitor lifecycle events, add rules and commands, and shape what the agent sees. Start with a local .ts file; Promote the package with a cline.plugins Clear when it’s ready.

import { AgentPlugin, createTool } from "@cline/sdk"

const myPlugin: AgentPlugin = {
  name: "my-plugin",
  tools() {
    return [createTool({
      name:        "fetch_docs",
      description: "Fetch internal API docs by slug",
      async run({ slug }) {
        return fetchFromInternalDocs(slug)
      },
    })]
  },
}

Also available: Custom tools, MCP connectors, and skills as extensibility points. Examples of work in sdk/examples/plugins/ On GitHub.

08/09Multi-agent

Multi-agent difference

Sub-agents and team coordination are native to runtime – no external coordinator needed.

  • 01

    Identify your specialized agents
    Each subagent gets its own Agent An instance with a custom model, toolset, and system guide customized for its task domain.

  • 02

    Use bundled subagent plugin tools
    Built-in tools for starting sub-agents, messaging them, reading status, and storing handover notes between sessions.

  • 03

    There is no coordination layer to build
    Live the sub-agent primitives @cline/core. Sessions remain durable across surfaces – long-term work no longer stops when the UI is restarted.

Are you familiar with LangGraph or CrewAI? The primitives here are built into the runtime itself, not layered on top of it.

09/09Built-in and deployed

Built-in and Publishing

What you get out of the box, and how to run agents in CI/CD or external platforms.

Cron scheduling
Checkpoints
Search on the Internet
MCP connectors
Session stability
Telemetry hooks

 Connect agent to Telegram, WhatsApp, Slack
cline connect

 Headless CI: auto-approve + structured JSON output
cline -y --json "Run tests and fix any failures"

 Pipe git diff into the agent
git diff origin/main | cline "Review these changes"

resources: Documents → docs.cline.bot/sdk · Examples → sdk/apps/examples/ · Disagreement → discord.gg/cline · License: Apache 2.0

Key takeaways

  • Cline has extracted its internal proxy harness into the open source TypeScript SDK (@cline/sdk), which re-export @cline/core; The CLI and Kanban have already been migrated, with the VS Code and JetBrains extensions continuing to be migrated
  • The SDK is a four-layer stack: @cline/shared (Types/Facilities) → @cline/llms (Provider Portal) → @cline/agents (browser-compatible stateless loop) → @cline/core (Node runtime: sessions, storage, embedded tools, automation, telemetry)
  • Sessions are now durable across surfaces – long-term work no longer stops when the UI is restarted
  • Native support for plugins, subagents, CRON jobs, checkpoints, MCP connectors, and switching between multiple providers without touching the agent loop
  • Install via npm install @cline/sdk (Requires Node.js 22+); Documents in docs.cline.bot/sdk

verify Repo and Technical details. Also, feel free to follow us on twitter Don’t forget to join us 150k+ mil SubReddit And subscribe to Our newsletter. I am waiting! Are you on telegram? Now you can join us on Telegram too.

Do you need to partner with us to promote your GitHub Repo page, face hug page, product release, webinar, etc.? Contact us


Leave a Reply