adapter

package
v1.0.4 Latest Latest
Warning

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

Go to latest
Published: Jun 21, 2026 License: Apache-2.0 Imports: 22 Imported by: 0

Documentation

Overview

Package adapter provides concrete implementations of the kernel interfaces. These adapters bridge kernel's abstract interfaces to OK's concrete infrastructure (sandbox, agent sessions, providers, file I/O, memory stores).

The adapter package depends on many internal packages — this is by design. kernel/ itself defines only interfaces (zero internal dependencies); adapter/ supplies the implementations so kernel/ stays pure.

See internal/kernel/kernel.go for interface definitions.

Index

Constants

View Source
const (
	ChunkText      = kernel.ChunkText
	ChunkReasoning = kernel.ChunkReasoning
	ChunkToolCall  = kernel.ChunkToolCall
	ChunkUsage     = kernel.ChunkUsage
	ChunkError     = kernel.ChunkError
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Bash

type Bash = kernel.Bash

func NewBash

func NewBash(sb Sandbox) Bash

type BashOut

type BashOut = kernel.BashOut

type Chunk

type Chunk = kernel.Chunk

type Controller

type Controller = kernel.Controller

type EditFile

type EditFile = kernel.EditFile

func NewEditFile

func NewEditFile(roots []string, workDir string) EditFile

type Fact

type Fact = kernel.Fact

type FileContent

type FileContent = kernel.FileContent

type Grep

type Grep = kernel.Grep

func NewGrep

func NewGrep(roots []string, workDir string) Grep

type Identity

type Identity = kernel.Identity

func NewIdentity

func NewIdentity() Identity

type Kernel

type Kernel = kernel.Kernel

type Learn

type Learn = kernel.Learn

func NewLearn

func NewLearn(skillsDir string) Learn

type LearnStats

type LearnStats = kernel.LearnStats

type Match

type Match = kernel.Match

type Message

type Message = kernel.Message

type Pattern

type Pattern = kernel.Pattern

type PluginIsolation

type PluginIsolation = kernel.PluginIsolation

type ProofEntry

type ProofEntry = kernel.ProofEntry

type Provider

type Provider = kernel.Provider

func NewProvider

func NewProvider(inner provider.Provider) Provider

type ReadFile

type ReadFile = kernel.ReadFile

func NewReadFile

func NewReadFile(roots []string, workDir string) ReadFile

type Recall

type Recall = kernel.Recall

func NewRecall

func NewRecall(store *memory.Store) Recall

func NewRecallWithSemantic

func NewRecallWithSemantic(store *memory.Store, semantic SemanticSearcher) Recall

type Request

type Request = kernel.Request

type RunOptions

type RunOptions = kernel.RunOptions

type RunResult

type RunResult = kernel.RunResult

type Sandbox

type Sandbox = kernel.Sandbox

func NewSandbox

func NewSandbox(spec sandbox.Spec, workDir string) Sandbox

type ScoredFact

type ScoredFact struct {
	Fact
	Score float64
}

type SemanticSearcher

type SemanticSearcher interface {
	Search(ctx context.Context, query string, limit int) ([]ScoredFact, error)
}

type Session

type Session = kernel.Session

func NewSession

func NewSession(inner *agent.Session) Session

type Skill

type Skill = kernel.Skill

type TaskRecord

type TaskRecord = kernel.TaskRecord

type ToolSchema

type ToolSchema = kernel.ToolSchema

type Trust

type Trust = kernel.Trust

func NewTrust

func NewTrust(pc *core.ProofChain) Trust

type TrustSummary

type TrustSummary = kernel.TrustSummary

type User

type User = kernel.User

type WriteFile

type WriteFile = kernel.WriteFile

func NewWriteFile

func NewWriteFile(roots []string, workDir string) WriteFile

Jump to

Keyboard shortcuts

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