local

package
v0.3.6 Latest Latest
Warning

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

Go to latest
Published: Sep 14, 2026 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Overview

Package local provides durable-go configuration for the local (in-process) execution runtime used by agent.NewAgent when no opt-in runtime factory (Temporal, Restate) is configured.

Local runtime is durable by default: every Run/Stream call is journaled via durable-go so an in-process crash can be resumed instead of losing the in-flight agent turn. Import this package and use WithLocalConfig to customize that behavior (change the journal directory, supply a pre-built engine, tune retries/timeouts) or opt out entirely by setting [LocalConfig.Durability] to a pointer to false — see DurabilityOff.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DurabilityOff

func DurabilityOff() *bool

DurabilityOff returns a pointer to false, for [LocalConfig.Durability]. Opts a local runtime out of durable-go entirely, restoring the original pure in-memory execution path (no journal, no resume, no crash recovery — matches pre-durability behavior).

func WithLocalConfig

func WithLocalConfig(cfg *LocalConfig) agent.Option

WithLocalConfig sets durable-go execution configuration for the local runtime. Not calling this option (or passing nil) means the zero-value LocalConfig — durable by default, using an engine constructed from defaults (DataDir "./agent_data/<agent_name>", 7-day auto-purge, no run timeout). Incompatible with agent.WithTemporalConfig / an opt-in runtime factory: those runtimes don't use LocalRuntime, so a local config would be silently ignored — the agent build fails instead with a clear error.

Types

type LocalConfig

type LocalConfig = internal_local.LocalConfig

LocalConfig configures durable-go-backed execution for the local runtime. See the field docs on github.com/agenticenv/agent-sdk-go/internal/runtime/local.LocalConfig (aliased here) for full semantics: Durability, Engine, DataDir, AutoPurgeAge, AutoPurgeInterval, MaxRetries, Timeout, LockTimeout.

Jump to

Keyboard shortcuts

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