chat

package
v5.99.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 9, 2026 License: Apache-2.0 Imports: 27 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package chat implements the AI-assisted chat command.

This package provides the `ksail chat` command, which starts an interactive AI chat session powered by GitHub Copilot. It supports both TUI and non-TUI modes, with tool permission enforcement and plan/agent mode switching.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BuildPreToolUseHook added in v5.33.0

func BuildPreToolUseHook(
	allowedRoot string,
) copilot.PreToolUseHandler

BuildPreToolUseHook creates a PreToolUseHandler that enforces path sandboxing on ALL tool invocations (both custom KSail tools and SDK-managed tools like git/shell/filesystem). Mode enforcement (plan mode tool blocking) is handled server-side via Session.RPC.Mode.Set().

func NewChatCmd

func NewChatCmd(_ *di.Runtime) *cobra.Command

NewChatCmd creates and returns the chat command.

func WrapToolsWithForceInjection added in v5.80.0

func WrapToolsWithForceInjection(
	tools []copilot.Tool,
	toolMetadata map[string]toolgen.ToolDefinition,
) []copilot.Tool

WrapToolsWithForceInjection wraps write tools to inject the --force flag after SDK-native permission approval. Permission handling is delegated entirely to the SDK's OnPermissionRequest handler — this wrapper only handles force-flag injection.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL