Documentation
¶
Index ¶
- Constants
- func CollectProviders(models map[string]string) []string
- func ExecInContainer(ctx context.Context, cli *client.Client, containerID string, cmd []string) (stdout, stderr string, exitCode int, err error)
- func ExpectedProviderKeys(provider string) []string
- func GenerateClawdapusMD(rc *driver.ResolvedClaw, podName string) string
- func IsFiveFieldCron(expr string) bool
- func MergeTree(dstDir, srcDir string) error
- func NormalizeProvider(provider string) string
- func ParseConfigSetCommand(line, driverPrefix string) (path string, value any, err error)
- func PlatformTokenVar(platform string) string
- func PreparePortableHistory(stateDir string, extraImportRoots ...string) (string, error)
- func PreparePortableMemory(stateDir string, extraImportRoots ...string) (string, error)
- func PrimaryModelRef(models map[string]string) (string, error)
- func ProviderAllowsEmptyAPIKey(provider string) bool
- func ResolveEnvToken(raw string) string
- func ResolveEnvTokenFromMap(env map[string]string, key string) string
- func ResolveProviderAPIKey(provider string, env map[string]string) string
- func ResolveStateDir(runtimeDir, stateDir string) string
- func SetPath(obj map[string]any, path string, value any) error
- func SplitModelRef(ref string) (string, string, bool)
Constants ¶
const ( PortableMemoryDir = "/claw/memory" PortableMemoryEnv = "CLAW_MEMORY_DIR" PortableHistoryDir = "/claw/history" PortableHistoryEnv = "CLAW_HISTORY_DIR" )
Variables ¶
This section is empty.
Functions ¶
func CollectProviders ¶ added in v0.2.0
CollectProviders returns a sorted unique provider list from MODEL refs.
func ExecInContainer ¶ added in v0.3.0
func ExpectedProviderKeys ¶ added in v0.2.0
func GenerateClawdapusMD ¶
func GenerateClawdapusMD(rc *driver.ResolvedClaw, podName string) string
GenerateClawdapusMD builds the CLAWDAPUS.md context file — the infrastructure layer's letter to the agent. Contains identity, surfaces, and skill index. Injected into the agent's context via bootstrap-extra-files hook.
func IsFiveFieldCron ¶ added in v0.3.0
func MergeTree ¶ added in v0.4.2
MergeTree recursively copies regular files from srcDir into dstDir without overwriting files that already exist in dstDir. Symlinks and special files are ignored.
func NormalizeProvider ¶ added in v0.2.0
func ParseConfigSetCommand ¶ added in v0.3.0
func PlatformTokenVar ¶
PlatformTokenVar returns the conventional env var name for a platform's bot token.
func PreparePortableHistory ¶ added in v0.4.2
PreparePortableHistory creates a read-oriented cross-driver history archive for one service and opportunistically imports native runner session stores. It is intentionally additive: existing files win, and imported history keeps runner-specific formats under subdirectories.
func PreparePortableMemory ¶ added in v0.4.2
PreparePortableMemory creates the canonical cross-driver memory directory for one service runtime and opportunistically imports memory from older layouts.
func PrimaryModelRef ¶ added in v0.3.0
func ProviderAllowsEmptyAPIKey ¶ added in v0.2.0
func ResolveEnvToken ¶ added in v0.2.0
func ResolveEnvTokenFromMap ¶ added in v0.2.0
func ResolveProviderAPIKey ¶ added in v0.2.0
func ResolveStateDir ¶ added in v0.4.2
ResolveStateDir picks the durable host state directory when one is provided, otherwise it falls back to the runtime directory for call sites that have not yet been wired for persistence-aware tests.
Types ¶
This section is empty.