import type { ExtensionAPI } from "@earendil-works/pi-coding-agent"; /** * Pi extension factory. Wires the steering engine onto pi's * lifecycle events. * * Strict-mode contract: see {@link SteeringConfig.failOnWarnings}. * * Lifecycle wiring: * * - factory time — eager load via {@link buildSessionRuntime}; * throws on diagnostic per the strict-mode * contract. * - `agent_start` — bump the internal `agentLoopIndex` counter * so tool_call / tool_result handlers can * forward it into the evaluator + dispatcher. * One agent loop = one user prompt + all the * tool calls it spawns. * - `session_start` — emit a `console.warn` if the resumed * session's `ctx.cwd` differs from the launch * cwd captured at factory time (cross-project * resume). The engine continues evaluating * with launch-cwd rules. * - `tool_call` / `tool_result` route through the evaluator and * dispatcher (see {@link buildSessionRuntime}). * * Exported as the default export per pi's extension convention. */ export default function register(pi: ExtensionAPI): Promise; export type { Command, CommandRef, EnvState, Modifier, Node, Script, SubshellSemantics, Tracker, WalkResult, Word, WordPart, } from "@cad0p/unbash-walker"; export { cwdTracker, envTracker, expandWrapperCommands, extractAllCommandsFromAST, formatCommand, getBasename, getCommandArgs, getCommandName, isStaticallyResolvable, parse, resolveWord, walk, } from "@cad0p/unbash-walker"; export { FromJSONError, fromJSON } from "./compat.ts"; export { DEFAULT_PLUGINS, DEFAULT_RULES } from "./defaults.ts"; export type { DefineConfigInput } from "./define-config.ts"; export { defineConfig } from "./define-config.ts"; export { definePredicate } from "./define-predicate.ts"; export { AGENT_LOOP_INDEX_KEY } from "./evaluator-internals/context.ts"; export { walkerUnknownCwdReason } from "./helpers/walker-unknown-cwd-reason.ts"; export { buildConfig, loadConfigs, loadSteeringConfig } from "./loader.ts"; export type { AnyPredicateHandler, BaseRule, BashRule, BuiltInWhenLeaves, BuiltInWhenLeavesInner, BuiltInWhenLeavesOuter, DefaultSpreadBase, EditRule, ExecOpts, ExecResult, InnerValue, Observer, ObserverContext, ObserverWatch, OperatorField, OuterValue, Pattern, Patterns, Plugin, PluginPredicateKey, PredicateContext, PredicateFn, PredicateHandler, PredicateModifiers, PredicateShape, PredicateToolInput, PredicateVerdict, ReasonFn, ReservedPredicateKey, Rule, SteeringConfig, SteeringDiagnostic, SteeringDiagnosticKind, ToolResultEvent, TopLevelWhenClause, TopLevelWhenClauseNoRecurse, WhenClause, WhenWalkerState, WriteRule, } from "./schema.ts"; export type { BashShorthand, CreateRecordingHostOptions, EditShorthand, ExpectBlocksOptions, Harness, LoadHarnessOptions, MatrixCase, MatrixCaseResult, MatrixResult, MockContextOptions, MockEntry, MockObserverContextOptions, PriorEntryOptions, RecordedExecCall, RecordedSessionEntry, RecordingHost, ToolCallShorthand, ToolResultShorthand, WriteShorthand, } from "./testing/index.ts"; export { createRecordingHost, expectAllows, expectBlocks, expectRuleFires, formatMatrix, getAppendedEntries, loadHarness, mockContext, mockExtensionContext, mockObserverContext, priorEntry, runMatrix, testObserver, testPredicate, } from "./testing/index.ts"; //# sourceMappingURL=index.d.ts.map