refactor(contracts): remove duplicate schema aliases
This commit is contained in:
@@ -67,19 +67,3 @@ export const compareJavaScriptExportShapesRequestSchema = z.strictObject({
|
||||
left: evidenceSchema,
|
||||
right: evidenceSchema,
|
||||
});
|
||||
|
||||
export type TraceApplicationFeatureRequest = z.output<
|
||||
typeof traceApplicationFeatureRequestSchema
|
||||
>;
|
||||
export type TraceJavaScriptSemanticsRequest = z.output<
|
||||
typeof traceJavaScriptSemanticsRequestSchema
|
||||
>;
|
||||
export type CompareApplicationVersionsRequest = z.output<
|
||||
typeof compareApplicationVersionsRequestSchema
|
||||
>;
|
||||
export type CompareSourceToBundleRequest = z.output<
|
||||
typeof compareSourceToBundleRequestSchema
|
||||
>;
|
||||
export type CompareJavaScriptExportShapesRequest = z.output<
|
||||
typeof compareJavaScriptExportShapesRequestSchema
|
||||
>;
|
||||
|
||||
@@ -1,12 +1,12 @@
|
||||
import type { ToolContract } from "./toolContracts.js";
|
||||
import {
|
||||
browserTargetListSchema,
|
||||
inspectWebPageToolInputSchema,
|
||||
inspectWebPageInputSchema,
|
||||
listBrowserTargetsInputSchema,
|
||||
webPageInspectionSchema,
|
||||
} from "../domain/browserObservation.js";
|
||||
import {
|
||||
analyzeWebBundleToolInputSchema,
|
||||
analyzeWebBundleInputSchema,
|
||||
webBundleAnalysisSchema,
|
||||
} from "../domain/webBundleAnalysis.js";
|
||||
import {
|
||||
@@ -140,7 +140,7 @@ export const BROWSER_TOOL_CONTRACTS = [
|
||||
description:
|
||||
"Passively inspect one approved page target through CDP without evaluating JavaScript, navigating, clicking, closing, or mutating the page. Returns DOM structure, accessibility, scripts, resources, attach-window network and console metadata, workers, and redacted storage inventory as Evidence.",
|
||||
kind: "browser-provider",
|
||||
inputSchema: inspectWebPageToolInputSchema,
|
||||
inputSchema: inspectWebPageInputSchema,
|
||||
outputSchema: inspectionOutputSchema,
|
||||
examples: [
|
||||
{
|
||||
@@ -159,7 +159,7 @@ export const BROWSER_TOOL_CONTRACTS = [
|
||||
description:
|
||||
"Capture JavaScript source from one configured CDP page and statically derive a chunk graph, route and endpoint candidates, vendor fingerprints, page-declared WebMCP metadata, and optionally fetch source maps from allowed origins. JavaScript is parsed but never executed.",
|
||||
kind: "browser-provider",
|
||||
inputSchema: analyzeWebBundleToolInputSchema,
|
||||
inputSchema: analyzeWebBundleInputSchema,
|
||||
outputSchema: bundleOutputSchema,
|
||||
examples: [
|
||||
{
|
||||
|
||||
@@ -4,7 +4,7 @@ import { evidenceResultOf } from "./toolOutputSchemas.js";
|
||||
import {
|
||||
electronPageInspectionSchema,
|
||||
electronTargetListSchema,
|
||||
inspectElectronPageToolInputSchema,
|
||||
inspectElectronPageInputSchema,
|
||||
listElectronTargetsInputSchema,
|
||||
} from "../domain/electronObservation.js";
|
||||
import {
|
||||
@@ -64,7 +64,7 @@ export const ELECTRON_TOOL_CONTRACTS = [
|
||||
description:
|
||||
"Passively inspect one Electron file page by supplying its loopback CDP endpoint and target ID. The provider rechecks that the target currently exists at that endpoint and is a local file page. Returns frames, DOM structure, resource paths, and scripts without evaluating renderer JavaScript or invoking Electron APIs. The selected endpoint exposes every local file page and its metadata to this tool.",
|
||||
kind: "electron-provider",
|
||||
inputSchema: inspectElectronPageToolInputSchema,
|
||||
inputSchema: inspectElectronPageInputSchema,
|
||||
outputSchema: inspectionOutputSchema,
|
||||
examples: [
|
||||
{
|
||||
|
||||
@@ -5,7 +5,7 @@ import {
|
||||
javascriptRuntimeObservationSchema,
|
||||
javascriptRuntimeTargetListSchema,
|
||||
listJavaScriptRuntimeTargetsInputSchema,
|
||||
observeJavaScriptRuntimeToolInputSchema,
|
||||
observeJavaScriptRuntimeInputSchema,
|
||||
} from "../domain/javascriptRuntimeObservation.js";
|
||||
|
||||
const endpoint = "http://127.0.0.1:9229";
|
||||
@@ -35,7 +35,7 @@ export const JAVASCRIPT_RUNTIME_OBSERVATION_TOOL_CONTRACTS = [
|
||||
description:
|
||||
"Attach passively to one Node/Electron V8 Inspector target by supplying its loopback Inspector endpoint and target ID. The provider rechecks that the target currently exists at that endpoint and is an attachable file or URL target. Captures Debugger.scriptParsed and Runtime execution-context events. REA never evaluates, pauses, resumes, reads source, or instruments the target; require/import edges, EventEmitter activity, and Electron IPC remain explicit unknowns. Reconcile the result with static Application Graph Evidence using reconcile_javascript_runtime. The selected endpoint exposes every target it serves to this tool.",
|
||||
kind: "runtime-provider",
|
||||
inputSchema: observeJavaScriptRuntimeToolInputSchema,
|
||||
inputSchema: observeJavaScriptRuntimeInputSchema,
|
||||
outputSchema: evidenceResultOf(javascriptRuntimeObservationSchema),
|
||||
examples: [
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user