codex

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Sep 6, 2026 License: GPL-3.0 Imports: 18 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

Index

Constants

View Source
const (
	PluginID      = "dev.bsbctl.codex"
	PluginVersion = "0.1.0"
	AppID         = "codex"

	ChannelAttention     = "attention"
	ChannelGuidance      = "guidance"
	ChannelOutcome       = "outcome"
	ChannelActivity      = "activity"
	ChannelProgress      = "progress"
	ChannelOverview      = "overview"
	ChannelConnection    = "connection"
	ChannelDetail        = "detail"
	ChannelQuotaSummary  = "quota-summary"
	ChannelQuotaPressure = "quota-pressure"

	OperationSessions = "sessions"
	OperationPin      = "pin"
	OperationUnpin    = "unpin"
)

Variables

This section is empty.

Functions

func AssetDeclarations

func AssetDeclarations() []assets.Declaration

AssetDeclarations returns the immutable static asset owned by the Codex app-server plugin.

func DefinitionForVersion

func DefinitionForVersion(version string) pluginsdk.Definition

Types

type Card

type Card struct {
	Channel     string
	Key         string
	StateWord   string
	ContextLine string
	SessionLine string
	ProjectLine string
	DetailLine  string
	Disposition protocol.Disposition
	Impact      protocol.Impact
	ReasonCode  string
	ObservedAt  time.Time
	ValidUntil  time.Time
	Scene       protocol.Scene
}

type Config

type Config struct {
	ShowSensitiveRequestDetails   bool
	ShowQuota                     bool
	QuotaWarningRemainingPercent  int
	QuotaCriticalRemainingPercent int
}

type Handler

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

func New

func New(host Host) *Handler

func (*Handler) EndSession

func (h *Handler) EndSession(ctx context.Context, request protocol.SessionEndRequest) error

func (*Handler) HandleSessionInput

func (h *Handler) HandleSessionInput(ctx context.Context, request protocol.SessionInputRequest) (protocol.SessionInputResult, error)

func (*Handler) Health

func (*Handler) InvokeOperation

func (h *Handler) InvokeOperation(ctx context.Context, request protocol.OperationRequest) (protocol.OperationResult, error)

func (*Handler) ReplaceInstances

func (h *Handler) ReplaceInstances(ctx context.Context, instances []protocol.Instance) error

func (*Handler) Shutdown

func (h *Handler) Shutdown(ctx context.Context) error

func (*Handler) StartSession

func (h *Handler) StartSession(ctx context.Context, request protocol.SessionStartRequest) error

type QuotaOptions

type QuotaOptions struct {
	Enabled      bool
	AssetPath    string
	Presentation codexusage.PresentationConfig
}

type Reducer

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

func NewReducerWithQuota

func NewReducerWithQuota(now func() time.Time, quota QuotaOptions) *Reducer

func (*Reducer) Apply

func (r *Reducer) Apply(event appserver.ManagerEvent)

func (*Reducer) Cards

func (r *Reducer) Cards() []Card

func (*Reducer) InterruptTarget

func (r *Reducer) InterruptTarget(key string) (threadID, turnID string, ok bool)

func (*Reducer) LauncherCard

func (r *Reducer) LauncherCard() Card

func (*Reducer) LiveCard

func (r *Reducer) LiveCard() Card

LiveCard returns the current foreground view without background visibility throttles.

func (*Reducer) PendingRequest

func (r *Reducer) PendingRequest(observationKey string) (pendingRequest, bool)

func (*Reducer) PinThread

func (r *Reducer) PinThread(threadID string) bool

func (*Reducer) PinnedThread

func (r *Reducer) PinnedThread() string

func (*Reducer) ReconnectDeadline

func (r *Reducer) ReconnectDeadline() (time.Time, bool)

func (*Reducer) RestorePinnedThread

func (r *Reducer) RestorePinnedThread(threadID string)

func (*Reducer) ThreadSummaries

func (r *Reducer) ThreadSummaries() []ThreadSummary

func (*Reducer) UnpinThread

func (r *Reducer) UnpinThread()

type ThreadSummary

type ThreadSummary struct {
	ThreadID string `json:"thread_id"`
	Title    string `json:"title"`
	Status   string `json:"status"`
	Pinned   bool   `json:"pinned"`
}

Directories

Path Synopsis
internal

Jump to

Keyboard shortcuts

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