@wowok/agent-mcp 2.5.1 → 2.5.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/knowledge/mcp-schema-audit.js +3 -2
- package/dist/project/business-puzzle.d.ts +1 -0
- package/dist/project/business-puzzle.js +11 -0
- package/dist/project/deployment-doc.d.ts +11 -0
- package/dist/project/deployment-doc.js +37 -0
- package/dist/project/index.d.ts +25 -0
- package/dist/project/index.js +42 -0
- package/dist/project/risk-aggregator.d.ts +7 -0
- package/dist/project/risk-aggregator.js +15 -0
- package/dist/schema/call/base.js +2 -2
- package/dist/schema/project/index.d.ts +203 -3
- package/dist/schema/project/index.js +45 -0
- package/dist/schemas/index.json +1 -1
- package/dist/schemas/onchain_operations_guard.schema.json +0 -577
- package/dist/schemas/project_operation.output.json +157 -0
- package/dist/schemas/project_operation.schema.json +2 -1
- package/dist/tools/handlers/project.js +47 -2
- package/dist/tools/index.js +346 -37
- package/dist/tools/wrap.js +61 -7
- package/package.json +1 -1
- package/dist/schemas/onchain_operations.output.json +0 -2819
|
@@ -484,7 +484,7 @@ export function analyzeHandlerTypeSafety(instances) {
|
|
|
484
484
|
export function analyzeOutputSchemaCoverage(census) {
|
|
485
485
|
const findings = [];
|
|
486
486
|
for (const c of census) {
|
|
487
|
-
if (!c.layer3_generated.output_exists) {
|
|
487
|
+
if (!c.layer3_generated.output_exists && c.name !== "onchain_operations") {
|
|
488
488
|
findings.push({
|
|
489
489
|
rule_id: 'MCP-OUTPUT-001',
|
|
490
490
|
severity: 'high',
|
|
@@ -559,7 +559,7 @@ export function analyzeSchemaQueryReflection(census) {
|
|
|
559
559
|
fix: `Run pnpm generate:schemas.`,
|
|
560
560
|
});
|
|
561
561
|
}
|
|
562
|
-
if (!c.layer3_generated.output_exists) {
|
|
562
|
+
if (!c.layer3_generated.output_exists && c.name !== "onchain_operations") {
|
|
563
563
|
findings.push({
|
|
564
564
|
rule_id: 'MCP-REFLECT-002',
|
|
565
565
|
severity: 'medium',
|
|
@@ -574,6 +574,7 @@ export function analyzeSchemaQueryReflection(census) {
|
|
|
574
574
|
'permission', 'service', 'machine', 'progress', 'guard',
|
|
575
575
|
'arbitration', 'repository', 'contact', 'treasury', 'reward',
|
|
576
576
|
'allocation', 'personal', 'payment', 'demand', 'order', 'gen_passport',
|
|
577
|
+
'proof', 'gen_proof',
|
|
577
578
|
];
|
|
578
579
|
for (const op of onchainOps) {
|
|
579
580
|
const opFile = path.join(GENERATED_SCHEMAS_DIR, `onchain_operations_${op}.schema.json`);
|
|
@@ -26,6 +26,7 @@ export interface BusinessPuzzleResult {
|
|
|
26
26
|
puzzles: Record<string, ObjectPuzzleEntry>;
|
|
27
27
|
overall_completeness: "complete" | "partial" | "empty";
|
|
28
28
|
next_step: string;
|
|
29
|
+
recommended_creation_order: string[];
|
|
29
30
|
warnings: string[];
|
|
30
31
|
}
|
|
31
32
|
export interface KeywordMatch {
|
|
@@ -246,6 +246,7 @@ export function analyzeBusinessIntent(input) {
|
|
|
246
246
|
puzzles: {},
|
|
247
247
|
overall_completeness: "empty",
|
|
248
248
|
next_step: "Please provide a non-empty business intent.",
|
|
249
|
+
recommended_creation_order: [],
|
|
249
250
|
warnings: ["input.user_intent is empty"],
|
|
250
251
|
};
|
|
251
252
|
}
|
|
@@ -295,8 +296,17 @@ export function analyzeBusinessIntent(input) {
|
|
|
295
296
|
puzzles,
|
|
296
297
|
overall_completeness: overall,
|
|
297
298
|
next_step: "",
|
|
299
|
+
recommended_creation_order: [],
|
|
298
300
|
warnings,
|
|
299
301
|
});
|
|
302
|
+
const creationOrder = [
|
|
303
|
+
"permission",
|
|
304
|
+
"progress",
|
|
305
|
+
"guard",
|
|
306
|
+
"allocation",
|
|
307
|
+
"machine",
|
|
308
|
+
"service",
|
|
309
|
+
];
|
|
300
310
|
return {
|
|
301
311
|
intent_parsed: {
|
|
302
312
|
primary_object: primary,
|
|
@@ -308,6 +318,7 @@ export function analyzeBusinessIntent(input) {
|
|
|
308
318
|
puzzles,
|
|
309
319
|
overall_completeness: overall,
|
|
310
320
|
next_step: nextStep,
|
|
321
|
+
recommended_creation_order: creationOrder,
|
|
311
322
|
warnings,
|
|
312
323
|
};
|
|
313
324
|
}
|
|
@@ -56,6 +56,17 @@ export interface DeploymentDocValidationResult {
|
|
|
56
56
|
}>;
|
|
57
57
|
errors: string[];
|
|
58
58
|
}
|
|
59
|
+
export interface GasEstimate {
|
|
60
|
+
total_gas_mist: number;
|
|
61
|
+
per_object: Array<{
|
|
62
|
+
entry_id: string;
|
|
63
|
+
object_type: string;
|
|
64
|
+
create_gas_mist: number;
|
|
65
|
+
publish_gas_mist: number;
|
|
66
|
+
}>;
|
|
67
|
+
publish_gas_mist: number;
|
|
68
|
+
}
|
|
59
69
|
export declare function generateDeploymentDoc(input: DeploymentDocInput): string;
|
|
70
|
+
export declare function estimateDeploymentGas(input: Pick<DeploymentDocInput, "objects">): GasEstimate;
|
|
60
71
|
export declare function validateDeploymentDoc(input: DeploymentDocInput): DeploymentDocValidationResult;
|
|
61
72
|
export declare function getStandardTopoOrder(): ProjectObjectType[];
|
|
@@ -300,6 +300,43 @@ export function generateDeploymentDoc(input) {
|
|
|
300
300
|
];
|
|
301
301
|
return sections.filter((s) => s.length > 0).join("\n");
|
|
302
302
|
}
|
|
303
|
+
export function estimateDeploymentGas(input) {
|
|
304
|
+
const GAS_RATES = {
|
|
305
|
+
permission: { create: 20_000_000, publish: 0 },
|
|
306
|
+
progress: { create: 40_000_000, publish: 0 },
|
|
307
|
+
guard: { create: 30_000_000, publish: 0 },
|
|
308
|
+
allocation: { create: 40_000_000, publish: 0 },
|
|
309
|
+
machine: { create: 50_000_000, publish: 200_000_000 },
|
|
310
|
+
service: { create: 50_000_000, publish: 100_000_000 },
|
|
311
|
+
arb: { create: 40_000_000, publish: 0 },
|
|
312
|
+
treasury: { create: 30_000_000, publish: 0 },
|
|
313
|
+
demand: { create: 40_000_000, publish: 0 },
|
|
314
|
+
repository: { create: 40_000_000, publish: 0 },
|
|
315
|
+
reward: { create: 30_000_000, publish: 0 },
|
|
316
|
+
};
|
|
317
|
+
const perObject = [];
|
|
318
|
+
let totalGas = 0;
|
|
319
|
+
let publishGas = 0;
|
|
320
|
+
for (const obj of input.objects) {
|
|
321
|
+
const rate = GAS_RATES[obj.object_type] ?? { create: 40_000_000, publish: 0 };
|
|
322
|
+
const createGas = obj.reused_from ? 0 : rate.create;
|
|
323
|
+
const pubGas = obj.publish_required ? rate.publish : 0;
|
|
324
|
+
const objTotal = createGas + pubGas;
|
|
325
|
+
perObject.push({
|
|
326
|
+
entry_id: obj.entry_id,
|
|
327
|
+
object_type: obj.object_type,
|
|
328
|
+
create_gas_mist: createGas,
|
|
329
|
+
publish_gas_mist: pubGas,
|
|
330
|
+
});
|
|
331
|
+
totalGas += objTotal;
|
|
332
|
+
publishGas += pubGas;
|
|
333
|
+
}
|
|
334
|
+
return {
|
|
335
|
+
total_gas_mist: totalGas,
|
|
336
|
+
per_object: perObject,
|
|
337
|
+
publish_gas_mist: publishGas,
|
|
338
|
+
};
|
|
339
|
+
}
|
|
303
340
|
export function validateDeploymentDoc(input) {
|
|
304
341
|
const errors = [];
|
|
305
342
|
const checks = [];
|
package/dist/project/index.d.ts
CHANGED
|
@@ -7,6 +7,31 @@ export * from "./query.js";
|
|
|
7
7
|
export declare function isProjectServiceEnabled(): boolean;
|
|
8
8
|
export declare function getGraph(): ProjectGraph;
|
|
9
9
|
export declare function setGraph(g: ProjectGraph): void;
|
|
10
|
+
export type ProjectStage = 1 | 2 | 3 | 4 | 5;
|
|
11
|
+
export interface StageCacheEntry {
|
|
12
|
+
stage: ProjectStage;
|
|
13
|
+
updated_at: number;
|
|
14
|
+
puzzles?: Record<string, unknown>;
|
|
15
|
+
risk_status?: string;
|
|
16
|
+
risk_can_proceed?: boolean;
|
|
17
|
+
doc_generated?: boolean;
|
|
18
|
+
doc_error_count?: number;
|
|
19
|
+
trace_coherent?: boolean;
|
|
20
|
+
trace_can_proceed?: boolean;
|
|
21
|
+
business_intent?: string;
|
|
22
|
+
industry?: string;
|
|
23
|
+
}
|
|
24
|
+
export declare function getStageCache(prefix: string, version: string): StageCacheEntry | undefined;
|
|
25
|
+
export declare function updateStageCache(prefix: string, version: string, update: Partial<StageCacheEntry>): StageCacheEntry;
|
|
26
|
+
export declare function getProjectStatus(prefix: string, version: string): {
|
|
27
|
+
stage: ProjectStage;
|
|
28
|
+
stage_name: string;
|
|
29
|
+
stage_description: string;
|
|
30
|
+
next_action: string;
|
|
31
|
+
can_proceed: boolean;
|
|
32
|
+
details: StageCacheEntry | undefined;
|
|
33
|
+
};
|
|
34
|
+
export declare function clearStageCache(prefix: string, version: string): void;
|
|
10
35
|
export interface NormalizeCallInput {
|
|
11
36
|
operation_type: string;
|
|
12
37
|
data: any;
|
package/dist/project/index.js
CHANGED
|
@@ -62,6 +62,48 @@ export function getGraph() {
|
|
|
62
62
|
export function setGraph(g) {
|
|
63
63
|
GRAPH_INSTANCE = g;
|
|
64
64
|
}
|
|
65
|
+
const STAGE_CACHE = new Map();
|
|
66
|
+
function stageCacheKey(prefix, version) {
|
|
67
|
+
return `${prefix}:${version}`;
|
|
68
|
+
}
|
|
69
|
+
export function getStageCache(prefix, version) {
|
|
70
|
+
return STAGE_CACHE.get(stageCacheKey(prefix, version));
|
|
71
|
+
}
|
|
72
|
+
export function updateStageCache(prefix, version, update) {
|
|
73
|
+
const key = stageCacheKey(prefix, version);
|
|
74
|
+
const existing = STAGE_CACHE.get(key);
|
|
75
|
+
const entry = {
|
|
76
|
+
stage: update.stage ?? existing?.stage ?? 1,
|
|
77
|
+
updated_at: Date.now(),
|
|
78
|
+
...existing,
|
|
79
|
+
...update,
|
|
80
|
+
};
|
|
81
|
+
STAGE_CACHE.set(key, entry);
|
|
82
|
+
return entry;
|
|
83
|
+
}
|
|
84
|
+
export function getProjectStatus(prefix, version) {
|
|
85
|
+
const entry = getStageCache(prefix, version);
|
|
86
|
+
const stage = entry?.stage ?? 1;
|
|
87
|
+
const stageInfo = {
|
|
88
|
+
1: { name: "Project Naming", description: "Project namespace established. Ready to analyze business intent.", next: "analyze_intent" },
|
|
89
|
+
2: { name: "Business Puzzle", description: "Business intent analyzed. Puzzles may need completion before risk assessment.", next: entry?.puzzles ? "aggregate_risks" : "analyze_intent" },
|
|
90
|
+
3: { name: "Risk Calibration", description: "Risks assessed. Fix CRITICAL risks before generating deployment doc.", next: entry?.risk_can_proceed ? "generate_deployment_doc" : "aggregate_risks" },
|
|
91
|
+
4: { name: "Deployment Document", description: "Deployment doc generated. Fix D-errors before substep trace.", next: entry?.doc_error_count === 0 ? "trace_substeps" : "generate_deployment_doc" },
|
|
92
|
+
5: { name: "Substep Trace", description: "Substeps traced. Ready for deployment execution.", next: entry?.trace_can_proceed ? "deploy" : "trace_substeps" },
|
|
93
|
+
};
|
|
94
|
+
const info = stageInfo[stage];
|
|
95
|
+
return {
|
|
96
|
+
stage,
|
|
97
|
+
stage_name: info.name,
|
|
98
|
+
stage_description: info.description,
|
|
99
|
+
next_action: info.next,
|
|
100
|
+
can_proceed: stage < 5,
|
|
101
|
+
details: entry,
|
|
102
|
+
};
|
|
103
|
+
}
|
|
104
|
+
export function clearStageCache(prefix, version) {
|
|
105
|
+
STAGE_CACHE.delete(stageCacheKey(prefix, version));
|
|
106
|
+
}
|
|
65
107
|
export function normalize(input) {
|
|
66
108
|
if (!isProjectServiceEnabled()) {
|
|
67
109
|
return { data: input.data, warnings: [] };
|
|
@@ -40,6 +40,13 @@ export interface RiskAggregationResult {
|
|
|
40
40
|
entry_id: string;
|
|
41
41
|
}>;
|
|
42
42
|
calibrated_at: number;
|
|
43
|
+
fix_suggestions_grouped?: Record<string, Array<{
|
|
44
|
+
risk_rule_id: string;
|
|
45
|
+
severity: RiskSeverity;
|
|
46
|
+
message: string;
|
|
47
|
+
fix_suggestion: string;
|
|
48
|
+
entry_id: string;
|
|
49
|
+
}>>;
|
|
43
50
|
warnings: string[];
|
|
44
51
|
}
|
|
45
52
|
export declare function aggregateProjectRisks(input: RiskAggregationInput): RiskAggregationResult;
|
|
@@ -179,6 +179,20 @@ export function aggregateProjectRisks(input) {
|
|
|
179
179
|
entry_id: f.entry_id,
|
|
180
180
|
}));
|
|
181
181
|
}
|
|
182
|
+
const fixSuggestionsGrouped = {};
|
|
183
|
+
for (const finding of findings) {
|
|
184
|
+
const key = finding.object_type;
|
|
185
|
+
if (!fixSuggestionsGrouped[key]) {
|
|
186
|
+
fixSuggestionsGrouped[key] = [];
|
|
187
|
+
}
|
|
188
|
+
fixSuggestionsGrouped[key].push({
|
|
189
|
+
risk_rule_id: finding.risk_rule_id,
|
|
190
|
+
severity: finding.severity,
|
|
191
|
+
message: finding.message,
|
|
192
|
+
fix_suggestion: finding.fix_suggestion,
|
|
193
|
+
entry_id: finding.entry_id,
|
|
194
|
+
});
|
|
195
|
+
}
|
|
182
196
|
return {
|
|
183
197
|
namespace: {
|
|
184
198
|
prefix: input.project_prefix ?? "",
|
|
@@ -190,6 +204,7 @@ export function aggregateProjectRisks(input) {
|
|
|
190
204
|
status,
|
|
191
205
|
pending_confirmations,
|
|
192
206
|
calibrated_at: Date.now(),
|
|
207
|
+
fix_suggestions_grouped: fixSuggestionsGrouped,
|
|
193
208
|
warnings,
|
|
194
209
|
};
|
|
195
210
|
}
|
package/dist/schema/call/base.js
CHANGED
|
@@ -340,9 +340,9 @@ export const SchemaWarningSchema = z.object({
|
|
|
340
340
|
}).describe("Server-side schema versions."),
|
|
341
341
|
}).strict().describe("Schema compatibility warning attached to tool output when client_schema_version is provided and a mismatch is detected.");
|
|
342
342
|
export const CallOutputSchema = z.object({
|
|
343
|
-
result: CallResultSchema.describe("Discriminated result. Check result.type first: 'transaction'|'submission'|'error'|'data'|'null'. Each variant has different fields."),
|
|
343
|
+
result: CallResultSchema.describe("Discriminated result. Check result.type first: 'transaction'|'submission'|'error'|'data'|'null'|'pending_confirmation'. Each variant has different fields."),
|
|
344
344
|
message: z.string().optional().describe("Human-readable summary or hint. Constraint: always present for error/transaction results; may be omitted for data/null. Example: 'Transaction completed successfully'"),
|
|
345
345
|
semantic: SemanticSummarySchema.optional().describe("Business semantic summary. AI should read semantic first; fall back to parsing result only when semantic is absent. Relation: populated by MCP server from operation context; undefined when intent cannot be confidently inferred or for non-transaction tools. Example: {intent:'publish_service', status:'success', summary:'...'}"),
|
|
346
346
|
harness_report: HarnessReportSchema.optional().describe("L4 Harness report (Verify + Recover). Present only when the Harness is injected and an Expected Result was declared for this operation. Relation: produced by handler.ts calling harness.verify() and harness.recover(). Example: {verify:{status:'fail', mismatches:[...]}, recovery:{strategy:'recreate'}}"),
|
|
347
347
|
schema_warning: SchemaWarningSchema.optional().describe("Schema compatibility warning. Present only when client_schema_version is provided in env and a mismatch is detected."),
|
|
348
|
-
}).strict().describe("Unified MCP tool output. result.type discriminates
|
|
348
|
+
}).strict().describe("Unified MCP tool output. result.type discriminates 6 outcomes: 'transaction' (raw Wow response), 'submission' (needs Guard data), 'error' (failed with error_code), 'data' (query result), 'null' (no-op), 'pending_confirmation' (ConfirmGate blocked — re-call with env.confirmed=true). When semantic is present, prefer it over raw result parsing. When harness_report is present, check verify.status first and follow recovery.strategy if status is 'fail'.");
|
|
@@ -2,7 +2,7 @@ import { z } from "zod";
|
|
|
2
2
|
export declare const ProjectObjectTypeEnum: z.ZodEnum<["service", "machine", "guard", "permission", "reward", "arb", "progress", "treasury", "demand", "repository", "contact", "order", "allocation", "personal", "payment", "proof"]>;
|
|
3
3
|
export declare const EdgeKindEnum: z.ZodEnum<["machine", "order_allocators", "arbitrations", "compensation_fund", "rewards", "buy_guard", "permission", "guard", "prev", "next", "forward", "parent", "service", "progress", "arbitration", "sub_order", "references"]>;
|
|
4
4
|
export declare const ProjectOperationInputSchema: z.ZodObject<{
|
|
5
|
-
action: z.ZodEnum<["list_projects", "list_objects", "shareable", "dependencies", "referenced_by", "pre_publish_check", "cross_project_refs", "graph_stats", "save_graph", "load_graph", "analyze_intent", "aggregate_risks", "generate_deployment_doc", "trace_substeps"]>;
|
|
5
|
+
action: z.ZodEnum<["list_projects", "list_objects", "shareable", "dependencies", "referenced_by", "pre_publish_check", "cross_project_refs", "graph_stats", "save_graph", "load_graph", "analyze_intent", "aggregate_risks", "generate_deployment_doc", "trace_substeps", "get_project_status"]>;
|
|
6
6
|
project: z.ZodOptional<z.ZodString>;
|
|
7
7
|
version: z.ZodOptional<z.ZodString>;
|
|
8
8
|
object: z.ZodOptional<z.ZodString>;
|
|
@@ -246,7 +246,7 @@ export declare const ProjectOperationInputSchema: z.ZodObject<{
|
|
|
246
246
|
} | undefined;
|
|
247
247
|
}>, "many">>;
|
|
248
248
|
}, "strict", z.ZodTypeAny, {
|
|
249
|
-
action: "dependencies" | "pre_publish_check" | "referenced_by" | "list_projects" | "list_objects" | "shareable" | "cross_project_refs" | "graph_stats" | "save_graph" | "load_graph" | "analyze_intent" | "aggregate_risks" | "generate_deployment_doc" | "trace_substeps";
|
|
249
|
+
action: "dependencies" | "pre_publish_check" | "referenced_by" | "list_projects" | "list_objects" | "shareable" | "cross_project_refs" | "graph_stats" | "save_graph" | "load_graph" | "analyze_intent" | "aggregate_risks" | "generate_deployment_doc" | "trace_substeps" | "get_project_status";
|
|
250
250
|
object?: string | undefined;
|
|
251
251
|
version?: string | undefined;
|
|
252
252
|
network?: "testnet" | "mainnet" | undefined;
|
|
@@ -330,7 +330,7 @@ export declare const ProjectOperationInputSchema: z.ZodObject<{
|
|
|
330
330
|
} | undefined;
|
|
331
331
|
}[] | undefined;
|
|
332
332
|
}, {
|
|
333
|
-
action: "dependencies" | "pre_publish_check" | "referenced_by" | "list_projects" | "list_objects" | "shareable" | "cross_project_refs" | "graph_stats" | "save_graph" | "load_graph" | "analyze_intent" | "aggregate_risks" | "generate_deployment_doc" | "trace_substeps";
|
|
333
|
+
action: "dependencies" | "pre_publish_check" | "referenced_by" | "list_projects" | "list_objects" | "shareable" | "cross_project_refs" | "graph_stats" | "save_graph" | "load_graph" | "analyze_intent" | "aggregate_risks" | "generate_deployment_doc" | "trace_substeps" | "get_project_status";
|
|
334
334
|
object?: string | undefined;
|
|
335
335
|
version?: string | undefined;
|
|
336
336
|
network?: "testnet" | "mainnet" | undefined;
|
|
@@ -589,6 +589,7 @@ export declare const ProjectOperationOutputSchema: z.ZodObject<{
|
|
|
589
589
|
}>>;
|
|
590
590
|
overall_completeness: z.ZodEnum<["complete", "partial", "empty"]>;
|
|
591
591
|
next_step: z.ZodString;
|
|
592
|
+
recommended_creation_order: z.ZodArray<z.ZodString, "many">;
|
|
592
593
|
next_action: z.ZodEnum<["aggregate_risks", "none"]>;
|
|
593
594
|
warnings: z.ZodArray<z.ZodString, "many">;
|
|
594
595
|
}, "strict", z.ZodTypeAny, {
|
|
@@ -617,6 +618,7 @@ export declare const ProjectOperationOutputSchema: z.ZodObject<{
|
|
|
617
618
|
};
|
|
618
619
|
overall_completeness: "partial" | "complete" | "empty";
|
|
619
620
|
next_step: string;
|
|
621
|
+
recommended_creation_order: string[];
|
|
620
622
|
next_action: "none" | "aggregate_risks";
|
|
621
623
|
}, {
|
|
622
624
|
action: "analyze_intent";
|
|
@@ -644,6 +646,7 @@ export declare const ProjectOperationOutputSchema: z.ZodObject<{
|
|
|
644
646
|
};
|
|
645
647
|
overall_completeness: "partial" | "complete" | "empty";
|
|
646
648
|
next_step: string;
|
|
649
|
+
recommended_creation_order: string[];
|
|
647
650
|
next_action: "none" | "aggregate_risks";
|
|
648
651
|
}>, z.ZodObject<{
|
|
649
652
|
action: z.ZodLiteral<"aggregate_risks">;
|
|
@@ -739,6 +742,25 @@ export declare const ProjectOperationOutputSchema: z.ZodObject<{
|
|
|
739
742
|
risk_rule_id: string;
|
|
740
743
|
fix_suggestion: string;
|
|
741
744
|
}>, "many">>;
|
|
745
|
+
fix_suggestions_grouped: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodArray<z.ZodObject<{
|
|
746
|
+
risk_rule_id: z.ZodString;
|
|
747
|
+
severity: z.ZodEnum<["CRITICAL", "HIGH", "MEDIUM", "LOW", "INFO"]>;
|
|
748
|
+
message: z.ZodString;
|
|
749
|
+
fix_suggestion: z.ZodString;
|
|
750
|
+
entry_id: z.ZodString;
|
|
751
|
+
}, "strip", z.ZodTypeAny, {
|
|
752
|
+
message: string;
|
|
753
|
+
severity: "CRITICAL" | "HIGH" | "MEDIUM" | "LOW" | "INFO";
|
|
754
|
+
entry_id: string;
|
|
755
|
+
risk_rule_id: string;
|
|
756
|
+
fix_suggestion: string;
|
|
757
|
+
}, {
|
|
758
|
+
message: string;
|
|
759
|
+
severity: "CRITICAL" | "HIGH" | "MEDIUM" | "LOW" | "INFO";
|
|
760
|
+
entry_id: string;
|
|
761
|
+
risk_rule_id: string;
|
|
762
|
+
fix_suggestion: string;
|
|
763
|
+
}>, "many">>>;
|
|
742
764
|
calibrated_at: z.ZodNumber;
|
|
743
765
|
warnings: z.ZodArray<z.ZodString, "many">;
|
|
744
766
|
can_proceed: z.ZodBoolean;
|
|
@@ -783,6 +805,13 @@ export declare const ProjectOperationOutputSchema: z.ZodObject<{
|
|
|
783
805
|
risk_rule_id: string;
|
|
784
806
|
fix_suggestion: string;
|
|
785
807
|
}[] | undefined;
|
|
808
|
+
fix_suggestions_grouped?: Record<string, {
|
|
809
|
+
message: string;
|
|
810
|
+
severity: "CRITICAL" | "HIGH" | "MEDIUM" | "LOW" | "INFO";
|
|
811
|
+
entry_id: string;
|
|
812
|
+
risk_rule_id: string;
|
|
813
|
+
fix_suggestion: string;
|
|
814
|
+
}[]> | undefined;
|
|
786
815
|
}, {
|
|
787
816
|
status: "RISK_PASSED" | "RISK_BLOCKED" | "RISK_PENDING_CONFIRM" | "RISK_CANCELLED";
|
|
788
817
|
action: "aggregate_risks";
|
|
@@ -822,6 +851,13 @@ export declare const ProjectOperationOutputSchema: z.ZodObject<{
|
|
|
822
851
|
risk_rule_id: string;
|
|
823
852
|
fix_suggestion: string;
|
|
824
853
|
}[] | undefined;
|
|
854
|
+
fix_suggestions_grouped?: Record<string, {
|
|
855
|
+
message: string;
|
|
856
|
+
severity: "CRITICAL" | "HIGH" | "MEDIUM" | "LOW" | "INFO";
|
|
857
|
+
entry_id: string;
|
|
858
|
+
risk_rule_id: string;
|
|
859
|
+
fix_suggestion: string;
|
|
860
|
+
}[]> | undefined;
|
|
825
861
|
}>, z.ZodObject<{
|
|
826
862
|
action: z.ZodLiteral<"generate_deployment_doc">;
|
|
827
863
|
markdown: z.ZodString;
|
|
@@ -882,6 +918,44 @@ export declare const ProjectOperationOutputSchema: z.ZodObject<{
|
|
|
882
918
|
notes?: string | undefined;
|
|
883
919
|
}[];
|
|
884
920
|
}>>;
|
|
921
|
+
estimated_gas: z.ZodOptional<z.ZodObject<{
|
|
922
|
+
total_gas_mist: z.ZodNumber;
|
|
923
|
+
per_object: z.ZodArray<z.ZodObject<{
|
|
924
|
+
entry_id: z.ZodString;
|
|
925
|
+
object_type: z.ZodString;
|
|
926
|
+
create_gas_mist: z.ZodNumber;
|
|
927
|
+
publish_gas_mist: z.ZodNumber;
|
|
928
|
+
}, "strip", z.ZodTypeAny, {
|
|
929
|
+
object_type: string;
|
|
930
|
+
entry_id: string;
|
|
931
|
+
create_gas_mist: number;
|
|
932
|
+
publish_gas_mist: number;
|
|
933
|
+
}, {
|
|
934
|
+
object_type: string;
|
|
935
|
+
entry_id: string;
|
|
936
|
+
create_gas_mist: number;
|
|
937
|
+
publish_gas_mist: number;
|
|
938
|
+
}>, "many">;
|
|
939
|
+
publish_gas_mist: z.ZodNumber;
|
|
940
|
+
}, "strip", z.ZodTypeAny, {
|
|
941
|
+
total_gas_mist: number;
|
|
942
|
+
per_object: {
|
|
943
|
+
object_type: string;
|
|
944
|
+
entry_id: string;
|
|
945
|
+
create_gas_mist: number;
|
|
946
|
+
publish_gas_mist: number;
|
|
947
|
+
}[];
|
|
948
|
+
publish_gas_mist: number;
|
|
949
|
+
}, {
|
|
950
|
+
total_gas_mist: number;
|
|
951
|
+
per_object: {
|
|
952
|
+
object_type: string;
|
|
953
|
+
entry_id: string;
|
|
954
|
+
create_gas_mist: number;
|
|
955
|
+
publish_gas_mist: number;
|
|
956
|
+
}[];
|
|
957
|
+
publish_gas_mist: number;
|
|
958
|
+
}>>;
|
|
885
959
|
can_proceed: z.ZodBoolean;
|
|
886
960
|
next_action: z.ZodEnum<["trace_substeps", "fix_doc_errors", "none"]>;
|
|
887
961
|
user_action_required: z.ZodString;
|
|
@@ -908,6 +982,16 @@ export declare const ProjectOperationOutputSchema: z.ZodObject<{
|
|
|
908
982
|
notes?: string | undefined;
|
|
909
983
|
}[];
|
|
910
984
|
} | undefined;
|
|
985
|
+
estimated_gas?: {
|
|
986
|
+
total_gas_mist: number;
|
|
987
|
+
per_object: {
|
|
988
|
+
object_type: string;
|
|
989
|
+
entry_id: string;
|
|
990
|
+
create_gas_mist: number;
|
|
991
|
+
publish_gas_mist: number;
|
|
992
|
+
}[];
|
|
993
|
+
publish_gas_mist: number;
|
|
994
|
+
} | undefined;
|
|
911
995
|
}, {
|
|
912
996
|
markdown: string;
|
|
913
997
|
meta: {
|
|
@@ -931,6 +1015,16 @@ export declare const ProjectOperationOutputSchema: z.ZodObject<{
|
|
|
931
1015
|
notes?: string | undefined;
|
|
932
1016
|
}[];
|
|
933
1017
|
} | undefined;
|
|
1018
|
+
estimated_gas?: {
|
|
1019
|
+
total_gas_mist: number;
|
|
1020
|
+
per_object: {
|
|
1021
|
+
object_type: string;
|
|
1022
|
+
entry_id: string;
|
|
1023
|
+
create_gas_mist: number;
|
|
1024
|
+
publish_gas_mist: number;
|
|
1025
|
+
}[];
|
|
1026
|
+
publish_gas_mist: number;
|
|
1027
|
+
} | undefined;
|
|
934
1028
|
}>, z.ZodObject<{
|
|
935
1029
|
action: z.ZodLiteral<"trace_substeps">;
|
|
936
1030
|
namespace: z.ZodObject<{
|
|
@@ -1121,6 +1215,48 @@ export declare const ProjectOperationOutputSchema: z.ZodObject<{
|
|
|
1121
1215
|
description: string;
|
|
1122
1216
|
check_id: "D-10";
|
|
1123
1217
|
};
|
|
1218
|
+
}>, z.ZodObject<{
|
|
1219
|
+
action: z.ZodLiteral<"get_project_status">;
|
|
1220
|
+
project: z.ZodString;
|
|
1221
|
+
version: z.ZodString;
|
|
1222
|
+
stage: z.ZodNumber;
|
|
1223
|
+
stage_name: z.ZodString;
|
|
1224
|
+
stage_description: z.ZodString;
|
|
1225
|
+
next_action: z.ZodString;
|
|
1226
|
+
can_proceed: z.ZodBoolean;
|
|
1227
|
+
last_updated: z.ZodOptional<z.ZodNumber>;
|
|
1228
|
+
risk_status: z.ZodOptional<z.ZodString>;
|
|
1229
|
+
risk_can_proceed: z.ZodOptional<z.ZodBoolean>;
|
|
1230
|
+
doc_generated: z.ZodOptional<z.ZodBoolean>;
|
|
1231
|
+
trace_coherent: z.ZodOptional<z.ZodBoolean>;
|
|
1232
|
+
}, "strict", z.ZodTypeAny, {
|
|
1233
|
+
version: string;
|
|
1234
|
+
action: "get_project_status";
|
|
1235
|
+
stage: number;
|
|
1236
|
+
project: string;
|
|
1237
|
+
next_action: string;
|
|
1238
|
+
can_proceed: boolean;
|
|
1239
|
+
stage_name: string;
|
|
1240
|
+
stage_description: string;
|
|
1241
|
+
risk_status?: string | undefined;
|
|
1242
|
+
last_updated?: number | undefined;
|
|
1243
|
+
risk_can_proceed?: boolean | undefined;
|
|
1244
|
+
doc_generated?: boolean | undefined;
|
|
1245
|
+
trace_coherent?: boolean | undefined;
|
|
1246
|
+
}, {
|
|
1247
|
+
version: string;
|
|
1248
|
+
action: "get_project_status";
|
|
1249
|
+
stage: number;
|
|
1250
|
+
project: string;
|
|
1251
|
+
next_action: string;
|
|
1252
|
+
can_proceed: boolean;
|
|
1253
|
+
stage_name: string;
|
|
1254
|
+
stage_description: string;
|
|
1255
|
+
risk_status?: string | undefined;
|
|
1256
|
+
last_updated?: number | undefined;
|
|
1257
|
+
risk_can_proceed?: boolean | undefined;
|
|
1258
|
+
doc_generated?: boolean | undefined;
|
|
1259
|
+
trace_coherent?: boolean | undefined;
|
|
1124
1260
|
}>]>;
|
|
1125
1261
|
}, "strict", z.ZodTypeAny, {
|
|
1126
1262
|
result: {
|
|
@@ -1149,6 +1285,7 @@ export declare const ProjectOperationOutputSchema: z.ZodObject<{
|
|
|
1149
1285
|
};
|
|
1150
1286
|
overall_completeness: "partial" | "complete" | "empty";
|
|
1151
1287
|
next_step: string;
|
|
1288
|
+
recommended_creation_order: string[];
|
|
1152
1289
|
next_action: "none" | "aggregate_risks";
|
|
1153
1290
|
} | {
|
|
1154
1291
|
status: "RISK_PASSED" | "RISK_BLOCKED" | "RISK_PENDING_CONFIRM" | "RISK_CANCELLED";
|
|
@@ -1189,6 +1326,13 @@ export declare const ProjectOperationOutputSchema: z.ZodObject<{
|
|
|
1189
1326
|
risk_rule_id: string;
|
|
1190
1327
|
fix_suggestion: string;
|
|
1191
1328
|
}[] | undefined;
|
|
1329
|
+
fix_suggestions_grouped?: Record<string, {
|
|
1330
|
+
message: string;
|
|
1331
|
+
severity: "CRITICAL" | "HIGH" | "MEDIUM" | "LOW" | "INFO";
|
|
1332
|
+
entry_id: string;
|
|
1333
|
+
risk_rule_id: string;
|
|
1334
|
+
fix_suggestion: string;
|
|
1335
|
+
}[]> | undefined;
|
|
1192
1336
|
} | {
|
|
1193
1337
|
markdown: string;
|
|
1194
1338
|
meta: {
|
|
@@ -1212,6 +1356,16 @@ export declare const ProjectOperationOutputSchema: z.ZodObject<{
|
|
|
1212
1356
|
notes?: string | undefined;
|
|
1213
1357
|
}[];
|
|
1214
1358
|
} | undefined;
|
|
1359
|
+
estimated_gas?: {
|
|
1360
|
+
total_gas_mist: number;
|
|
1361
|
+
per_object: {
|
|
1362
|
+
object_type: string;
|
|
1363
|
+
entry_id: string;
|
|
1364
|
+
create_gas_mist: number;
|
|
1365
|
+
publish_gas_mist: number;
|
|
1366
|
+
}[];
|
|
1367
|
+
publish_gas_mist: number;
|
|
1368
|
+
} | undefined;
|
|
1215
1369
|
} | {
|
|
1216
1370
|
network: "testnet" | "mainnet";
|
|
1217
1371
|
action: "trace_substeps";
|
|
@@ -1256,6 +1410,20 @@ export declare const ProjectOperationOutputSchema: z.ZodObject<{
|
|
|
1256
1410
|
description: string;
|
|
1257
1411
|
check_id: "D-10";
|
|
1258
1412
|
};
|
|
1413
|
+
} | {
|
|
1414
|
+
version: string;
|
|
1415
|
+
action: "get_project_status";
|
|
1416
|
+
stage: number;
|
|
1417
|
+
project: string;
|
|
1418
|
+
next_action: string;
|
|
1419
|
+
can_proceed: boolean;
|
|
1420
|
+
stage_name: string;
|
|
1421
|
+
stage_description: string;
|
|
1422
|
+
risk_status?: string | undefined;
|
|
1423
|
+
last_updated?: number | undefined;
|
|
1424
|
+
risk_can_proceed?: boolean | undefined;
|
|
1425
|
+
doc_generated?: boolean | undefined;
|
|
1426
|
+
trace_coherent?: boolean | undefined;
|
|
1259
1427
|
} | {
|
|
1260
1428
|
action: string;
|
|
1261
1429
|
items: Record<string, unknown>[];
|
|
@@ -1300,6 +1468,7 @@ export declare const ProjectOperationOutputSchema: z.ZodObject<{
|
|
|
1300
1468
|
};
|
|
1301
1469
|
overall_completeness: "partial" | "complete" | "empty";
|
|
1302
1470
|
next_step: string;
|
|
1471
|
+
recommended_creation_order: string[];
|
|
1303
1472
|
next_action: "none" | "aggregate_risks";
|
|
1304
1473
|
} | {
|
|
1305
1474
|
status: "RISK_PASSED" | "RISK_BLOCKED" | "RISK_PENDING_CONFIRM" | "RISK_CANCELLED";
|
|
@@ -1340,6 +1509,13 @@ export declare const ProjectOperationOutputSchema: z.ZodObject<{
|
|
|
1340
1509
|
risk_rule_id: string;
|
|
1341
1510
|
fix_suggestion: string;
|
|
1342
1511
|
}[] | undefined;
|
|
1512
|
+
fix_suggestions_grouped?: Record<string, {
|
|
1513
|
+
message: string;
|
|
1514
|
+
severity: "CRITICAL" | "HIGH" | "MEDIUM" | "LOW" | "INFO";
|
|
1515
|
+
entry_id: string;
|
|
1516
|
+
risk_rule_id: string;
|
|
1517
|
+
fix_suggestion: string;
|
|
1518
|
+
}[]> | undefined;
|
|
1343
1519
|
} | {
|
|
1344
1520
|
markdown: string;
|
|
1345
1521
|
meta: {
|
|
@@ -1363,6 +1539,16 @@ export declare const ProjectOperationOutputSchema: z.ZodObject<{
|
|
|
1363
1539
|
notes?: string | undefined;
|
|
1364
1540
|
}[];
|
|
1365
1541
|
} | undefined;
|
|
1542
|
+
estimated_gas?: {
|
|
1543
|
+
total_gas_mist: number;
|
|
1544
|
+
per_object: {
|
|
1545
|
+
object_type: string;
|
|
1546
|
+
entry_id: string;
|
|
1547
|
+
create_gas_mist: number;
|
|
1548
|
+
publish_gas_mist: number;
|
|
1549
|
+
}[];
|
|
1550
|
+
publish_gas_mist: number;
|
|
1551
|
+
} | undefined;
|
|
1366
1552
|
} | {
|
|
1367
1553
|
network: "testnet" | "mainnet";
|
|
1368
1554
|
action: "trace_substeps";
|
|
@@ -1407,6 +1593,20 @@ export declare const ProjectOperationOutputSchema: z.ZodObject<{
|
|
|
1407
1593
|
description: string;
|
|
1408
1594
|
check_id: "D-10";
|
|
1409
1595
|
};
|
|
1596
|
+
} | {
|
|
1597
|
+
version: string;
|
|
1598
|
+
action: "get_project_status";
|
|
1599
|
+
stage: number;
|
|
1600
|
+
project: string;
|
|
1601
|
+
next_action: string;
|
|
1602
|
+
can_proceed: boolean;
|
|
1603
|
+
stage_name: string;
|
|
1604
|
+
stage_description: string;
|
|
1605
|
+
risk_status?: string | undefined;
|
|
1606
|
+
last_updated?: number | undefined;
|
|
1607
|
+
risk_can_proceed?: boolean | undefined;
|
|
1608
|
+
doc_generated?: boolean | undefined;
|
|
1609
|
+
trace_coherent?: boolean | undefined;
|
|
1410
1610
|
} | {
|
|
1411
1611
|
action: string;
|
|
1412
1612
|
items: Record<string, unknown>[];
|