command

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Feb 19, 2025 License: MIT Imports: 7 Imported by: 1

Documentation

Index

Constants

View Source
const BASH = "bash"

A unique name for bash (the shell)

View Source
const RETURN = "return"

A unique name for return command

Variables

This section is empty.

Functions

func Bash

func Bash(os, dir string) thinker.Cmd

Create new bash command, defining the os variant and working dir

func Return

func Return() thinker.Cmd

Creates new return command, instructing LLM return results

Types

type Registry

type Registry struct {
	// contains filtered or unexported fields
}

The command registry, used by the application to define available tools and commands for workflows. It automates the advertisement of registered commands and their usage rules.

func NewRegistry

func NewRegistry() *Registry

Creates new command registry.

func (*Registry) FMap

func (r *Registry) FMap(reply chatter.Reply) (float64, thinker.CmdOut, error)

Transform LLM response into the command invokation, returns the result of command.

func (*Registry) Harden

func (r *Registry) Harden(prompt *chatter.Prompt)

Injects requirments for LLM about available tooling

func (*Registry) Register

func (r *Registry) Register(cmd thinker.Cmd) error

Register new command

Jump to

Keyboard shortcuts

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