PrivatebuildBuilds extras for create operations (createNotebook, createLexical) with VS Code-specific logic
PrivatebuildBuilds default extras for non-createNotebook tools
PrivatebuildBuilds the execution context for the operation
PrivateexecuteExecutes operation by sending message to active webview Uses the Runner pattern: extension → webview message → DefaultExecutor
PrivateformatFormats operation result for VS Code
Executes the tool by delegating to the core operation
PrivateopenOpen a notebook document in the editor Handles both local (file://) and cloud (datalayer://) schemes Always uses the Datalayer notebook editor
Prepares the tool invocation with user-facing messages
PrivatepromptPrompts user to choose notebook location when intent is ambiguous (VS Code-specific UI)
OptionalspaceName: stringPrivateresolveResolves Lexical document ID from parameters or active editor
PrivateresolvePrivateresolveResolves notebook ID from parameters or active editor
VS Code Tool Adapter
This adapter bridges VS Code's LanguageModelTool interface to our platform-agnostic core operations. It handles: