UNPKG

eve

Version:

Filesystem-first framework for durable backend AI agents that run anywhere.

32 lines (31 loc) • 1.61 kB
import type { SandboxSession } from "eve/sandbox"; import type { GitHubRepository } from "./config.js"; export declare const SELF_MODIFICATION_CONFIG_PATH = "agent/extensions/self-modification/extension.ts"; export declare const WORKSPACE_PATH = "/workspace"; export declare const REPOSITORY_PATH = "/workspace/repository"; export declare const BASE_REF = "refs/eve-self-modification/base"; export interface PreparedSelfModificationWorkspace { readonly baseSha: string; readonly directory: string; readonly repository: GitHubRepository; readonly repositoryPath: string; readonly targetBranch: string; } type CheckoutSandbox = Pick<SandboxSession, "run"> & Required<Pick<SandboxSession, "setNetworkPolicy">>; /** Prepares a token-free remote and immutable target-branch checkout for one child session. */ export declare function prepareSelfModificationWorkspace(input: { readonly directory: string; readonly repository: GitHubRepository; readonly sandbox: CheckoutSandbox; readonly targetBranch: string; readonly token: string; }): Promise<PreparedSelfModificationWorkspace>; /** Reconstructs trusted workspace metadata after the session checkout preflight. */ export declare function readPreparedSelfModificationWorkspace(input: { readonly directory: string; readonly repository: GitHubRepository; readonly sandbox: Pick<SandboxSession, "run">; readonly targetBranch: string; }): Promise<PreparedSelfModificationWorkspace>; export declare function verifyApplicationRoot(sandbox: Pick<SandboxSession, "run">, directory: string): Promise<void>; export {};