codex

package
v0.9.1 Latest Latest
Warning

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

Go to latest
Published: May 12, 2026 License: MIT Imports: 23 Imported by: 0

Documentation

Index

Constants

View Source
const Codex = briefkit.RuntimeKind("codex")

Variables

This section is empty.

Functions

This section is empty.

Types

type CodexArguments

type CodexArguments struct {
	JSON             *bool
	SkipGitRepoCheck *bool
	Model            *string
	SandboxMode      *string
	ConfigOverrides  map[string]any
}

CodexArguments constructs command-line arguments for the Codex CLI runtime.

func NewCodexArguments

func NewCodexArguments() *CodexArguments

NewCodexArguments creates a new CodexArguments instance with sensible defaults. JSON output is enabled by default for parseable responses.

func (*CodexArguments) ApplyExecutionInput

func (arguments *CodexArguments) ApplyExecutionInput(executionInput briefkit.ExecutionInput) error

ApplyExecutionInput applies execution-specific inputs like model selection. Returns error if model or reasoning effort value is provided but empty.

func (*CodexArguments) ApplyRuntimeConfig

func (arguments *CodexArguments) ApplyRuntimeConfig(config briefkit.RuntimeConfig) error

ApplyRuntimeConfig applies codex-specific runtime configuration to arguments. Handles type conversion from the opaque RuntimeConfig interface.

func (*CodexArguments) ApplyRuntimeFeatures

func (arguments *CodexArguments) ApplyRuntimeFeatures(features briefkit.RuntimeFeatures) error

ApplyRuntimeFeatures applies runtime feature flags to codex arguments.

func (*CodexArguments) ToSlice

func (arguments *CodexArguments) ToSlice() []string

ToSlice converts CodexArguments into a command-line argument slice. Returns arguments in deterministic order with sorted config overrides.

type Instance

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

func (*Instance) Events

func (instance *Instance) Events() <-chan briefkit.RuntimeEvent

func (*Instance) Wait

func (instance *Instance) Wait(ctx context.Context) (briefkit.RuntimeResult, error)

type Runtime

type Runtime struct {
}

func NewRuntime

func NewRuntime() *Runtime

func (*Runtime) Discovery

func (runtime *Runtime) Discovery(ctx context.Context) (bool, error)

func (*Runtime) Execute

func (runtime *Runtime) Execute(ctx context.Context, executionId briefkit.ExecutionID, executionInput briefkit.ExecutionInput, agentConfig briefkit.Config) (briefkit.RuntimeInstance, error)

func (*Runtime) GetDefaultConfig

func (runtime *Runtime) GetDefaultConfig(ctx context.Context) (briefkit.RuntimeConfig, error)

func (*Runtime) GetDefaultFeatures

func (runtime *Runtime) GetDefaultFeatures(ctx context.Context) (briefkit.RuntimeFeatures, error)

func (*Runtime) GetInfo

func (runtime *Runtime) GetInfo(ctx context.Context) (briefkit.RuntimeInfo, error)

func (*Runtime) RegisterMCPServer

func (runtime *Runtime) RegisterMCPServer(ctx context.Context, serverName briefkit.RuntimeMCPServerName, server briefkit.RuntimeMCPServer) error

type RuntimeConfig

type RuntimeConfig struct {
	// RequireWorkspaceRepository enforces that codex workdir must be a GIT repository.
	RequireWorkspaceRepository bool `json:"requireWorkspaceRepository" default:"true"`
}

RuntimeConfig defines runtime options for Codex execution.

Jump to

Keyboard shortcuts

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