@wowok/agent-mcp 2.3.16 → 2.4.1
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/customer/index.d.ts +9 -0
- package/dist/customer/index.js +9 -0
- package/dist/customer/industry-risks.d.ts +4 -0
- package/dist/customer/industry-risks.js +45 -31
- package/dist/customer/order-monitor.js +57 -57
- package/dist/customer/order-strategy.js +89 -89
- package/dist/customer/post-purchase.js +97 -97
- package/dist/customer/reminder-system.js +26 -26
- package/dist/customer/risk-assessment.js +46 -46
- package/dist/customer/types.d.ts +4 -4
- package/dist/customer/types.js +4 -4
- package/dist/customer/user-preferences.d.ts +3 -0
- package/dist/customer/user-preferences.js +59 -50
- package/dist/experience/intent-distill.js +6 -6
- package/dist/experience/realtime-feedback.js +17 -0
- package/dist/index.js +360 -273
- package/dist/knowledge/acquisition-flywheel.d.ts +3 -0
- package/dist/knowledge/acquisition-flywheel.js +73 -64
- package/dist/knowledge/arbitration-trust.js +10 -10
- package/dist/knowledge/demand-matching.js +8 -8
- package/dist/knowledge/dynamic-pricing.js +18 -18
- package/dist/knowledge/flywheel-loop.js +11 -11
- package/dist/knowledge/glossary.js +22 -22
- package/dist/knowledge/guard-ledger.d.ts +19 -0
- package/dist/knowledge/guard-ledger.js +246 -0
- package/dist/knowledge/guard-lint.d.ts +76 -0
- package/dist/knowledge/guard-lint.js +590 -0
- package/dist/knowledge/guard-puzzle.d.ts +188 -0
- package/dist/knowledge/guard-puzzle.js +804 -0
- package/dist/knowledge/guard-risk.d.ts +67 -0
- package/dist/knowledge/guard-risk.js +1046 -0
- package/dist/knowledge/guard-templates.d.ts +37 -0
- package/dist/knowledge/guard-templates.js +329 -0
- package/dist/knowledge/guard-translation.d.ts +58 -0
- package/dist/knowledge/guard-translation.js +1118 -0
- package/dist/knowledge/index.d.ts +17 -0
- package/dist/knowledge/index.js +17 -0
- package/dist/knowledge/industry-evolution.js +29 -29
- package/dist/knowledge/industry-generalizer.js +52 -52
- package/dist/knowledge/industry-registry.d.ts +1 -2
- package/dist/knowledge/industry-registry.js +43 -36
- package/dist/knowledge/intent-metrics.js +67 -67
- package/dist/knowledge/process-model.js +80 -80
- package/dist/knowledge/reputation-rules.js +9 -9
- package/dist/knowledge/reward-templates.js +51 -51
- package/dist/knowledge/safety-rules.js +63 -2
- package/dist/knowledge/tool-constraints.js +17 -11
- package/dist/knowledge/trust-metrics.js +26 -26
- package/dist/safety/confirm-gate.d.ts +4 -2
- package/dist/safety/confirm-gate.js +48 -4
- package/dist/schema/call/allocation.d.ts +24 -14
- package/dist/schema/call/arbitration.d.ts +142 -132
- package/dist/schema/call/base.d.ts +901 -43
- package/dist/schema/call/base.js +77 -13
- package/dist/schema/call/bridge-handler.js +15 -2
- package/dist/schema/call/bridge.d.ts +795 -27
- package/dist/schema/call/bridge.js +37 -0
- package/dist/schema/call/contact.d.ts +10 -0
- package/dist/schema/call/demand.d.ts +94 -84
- package/dist/schema/call/guard.d.ts +229 -46
- package/dist/schema/call/guard.js +50 -0
- package/dist/schema/call/handler.js +46 -14
- package/dist/schema/call/machine.d.ts +158 -138
- package/dist/schema/call/order.d.ts +10 -0
- package/dist/schema/call/payment.d.ts +10 -0
- package/dist/schema/call/permission.d.ts +314 -304
- package/dist/schema/call/personal.d.ts +10 -0
- package/dist/schema/call/progress.d.ts +10 -0
- package/dist/schema/call/proof.d.ts +20 -0
- package/dist/schema/call/repository.d.ts +32 -22
- package/dist/schema/call/reward.d.ts +10 -0
- package/dist/schema/call/semantic.d.ts +9 -2
- package/dist/schema/call/semantic.js +617 -25
- package/dist/schema/call/service.d.ts +20 -10
- package/dist/schema/call/treasury.d.ts +10 -0
- package/dist/schema/config/index.d.ts +18 -0
- package/dist/schema/config/index.js +17 -0
- package/dist/schema/index.d.ts +6 -0
- package/dist/schema/index.js +5 -0
- package/dist/schema/local/index.d.ts +9 -9
- package/dist/schema/local/index.js +9 -0
- package/dist/schema/local/wip.d.ts +39 -19
- package/dist/schema/local/wip.js +5 -5
- package/dist/schema/messenger/index.d.ts +376 -55
- package/dist/schema/messenger/index.js +19 -19
- package/dist/schema/operations.d.ts +1881 -681
- package/dist/schema/operations.js +91 -96
- package/dist/schema/project/index.d.ts +21 -0
- package/dist/schema/project/index.js +32 -0
- package/dist/schema/query/index.d.ts +1074 -168
- package/dist/schema/query/index.js +8 -8
- package/dist/schema/schema-query/index.d.ts +33 -0
- package/dist/schema/schema-query/index.js +36 -0
- package/dist/schema/schema-version.d.ts +25 -0
- package/dist/schema/schema-version.js +76 -0
- package/dist/schema/trust/index.d.ts +407 -0
- package/dist/schema/trust/index.js +113 -0
- package/dist/schema/utils/guard-parser.js +4 -4
- package/dist/schema/utils/node-parser.js +14 -14
- package/dist/schemas/bridge_operation.output.json +233 -9
- package/dist/schemas/bridge_operation.schema.json +67 -8
- package/dist/schemas/config_operation.output.json +18 -0
- package/dist/schemas/config_operation.schema.json +34 -0
- package/dist/schemas/guard-node-schema.json +82 -0
- package/dist/schemas/guard2file.schema.json +8 -0
- package/dist/schemas/index.json +19 -1
- package/dist/schemas/machineNode2file.schema.json +8 -0
- package/dist/schemas/messenger_operation.output.json +236 -10
- package/dist/schemas/onchain_events.output.json +718 -0
- package/dist/schemas/onchain_operations.output.json +286 -11
- package/dist/schemas/onchain_operations.schema.json +19 -16
- package/dist/schemas/onchain_operations_allocation.schema.json +8 -0
- package/dist/schemas/onchain_operations_arbitration.schema.json +8 -0
- package/dist/schemas/onchain_operations_contact.schema.json +8 -0
- package/dist/schemas/onchain_operations_demand.schema.json +8 -0
- package/dist/schemas/onchain_operations_gen_passport.schema.json +16 -0
- package/dist/schemas/onchain_operations_guard.schema.json +11 -16
- package/dist/schemas/onchain_operations_machine.schema.json +8 -0
- package/dist/schemas/onchain_operations_order.schema.json +8 -0
- package/dist/schemas/onchain_operations_payment.schema.json +8 -0
- package/dist/schemas/onchain_operations_permission.schema.json +8 -0
- package/dist/schemas/onchain_operations_personal.schema.json +8 -0
- package/dist/schemas/onchain_operations_progress.schema.json +8 -0
- package/dist/schemas/onchain_operations_repository.schema.json +8 -0
- package/dist/schemas/onchain_operations_reward.schema.json +8 -0
- package/dist/schemas/onchain_operations_service.schema.json +8 -0
- package/dist/schemas/onchain_operations_treasury.schema.json +8 -0
- package/dist/schemas/onchain_table_data.output.json +718 -0
- package/dist/schemas/project_operation.output.json +18 -0
- package/dist/schemas/project_operation.schema.json +42 -0
- package/dist/schemas/query_toolkit.schema.json +360 -368
- package/dist/schemas/schema_query.schema.json +6 -3
- package/dist/schemas/trust_score.output.json +327 -0
- package/dist/schemas/trust_score.schema.json +46 -0
- package/dist/schemas/wip_file.output.json +24 -1
- package/package.json +2 -2
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
import type { GuardScene } from "./guard-ledger.js";
|
|
2
|
+
export type GuardStakeholder = "customer" | "provider" | "arbitrator" | "claimant" | "system";
|
|
3
|
+
export type RiskLevel = "critical" | "high" | "medium" | "low" | "info";
|
|
4
|
+
export type DataSourceClass = "type1_onchain_constant" | "type2_witness_derived" | "type3_submitted_object" | "type4_system_context" | "cross_type";
|
|
5
|
+
export type RiskCategory = "data_source_trust" | "submission_forgery" | "system_context_risk" | "game_theory" | "logic_gap" | "binding_risk" | "dependency_risk" | "impack_risk" | "rep_risk";
|
|
6
|
+
export interface GuardRisk {
|
|
7
|
+
id: string;
|
|
8
|
+
data_source_class: DataSourceClass;
|
|
9
|
+
level: RiskLevel;
|
|
10
|
+
category: RiskCategory;
|
|
11
|
+
title: string;
|
|
12
|
+
description: string;
|
|
13
|
+
affected_stakeholders: GuardStakeholder[];
|
|
14
|
+
scenario: string;
|
|
15
|
+
mitigation: string;
|
|
16
|
+
evidence?: string;
|
|
17
|
+
}
|
|
18
|
+
export interface GuardRiskAssessment {
|
|
19
|
+
guard_summary: string;
|
|
20
|
+
scene?: GuardScene;
|
|
21
|
+
risks: GuardRisk[];
|
|
22
|
+
overall_risk: RiskLevel;
|
|
23
|
+
risks_by_data_source: Partial<Record<DataSourceClass, number>>;
|
|
24
|
+
stakeholder_advice: Partial<Record<GuardStakeholder, string[]>>;
|
|
25
|
+
needs_human_review: boolean;
|
|
26
|
+
}
|
|
27
|
+
export interface RiskRule {
|
|
28
|
+
id: string;
|
|
29
|
+
data_source_class: DataSourceClass;
|
|
30
|
+
trigger: string;
|
|
31
|
+
check: (ctx: RiskCheckContext) => GuardRisk | null;
|
|
32
|
+
}
|
|
33
|
+
export interface RiskCheckContext {
|
|
34
|
+
table: Array<{
|
|
35
|
+
identifier: number;
|
|
36
|
+
b_submission: boolean;
|
|
37
|
+
value_type: string;
|
|
38
|
+
value?: unknown;
|
|
39
|
+
name?: string;
|
|
40
|
+
object_type?: string;
|
|
41
|
+
}>;
|
|
42
|
+
root: any;
|
|
43
|
+
rely?: {
|
|
44
|
+
guards: string[];
|
|
45
|
+
logic_or?: boolean;
|
|
46
|
+
};
|
|
47
|
+
scene?: GuardScene;
|
|
48
|
+
operation_type?: string;
|
|
49
|
+
}
|
|
50
|
+
export declare function assessGuardRisks(params: {
|
|
51
|
+
table: RiskCheckContext["table"];
|
|
52
|
+
root: any;
|
|
53
|
+
rely?: RiskCheckContext["rely"];
|
|
54
|
+
scene?: GuardScene;
|
|
55
|
+
operation_type?: string;
|
|
56
|
+
}): GuardRiskAssessment;
|
|
57
|
+
export declare function assessGuardRisksForOperation(operation_type: string, data: any): GuardRiskAssessment | null;
|
|
58
|
+
export declare function getRiskSummary(assessment: GuardRiskAssessment): {
|
|
59
|
+
risk_count: number;
|
|
60
|
+
critical_count: number;
|
|
61
|
+
high_count: number;
|
|
62
|
+
needs_human_review: boolean;
|
|
63
|
+
top_risks: string[];
|
|
64
|
+
};
|
|
65
|
+
export declare function getRiskRulesByDataSourceClass(dataSourceClass: DataSourceClass): RiskRule[];
|
|
66
|
+
export declare function getAllRiskRules(): RiskRule[];
|
|
67
|
+
export declare function getRiskRulesCount(): number;
|