Help us shape the future of Go! Take the 2026 Go Developer Survey

kimi

package
v6.9.3 Latest Latest
Warning

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

Go to latest
Published: Mar 25, 2026 License: MIT Imports: 5 Imported by: 0

Documentation

Overview

Package kimi implements thinking configuration for Kimi (Moonshot AI) models.

Kimi models use the OpenAI-compatible reasoning_effort format for enabled thinking levels, but use thinking.type=disabled when thinking is explicitly turned off.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Applier

type Applier struct{}

Applier implements thinking.ProviderApplier for Kimi models.

Kimi-specific behavior:

  • Enabled thinking: reasoning_effort (string levels)
  • Disabled thinking: thinking.type="disabled"
  • Supports budget-to-level conversion

func NewApplier

func NewApplier() *Applier

NewApplier creates a new Kimi thinking applier.

func (*Applier) Apply

func (a *Applier) Apply(body []byte, config thinking.ThinkingConfig, modelInfo *registry.ModelInfo) ([]byte, error)

Apply applies thinking configuration to Kimi request body.

Expected output format (enabled):

{
  "reasoning_effort": "high"
}

Expected output format (disabled):

{
  "thinking": {
    "type": "disabled"
  }
}

Jump to

Keyboard shortcuts

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