MCPcopy Create free account
hub / github.com/anus-dev/ANUS / silentBuild

Function silentBuild

packages/core/src/tools/tools.ts:210–221  ·  view source on GitHub ↗

* Similar to `build` but never throws. * @param params The raw, untrusted parameters from the model. * @returns A `ToolInvocation` instance.

(
    params: TParams,
  )

Source from the content-addressed store, hash-verified

208 * @returns A `ToolInvocation` instance.
209 */
210 private silentBuild(
211 params: TParams,
212 ): ToolInvocation<TParams, TResult> | Error {
213 try {
214 return this.build(params);
215 } catch (e) {
216 if (e instanceof Error) {
217 return e;
218 }
219 return new Error(String(e));
220 }
221 }
222
223 /**
224 * A convenience method that builds and executes the tool in one step.

Callers

nothing calls this directly

Calls 1

buildMethod · 0.65

Tested by

no test coverage detected