Skip to content

rulvar API reference


rulvar API reference / @rulvar/rulvar / ToolSource

Interface: ToolSource

Defined in: packages/core/dist/index.d.ts

The ToolSource seam: tools() yields the source's current ToolDefs. The toolset snapshot for a given agent spawn is captured at spawn time and hashed into the spawn's identity via toolsetHash; a mid-run change MUST NOT mutate an in-flight agent's toolset.

Properties

PropertyTypeDefined in
idstringpackages/core/dist/index.d.ts

Methods

tools()

ts
tools(session): Promise<ToolDef<SchemaSpec<unknown>>[]>;

Defined in: packages/core/dist/index.d.ts

Parameters

ParameterType
sessionToolSourceSession

Returns

Promise&lt;ToolDef&lt;SchemaSpec&lt;unknown&gt;&gt;[]&gt;