@wowok/agent-mcp 3.2.1 → 3.2.3
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/chain-semantics/field-capability.d.ts +11 -0
- package/dist/chain-semantics/field-capability.js +1 -0
- package/dist/chain-semantics/freeze-map.d.ts +11 -0
- package/dist/chain-semantics/freeze-map.js +1 -0
- package/dist/chain-semantics/fund-flow.d.ts +10 -0
- package/dist/chain-semantics/fund-flow.js +1 -0
- package/dist/chain-semantics/guard-verbs.d.ts +22 -0
- package/dist/chain-semantics/guard-verbs.js +1 -0
- package/dist/chain-semantics/index.d.ts +10 -0
- package/dist/chain-semantics/index.js +1 -0
- package/dist/chain-semantics/object-graph.d.ts +18 -0
- package/dist/chain-semantics/object-graph.js +1 -0
- package/dist/communication/wts-attestation.d.ts +34 -0
- package/dist/communication/wts-attestation.js +1 -0
- package/dist/composition/audit.d.ts +10 -0
- package/dist/composition/audit.js +1 -0
- package/dist/composition/compile.d.ts +38 -0
- package/dist/composition/compile.js +1 -0
- package/dist/composition/materialize.d.ts +64 -0
- package/dist/composition/materialize.js +1 -0
- package/dist/composition/plan.d.ts +92 -0
- package/dist/composition/plan.js +1 -0
- package/dist/composition/reflux.d.ts +28 -0
- package/dist/composition/reflux.js +1 -0
- package/dist/config/judgment.d.ts +25 -0
- package/dist/config/rule-engine.d.ts +10 -0
- package/dist/config/rule-engine.js +1 -1
- package/dist/evaluation/builtins/graph-service.spec.js +1 -1
- package/dist/evaluation/engine.js +1 -1
- package/dist/experience/realtime-feedback.js +1 -1
- package/dist/extensions/business-modules.js +1 -1
- package/dist/extensions/industry-pack.js +1 -1
- package/dist/extensions/modes.js +1 -1
- package/dist/graph/onchain/expand.js +1 -1
- package/dist/graph/onchain/exposure.js +1 -1
- package/dist/graph/onchain/facts.js +1 -1
- package/dist/keeper/detectors.d.ts +7 -0
- package/dist/keeper/detectors.js +1 -1
- package/dist/keeper/types.d.ts +1 -1
- package/dist/keeper/types.js +1 -1
- package/dist/knowledge/allocation-ledger.js +1 -1
- package/dist/knowledge/allocation-puzzle.js +1 -1
- package/dist/knowledge/allocation-risk.d.ts +2 -1
- package/dist/knowledge/allocation-risk.js +1 -1
- package/dist/knowledge/allocation-templates.js +1 -1
- package/dist/knowledge/arb-fund-facts.d.ts +31 -0
- package/dist/knowledge/arb-fund-facts.js +1 -0
- package/dist/knowledge/audit-rules.js +1 -1
- package/dist/knowledge/baselines/rules/allocation.json +75 -16
- package/dist/knowledge/baselines/rules/guard.json +27 -8
- package/dist/knowledge/baselines/rules/plan.json +161 -0
- package/dist/knowledge/baselines/semantic-facts.d.ts +12 -0
- package/dist/knowledge/baselines/semantic-facts.js +1 -0
- package/dist/knowledge/builtin-templates.d.ts +3 -1
- package/dist/knowledge/builtin-templates.js +1 -1
- package/dist/knowledge/entity-recipient-guard.d.ts +21 -0
- package/dist/knowledge/entity-recipient-guard.js +1 -0
- package/dist/knowledge/getting-started.js +1 -1
- package/dist/knowledge/guard-design-patterns.js +1 -1
- package/dist/knowledge/guard-ledger.js +1 -1
- package/dist/knowledge/guard-risk.js +1 -1
- package/dist/knowledge/guard-templates.js +1 -1
- package/dist/knowledge/index.js +1 -1
- package/dist/knowledge/industry-registry.js +1 -1
- package/dist/knowledge/jsonrpc-enum.js +1 -1
- package/dist/knowledge/machine-topology.d.ts +34 -0
- package/dist/knowledge/machine-topology.js +1 -1
- package/dist/knowledge/onchain-constants.d.ts +2 -2
- package/dist/knowledge/onchain-constants.js +1 -1
- package/dist/knowledge/scenario-modes.d.ts +13 -0
- package/dist/knowledge/scenario-modes.js +1 -1
- package/dist/knowledge/service-allocation-semantics.js +1 -1
- package/dist/knowledge/service-ledger.js +1 -1
- package/dist/knowledge/service-templates.js +1 -1
- package/dist/knowledge/strategy-manuals.js +1 -1
- package/dist/knowledge/template-loader.d.ts +37 -1
- package/dist/knowledge/template-loader.js +1 -1
- package/dist/knowledge/template-registry.js +1 -1
- package/dist/knowledge/template-scanner.js +1 -1
- package/dist/knowledge/tool-constraints.js +1 -1
- package/dist/knowledge/tools-reference.js +1 -1
- package/dist/knowledge/workflow-guidance.d.ts +4 -0
- package/dist/knowledge/workflow-guidance.js +1 -1
- package/dist/monitor/MonitorLoop.js +1 -1
- package/dist/participation/radar-core.d.ts +6 -0
- package/dist/participation/radar-core.js +1 -1
- package/dist/playbooks/service-build/business-puzzle.js +1 -1
- package/dist/playbooks/service-build/index.d.ts +1 -0
- package/dist/playbooks/service-build/intent-analyzer.d.ts +1 -0
- package/dist/playbooks/service-build/intent-analyzer.js +1 -1
- package/dist/playbooks/service-build/machine-nodes.d.ts +1 -1
- package/dist/playbooks/service-build/machine-nodes.js +1 -1
- package/dist/playbooks/service-build/machine-panorama.js +1 -1
- package/dist/playbooks/service-build/merchant-guide.js +1 -1
- package/dist/playbooks/service-build/migration-planner.js +1 -1
- package/dist/playbooks/service-build/object-panorama.d.ts +27 -1
- package/dist/playbooks/service-build/object-panorama.js +1 -1
- package/dist/playbooks/service-build/participation-radar.js +1 -1
- package/dist/playbooks/service-build/pipeline-actions.d.ts +4 -0
- package/dist/playbooks/service-build/pipeline-actions.js +1 -1
- package/dist/playbooks/service-build/relationship-profile.js +1 -1
- package/dist/playbooks/service-build/semantic-graph.d.ts +1 -0
- package/dist/playbooks/service-build/semantic-graph.js +1 -1
- package/dist/playbooks/service-build/service-panorama.js +1 -1
- package/dist/playbooks/service-build/service-quote.js +1 -1
- package/dist/review/index.js +1 -1
- package/dist/safety/confirm-gate.js +1 -1
- package/dist/schema/call/machine.d.ts +1 -0
- package/dist/schema/call/machine.js +1 -1
- package/dist/schema/call/order.d.ts +60 -0
- package/dist/schema/call/order.js +1 -1
- package/dist/schema/call/semantic.js +1 -1
- package/dist/schema/call/service.d.ts +56 -0
- package/dist/schema/call/service.js +1 -1
- package/dist/schema/common/index.js +1 -1
- package/dist/schema/goal/planning.d.ts +7 -0
- package/dist/schema/goal/planning.js +1 -1
- package/dist/schema/index.d.ts +1 -0
- package/dist/schema/index.js +1 -1
- package/dist/schema/industry-pack/index.d.ts +26 -0
- package/dist/schema/industry-pack/index.js +1 -1
- package/dist/schema/local/index.js +1 -1
- package/dist/schema/messenger/index.d.ts +20 -0
- package/dist/schema/messenger/index.js +1 -1
- package/dist/schema/operations.d.ts +50 -0
- package/dist/schema/persona/index.d.ts +110 -0
- package/dist/schema/query/bi.d.ts +2 -0
- package/dist/schema/query/bi.js +1 -1
- package/dist/schema/query/index.js +1 -1
- package/dist/schema/schema-version.js +1 -1
- package/dist/schema/service-clone/index.d.ts +46 -0
- package/dist/schema/service-clone/index.js +1 -0
- package/dist/schema/utils/node-parser.js +1 -1
- package/dist/schema-query-impl/index.js +1 -1
- package/dist/schemas/index.json +7 -1
- package/dist/schemas/industry_pack_operation.output.json +113 -0
- package/dist/schemas/industry_pack_operation.schema.json +7 -1
- package/dist/schemas/messenger_operation.output.json +42 -4
- package/dist/schemas/onchain_operations.output.json +1 -1
- package/dist/schemas/onchain_operations.schema.json +409 -98
- package/dist/schemas/onchain_operations_allocation.schema.json +5 -5
- package/dist/schemas/onchain_operations_arbitration.schema.json +2 -2
- package/dist/schemas/onchain_operations_contact.schema.json +1 -1
- package/dist/schemas/onchain_operations_demand.schema.json +3 -3
- package/dist/schemas/onchain_operations_gen_passport.schema.json +1 -1
- package/dist/schemas/onchain_operations_guard.schema.json +59 -59
- package/dist/schemas/onchain_operations_machine.schema.json +3 -3
- package/dist/schemas/onchain_operations_order.schema.json +133 -1
- package/dist/schemas/onchain_operations_progress.schema.json +1 -1
- package/dist/schemas/onchain_operations_proof.schema.json +1 -1
- package/dist/schemas/onchain_operations_repository.schema.json +1 -1
- package/dist/schemas/onchain_operations_reward.schema.json +4 -4
- package/dist/schemas/onchain_operations_service.schema.json +188 -9
- package/dist/schemas/onchain_operations_treasury.schema.json +7 -7
- package/dist/schemas/onchain_table_data.output.json +5 -1
- package/dist/schemas/persona_operation.output.json +266 -0
- package/dist/schemas/persona_operation.schema.json +42 -0
- package/dist/schemas/query_toolkit.output.json +46 -46
- package/dist/schemas/query_toolkit.schema.json +5 -1
- package/dist/schemas/service_clone_operation.output.json +168 -0
- package/dist/schemas/service_clone_operation.schema.json +49 -0
- package/dist/schemas/workflow_operation.schema.json +1 -1
- package/dist/tools/handlers/benchmark-migration.d.ts +17 -0
- package/dist/tools/handlers/benchmark-migration.js +1 -1
- package/dist/tools/handlers/config.js +1 -1
- package/dist/tools/handlers/industry-pack.js +1 -1
- package/dist/tools/handlers/messenger.js +1 -1
- package/dist/tools/handlers/onchain.js +1 -1
- package/dist/tools/handlers/query.js +1 -1
- package/dist/tools/handlers/service-clone.d.ts +2 -0
- package/dist/tools/handlers/service-clone.js +1 -0
- package/dist/tools/index.js +1 -1
- package/dist/tools/registry/business.js +1 -1
- package/dist/tools/wrap.d.ts +6 -1
- package/dist/tools/wrap.js +1 -1
- package/package.json +4 -3
package/dist/knowledge/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{buildWorkflowGuidance,buildWorkflowReceipt,enrichWorkflowGuidance,mergeGuidanceIntoOutput,resolvePermissionRole,resolveLocalNamesFor,listLocalAccounts,accountCanExecuteForward,enumerateActionableForwards,forwardOperatorKind}from'./workflow-guidance.js';import{CONFIRMATION_RULES,SAFETY_RULES_VERSION,OBJECT_REUSE_RULES,CREATE_VS_MODIFY_PATTERN,IMMUTABILITY_RULES,OPERATION_TYPE_CLASSIFICATION,OPERATION_CLASS_META,classifyTool,NAMING_CONVENTIONS,checkObjectReuseRules,checkImmutabilityRules}from'./safety-rules.js';import{TOOL_CONSTRAINTS,TOOL_CONSTRAINTS_VERSION,validateOperation,hasBlockingViolations,getWarningViolations}from'./tool-constraints.js';import{REWARD_TEMPLATES,REWARD_TEMPLATES_VERSION,getRewardTemplate,listRewardTemplates,suggestRewardTemplate}from'./reward-templates.js';import{AUDIT_RULES,AUDIT_RULES_VERSION,auditService,hasBlockingErrors,getErrors,getWarnings,summarizeFindings}from'./audit-rules.js';import{suggestPricing,MUTABLE_FIELDS,DYNAMIC_PRICING_VERSION}from'./dynamic-pricing.js';import{buildReviewRepositorySetup,computeReviewStats,isVerifiedReview,filterVerifiedReviews,detectReviewManipulation,REPUTATION_RULES_VERSION}from'./reputation-rules.js';import{INDUSTRY_FLYWHEELS,getFlywheelForIndustry,listIndustries,suggestAcquisitionActions,generateTrustDescription,buildAcquisitionDashboard,ACQUISITION_FLYWHEEL_VERSION}from'./acquisition-flywheel.js';import{INDUSTRY_REGISTRY_VERSION,getIndustryProfile,registerIndustry,getIndustryTraits,resolveIndustryName,isRegisteredIndustry,getRegistrySize,listBuiltinIndustryNames}from'./industry-registry.js';import{DEFAULT_TRAITS,inferTraitsFromDescription,synthesizeProfile,findSimilarIndustries,composeIndustries,INDUSTRY_REQUIRED_TRAITS,DOMAIN_PRIORS,detectDomainPriors,traitContradictions,filterConsistentIndustries}from'./industry-generalizer.js';import{INDUSTRY_EVOLUTION_THRESHOLDS,aggregateIndustryMetrics,evaluateIndustryHealth,suggestIndustryUpdate,applyIndustryUpdate,runIndustryHealthPipeline}from'./industry-evolution.js';import{FLYWHEEL_LOOP_VERSION,FLYWHEEL_LOOP_MIN_SIGNALS,recordIndustrySignal,updateIndustryCognition,injectEvolutionContext}from'./flywheel-loop.js';import{BUILTIN_INTENT_SPECS,registerIntentProfile,getIntentProfile,listIntents,evaluateIndustryHealthByIntent,suggestIndustryUpdateByIntent,evaluateIndustryHealthMultiIntent,getRoleAdvice,filterSuggestionsByRole}from'./intent-metrics.js';import{GUARD_SCENES,findScene,inferSceneFromAction,getImmutableScenes,getNumericIdentifierScenes}from'./guard-ledger.js';import{SEMANTIC_TO_SCHEMA_RULES,SCHEMA_TO_SEMANTIC_RULES,GUARD_CONSTRAINT_RULES,matchSemanticPattern,explainNode,explainWitness,getConstraintsByCategory}from'./guard-translation.js';import{checkPuzzleCompleteness,generateConfirmationText,initPuzzleFromIntent,inferBindingFromAction,emptyDataSources,getWitnessInfo,WITNESS_NAME_MAP}from'./guard-puzzle.js';import{runGuardRulePack,assembleGuardAssessment,getRiskRulesCount}from'./guard-risk.js';import{evaluateGuardDraft}from'./guard-eval.js';import{GUARD_BINDING_REGISTRY,GUARD_BINDINGS_VERSION,OWNER_RECEIVE_COGNITION,getGuardBindingsByObject,getGuardBinding,summarizeGuardBinding}from'./guard-bindings.js';import{SCENARIO_BRIDGE_REGISTRY,SCENARIO_CHAINS,SCENARIO_TOPOLOGY_VERSION,getBridgeById,getBridgeByCode,getBridgesByObject,getBridgesForEdge,detectBridgesForEdges,getChainById,summarizeBridge,detectBridgesForObjects}from'./scenario-topology.js';import{GUARD_TEMPLATES,GUARD_TEMPLATES_VERSION,GUARD_TEMPLATES_COUNT,getTemplatesByScene,getTemplateById,getTemplatesByIndustry,getTemplatesByPattern,listGuardTemplates,suggestTemplateForScene,getTemplateParameters,validateTemplateParams}from'./guard-templates.js';import{lintGuard,autoFixGuard,isGuardReady,getGuardErrors,formatLintResult}from'./guard-lint.js';import{MACHINE_SCENES,MACHINE_LEDGER_VERSION,MACHINE_SCENES_COUNT,findScene as a180a,getScenesByIndustry as a180b,getScenesByPattern,inferSceneFromFlow}from'./machine-ledger.js';import{MACHINE_TEMPLATES,MACHINE_TEMPLATES_VERSION,MACHINE_TEMPLATES_COUNT,getAllTemplates as a180c,getTemplateById as a180d,getTemplatesByScene as a180e,getTemplatesByIndustry as a180f,suggestTemplateForIntent,walkDecisionTree,fillTemplate as a180g,forkTemplate as a180h,verifyTemplateSceneReferences,getReferencedGuardTemplateIds,getReferencedRiskIds}from'./machine-templates.js';import{SEMANTIC_TO_MACHINE_RULES,MACHINE_CONSTRAINT_RULES,MACHINE_TRANSLATION_VERSION,MACHINE_PATTERNS_COUNT,MACHINE_CONSTRAINTS_COUNT,matchSemanticPattern as a180i,identifyExecutionMode,identifyTopology,explainForwardPermission,getConstraintsByCategory as a180j,getConstraintById,getOnChainConstraints as a180k,getOffChainConstraints as a180l}from'./machine-translation.js';import{MACHINE_RISK_RULES,MACHINE_RISK_VERSION,assessMachineRisks}from'./machine-risk.js';import{analyzeTopology,identifyTopologyPattern,formatTopologySummary,MACHINE_TOPOLOGY_VERSION,MAX_NODE_COUNT,MAX_NODE_PAIR_COUNT,MAX_FORWARD_COUNT}from'./machine-topology.js';import{initPuzzleFromIntent as a180m,initPuzzleFromTemplate,checkPuzzleCompleteness as a180n,recommendNextStep as a180o,derivePuzzleFromMachineJson,generateConfirmationText as a180p,MACHINE_PUZZLE_VERSION}from'./machine-puzzle.js';import{SERVICE_SCENES,SERVICE_LEDGER_VERSION,SERVICE_PERMISSIONS,SERVICE_ORDER_FLOW_STAGES,SERVICE_CROSS_OBJECT_BINDINGS,getScenesByCategory as a180q,findSceneById as a180r,getServicePermissionByIndex,isServicePermission,getPermissionsByMutability,getImmutablePostPublishPermissions,getLockedByDurationPermissions,inferSceneFromIntent as a180s,getAllServiceScenes,getServiceScenesCount,getServicePermissionsCount,getOrderFlowStage,getCrossObjectBindings as a180t}from'./service-ledger.js';import{initPuzzleFromIntent as a180u,checkPuzzleCompleteness as a180v,validateConstraints as a180w,generateConfirmationText as a180x,initOrderFlowPuzzle,checkOrderFlowCompleteness}from'./service-puzzle.js';import{SERVICE_RISK_VERSION,assessServiceRisks,getAllServiceRiskRules}from'./service-risk.js';import{SERVICE_TEMPLATES,SERVICE_TEMPLATES_VERSION,getServiceTemplateById,getServiceTemplatesByScene,getServiceTemplatesByIndustry,suggestServiceTemplateForScene,listServiceTemplates,fillServiceTemplate,getAllServiceTemplates}from'./service-templates.js';import{ALLOCATION_SCENES,ALLOCATION_LEDGER_VERSION,MAX_ALLOCATOR_COUNT,ALLOCATION_MAX_SHARING_COUNT,ALLOCATION_MODE_AMOUNT,ALLOCATION_MODE_RATE,ALLOCATION_MODE_SURPLUS,RATE_TOTAL_FULL,ALLOCATION_ERROR_CODES,getScenesByTriggerSource as a180y,getScenesByMode as a180z,getScenesByStrategy as a180A,findSceneById as a180B,inferSceneFromIntent as a180C,getAllScenes as a180D,getScenesCount as a180E,allocationModeToNumber,allocationModeFromNumber,getRecipientType,isSignerRecipient,isEntityRecipient,isGuardIdentifierRecipient,getErrorName as a180F,getErrorDescription as a180G}from'./allocation-ledger.js';import{initPuzzleFromIntent as a180H,checkPuzzleCompleteness as a180I,validateConstraints as a180J,generateConfirmationText as a180K,buildDefaultAllocFlow,buildDefaultRecipientRules,buildDefaultLogicPuzzle,ALLOCATION_PUZZLE_VERSION}from'./allocation-puzzle.js';import{ALLOCATION_RISK_VERSION,assessAllocationRisks,getAllRiskRules as a180L}from'./allocation-risk.js';import{ALLOCATION_TEMPLATES,ALLOCATION_TEMPLATES_VERSION,getAllTemplates as a180M,getTemplateById as a180N,getTemplatesByScene as a180O,getTemplatesByIndustry as a180P,suggestTemplateForScene as a180Q,listTemplates as a180R,fillTemplate as a180S}from'./allocation-templates.js';import{RECIPIENT_CONSTRAINT_VERSION,classifyRecipient,analyzeRecipientConstraints,isUnboundSignerTheft,canonicalDoctrine,recipientDesignGuidance,derivePayoffFromSharing,OBJECT_DRIVEABILITY,driveabilityOf,RECIPIENT_DESIGN_OPTIONS}from'./recipient-constraint.js';import{paymentRelations,scanRecentPaymentEvents,resolveBeneficialOwners,extractionPlanForHolder,pendingWrappersAt,trackAccountPayments}from'./payment-tracker.js';import{TREASURY_LEDGER_VERSION,TREASURY_SCENES,TREASURY_PERMISSIONS as a180T,getScenesByHostObject as a180U,findSceneById as a180V,findSceneByPermissionIndex as a180W,getBuiltinPermissionByIndex as a180X,isBuiltinTreasuryPermission,getActiveBuiltinPermissions as a180Y,getReservedBuiltinPermissions as a180Z,inferSceneFromIntent as a180a0,getTreasuryScenesCount,getGovernedOperationsForPermissionIndex as a180a1}from'./treasury-ledger.js';import{initPuzzleFromIntent as a180a2,checkPuzzleCompleteness as a180a3,validateConstraints as a180a4,generateConfirmationText as a180a5,MAX_EXTERNAL_DEPOSIT_GUARD_COUNT,MAX_EXTERNAL_WITHDRAW_GUARD_COUNT,MAX_DESCRIPTION_LENGTH as a180a6}from'./treasury-puzzle.js';import{TREASURY_TEMPLATES,TREASURY_TEMPLATES_VERSION,getAllTreasuryTemplates,getTemplateById as a180a7,getTemplatesByScene as a180a8,getTemplatesByIndustry as a180a9,suggestTemplateForScene as a180aa,listTemplates as a180ab,fillTemplate as a180ac}from'./treasury-templates.js';import{TREASURY_RISK_VERSION,assessTreasuryRisks,getAllTreasuryRiskRules}from'./treasury-risk.js';import{ORDER_LEDGER_VERSION,ORDER_SCENES,ORDER_FIELDS,ORDER_STATES,ORDER_STATE_TRANSITIONS,ORDER_LIFECYCLE_EVENTS,ORDER_PERMISSION_MATRIX,ORDER_AUDIT_FORMULAS,getScenesByOperationField as a180ad,findSceneById as a180ae,findSceneByMoveEntry as a180af,getScenesByPermissionLayer as a180ag,getScenesByReversibility as a180ah,getFieldDef as a180ai,getMutableFields as a180aj,getImmutableFields as a180ak,getFrozenAfterProgressFields as a180al,getOneTimeSetFields as a180am,inferSceneFromIntent as a180an,getEmittedEvents as a180ao,getInferredEvents as a180ap,getOrderScenesCount,sdkToMoveField as a180aq,moveToSdkField as a180ar}from'./order-ledger.js';import{initPuzzleFromIntent as a180as,checkPuzzleCompleteness as a180at,validateConstraints as a180au,generateConfirmationText as a180av,verifySnapshotMechanism as a180aw,inferLifecyclePhase as a180ax,matchSceneFromPuzzle as a180ay,listAllScenes as a180az,lookupScene as a180aA}from'./order-puzzle.js';import{ORDER_TEMPLATES,ORDER_TEMPLATES_VERSION,ORDER_TEMPLATES_COUNT,getAllOrderTemplates,getTemplateById as a180aB,getTemplatesByScene as a180aC,getTemplatesByIndustry as a180aD,getTemplatesByPermissionLayer as a180aE,getIrreversibleTemplates as a180aF,suggestTemplateForScene as a180aG,listOrderTemplates,fillTemplate as a180aH,suggestTemplateFromIntent as a180aI,getTemplateParameters as a180aJ,validateTemplateParams as a180aK}from'./order-templates.js';import{ORDER_RISK_VERSION,assessOrderRisks,getAllOrderRiskRules}from'./order-risk.js';import{PROGRESS_LEDGER_VERSION,PROGRESS_SCENES,PROGRESS_PERMISSIONS as a180aL,PROGRESS_NEW,PROGRESS_NAMED_OPERATOR,PROGRESS_TASK,PROGRESS_CONTEXT_REPOSITORY,PROGRESS_UNHOLD,PROGRESS_OWNER_RECEIVE,PROGRESS_CROSS_OBJECT_REFS,getScenesByPhase as a180aM,findSceneById as a180aN,getScenesByIndustry as a180aO,getBuiltinPermissionByIndex as a180aP,isProgressBuiltinPermission,inferSceneFromIntent as a180aQ,getAllBuiltinPermissions as a180aR,getProgressScenesCount,validateNamedOperatorAddressList,validateNamedOperatorCount,validateContextRepositoryCount}from'./progress-ledger.js';import{initPuzzleFromIntent as a180aS,checkPuzzleCompleteness as a180aT,validateConstraints as a180aU,generateConfirmationText as a180aV,resolveBuiltinPermission as a180aW,isOrderHolderForward,getRelevantDimensions as a180aX}from'./progress-puzzle.js';import{PROGRESS_TEMPLATES,PROGRESS_TEMPLATES_VERSION,getAllProgressTemplates,getProgressTemplateById,getProgressTemplatesByScene,getProgressTemplatesByIndustry,suggestProgressTemplateForScene,listProgressTemplates,fillProgressTemplate}from'./progress-templates.js';import{PROGRESS_RISK_VERSION,assessProgressRisks,getAllProgressRiskRules}from'./progress-risk.js';import{ARBITRATION_LEDGER_VERSION,ARBITRATION_SCENES,ARBITRATION_PERMISSIONS as a180aY,ARB_STATUS_CODE,ARB_TERMINAL_STATUSES,ARB_STATUS_ALIASES,DUAL_GUARD_MATRIX,getScenesByCategory as a180aZ,findSceneById as a180b0,findSceneByPermissionIndex as a180b1,getPermissionByIndex as a180b2,getPermissionByName as a180b3,isReservedIndex as a180b4,isUsedPermissionIndex as a180b5,getActivePermissionCount as a180b6,inferSceneFromIntent as a180b7,getDualGuardMatrixEntry,isValidArbStatusTransition,isTerminalArbStatus,getScenesProducingStatus as a180b8,getScenesRequiringStatus as a180b9,getArbitrationScenesCount,getAllArbitrationPermissions,getActiveArbitrationPermissions}from'./arbitration-ledger.js';import{initPuzzleFromIntent as a180ba,checkPuzzleCompleteness as a180bb,validateConstraints as a180bc,generateConfirmationText as a180bd}from'./arbitration-puzzle.js';import{ARBITRATION_TEMPLATES,ARBITRATION_TEMPLATES_VERSION,getAllTemplates as a180be,getTemplateById as a180bf,getTemplatesByScene as a180bg,getTemplatesByIndustry as a180bh,suggestTemplateForScene as a180bi,listTemplates as a180bj,fillTemplate as a180bk}from'./arbitration-templates.js';import{ARBITRATION_RISK_VERSION,assessArbitrationRisks,getAllRiskRules as a180bl}from'./arbitration-risk.js';import{REWARD_LEDGER_VERSION,REWARD_SCENES,REWARD_PERMISSIONS,REWARD_FIELDS,REWARD_GUARD_CONSTRUCTORS,REWARD_ERROR_CODES,REWARD_CROSS_OBJECT_REFS,MAX_GUARD_COUNT_REWARD,MAX_RECORD_COUNT_REWARD,getScenesByPhase as a180bm,findSceneById as a180bn,getScenesByIndustry as a180bo,getBuiltinPermissionByIndex as a180bp,isRewardBuiltinPermission,getAllBuiltinPermissions as a180bq,getRewardScenesCount,getGuardConstructorSpec as a180br,resolveGuardConstructor as a180bs,getRewardErrorByCode,getRewardErrorByName,validateGuardCount as a180bt,validateRecordCount as a180bu,inferSceneFromIntent as a180bv}from'./reward-ledger.js';import{REWARD_FIELD_MUTABILITY,initPuzzleFromIntent as a180bw,checkPuzzleCompleteness as a180bx,validateConstraints as a180by,generateConfirmationText as a180bz,resolveBuiltinPermission as a180bA,requiresGuardConfig as a180bB,requiresPassport as a180bC,getRelevantDimensions as a180bD,getFieldMutability as a180bE,isAdminMutableField as a180bF,getFieldPermissionIndex as a180bG}from'./reward-puzzle.js';import{REWARD_RISK_VERSION,assessRewardRisks,getAllRewardRiskRules}from'./reward-risk.js';import{PASSPORT_LEDGER_VERSION,PASSPORT_ERROR_CODES,PASSPORT_SCENARIOS,MAX_GUARD_COUNT_PASSPORT,MAX_SUBMISSION_SIZE_PASSPORT,getAllScenarios as a180bH,getScenariosCount as a180bI,findScenarioById as a180bJ,getScenariosByConsumer as a180bK,getScenariosUsingRelies as a180bL,inferScenarioFromIntent as a180bM,impackRoleFromBoolean,impackRoleToBoolean,reliesLogicFromBoolean,reliesLogicToBoolean,getErrorName as a180bN,getErrorDescription as a180bO}from'./passport-ledger.js';import{PASSPORT_TEMPLATES,PASSPORT_TEMPLATES_VERSION,getAllTemplates as a180bP,getTemplateById as a180bQ,getTemplatesByScenario as a180bR,getTemplatesByIndustry as a180bS,suggestTemplateForScenario as a180bT,listTemplates as a180bU,fillTemplate as a180bV}from'./passport-templates.js';import{PROOF_RISK_RULES,checkProofRisks}from'./proof-risk.js';import{REPOSITORY_RISK_RULES,checkRepositoryRisks,parseIdFromForRiskCheck}from'./repository-risk.js';import{DEMAND_RISK_RULES,checkDemandRisks}from'./demand-risk.js';import{CONTACT_RISK_RULES,CONTACT_RISK_VERSION,checkContactRisks}from'./contact-risk.js';import{RESOURCE_RISK_RULES,RESOURCE_RISK_VERSION,checkResourceRisks}from'./resource-risk.js';import{PAYMENT_RISK_RULES,PAYMENT_RISK_VERSION,checkPaymentRisks}from'./payment-risk.js';import{ARB_RISK_RULES,ARB_RISK_VERSION,checkArbRisks}from'./arb-risk.js';import{PERSONAL_RISK_RULES,PERSONAL_RISK_VERSION,checkPersonalRisks}from'./personal-risk.js';import{UTIL_RISK_RULES,UTIL_RISK_VERSION,checkUtilRisks}from'./util-risk.js';import{REGISTRAR_RISK_RULES,REGISTRAR_RISK_VERSION,checkRegistrarRisks}from'./registrar-risk.js';import{BRIDGE_RISK_RULES,BRIDGE_RISK_VERSION,checkBridgeRisks}from'./bridge-risk.js';import{TOOLS_REFERENCE,getToolReference,searchToolReference,getToolSequence}from'./tools-reference.js';import{SCENARIO_MODES,SCENARIO_MODES_VERSION,MODE_COMPOSITIONS,matchScenarioMode,inferScenarioTraits,getScenarioMode,listScenarioModes,getShippedModes,getModeCompositions}from'./scenario-modes.js';import{BUILTIN_TEMPLATES,BUILTIN_TEMPLATES_VERSION,getBuiltinTemplate,listBuiltinTemplates,TEMPLATE_KEYWORDS}from'./builtin-templates.js';import{resolveTemplatesDir,seedBuiltinTemplates,reloadTemplates,listTemplates,getTemplate,getTemplatesByIndustry as a180bW,parseTemplateFile,renderTemplateFile,loadAndValidate,TemplateFrontmatterSchema}from'./template-loader.js';import{scanTemplate}from'./template-scanner.js';import{GUARD_DESIGN_PATTERNS,GUARD_DESIGN_PATTERNS_VERSION,VERIFIER_LEVEL_GUIDANCE,getGuardDesignPattern,searchGuardDesignPatterns,getPatternsByHost,getPatternsByIndustry,getPatternsByDataSourceClass,getVerifierLevelGuidance,suggestPatternForRequirement}from'./guard-design-patterns.js';export{CONFIRMATION_RULES,SAFETY_RULES_VERSION,OBJECT_REUSE_RULES,CREATE_VS_MODIFY_PATTERN,IMMUTABILITY_RULES,OPERATION_TYPE_CLASSIFICATION,OPERATION_CLASS_META,classifyTool,NAMING_CONVENTIONS,checkObjectReuseRules,checkImmutabilityRules};export{TOOL_CONSTRAINTS,TOOL_CONSTRAINTS_VERSION,validateOperation,hasBlockingViolations,getWarningViolations};export{REWARD_TEMPLATES,REWARD_TEMPLATES_VERSION,getRewardTemplate,listRewardTemplates,suggestRewardTemplate};export{AUDIT_RULES,AUDIT_RULES_VERSION,auditService,hasBlockingErrors,getErrors,getWarnings,summarizeFindings};export{suggestPricing,MUTABLE_FIELDS,DYNAMIC_PRICING_VERSION};export{buildReviewRepositorySetup,computeReviewStats,isVerifiedReview,filterVerifiedReviews,detectReviewManipulation,REPUTATION_RULES_VERSION};export{INDUSTRY_FLYWHEELS,getFlywheelForIndustry,listIndustries,suggestAcquisitionActions,generateTrustDescription,buildAcquisitionDashboard,ACQUISITION_FLYWHEEL_VERSION};export{STRATEGY_MANUAL_FILENAME,STRATEGY_MANUAL_VERSION,renderStrategyManual,parseManualSentinel,classifyManualFile,getBuiltinStrategyManual,listBuiltinStrategyManualIndustries}from'./strategy-manuals.js';export{INDUSTRY_STRATEGIES,getIndustryStrategy,listIndustryStrategies,registerIndustryStrategy,unregisterIndustryStrategy,recommendStrategy,stageFromOrderCount,validateStrategyLevers}from'./industry-strategy.js';export{INDUSTRY_REGISTRY_VERSION,getIndustryProfile,listIndustries as listRegistryIndustries,registerIndustry,getIndustryTraits,resolveIndustryName,isRegisteredIndustry,getRegistrySize,listBuiltinIndustryNames};export{DEFAULT_TRAITS,inferTraitsFromDescription,synthesizeProfile,findSimilarIndustries,composeIndustries,INDUSTRY_REQUIRED_TRAITS,DOMAIN_PRIORS,detectDomainPriors,traitContradictions,filterConsistentIndustries};export{INDUSTRY_EVOLUTION_THRESHOLDS,aggregateIndustryMetrics,evaluateIndustryHealth,suggestIndustryUpdate,applyIndustryUpdate,runIndustryHealthPipeline};export{FLYWHEEL_LOOP_VERSION,FLYWHEEL_LOOP_MIN_SIGNALS,recordIndustrySignal,updateIndustryCognition,injectEvolutionContext};export{BUILTIN_INTENT_SPECS,registerIntentProfile,getIntentProfile,listIntents,evaluateIndustryHealthByIntent,suggestIndustryUpdateByIntent,evaluateIndustryHealthMultiIntent,getRoleAdvice,filterSuggestionsByRole};export{GUARD_SCENES,findScene,inferSceneFromAction,getImmutableScenes,getNumericIdentifierScenes};export{SEMANTIC_TO_SCHEMA_RULES,SCHEMA_TO_SEMANTIC_RULES,GUARD_CONSTRAINT_RULES,matchSemanticPattern,explainNode,explainWitness,getConstraintsByCategory};export{checkPuzzleCompleteness,generateConfirmationText,initPuzzleFromIntent,inferBindingFromAction,emptyDataSources,getWitnessInfo,WITNESS_NAME_MAP};export{runGuardRulePack,assembleGuardAssessment,evaluateGuardDraft,getRiskRulesCount,GUARD_TEMPLATES,GUARD_TEMPLATES_VERSION,GUARD_TEMPLATES_COUNT,getTemplatesByScene,getTemplateById,getTemplatesByIndustry,getTemplatesByPattern,listGuardTemplates,suggestTemplateForScene,getTemplateParameters,validateTemplateParams,GUARD_BINDING_REGISTRY,GUARD_BINDINGS_VERSION,OWNER_RECEIVE_COGNITION,getGuardBindingsByObject,getGuardBinding,summarizeGuardBinding,SCENARIO_BRIDGE_REGISTRY,SCENARIO_CHAINS,SCENARIO_TOPOLOGY_VERSION,getBridgeById,getBridgeByCode,getBridgesByObject,getBridgesForEdge,detectBridgesForEdges,getChainById,summarizeBridge,detectBridgesForObjects,lintGuard,autoFixGuard,isGuardReady,getGuardErrors,formatLintResult};export{MACHINE_SCENES,MACHINE_LEDGER_VERSION,MACHINE_SCENES_COUNT,a180a as findMachineScene,a180b as getMachineScenesByIndustry,getScenesByPattern,inferSceneFromFlow};export{MACHINE_TEMPLATES,MACHINE_TEMPLATES_VERSION,MACHINE_TEMPLATES_COUNT,a180c as getAllMachineTemplates,a180d as getMachineTemplateById,a180e as getMachineTemplatesByScene,a180f as getMachineTemplatesByIndustry,suggestTemplateForIntent,walkDecisionTree,a180g as fillMachineTemplate,a180h as forkMachineTemplate,verifyTemplateSceneReferences,getReferencedGuardTemplateIds,getReferencedRiskIds};export{SEMANTIC_TO_MACHINE_RULES,MACHINE_CONSTRAINT_RULES,MACHINE_TRANSLATION_VERSION,MACHINE_PATTERNS_COUNT,MACHINE_CONSTRAINTS_COUNT,a180i as matchMachinePattern,identifyExecutionMode,identifyTopology,explainForwardPermission,a180j as getMachineConstraintsByCategory,getConstraintById,a180k as getOnChainMachineConstraints,a180l as getOffChainMachineConstraints};export{MACHINE_RISK_RULES,MACHINE_RISK_VERSION,assessMachineRisks};export{analyzeTopology,identifyTopologyPattern,formatTopologySummary,MACHINE_TOPOLOGY_VERSION,MAX_NODE_COUNT,MAX_NODE_PAIR_COUNT,MAX_FORWARD_COUNT};export{a180m as initMachinePuzzleFromIntent,initPuzzleFromTemplate,a180n as checkMachinePuzzleCompleteness,a180o as recommendMachineNextStep,derivePuzzleFromMachineJson,a180p as generateMachineConfirmationText,MACHINE_PUZZLE_VERSION};export{SERVICE_SCENES,SERVICE_LEDGER_VERSION,SERVICE_PERMISSIONS,SERVICE_ORDER_FLOW_STAGES,SERVICE_CROSS_OBJECT_BINDINGS,a180q as getServiceScenesByCategory,a180r as findServiceSceneById,getServicePermissionByIndex,isServicePermission,getPermissionsByMutability,getImmutablePostPublishPermissions,getLockedByDurationPermissions,a180s as inferServiceSceneFromIntent,getAllServiceScenes,getServiceScenesCount,getServicePermissionsCount,getOrderFlowStage,a180t as getServiceCrossObjectBindings};export{a180u as initServicePuzzleFromIntent,a180v as checkServicePuzzleCompleteness,a180w as validateServiceConstraints,a180x as generateServicePuzzleConfirmationText,initOrderFlowPuzzle,checkOrderFlowCompleteness};export{SERVICE_RISK_VERSION,assessServiceRisks,getAllServiceRiskRules};export{SERVICE_TEMPLATES,SERVICE_TEMPLATES_VERSION,getServiceTemplateById,getServiceTemplatesByScene,getServiceTemplatesByIndustry,suggestServiceTemplateForScene,listServiceTemplates,fillServiceTemplate,getAllServiceTemplates};export{ALLOCATION_SCENES,ALLOCATION_LEDGER_VERSION,MAX_ALLOCATOR_COUNT,ALLOCATION_MAX_SHARING_COUNT,ALLOCATION_MODE_AMOUNT,ALLOCATION_MODE_RATE,ALLOCATION_MODE_SURPLUS,RATE_TOTAL_FULL,ALLOCATION_ERROR_CODES,a180y as getAllocationScenesByTriggerSource,a180z as getAllocationScenesByMode,a180A as getAllocationScenesByStrategy,a180B as findAllocationSceneById,a180C as inferAllocationSceneFromIntent,a180D as getAllAllocationScenes,a180E as getAllocationScenesCount,allocationModeToNumber,allocationModeFromNumber,getRecipientType,isSignerRecipient,isEntityRecipient,isGuardIdentifierRecipient,a180F as getAllocationErrorName,a180G as getAllocationErrorDescription};export{a180H as initAllocationPuzzleFromIntent,a180I as checkAllocationPuzzleCompleteness,a180J as validateAllocationConstraints,a180K as generateAllocationPuzzleConfirmationText,buildDefaultAllocFlow,buildDefaultRecipientRules,buildDefaultLogicPuzzle,ALLOCATION_PUZZLE_VERSION};export{ALLOCATION_RISK_VERSION,assessAllocationRisks,a180L as getAllAllocationRiskRules};export{ALLOCATION_TEMPLATES,ALLOCATION_TEMPLATES_VERSION,a180M as getAllAllocationTemplates,a180N as getAllocationTemplateById,a180O as getAllocationTemplatesByScene,a180P as getAllocationTemplatesByIndustry,a180Q as suggestAllocationTemplateForScene,a180R as listAllocationTemplates,a180S as fillAllocationTemplate};export{RECIPIENT_CONSTRAINT_VERSION,classifyRecipient,analyzeRecipientConstraints,isUnboundSignerTheft,canonicalDoctrine,recipientDesignGuidance,derivePayoffFromSharing,OBJECT_DRIVEABILITY,driveabilityOf,RECIPIENT_DESIGN_OPTIONS};export{paymentRelations,scanRecentPaymentEvents,resolveBeneficialOwners,extractionPlanForHolder,pendingWrappersAt,trackAccountPayments};export{TREASURY_LEDGER_VERSION,TREASURY_SCENES,a180T as TREASURY_BUILTIN_PERMISSIONS,a180U as getTreasuryScenesByHostObject,a180V as findTreasurySceneById,a180W as findTreasurySceneByPermissionIndex,a180X as getTreasuryBuiltinPermissionByIndex,isBuiltinTreasuryPermission,a180Y as getActiveTreasuryBuiltinPermissions,a180Z as getReservedTreasuryBuiltinPermissions,a180a0 as inferTreasurySceneFromIntent,getTreasuryScenesCount,a180a1 as getTreasuryGovernedOperationsForPermissionIndex};export{a180a2 as initTreasuryPuzzleFromIntent,a180a3 as checkTreasuryPuzzleCompleteness,a180a4 as validateTreasuryConstraints,a180a5 as generateTreasuryPuzzleConfirmationText,MAX_EXTERNAL_DEPOSIT_GUARD_COUNT,MAX_EXTERNAL_WITHDRAW_GUARD_COUNT,a180a6 as TREASURY_MAX_DESCRIPTION_LENGTH};export{TREASURY_TEMPLATES,TREASURY_TEMPLATES_VERSION,getAllTreasuryTemplates,a180a7 as getTreasuryTemplateById,a180a8 as getTreasuryTemplatesByScene,a180a9 as getTreasuryTemplatesByIndustry,a180aa as suggestTreasuryTemplateForScene,a180ab as listTreasuryTemplates,a180ac as fillTreasuryTemplate};export{TREASURY_RISK_VERSION,assessTreasuryRisks,getAllTreasuryRiskRules};export{ORDER_LEDGER_VERSION,ORDER_SCENES,ORDER_FIELDS,ORDER_STATES,ORDER_STATE_TRANSITIONS,ORDER_LIFECYCLE_EVENTS,ORDER_PERMISSION_MATRIX,ORDER_AUDIT_FORMULAS,a180ad as getOrderScenesByOperationField,a180ae as findOrderSceneById,a180af as findOrderSceneByMoveEntry,a180ag as getOrderScenesByPermissionLayer,a180ah as getOrderScenesByReversibility,a180ai as getOrderFieldDef,a180aj as getOrderMutableFields,a180ak as getOrderImmutableFields,a180al as getOrderFrozenAfterProgressFields,a180am as getOrderOneTimeSetFields,a180an as inferOrderSceneFromIntent,a180ao as getOrderEmittedEvents,a180ap as getOrderInferredEvents,getOrderScenesCount,a180aq as sdkToMoveOrderField,a180ar as moveToSdkOrderField};export{a180as as initOrderPuzzleFromIntent,a180at as checkOrderPuzzleCompleteness,a180au as validateOrderConstraints,a180av as generateOrderPuzzleConfirmationText,a180aw as verifyOrderSnapshotMechanism,a180ax as inferOrderLifecyclePhase,a180ay as matchOrderSceneFromPuzzle,a180az as listAllOrderScenes,a180aA as lookupOrderScene};export{ORDER_TEMPLATES,ORDER_TEMPLATES_VERSION,ORDER_TEMPLATES_COUNT,getAllOrderTemplates,a180aB as getOrderTemplateById,a180aC as getOrderTemplatesByScene,a180aD as getOrderTemplatesByIndustry,a180aE as getOrderTemplatesByPermissionLayer,a180aF as getIrreversibleOrderTemplates,a180aG as suggestOrderTemplateForScene,listOrderTemplates,a180aH as fillOrderTemplate,a180aI as suggestOrderTemplateFromIntent,a180aJ as getOrderTemplateParameters,a180aK as validateOrderTemplateParams};export{ORDER_RISK_VERSION,assessOrderRisks,getAllOrderRiskRules};export{PROGRESS_LEDGER_VERSION,PROGRESS_SCENES,a180aL as PROGRESS_BUILTIN_PERMISSIONS,PROGRESS_NEW,PROGRESS_NAMED_OPERATOR,PROGRESS_TASK,PROGRESS_CONTEXT_REPOSITORY,PROGRESS_UNHOLD,PROGRESS_OWNER_RECEIVE,PROGRESS_CROSS_OBJECT_REFS,a180aM as getProgressScenesByPhase,a180aN as findProgressSceneById,a180aO as getProgressScenesByIndustry,a180aP as getProgressBuiltinPermissionByIndex,isProgressBuiltinPermission,a180aQ as inferProgressSceneFromIntent,a180aR as getAllProgressBuiltinPermissions,getProgressScenesCount,validateNamedOperatorAddressList,validateNamedOperatorCount,validateContextRepositoryCount};export{a180aS as initProgressPuzzleFromIntent,a180aT as checkProgressPuzzleCompleteness,a180aU as validateProgressConstraints,a180aV as generateProgressPuzzleConfirmationText,a180aW as resolveProgressBuiltinPermission,isOrderHolderForward,a180aX as getProgressRelevantDimensions};export{PROGRESS_TEMPLATES,PROGRESS_TEMPLATES_VERSION,getAllProgressTemplates,getProgressTemplateById,getProgressTemplatesByScene,getProgressTemplatesByIndustry,suggestProgressTemplateForScene,listProgressTemplates,fillProgressTemplate};export{PROGRESS_RISK_VERSION,assessProgressRisks,getAllProgressRiskRules};export{ARBITRATION_LEDGER_VERSION,ARBITRATION_SCENES,a180aY as ARBITRATION_BUILTIN_PERMISSIONS,ARB_STATUS_CODE,ARB_TERMINAL_STATUSES,ARB_STATUS_ALIASES,DUAL_GUARD_MATRIX,a180aZ as getArbitrationScenesByCategory,a180b0 as findArbitrationSceneById,a180b1 as findArbitrationSceneByPermissionIndex,a180b2 as getArbitrationPermissionByIndex,a180b3 as getArbitrationPermissionByName,a180b4 as isArbitrationReservedIndex,a180b5 as isArbitrationUsedPermissionIndex,a180b6 as getArbitrationActivePermissionCount,a180b7 as inferArbitrationSceneFromIntent,getDualGuardMatrixEntry,isValidArbStatusTransition,isTerminalArbStatus,a180b8 as getArbitrationScenesProducingStatus,a180b9 as getArbitrationScenesRequiringStatus,getArbitrationScenesCount,getAllArbitrationPermissions,getActiveArbitrationPermissions};export{a180ba as initArbitrationPuzzleFromIntent,a180bb as checkArbitrationPuzzleCompleteness,a180bc as validateArbitrationConstraints,a180bd as generateArbitrationPuzzleConfirmationText};export{ARBITRATION_TEMPLATES,ARBITRATION_TEMPLATES_VERSION,a180be as getAllArbitrationTemplates,a180bf as getArbitrationTemplateById,a180bg as getArbitrationTemplatesByScene,a180bh as getArbitrationTemplatesByIndustry,a180bi as suggestArbitrationTemplateForScene,a180bj as listArbitrationTemplates,a180bk as fillArbitrationTemplate};export{ARBITRATION_RISK_VERSION,assessArbitrationRisks,a180bl as getAllArbitrationRiskRules};export{REWARD_LEDGER_VERSION,REWARD_SCENES,REWARD_PERMISSIONS,REWARD_FIELDS,REWARD_GUARD_CONSTRUCTORS,REWARD_ERROR_CODES,REWARD_CROSS_OBJECT_REFS,MAX_GUARD_COUNT_REWARD,MAX_RECORD_COUNT_REWARD,a180bm as getRewardScenesByPhase,a180bn as findRewardSceneById,a180bo as getRewardScenesByIndustry,a180bp as getRewardBuiltinPermissionByIndex,isRewardBuiltinPermission,a180bq as getAllRewardBuiltinPermissions,getRewardScenesCount,a180br as getRewardGuardConstructorSpec,a180bs as resolveRewardGuardConstructor,getRewardErrorByCode,getRewardErrorByName,a180bt as validateRewardGuardCount,a180bu as validateRewardRecordCount,a180bv as inferRewardSceneFromIntent};export{REWARD_FIELD_MUTABILITY,a180bw as initRewardPuzzleFromIntent,a180bx as checkRewardPuzzleCompleteness,a180by as validateRewardConstraints,a180bz as generateRewardPuzzleConfirmationText,a180bA as resolveRewardBuiltinPermission,a180bB as requiresRewardGuardConfig,a180bC as requiresRewardPassport,a180bD as getRewardRelevantDimensions,a180bE as getRewardFieldMutability,a180bF as isRewardAdminMutableField,a180bG as getRewardFieldPermissionIndex};export{REWARD_RISK_VERSION,assessRewardRisks,getAllRewardRiskRules};export{PASSPORT_LEDGER_VERSION,PASSPORT_ERROR_CODES,PASSPORT_SCENARIOS,MAX_GUARD_COUNT_PASSPORT,MAX_SUBMISSION_SIZE_PASSPORT,a180bH as getAllPassportScenarios,a180bI as getPassportScenesCount,a180bJ as findPassportScenarioById,a180bK as getPassportScenariosByConsumer,a180bL as getPassportScenariosUsingRelies,a180bM as inferPassportScenarioFromIntent,impackRoleFromBoolean,impackRoleToBoolean,reliesLogicFromBoolean,reliesLogicToBoolean,a180bN as getPassportErrorName,a180bO as getPassportErrorDescription};export{PASSPORT_TEMPLATES,PASSPORT_TEMPLATES_VERSION,a180bP as getAllPassportTemplates,a180bQ as getPassportTemplateById,a180bR as getPassportTemplatesByScenario,a180bS as getPassportTemplatesByIndustry,a180bT as suggestPassportTemplateForScenario,a180bU as listPassportTemplates,a180bV as fillPassportTemplate};export{PROOF_RISK_RULES,checkProofRisks};export{REPOSITORY_RISK_RULES,checkRepositoryRisks,parseIdFromForRiskCheck};export{assessEvidenceReview,reviewEvidenceList}from'./evidence-review.js';export{DEMAND_RISK_RULES,checkDemandRisks};export{CONTACT_RISK_RULES,CONTACT_RISK_VERSION,checkContactRisks};export{RESOURCE_RISK_RULES,RESOURCE_RISK_VERSION,checkResourceRisks};export{PAYMENT_RISK_RULES,PAYMENT_RISK_VERSION,checkPaymentRisks};export{ARB_RISK_RULES,ARB_RISK_VERSION,checkArbRisks};export{PERSONAL_RISK_RULES,PERSONAL_RISK_VERSION,checkPersonalRisks};export{UTIL_RISK_RULES,UTIL_RISK_VERSION,checkUtilRisks};export{REGISTRAR_RISK_RULES,REGISTRAR_RISK_VERSION,checkRegistrarRisks};export{BRIDGE_RISK_RULES,BRIDGE_RISK_VERSION,checkBridgeRisks};export{TOOLS_REFERENCE,getToolReference,searchToolReference,getToolSequence};export{SCENARIO_MODES,SCENARIO_MODES_VERSION,MODE_COMPOSITIONS,matchScenarioMode,inferScenarioTraits,getScenarioMode,listScenarioModes,getShippedModes,getModeCompositions};export{BUILTIN_TEMPLATES,BUILTIN_TEMPLATES_VERSION,getBuiltinTemplate,listBuiltinTemplates,TEMPLATE_KEYWORDS};export{resolveTemplatesDir,seedBuiltinTemplates,reloadTemplates,listTemplates,getTemplate,a180bW as getIndustryTemplates,parseTemplateFile,renderTemplateFile,loadAndValidate,TemplateFrontmatterSchema};export{scanTemplate};export{GUARD_DESIGN_PATTERNS,GUARD_DESIGN_PATTERNS_VERSION,VERIFIER_LEVEL_GUIDANCE,getGuardDesignPattern,searchGuardDesignPatterns,getPatternsByHost,getPatternsByIndustry,getPatternsByDataSourceClass,getVerifierLevelGuidance,suggestPatternForRequirement};export function getKnowledgeBase(){return{'version':{'safety':SAFETY_RULES_VERSION,'tool_constraints':TOOL_CONSTRAINTS_VERSION,'reward_templates':REWARD_TEMPLATES_VERSION,'audit_rules':AUDIT_RULES_VERSION,'dynamic_pricing':DYNAMIC_PRICING_VERSION,'reputation_rules':REPUTATION_RULES_VERSION,'acquisition_flywheel':ACQUISITION_FLYWHEEL_VERSION,'industry_registry':INDUSTRY_REGISTRY_VERSION,'flywheel_loop':FLYWHEEL_LOOP_VERSION,'machine_ledger':MACHINE_LEDGER_VERSION,'machine_templates':MACHINE_TEMPLATES_VERSION,'machine_translation':MACHINE_TRANSLATION_VERSION,'machine_risk':MACHINE_RISK_VERSION,'machine_topology':MACHINE_TOPOLOGY_VERSION,'machine_puzzle':MACHINE_PUZZLE_VERSION,'service_ledger':SERVICE_LEDGER_VERSION,'service_risk':SERVICE_RISK_VERSION,'service_templates':SERVICE_TEMPLATES_VERSION,'allocation_ledger':ALLOCATION_LEDGER_VERSION,'allocation_puzzle':ALLOCATION_PUZZLE_VERSION,'allocation_risk':ALLOCATION_RISK_VERSION,'allocation_templates':ALLOCATION_TEMPLATES_VERSION,'treasury_ledger':TREASURY_LEDGER_VERSION,'treasury_templates':TREASURY_TEMPLATES_VERSION,'treasury_risk':TREASURY_RISK_VERSION,'order_ledger':ORDER_LEDGER_VERSION,'order_templates':ORDER_TEMPLATES_VERSION,'order_risk':ORDER_RISK_VERSION,'progress_ledger':PROGRESS_LEDGER_VERSION,'progress_templates':PROGRESS_TEMPLATES_VERSION,'progress_risk':PROGRESS_RISK_VERSION,'arbitration_ledger':ARBITRATION_LEDGER_VERSION,'arbitration_templates':ARBITRATION_TEMPLATES_VERSION,'arbitration_risk':ARBITRATION_RISK_VERSION,'reward_ledger':REWARD_LEDGER_VERSION,'reward_risk':REWARD_RISK_VERSION,'passport_ledger':PASSPORT_LEDGER_VERSION,'passport_templates':PASSPORT_TEMPLATES_VERSION,'contact_risk':CONTACT_RISK_VERSION,'resource_risk':RESOURCE_RISK_VERSION,'payment_risk':PAYMENT_RISK_VERSION,'arb_risk':ARB_RISK_VERSION,'personal_risk':PERSONAL_RISK_VERSION,'util_risk':UTIL_RISK_VERSION,'registrar_risk':REGISTRAR_RISK_VERSION,'bridge_risk':BRIDGE_RISK_VERSION,'scenario_modes':SCENARIO_MODES_VERSION,'guard_design_patterns':GUARD_DESIGN_PATTERNS_VERSION,'builtin_templates':BUILTIN_TEMPLATES_VERSION},'confirmation_rules':CONFIRMATION_RULES['length'],'confirmation_rule_ids':CONFIRMATION_RULES['map'](a=>a['id']),'tool_constraints_count':TOOL_CONSTRAINTS['length'],'reward_templates_count':REWARD_TEMPLATES['length'],'audit_rules_count':AUDIT_RULES['length'],'mutable_fields_count':MUTABLE_FIELDS['length'],'industry_flywheels_count':INDUSTRY_FLYWHEELS['length'],'industry_registry_count':getRegistrySize(),'intent_count':listIntents()['length'],'guard_scenes_count':GUARD_SCENES['length'],'guard_semantic_rules_count':SEMANTIC_TO_SCHEMA_RULES['length'],'guard_schema_rules_count':SCHEMA_TO_SEMANTIC_RULES['length'],'guard_constraint_rules_count':GUARD_CONSTRAINT_RULES['length'],'guard_risk_rules_count':getRiskRulesCount(),'guard_templates_count':GUARD_TEMPLATES_COUNT,'guard_lint_enabled':!![],'machine_scenes_count':MACHINE_SCENES_COUNT,'machine_templates_count':MACHINE_TEMPLATES['length'],'machine_patterns_count':SEMANTIC_TO_MACHINE_RULES['length'],'machine_constraint_rules_count':MACHINE_CONSTRAINT_RULES['length'],'machine_risk_rules_count':MACHINE_RISK_RULES['length'],'machine_on_chain_limits':{'max_node_count':MAX_NODE_COUNT,'max_node_pair_count':MAX_NODE_PAIR_COUNT,'max_forward_count':MAX_FORWARD_COUNT},'service_scenes_count':SERVICE_SCENES['length'],'service_permissions_count':SERVICE_PERMISSIONS['length'],'service_order_flow_stages_count':SERVICE_ORDER_FLOW_STAGES['length'],'service_cross_object_bindings_count':SERVICE_CROSS_OBJECT_BINDINGS['length'],'service_risk_rules_count':getAllServiceRiskRules()['length'],'service_templates_count':SERVICE_TEMPLATES['length'],'service_context_enabled':!![],'allocation_scenes_count':ALLOCATION_SCENES['length'],'allocation_risk_rules_count':a180L()['length'],'allocation_templates_count':ALLOCATION_TEMPLATES['length'],'allocation_context_enabled':!![],'treasury_scenes_count':TREASURY_SCENES['length'],'treasury_builtin_permissions_count':a180T['length'],'treasury_risk_rules_count':getAllTreasuryRiskRules()['length'],'treasury_templates_count':TREASURY_TEMPLATES['length'],'treasury_context_enabled':!![],'order_scenes_count':ORDER_SCENES['length'],'order_fields_count':ORDER_FIELDS['length'],'order_states_count':ORDER_STATES['length'],'order_lifecycle_events_count':ORDER_LIFECYCLE_EVENTS['length'],'order_risk_rules_count':getAllOrderRiskRules()['length'],'order_templates_count':ORDER_TEMPLATES['length'],'order_context_enabled':!![],'progress_scenes_count':PROGRESS_SCENES['length'],'progress_builtin_permissions_count':a180aL['length'],'progress_risk_rules_count':getAllProgressRiskRules()['length'],'progress_templates_count':PROGRESS_TEMPLATES['length'],'progress_context_enabled':!![],'arbitration_scenes_count':ARBITRATION_SCENES['length'],'arbitration_builtin_permissions_count':a180aY['length'],'arbitration_risk_rules_count':a180bl()['length'],'arbitration_templates_count':ARBITRATION_TEMPLATES['length'],'arbitration_context_enabled':!![],'reward_scenes_count':REWARD_SCENES['length'],'reward_builtin_permissions_count':REWARD_PERMISSIONS['length'],'reward_fields_count':REWARD_FIELDS['length'],'reward_guard_constructors_count':REWARD_GUARD_CONSTRUCTORS['length'],'reward_error_codes_count':REWARD_ERROR_CODES['length'],'reward_risk_rules_count':getAllRewardRiskRules()['length'],'reward_context_enabled':!![],'passport_scenarios_count':PASSPORT_SCENARIOS['length'],'passport_max_guard_count':MAX_GUARD_COUNT_PASSPORT,'passport_max_submission_size':MAX_SUBMISSION_SIZE_PASSPORT,'passport_templates_count':PASSPORT_TEMPLATES['length'],'passport_context_enabled':!![],'proof_risk_rules_count':PROOF_RISK_RULES['length'],'repository_risk_rules_count':REPOSITORY_RISK_RULES['length'],'demand_risk_rules_count':DEMAND_RISK_RULES['length'],'contact_risk_rules_count':CONTACT_RISK_RULES['length'],'resource_risk_rules_count':RESOURCE_RISK_RULES['length'],'payment_risk_rules_count':PAYMENT_RISK_RULES['length'],'arb_risk_rules_count':ARB_RISK_RULES['length'],'personal_risk_rules_count':PERSONAL_RISK_RULES['length'],'util_risk_rules_count':UTIL_RISK_RULES['length'],'registrar_risk_rules_count':REGISTRAR_RISK_RULES['length'],'bridge_risk_rules_count':BRIDGE_RISK_RULES['length'],'tools_reference_count':TOOLS_REFERENCE['length'],'scenario_modes_count':SCENARIO_MODES['length'],'scenario_mode_compositions_count':MODE_COMPOSITIONS['length'],'builtin_templates_count':BUILTIN_TEMPLATES['length'],'guard_design_patterns_count':GUARD_DESIGN_PATTERNS['length'],'verifier_level_guidance_count':VERIFIER_LEVEL_GUIDANCE['length']};}export{buildWorkflowGuidance,buildWorkflowReceipt,enrichWorkflowGuidance,mergeGuidanceIntoOutput,resolvePermissionRole,resolveLocalNamesFor,listLocalAccounts,accountCanExecuteForward,enumerateActionableForwards,forwardOperatorKind};export{buildWorkspaceLists}from'./workspace-lists.js';export{resolveSupplyChainGraph}from'./supply-chain.js';export{enumerateObjectOperations,operationCategoryOf,operationComplexityOf,isPermissionIndexType}from'./operation-dictionary.js';export{enumerateServices,enumerateDemands,enumerateArbs}from'./jsonrpc-enum.js';export{FIELD_MUTABILITY_RULES,LOCK_CONSTRAINTS,IRREVERSIBLE_OPERATIONS,STATE_MACHINE_TERMINALS,NUMERIC_LIMIT_CONSTRAINTS,EXTERNAL_ACCESS_MECHANISMS,fieldMutabilityOf,isActionForbidden,lockConstraintOf,numericLimitOf,externalAccessOf}from'./contract-invariants.js';export{GUARD_FIELD_COGNITION_VERSION,GUARD_FIELD_SITES,VALUE_ORIGIN_SEMANTICS,GUARD_PASSPORT_DOCTRINE,guardSitesFor,guardCognitionDoctrine,REPOSITORY_WRITE_ROUTE_MATRIX,repositoryRouteSlotConflicts}from'./guard-field-cognition.js';
|
|
1
|
+
import{buildWorkflowGuidance,buildWorkflowReceipt,enrichWorkflowGuidance,mergeGuidanceIntoOutput,resolvePermissionRole,resolveLocalNamesFor,listLocalAccounts,accountCanExecuteForward,enumerateActionableForwards,forwardOperatorKind}from'./workflow-guidance.js';import{CONFIRMATION_RULES,SAFETY_RULES_VERSION,OBJECT_REUSE_RULES,CREATE_VS_MODIFY_PATTERN,IMMUTABILITY_RULES,OPERATION_TYPE_CLASSIFICATION,OPERATION_CLASS_META,classifyTool,NAMING_CONVENTIONS,checkObjectReuseRules,checkImmutabilityRules}from'./safety-rules.js';import{TOOL_CONSTRAINTS,TOOL_CONSTRAINTS_VERSION,validateOperation,hasBlockingViolations,getWarningViolations}from'./tool-constraints.js';import{REWARD_TEMPLATES,REWARD_TEMPLATES_VERSION,getRewardTemplate,listRewardTemplates,suggestRewardTemplate}from'./reward-templates.js';import{AUDIT_RULES,AUDIT_RULES_VERSION,auditService,hasBlockingErrors,getErrors,getWarnings,summarizeFindings}from'./audit-rules.js';import{suggestPricing,MUTABLE_FIELDS,DYNAMIC_PRICING_VERSION}from'./dynamic-pricing.js';import{buildReviewRepositorySetup,computeReviewStats,isVerifiedReview,filterVerifiedReviews,detectReviewManipulation,REPUTATION_RULES_VERSION}from'./reputation-rules.js';import{INDUSTRY_FLYWHEELS,getFlywheelForIndustry,listIndustries,suggestAcquisitionActions,generateTrustDescription,buildAcquisitionDashboard,ACQUISITION_FLYWHEEL_VERSION}from'./acquisition-flywheel.js';import{INDUSTRY_REGISTRY_VERSION,getIndustryProfile,registerIndustry,getIndustryTraits,resolveIndustryName,isRegisteredIndustry,getRegistrySize,listBuiltinIndustryNames}from'./industry-registry.js';import{DEFAULT_TRAITS,inferTraitsFromDescription,synthesizeProfile,findSimilarIndustries,composeIndustries,INDUSTRY_REQUIRED_TRAITS,DOMAIN_PRIORS,detectDomainPriors,traitContradictions,filterConsistentIndustries}from'./industry-generalizer.js';import{INDUSTRY_EVOLUTION_THRESHOLDS,aggregateIndustryMetrics,evaluateIndustryHealth,suggestIndustryUpdate,applyIndustryUpdate,runIndustryHealthPipeline}from'./industry-evolution.js';import{FLYWHEEL_LOOP_VERSION,FLYWHEEL_LOOP_MIN_SIGNALS,recordIndustrySignal,updateIndustryCognition,injectEvolutionContext}from'./flywheel-loop.js';import{BUILTIN_INTENT_SPECS,registerIntentProfile,getIntentProfile,listIntents,evaluateIndustryHealthByIntent,suggestIndustryUpdateByIntent,evaluateIndustryHealthMultiIntent,getRoleAdvice,filterSuggestionsByRole}from'./intent-metrics.js';import{GUARD_SCENES,findScene,inferSceneFromAction,getImmutableScenes,getNumericIdentifierScenes}from'./guard-ledger.js';import{SEMANTIC_TO_SCHEMA_RULES,SCHEMA_TO_SEMANTIC_RULES,GUARD_CONSTRAINT_RULES,matchSemanticPattern,explainNode,explainWitness,getConstraintsByCategory}from'./guard-translation.js';import{checkPuzzleCompleteness,generateConfirmationText,initPuzzleFromIntent,inferBindingFromAction,emptyDataSources,getWitnessInfo,WITNESS_NAME_MAP}from'./guard-puzzle.js';import{runGuardRulePack,assembleGuardAssessment,getRiskRulesCount}from'./guard-risk.js';import{evaluateGuardDraft}from'./guard-eval.js';import{GUARD_BINDING_REGISTRY,GUARD_BINDINGS_VERSION,OWNER_RECEIVE_COGNITION,getGuardBindingsByObject,getGuardBinding,summarizeGuardBinding}from'./guard-bindings.js';import{SCENARIO_BRIDGE_REGISTRY,SCENARIO_CHAINS,SCENARIO_TOPOLOGY_VERSION,getBridgeById,getBridgeByCode,getBridgesByObject,getBridgesForEdge,detectBridgesForEdges,getChainById,summarizeBridge,detectBridgesForObjects}from'./scenario-topology.js';import{GUARD_TEMPLATES,GUARD_TEMPLATES_VERSION,GUARD_TEMPLATES_COUNT,getTemplatesByScene,getTemplateById,getTemplatesByIndustry,getTemplatesByPattern,listGuardTemplates,suggestTemplateForScene,getTemplateParameters,validateTemplateParams}from'./guard-templates.js';import{lintGuard,autoFixGuard,isGuardReady,getGuardErrors,formatLintResult}from'./guard-lint.js';import{MACHINE_SCENES,MACHINE_LEDGER_VERSION,MACHINE_SCENES_COUNT,findScene as a195a,getScenesByIndustry as a195b,getScenesByPattern,inferSceneFromFlow}from'./machine-ledger.js';import{MACHINE_TEMPLATES,MACHINE_TEMPLATES_VERSION,MACHINE_TEMPLATES_COUNT,getAllTemplates as a195c,getTemplateById as a195d,getTemplatesByScene as a195e,getTemplatesByIndustry as a195f,suggestTemplateForIntent,walkDecisionTree,fillTemplate as a195g,forkTemplate as a195h,verifyTemplateSceneReferences,getReferencedGuardTemplateIds,getReferencedRiskIds}from'./machine-templates.js';import{SEMANTIC_TO_MACHINE_RULES,MACHINE_CONSTRAINT_RULES,MACHINE_TRANSLATION_VERSION,MACHINE_PATTERNS_COUNT,MACHINE_CONSTRAINTS_COUNT,matchSemanticPattern as a195i,identifyExecutionMode,identifyTopology,explainForwardPermission,getConstraintsByCategory as a195j,getConstraintById,getOnChainConstraints as a195k,getOffChainConstraints as a195l}from'./machine-translation.js';import{MACHINE_RISK_RULES,MACHINE_RISK_VERSION,assessMachineRisks}from'./machine-risk.js';import{analyzeTopology,identifyTopologyPattern,formatTopologySummary,MACHINE_TOPOLOGY_VERSION,MAX_NODE_COUNT,MAX_NODE_PAIR_COUNT,MAX_FORWARD_COUNT}from'./machine-topology.js';import{initPuzzleFromIntent as a195m,initPuzzleFromTemplate,checkPuzzleCompleteness as a195n,recommendNextStep as a195o,derivePuzzleFromMachineJson,generateConfirmationText as a195p,MACHINE_PUZZLE_VERSION}from'./machine-puzzle.js';import{SERVICE_SCENES,SERVICE_LEDGER_VERSION,SERVICE_PERMISSIONS,SERVICE_ORDER_FLOW_STAGES,SERVICE_CROSS_OBJECT_BINDINGS,getScenesByCategory as a195q,findSceneById as a195r,getServicePermissionByIndex,isServicePermission,getPermissionsByMutability,getImmutablePostPublishPermissions,getLockedByDurationPermissions,inferSceneFromIntent as a195s,getAllServiceScenes,getServiceScenesCount,getServicePermissionsCount,getOrderFlowStage,getCrossObjectBindings as a195t}from'./service-ledger.js';import{initPuzzleFromIntent as a195u,checkPuzzleCompleteness as a195v,validateConstraints as a195w,generateConfirmationText as a195x,initOrderFlowPuzzle,checkOrderFlowCompleteness}from'./service-puzzle.js';import{SERVICE_RISK_VERSION,assessServiceRisks,getAllServiceRiskRules}from'./service-risk.js';import{SERVICE_TEMPLATES,SERVICE_TEMPLATES_VERSION,getServiceTemplateById,getServiceTemplatesByScene,getServiceTemplatesByIndustry,suggestServiceTemplateForScene,listServiceTemplates,fillServiceTemplate,getAllServiceTemplates}from'./service-templates.js';import{ALLOCATION_SCENES,ALLOCATION_LEDGER_VERSION,MAX_ALLOCATOR_COUNT,ALLOCATION_MAX_SHARING_COUNT,ALLOCATION_MODE_AMOUNT,ALLOCATION_MODE_RATE,ALLOCATION_MODE_SURPLUS,RATE_TOTAL_FULL,ALLOCATION_ERROR_CODES,getScenesByTriggerSource as a195y,getScenesByMode as a195z,getScenesByStrategy as a195A,findSceneById as a195B,inferSceneFromIntent as a195C,getAllScenes as a195D,getScenesCount as a195E,allocationModeToNumber,allocationModeFromNumber,getRecipientType,isSignerRecipient,isEntityRecipient,isGuardIdentifierRecipient,getErrorName as a195F,getErrorDescription as a195G}from'./allocation-ledger.js';import{initPuzzleFromIntent as a195H,checkPuzzleCompleteness as a195I,validateConstraints as a195J,generateConfirmationText as a195K,buildDefaultAllocFlow,buildDefaultRecipientRules,buildDefaultLogicPuzzle,ALLOCATION_PUZZLE_VERSION}from'./allocation-puzzle.js';import{ALLOCATION_RISK_VERSION,assessAllocationRisks,getAllRiskRules as a195L}from'./allocation-risk.js';import{ALLOCATION_TEMPLATES,ALLOCATION_TEMPLATES_VERSION,getAllTemplates as a195M,getTemplateById as a195N,getTemplatesByScene as a195O,getTemplatesByIndustry as a195P,suggestTemplateForScene as a195Q,listTemplates as a195R,fillTemplate as a195S}from'./allocation-templates.js';import{RECIPIENT_CONSTRAINT_VERSION,classifyRecipient,analyzeRecipientConstraints,isUnboundSignerTheft,canonicalDoctrine,recipientDesignGuidance,derivePayoffFromSharing,OBJECT_DRIVEABILITY,driveabilityOf,RECIPIENT_DESIGN_OPTIONS}from'./recipient-constraint.js';import{paymentRelations,scanRecentPaymentEvents,resolveBeneficialOwners,extractionPlanForHolder,pendingWrappersAt,trackAccountPayments}from'./payment-tracker.js';import{TREASURY_LEDGER_VERSION,TREASURY_SCENES,TREASURY_PERMISSIONS as a195T,getScenesByHostObject as a195U,findSceneById as a195V,findSceneByPermissionIndex as a195W,getBuiltinPermissionByIndex as a195X,isBuiltinTreasuryPermission,getActiveBuiltinPermissions as a195Y,getReservedBuiltinPermissions as a195Z,inferSceneFromIntent as a195a0,getTreasuryScenesCount,getGovernedOperationsForPermissionIndex as a195a1}from'./treasury-ledger.js';import{initPuzzleFromIntent as a195a2,checkPuzzleCompleteness as a195a3,validateConstraints as a195a4,generateConfirmationText as a195a5,MAX_EXTERNAL_DEPOSIT_GUARD_COUNT,MAX_EXTERNAL_WITHDRAW_GUARD_COUNT,MAX_DESCRIPTION_LENGTH as a195a6}from'./treasury-puzzle.js';import{TREASURY_TEMPLATES,TREASURY_TEMPLATES_VERSION,getAllTreasuryTemplates,getTemplateById as a195a7,getTemplatesByScene as a195a8,getTemplatesByIndustry as a195a9,suggestTemplateForScene as a195aa,listTemplates as a195ab,fillTemplate as a195ac}from'./treasury-templates.js';import{TREASURY_RISK_VERSION,assessTreasuryRisks,getAllTreasuryRiskRules}from'./treasury-risk.js';import{ORDER_LEDGER_VERSION,ORDER_SCENES,ORDER_FIELDS,ORDER_STATES,ORDER_STATE_TRANSITIONS,ORDER_LIFECYCLE_EVENTS,ORDER_PERMISSION_MATRIX,ORDER_AUDIT_FORMULAS,getScenesByOperationField as a195ad,findSceneById as a195ae,findSceneByMoveEntry as a195af,getScenesByPermissionLayer as a195ag,getScenesByReversibility as a195ah,getFieldDef as a195ai,getMutableFields as a195aj,getImmutableFields as a195ak,getFrozenAfterProgressFields as a195al,getOneTimeSetFields as a195am,inferSceneFromIntent as a195an,getEmittedEvents as a195ao,getInferredEvents as a195ap,getOrderScenesCount,sdkToMoveField as a195aq,moveToSdkField as a195ar}from'./order-ledger.js';import{initPuzzleFromIntent as a195as,checkPuzzleCompleteness as a195at,validateConstraints as a195au,generateConfirmationText as a195av,verifySnapshotMechanism as a195aw,inferLifecyclePhase as a195ax,matchSceneFromPuzzle as a195ay,listAllScenes as a195az,lookupScene as a195aA}from'./order-puzzle.js';import{ORDER_TEMPLATES,ORDER_TEMPLATES_VERSION,ORDER_TEMPLATES_COUNT,getAllOrderTemplates,getTemplateById as a195aB,getTemplatesByScene as a195aC,getTemplatesByIndustry as a195aD,getTemplatesByPermissionLayer as a195aE,getIrreversibleTemplates as a195aF,suggestTemplateForScene as a195aG,listOrderTemplates,fillTemplate as a195aH,suggestTemplateFromIntent as a195aI,getTemplateParameters as a195aJ,validateTemplateParams as a195aK}from'./order-templates.js';import{ORDER_RISK_VERSION,assessOrderRisks,getAllOrderRiskRules}from'./order-risk.js';import{PROGRESS_LEDGER_VERSION,PROGRESS_SCENES,PROGRESS_PERMISSIONS as a195aL,PROGRESS_NEW,PROGRESS_NAMED_OPERATOR,PROGRESS_TASK,PROGRESS_CONTEXT_REPOSITORY,PROGRESS_UNHOLD,PROGRESS_OWNER_RECEIVE,PROGRESS_CROSS_OBJECT_REFS,getScenesByPhase as a195aM,findSceneById as a195aN,getScenesByIndustry as a195aO,getBuiltinPermissionByIndex as a195aP,isProgressBuiltinPermission,inferSceneFromIntent as a195aQ,getAllBuiltinPermissions as a195aR,getProgressScenesCount,validateNamedOperatorAddressList,validateNamedOperatorCount,validateContextRepositoryCount}from'./progress-ledger.js';import{initPuzzleFromIntent as a195aS,checkPuzzleCompleteness as a195aT,validateConstraints as a195aU,generateConfirmationText as a195aV,resolveBuiltinPermission as a195aW,isOrderHolderForward,getRelevantDimensions as a195aX}from'./progress-puzzle.js';import{PROGRESS_TEMPLATES,PROGRESS_TEMPLATES_VERSION,getAllProgressTemplates,getProgressTemplateById,getProgressTemplatesByScene,getProgressTemplatesByIndustry,suggestProgressTemplateForScene,listProgressTemplates,fillProgressTemplate}from'./progress-templates.js';import{PROGRESS_RISK_VERSION,assessProgressRisks,getAllProgressRiskRules}from'./progress-risk.js';import{ARBITRATION_LEDGER_VERSION,ARBITRATION_SCENES,ARBITRATION_PERMISSIONS as a195aY,ARB_STATUS_CODE,ARB_TERMINAL_STATUSES,ARB_STATUS_ALIASES,DUAL_GUARD_MATRIX,getScenesByCategory as a195aZ,findSceneById as a195b0,findSceneByPermissionIndex as a195b1,getPermissionByIndex as a195b2,getPermissionByName as a195b3,isReservedIndex as a195b4,isUsedPermissionIndex as a195b5,getActivePermissionCount as a195b6,inferSceneFromIntent as a195b7,getDualGuardMatrixEntry,isValidArbStatusTransition,isTerminalArbStatus,getScenesProducingStatus as a195b8,getScenesRequiringStatus as a195b9,getArbitrationScenesCount,getAllArbitrationPermissions,getActiveArbitrationPermissions}from'./arbitration-ledger.js';import{initPuzzleFromIntent as a195ba,checkPuzzleCompleteness as a195bb,validateConstraints as a195bc,generateConfirmationText as a195bd}from'./arbitration-puzzle.js';import{ARBITRATION_TEMPLATES,ARBITRATION_TEMPLATES_VERSION,getAllTemplates as a195be,getTemplateById as a195bf,getTemplatesByScene as a195bg,getTemplatesByIndustry as a195bh,suggestTemplateForScene as a195bi,listTemplates as a195bj,fillTemplate as a195bk}from'./arbitration-templates.js';import{ARBITRATION_RISK_VERSION,assessArbitrationRisks,getAllRiskRules as a195bl}from'./arbitration-risk.js';import{REWARD_LEDGER_VERSION,REWARD_SCENES,REWARD_PERMISSIONS,REWARD_FIELDS,REWARD_GUARD_CONSTRUCTORS,REWARD_ERROR_CODES,REWARD_CROSS_OBJECT_REFS,MAX_GUARD_COUNT_REWARD,MAX_RECORD_COUNT_REWARD,getScenesByPhase as a195bm,findSceneById as a195bn,getScenesByIndustry as a195bo,getBuiltinPermissionByIndex as a195bp,isRewardBuiltinPermission,getAllBuiltinPermissions as a195bq,getRewardScenesCount,getGuardConstructorSpec as a195br,resolveGuardConstructor as a195bs,getRewardErrorByCode,getRewardErrorByName,validateGuardCount as a195bt,validateRecordCount as a195bu,inferSceneFromIntent as a195bv}from'./reward-ledger.js';import{REWARD_FIELD_MUTABILITY,initPuzzleFromIntent as a195bw,checkPuzzleCompleteness as a195bx,validateConstraints as a195by,generateConfirmationText as a195bz,resolveBuiltinPermission as a195bA,requiresGuardConfig as a195bB,requiresPassport as a195bC,getRelevantDimensions as a195bD,getFieldMutability as a195bE,isAdminMutableField as a195bF,getFieldPermissionIndex as a195bG}from'./reward-puzzle.js';import{REWARD_RISK_VERSION,assessRewardRisks,getAllRewardRiskRules}from'./reward-risk.js';import{PASSPORT_LEDGER_VERSION,PASSPORT_ERROR_CODES,PASSPORT_SCENARIOS,MAX_GUARD_COUNT_PASSPORT,MAX_SUBMISSION_SIZE_PASSPORT,getAllScenarios as a195bH,getScenariosCount as a195bI,findScenarioById as a195bJ,getScenariosByConsumer as a195bK,getScenariosUsingRelies as a195bL,inferScenarioFromIntent as a195bM,impackRoleFromBoolean,impackRoleToBoolean,reliesLogicFromBoolean,reliesLogicToBoolean,getErrorName as a195bN,getErrorDescription as a195bO}from'./passport-ledger.js';import{PASSPORT_TEMPLATES,PASSPORT_TEMPLATES_VERSION,getAllTemplates as a195bP,getTemplateById as a195bQ,getTemplatesByScenario as a195bR,getTemplatesByIndustry as a195bS,suggestTemplateForScenario as a195bT,listTemplates as a195bU,fillTemplate as a195bV}from'./passport-templates.js';import{PROOF_RISK_RULES,checkProofRisks}from'./proof-risk.js';import{REPOSITORY_RISK_RULES,checkRepositoryRisks,parseIdFromForRiskCheck}from'./repository-risk.js';import{DEMAND_RISK_RULES,checkDemandRisks}from'./demand-risk.js';import{CONTACT_RISK_RULES,CONTACT_RISK_VERSION,checkContactRisks}from'./contact-risk.js';import{RESOURCE_RISK_RULES,RESOURCE_RISK_VERSION,checkResourceRisks}from'./resource-risk.js';import{PAYMENT_RISK_RULES,PAYMENT_RISK_VERSION,checkPaymentRisks}from'./payment-risk.js';import{ARB_RISK_RULES,ARB_RISK_VERSION,checkArbRisks}from'./arb-risk.js';import{PERSONAL_RISK_RULES,PERSONAL_RISK_VERSION,checkPersonalRisks}from'./personal-risk.js';import{UTIL_RISK_RULES,UTIL_RISK_VERSION,checkUtilRisks}from'./util-risk.js';import{REGISTRAR_RISK_RULES,REGISTRAR_RISK_VERSION,checkRegistrarRisks}from'./registrar-risk.js';import{BRIDGE_RISK_RULES,BRIDGE_RISK_VERSION,checkBridgeRisks}from'./bridge-risk.js';import{TOOLS_REFERENCE,getToolReference,searchToolReference,getToolSequence}from'./tools-reference.js';import{SCENARIO_MODES,SCENARIO_MODES_VERSION,MODE_COMPOSITIONS,matchScenarioMode,inferScenarioTraits,getScenarioMode,listScenarioModes,getShippedModes,getModeCompositions}from'./scenario-modes.js';import{BUILTIN_TEMPLATES,BUILTIN_TEMPLATES_VERSION,getBuiltinTemplate,listBuiltinTemplates,TEMPLATE_KEYWORDS}from'./builtin-templates.js';import{resolveTemplatesDir,seedBuiltinTemplates,reloadTemplates,listTemplates,getTemplate,getTemplatesByIndustry as a195bW,parseTemplateFile,renderTemplateFile,loadAndValidate,TemplateFrontmatterSchema}from'./template-loader.js';import{scanTemplate}from'./template-scanner.js';import{GUARD_DESIGN_PATTERNS,GUARD_DESIGN_PATTERNS_VERSION,VERIFIER_LEVEL_GUIDANCE,getGuardDesignPattern,searchGuardDesignPatterns,getPatternsByHost,getPatternsByIndustry,getPatternsByDataSourceClass,getVerifierLevelGuidance,suggestPatternForRequirement}from'./guard-design-patterns.js';export{CONFIRMATION_RULES,SAFETY_RULES_VERSION,OBJECT_REUSE_RULES,CREATE_VS_MODIFY_PATTERN,IMMUTABILITY_RULES,OPERATION_TYPE_CLASSIFICATION,OPERATION_CLASS_META,classifyTool,NAMING_CONVENTIONS,checkObjectReuseRules,checkImmutabilityRules};export{TOOL_CONSTRAINTS,TOOL_CONSTRAINTS_VERSION,validateOperation,hasBlockingViolations,getWarningViolations};export{REWARD_TEMPLATES,REWARD_TEMPLATES_VERSION,getRewardTemplate,listRewardTemplates,suggestRewardTemplate};export{AUDIT_RULES,AUDIT_RULES_VERSION,auditService,hasBlockingErrors,getErrors,getWarnings,summarizeFindings};export{suggestPricing,MUTABLE_FIELDS,DYNAMIC_PRICING_VERSION};export{buildReviewRepositorySetup,computeReviewStats,isVerifiedReview,filterVerifiedReviews,detectReviewManipulation,REPUTATION_RULES_VERSION};export{INDUSTRY_FLYWHEELS,getFlywheelForIndustry,listIndustries,suggestAcquisitionActions,generateTrustDescription,buildAcquisitionDashboard,ACQUISITION_FLYWHEEL_VERSION};export{STRATEGY_MANUAL_FILENAME,STRATEGY_MANUAL_VERSION,renderStrategyManual,parseManualSentinel,classifyManualFile,getBuiltinStrategyManual,listBuiltinStrategyManualIndustries}from'./strategy-manuals.js';export{INDUSTRY_STRATEGIES,getIndustryStrategy,listIndustryStrategies,registerIndustryStrategy,unregisterIndustryStrategy,recommendStrategy,stageFromOrderCount,validateStrategyLevers}from'./industry-strategy.js';export{INDUSTRY_REGISTRY_VERSION,getIndustryProfile,listIndustries as listRegistryIndustries,registerIndustry,getIndustryTraits,resolveIndustryName,isRegisteredIndustry,getRegistrySize,listBuiltinIndustryNames};export{DEFAULT_TRAITS,inferTraitsFromDescription,synthesizeProfile,findSimilarIndustries,composeIndustries,INDUSTRY_REQUIRED_TRAITS,DOMAIN_PRIORS,detectDomainPriors,traitContradictions,filterConsistentIndustries};export{INDUSTRY_EVOLUTION_THRESHOLDS,aggregateIndustryMetrics,evaluateIndustryHealth,suggestIndustryUpdate,applyIndustryUpdate,runIndustryHealthPipeline};export{FLYWHEEL_LOOP_VERSION,FLYWHEEL_LOOP_MIN_SIGNALS,recordIndustrySignal,updateIndustryCognition,injectEvolutionContext};export{BUILTIN_INTENT_SPECS,registerIntentProfile,getIntentProfile,listIntents,evaluateIndustryHealthByIntent,suggestIndustryUpdateByIntent,evaluateIndustryHealthMultiIntent,getRoleAdvice,filterSuggestionsByRole};export{GUARD_SCENES,findScene,inferSceneFromAction,getImmutableScenes,getNumericIdentifierScenes};export{SEMANTIC_TO_SCHEMA_RULES,SCHEMA_TO_SEMANTIC_RULES,GUARD_CONSTRAINT_RULES,matchSemanticPattern,explainNode,explainWitness,getConstraintsByCategory};export{checkPuzzleCompleteness,generateConfirmationText,initPuzzleFromIntent,inferBindingFromAction,emptyDataSources,getWitnessInfo,WITNESS_NAME_MAP};export{runGuardRulePack,assembleGuardAssessment,evaluateGuardDraft,getRiskRulesCount,GUARD_TEMPLATES,GUARD_TEMPLATES_VERSION,GUARD_TEMPLATES_COUNT,getTemplatesByScene,getTemplateById,getTemplatesByIndustry,getTemplatesByPattern,listGuardTemplates,suggestTemplateForScene,getTemplateParameters,validateTemplateParams,GUARD_BINDING_REGISTRY,GUARD_BINDINGS_VERSION,OWNER_RECEIVE_COGNITION,getGuardBindingsByObject,getGuardBinding,summarizeGuardBinding,SCENARIO_BRIDGE_REGISTRY,SCENARIO_CHAINS,SCENARIO_TOPOLOGY_VERSION,getBridgeById,getBridgeByCode,getBridgesByObject,getBridgesForEdge,detectBridgesForEdges,getChainById,summarizeBridge,detectBridgesForObjects,lintGuard,autoFixGuard,isGuardReady,getGuardErrors,formatLintResult};export{MACHINE_SCENES,MACHINE_LEDGER_VERSION,MACHINE_SCENES_COUNT,a195a as findMachineScene,a195b as getMachineScenesByIndustry,getScenesByPattern,inferSceneFromFlow};export{MACHINE_TEMPLATES,MACHINE_TEMPLATES_VERSION,MACHINE_TEMPLATES_COUNT,a195c as getAllMachineTemplates,a195d as getMachineTemplateById,a195e as getMachineTemplatesByScene,a195f as getMachineTemplatesByIndustry,suggestTemplateForIntent,walkDecisionTree,a195g as fillMachineTemplate,a195h as forkMachineTemplate,verifyTemplateSceneReferences,getReferencedGuardTemplateIds,getReferencedRiskIds};export{SEMANTIC_TO_MACHINE_RULES,MACHINE_CONSTRAINT_RULES,MACHINE_TRANSLATION_VERSION,MACHINE_PATTERNS_COUNT,MACHINE_CONSTRAINTS_COUNT,a195i as matchMachinePattern,identifyExecutionMode,identifyTopology,explainForwardPermission,a195j as getMachineConstraintsByCategory,getConstraintById,a195k as getOnChainMachineConstraints,a195l as getOffChainMachineConstraints};export{MACHINE_RISK_RULES,MACHINE_RISK_VERSION,assessMachineRisks};export{analyzeTopology,identifyTopologyPattern,formatTopologySummary,MACHINE_TOPOLOGY_VERSION,MAX_NODE_COUNT,MAX_NODE_PAIR_COUNT,MAX_FORWARD_COUNT};export{a195m as initMachinePuzzleFromIntent,initPuzzleFromTemplate,a195n as checkMachinePuzzleCompleteness,a195o as recommendMachineNextStep,derivePuzzleFromMachineJson,a195p as generateMachineConfirmationText,MACHINE_PUZZLE_VERSION};export{SERVICE_SCENES,SERVICE_LEDGER_VERSION,SERVICE_PERMISSIONS,SERVICE_ORDER_FLOW_STAGES,SERVICE_CROSS_OBJECT_BINDINGS,a195q as getServiceScenesByCategory,a195r as findServiceSceneById,getServicePermissionByIndex,isServicePermission,getPermissionsByMutability,getImmutablePostPublishPermissions,getLockedByDurationPermissions,a195s as inferServiceSceneFromIntent,getAllServiceScenes,getServiceScenesCount,getServicePermissionsCount,getOrderFlowStage,a195t as getServiceCrossObjectBindings};export{a195u as initServicePuzzleFromIntent,a195v as checkServicePuzzleCompleteness,a195w as validateServiceConstraints,a195x as generateServicePuzzleConfirmationText,initOrderFlowPuzzle,checkOrderFlowCompleteness};export{SERVICE_RISK_VERSION,assessServiceRisks,getAllServiceRiskRules};export{SERVICE_TEMPLATES,SERVICE_TEMPLATES_VERSION,getServiceTemplateById,getServiceTemplatesByScene,getServiceTemplatesByIndustry,suggestServiceTemplateForScene,listServiceTemplates,fillServiceTemplate,getAllServiceTemplates};export{ALLOCATION_SCENES,ALLOCATION_LEDGER_VERSION,MAX_ALLOCATOR_COUNT,ALLOCATION_MAX_SHARING_COUNT,ALLOCATION_MODE_AMOUNT,ALLOCATION_MODE_RATE,ALLOCATION_MODE_SURPLUS,RATE_TOTAL_FULL,ALLOCATION_ERROR_CODES,a195y as getAllocationScenesByTriggerSource,a195z as getAllocationScenesByMode,a195A as getAllocationScenesByStrategy,a195B as findAllocationSceneById,a195C as inferAllocationSceneFromIntent,a195D as getAllAllocationScenes,a195E as getAllocationScenesCount,allocationModeToNumber,allocationModeFromNumber,getRecipientType,isSignerRecipient,isEntityRecipient,isGuardIdentifierRecipient,a195F as getAllocationErrorName,a195G as getAllocationErrorDescription};export{a195H as initAllocationPuzzleFromIntent,a195I as checkAllocationPuzzleCompleteness,a195J as validateAllocationConstraints,a195K as generateAllocationPuzzleConfirmationText,buildDefaultAllocFlow,buildDefaultRecipientRules,buildDefaultLogicPuzzle,ALLOCATION_PUZZLE_VERSION};export{ALLOCATION_RISK_VERSION,assessAllocationRisks,a195L as getAllAllocationRiskRules};export{ALLOCATION_TEMPLATES,ALLOCATION_TEMPLATES_VERSION,a195M as getAllAllocationTemplates,a195N as getAllocationTemplateById,a195O as getAllocationTemplatesByScene,a195P as getAllocationTemplatesByIndustry,a195Q as suggestAllocationTemplateForScene,a195R as listAllocationTemplates,a195S as fillAllocationTemplate};export{RECIPIENT_CONSTRAINT_VERSION,classifyRecipient,analyzeRecipientConstraints,isUnboundSignerTheft,canonicalDoctrine,recipientDesignGuidance,derivePayoffFromSharing,OBJECT_DRIVEABILITY,driveabilityOf,RECIPIENT_DESIGN_OPTIONS};export{paymentRelations,scanRecentPaymentEvents,resolveBeneficialOwners,extractionPlanForHolder,pendingWrappersAt,trackAccountPayments};export{TREASURY_LEDGER_VERSION,TREASURY_SCENES,a195T as TREASURY_BUILTIN_PERMISSIONS,a195U as getTreasuryScenesByHostObject,a195V as findTreasurySceneById,a195W as findTreasurySceneByPermissionIndex,a195X as getTreasuryBuiltinPermissionByIndex,isBuiltinTreasuryPermission,a195Y as getActiveTreasuryBuiltinPermissions,a195Z as getReservedTreasuryBuiltinPermissions,a195a0 as inferTreasurySceneFromIntent,getTreasuryScenesCount,a195a1 as getTreasuryGovernedOperationsForPermissionIndex};export{a195a2 as initTreasuryPuzzleFromIntent,a195a3 as checkTreasuryPuzzleCompleteness,a195a4 as validateTreasuryConstraints,a195a5 as generateTreasuryPuzzleConfirmationText,MAX_EXTERNAL_DEPOSIT_GUARD_COUNT,MAX_EXTERNAL_WITHDRAW_GUARD_COUNT,a195a6 as TREASURY_MAX_DESCRIPTION_LENGTH};export{TREASURY_TEMPLATES,TREASURY_TEMPLATES_VERSION,getAllTreasuryTemplates,a195a7 as getTreasuryTemplateById,a195a8 as getTreasuryTemplatesByScene,a195a9 as getTreasuryTemplatesByIndustry,a195aa as suggestTreasuryTemplateForScene,a195ab as listTreasuryTemplates,a195ac as fillTreasuryTemplate};export{TREASURY_RISK_VERSION,assessTreasuryRisks,getAllTreasuryRiskRules};export{ORDER_LEDGER_VERSION,ORDER_SCENES,ORDER_FIELDS,ORDER_STATES,ORDER_STATE_TRANSITIONS,ORDER_LIFECYCLE_EVENTS,ORDER_PERMISSION_MATRIX,ORDER_AUDIT_FORMULAS,a195ad as getOrderScenesByOperationField,a195ae as findOrderSceneById,a195af as findOrderSceneByMoveEntry,a195ag as getOrderScenesByPermissionLayer,a195ah as getOrderScenesByReversibility,a195ai as getOrderFieldDef,a195aj as getOrderMutableFields,a195ak as getOrderImmutableFields,a195al as getOrderFrozenAfterProgressFields,a195am as getOrderOneTimeSetFields,a195an as inferOrderSceneFromIntent,a195ao as getOrderEmittedEvents,a195ap as getOrderInferredEvents,getOrderScenesCount,a195aq as sdkToMoveOrderField,a195ar as moveToSdkOrderField};export{a195as as initOrderPuzzleFromIntent,a195at as checkOrderPuzzleCompleteness,a195au as validateOrderConstraints,a195av as generateOrderPuzzleConfirmationText,a195aw as verifyOrderSnapshotMechanism,a195ax as inferOrderLifecyclePhase,a195ay as matchOrderSceneFromPuzzle,a195az as listAllOrderScenes,a195aA as lookupOrderScene};export{ORDER_TEMPLATES,ORDER_TEMPLATES_VERSION,ORDER_TEMPLATES_COUNT,getAllOrderTemplates,a195aB as getOrderTemplateById,a195aC as getOrderTemplatesByScene,a195aD as getOrderTemplatesByIndustry,a195aE as getOrderTemplatesByPermissionLayer,a195aF as getIrreversibleOrderTemplates,a195aG as suggestOrderTemplateForScene,listOrderTemplates,a195aH as fillOrderTemplate,a195aI as suggestOrderTemplateFromIntent,a195aJ as getOrderTemplateParameters,a195aK as validateOrderTemplateParams};export{ORDER_RISK_VERSION,assessOrderRisks,getAllOrderRiskRules};export{PROGRESS_LEDGER_VERSION,PROGRESS_SCENES,a195aL as PROGRESS_BUILTIN_PERMISSIONS,PROGRESS_NEW,PROGRESS_NAMED_OPERATOR,PROGRESS_TASK,PROGRESS_CONTEXT_REPOSITORY,PROGRESS_UNHOLD,PROGRESS_OWNER_RECEIVE,PROGRESS_CROSS_OBJECT_REFS,a195aM as getProgressScenesByPhase,a195aN as findProgressSceneById,a195aO as getProgressScenesByIndustry,a195aP as getProgressBuiltinPermissionByIndex,isProgressBuiltinPermission,a195aQ as inferProgressSceneFromIntent,a195aR as getAllProgressBuiltinPermissions,getProgressScenesCount,validateNamedOperatorAddressList,validateNamedOperatorCount,validateContextRepositoryCount};export{a195aS as initProgressPuzzleFromIntent,a195aT as checkProgressPuzzleCompleteness,a195aU as validateProgressConstraints,a195aV as generateProgressPuzzleConfirmationText,a195aW as resolveProgressBuiltinPermission,isOrderHolderForward,a195aX as getProgressRelevantDimensions};export{PROGRESS_TEMPLATES,PROGRESS_TEMPLATES_VERSION,getAllProgressTemplates,getProgressTemplateById,getProgressTemplatesByScene,getProgressTemplatesByIndustry,suggestProgressTemplateForScene,listProgressTemplates,fillProgressTemplate};export{PROGRESS_RISK_VERSION,assessProgressRisks,getAllProgressRiskRules};export{ARBITRATION_LEDGER_VERSION,ARBITRATION_SCENES,a195aY as ARBITRATION_BUILTIN_PERMISSIONS,ARB_STATUS_CODE,ARB_TERMINAL_STATUSES,ARB_STATUS_ALIASES,DUAL_GUARD_MATRIX,a195aZ as getArbitrationScenesByCategory,a195b0 as findArbitrationSceneById,a195b1 as findArbitrationSceneByPermissionIndex,a195b2 as getArbitrationPermissionByIndex,a195b3 as getArbitrationPermissionByName,a195b4 as isArbitrationReservedIndex,a195b5 as isArbitrationUsedPermissionIndex,a195b6 as getArbitrationActivePermissionCount,a195b7 as inferArbitrationSceneFromIntent,getDualGuardMatrixEntry,isValidArbStatusTransition,isTerminalArbStatus,a195b8 as getArbitrationScenesProducingStatus,a195b9 as getArbitrationScenesRequiringStatus,getArbitrationScenesCount,getAllArbitrationPermissions,getActiveArbitrationPermissions};export{a195ba as initArbitrationPuzzleFromIntent,a195bb as checkArbitrationPuzzleCompleteness,a195bc as validateArbitrationConstraints,a195bd as generateArbitrationPuzzleConfirmationText};export{ARBITRATION_TEMPLATES,ARBITRATION_TEMPLATES_VERSION,a195be as getAllArbitrationTemplates,a195bf as getArbitrationTemplateById,a195bg as getArbitrationTemplatesByScene,a195bh as getArbitrationTemplatesByIndustry,a195bi as suggestArbitrationTemplateForScene,a195bj as listArbitrationTemplates,a195bk as fillArbitrationTemplate};export{ARBITRATION_RISK_VERSION,assessArbitrationRisks,a195bl as getAllArbitrationRiskRules};export{REWARD_LEDGER_VERSION,REWARD_SCENES,REWARD_PERMISSIONS,REWARD_FIELDS,REWARD_GUARD_CONSTRUCTORS,REWARD_ERROR_CODES,REWARD_CROSS_OBJECT_REFS,MAX_GUARD_COUNT_REWARD,MAX_RECORD_COUNT_REWARD,a195bm as getRewardScenesByPhase,a195bn as findRewardSceneById,a195bo as getRewardScenesByIndustry,a195bp as getRewardBuiltinPermissionByIndex,isRewardBuiltinPermission,a195bq as getAllRewardBuiltinPermissions,getRewardScenesCount,a195br as getRewardGuardConstructorSpec,a195bs as resolveRewardGuardConstructor,getRewardErrorByCode,getRewardErrorByName,a195bt as validateRewardGuardCount,a195bu as validateRewardRecordCount,a195bv as inferRewardSceneFromIntent};export{REWARD_FIELD_MUTABILITY,a195bw as initRewardPuzzleFromIntent,a195bx as checkRewardPuzzleCompleteness,a195by as validateRewardConstraints,a195bz as generateRewardPuzzleConfirmationText,a195bA as resolveRewardBuiltinPermission,a195bB as requiresRewardGuardConfig,a195bC as requiresRewardPassport,a195bD as getRewardRelevantDimensions,a195bE as getRewardFieldMutability,a195bF as isRewardAdminMutableField,a195bG as getRewardFieldPermissionIndex};export{REWARD_RISK_VERSION,assessRewardRisks,getAllRewardRiskRules};export{PASSPORT_LEDGER_VERSION,PASSPORT_ERROR_CODES,PASSPORT_SCENARIOS,MAX_GUARD_COUNT_PASSPORT,MAX_SUBMISSION_SIZE_PASSPORT,a195bH as getAllPassportScenarios,a195bI as getPassportScenesCount,a195bJ as findPassportScenarioById,a195bK as getPassportScenariosByConsumer,a195bL as getPassportScenariosUsingRelies,a195bM as inferPassportScenarioFromIntent,impackRoleFromBoolean,impackRoleToBoolean,reliesLogicFromBoolean,reliesLogicToBoolean,a195bN as getPassportErrorName,a195bO as getPassportErrorDescription};export{PASSPORT_TEMPLATES,PASSPORT_TEMPLATES_VERSION,a195bP as getAllPassportTemplates,a195bQ as getPassportTemplateById,a195bR as getPassportTemplatesByScenario,a195bS as getPassportTemplatesByIndustry,a195bT as suggestPassportTemplateForScenario,a195bU as listPassportTemplates,a195bV as fillPassportTemplate};export{PROOF_RISK_RULES,checkProofRisks};export{REPOSITORY_RISK_RULES,checkRepositoryRisks,parseIdFromForRiskCheck};export{assessEvidenceReview,reviewEvidenceList}from'./evidence-review.js';export{DEMAND_RISK_RULES,checkDemandRisks};export{CONTACT_RISK_RULES,CONTACT_RISK_VERSION,checkContactRisks};export{RESOURCE_RISK_RULES,RESOURCE_RISK_VERSION,checkResourceRisks};export{PAYMENT_RISK_RULES,PAYMENT_RISK_VERSION,checkPaymentRisks};export{ARB_RISK_RULES,ARB_RISK_VERSION,checkArbRisks};export{PERSONAL_RISK_RULES,PERSONAL_RISK_VERSION,checkPersonalRisks};export{UTIL_RISK_RULES,UTIL_RISK_VERSION,checkUtilRisks};export{REGISTRAR_RISK_RULES,REGISTRAR_RISK_VERSION,checkRegistrarRisks};export{BRIDGE_RISK_RULES,BRIDGE_RISK_VERSION,checkBridgeRisks};export{TOOLS_REFERENCE,getToolReference,searchToolReference,getToolSequence};export{SCENARIO_MODES,SCENARIO_MODES_VERSION,MODE_COMPOSITIONS,matchScenarioMode,inferScenarioTraits,getScenarioMode,listScenarioModes,getShippedModes,getModeCompositions};export{BUILTIN_TEMPLATES,BUILTIN_TEMPLATES_VERSION,getBuiltinTemplate,listBuiltinTemplates,TEMPLATE_KEYWORDS};export{resolveTemplatesDir,seedBuiltinTemplates,reloadTemplates,listTemplates,getTemplate,a195bW as getIndustryTemplates,parseTemplateFile,renderTemplateFile,loadAndValidate,TemplateFrontmatterSchema};export{scanTemplate};export{GUARD_DESIGN_PATTERNS,GUARD_DESIGN_PATTERNS_VERSION,VERIFIER_LEVEL_GUIDANCE,getGuardDesignPattern,searchGuardDesignPatterns,getPatternsByHost,getPatternsByIndustry,getPatternsByDataSourceClass,getVerifierLevelGuidance,suggestPatternForRequirement};export function getKnowledgeBase(){return{'version':{'safety':SAFETY_RULES_VERSION,'tool_constraints':TOOL_CONSTRAINTS_VERSION,'reward_templates':REWARD_TEMPLATES_VERSION,'audit_rules':AUDIT_RULES_VERSION,'dynamic_pricing':DYNAMIC_PRICING_VERSION,'reputation_rules':REPUTATION_RULES_VERSION,'acquisition_flywheel':ACQUISITION_FLYWHEEL_VERSION,'industry_registry':INDUSTRY_REGISTRY_VERSION,'flywheel_loop':FLYWHEEL_LOOP_VERSION,'machine_ledger':MACHINE_LEDGER_VERSION,'machine_templates':MACHINE_TEMPLATES_VERSION,'machine_translation':MACHINE_TRANSLATION_VERSION,'machine_risk':MACHINE_RISK_VERSION,'machine_topology':MACHINE_TOPOLOGY_VERSION,'machine_puzzle':MACHINE_PUZZLE_VERSION,'service_ledger':SERVICE_LEDGER_VERSION,'service_risk':SERVICE_RISK_VERSION,'service_templates':SERVICE_TEMPLATES_VERSION,'allocation_ledger':ALLOCATION_LEDGER_VERSION,'allocation_puzzle':ALLOCATION_PUZZLE_VERSION,'allocation_risk':ALLOCATION_RISK_VERSION,'allocation_templates':ALLOCATION_TEMPLATES_VERSION,'treasury_ledger':TREASURY_LEDGER_VERSION,'treasury_templates':TREASURY_TEMPLATES_VERSION,'treasury_risk':TREASURY_RISK_VERSION,'order_ledger':ORDER_LEDGER_VERSION,'order_templates':ORDER_TEMPLATES_VERSION,'order_risk':ORDER_RISK_VERSION,'progress_ledger':PROGRESS_LEDGER_VERSION,'progress_templates':PROGRESS_TEMPLATES_VERSION,'progress_risk':PROGRESS_RISK_VERSION,'arbitration_ledger':ARBITRATION_LEDGER_VERSION,'arbitration_templates':ARBITRATION_TEMPLATES_VERSION,'arbitration_risk':ARBITRATION_RISK_VERSION,'reward_ledger':REWARD_LEDGER_VERSION,'reward_risk':REWARD_RISK_VERSION,'passport_ledger':PASSPORT_LEDGER_VERSION,'passport_templates':PASSPORT_TEMPLATES_VERSION,'contact_risk':CONTACT_RISK_VERSION,'resource_risk':RESOURCE_RISK_VERSION,'payment_risk':PAYMENT_RISK_VERSION,'arb_risk':ARB_RISK_VERSION,'personal_risk':PERSONAL_RISK_VERSION,'util_risk':UTIL_RISK_VERSION,'registrar_risk':REGISTRAR_RISK_VERSION,'bridge_risk':BRIDGE_RISK_VERSION,'scenario_modes':SCENARIO_MODES_VERSION,'guard_design_patterns':GUARD_DESIGN_PATTERNS_VERSION,'builtin_templates':BUILTIN_TEMPLATES_VERSION},'confirmation_rules':CONFIRMATION_RULES['length'],'confirmation_rule_ids':CONFIRMATION_RULES['map'](a=>a['id']),'tool_constraints_count':TOOL_CONSTRAINTS['length'],'reward_templates_count':REWARD_TEMPLATES['length'],'audit_rules_count':AUDIT_RULES['length'],'mutable_fields_count':MUTABLE_FIELDS['length'],'industry_flywheels_count':INDUSTRY_FLYWHEELS['length'],'industry_registry_count':getRegistrySize(),'intent_count':listIntents()['length'],'guard_scenes_count':GUARD_SCENES['length'],'guard_semantic_rules_count':SEMANTIC_TO_SCHEMA_RULES['length'],'guard_schema_rules_count':SCHEMA_TO_SEMANTIC_RULES['length'],'guard_constraint_rules_count':GUARD_CONSTRAINT_RULES['length'],'guard_risk_rules_count':getRiskRulesCount(),'guard_templates_count':GUARD_TEMPLATES_COUNT,'guard_lint_enabled':!![],'machine_scenes_count':MACHINE_SCENES_COUNT,'machine_templates_count':MACHINE_TEMPLATES['length'],'machine_patterns_count':SEMANTIC_TO_MACHINE_RULES['length'],'machine_constraint_rules_count':MACHINE_CONSTRAINT_RULES['length'],'machine_risk_rules_count':MACHINE_RISK_RULES['length'],'machine_on_chain_limits':{'max_node_count':MAX_NODE_COUNT,'max_node_pair_count':MAX_NODE_PAIR_COUNT,'max_forward_count':MAX_FORWARD_COUNT},'service_scenes_count':SERVICE_SCENES['length'],'service_permissions_count':SERVICE_PERMISSIONS['length'],'service_order_flow_stages_count':SERVICE_ORDER_FLOW_STAGES['length'],'service_cross_object_bindings_count':SERVICE_CROSS_OBJECT_BINDINGS['length'],'service_risk_rules_count':getAllServiceRiskRules()['length'],'service_templates_count':SERVICE_TEMPLATES['length'],'service_context_enabled':!![],'allocation_scenes_count':ALLOCATION_SCENES['length'],'allocation_risk_rules_count':a195L()['length'],'allocation_templates_count':ALLOCATION_TEMPLATES['length'],'allocation_context_enabled':!![],'treasury_scenes_count':TREASURY_SCENES['length'],'treasury_builtin_permissions_count':a195T['length'],'treasury_risk_rules_count':getAllTreasuryRiskRules()['length'],'treasury_templates_count':TREASURY_TEMPLATES['length'],'treasury_context_enabled':!![],'order_scenes_count':ORDER_SCENES['length'],'order_fields_count':ORDER_FIELDS['length'],'order_states_count':ORDER_STATES['length'],'order_lifecycle_events_count':ORDER_LIFECYCLE_EVENTS['length'],'order_risk_rules_count':getAllOrderRiskRules()['length'],'order_templates_count':ORDER_TEMPLATES['length'],'order_context_enabled':!![],'progress_scenes_count':PROGRESS_SCENES['length'],'progress_builtin_permissions_count':a195aL['length'],'progress_risk_rules_count':getAllProgressRiskRules()['length'],'progress_templates_count':PROGRESS_TEMPLATES['length'],'progress_context_enabled':!![],'arbitration_scenes_count':ARBITRATION_SCENES['length'],'arbitration_builtin_permissions_count':a195aY['length'],'arbitration_risk_rules_count':a195bl()['length'],'arbitration_templates_count':ARBITRATION_TEMPLATES['length'],'arbitration_context_enabled':!![],'reward_scenes_count':REWARD_SCENES['length'],'reward_builtin_permissions_count':REWARD_PERMISSIONS['length'],'reward_fields_count':REWARD_FIELDS['length'],'reward_guard_constructors_count':REWARD_GUARD_CONSTRUCTORS['length'],'reward_error_codes_count':REWARD_ERROR_CODES['length'],'reward_risk_rules_count':getAllRewardRiskRules()['length'],'reward_context_enabled':!![],'passport_scenarios_count':PASSPORT_SCENARIOS['length'],'passport_max_guard_count':MAX_GUARD_COUNT_PASSPORT,'passport_max_submission_size':MAX_SUBMISSION_SIZE_PASSPORT,'passport_templates_count':PASSPORT_TEMPLATES['length'],'passport_context_enabled':!![],'proof_risk_rules_count':PROOF_RISK_RULES['length'],'repository_risk_rules_count':REPOSITORY_RISK_RULES['length'],'demand_risk_rules_count':DEMAND_RISK_RULES['length'],'contact_risk_rules_count':CONTACT_RISK_RULES['length'],'resource_risk_rules_count':RESOURCE_RISK_RULES['length'],'payment_risk_rules_count':PAYMENT_RISK_RULES['length'],'arb_risk_rules_count':ARB_RISK_RULES['length'],'personal_risk_rules_count':PERSONAL_RISK_RULES['length'],'util_risk_rules_count':UTIL_RISK_RULES['length'],'registrar_risk_rules_count':REGISTRAR_RISK_RULES['length'],'bridge_risk_rules_count':BRIDGE_RISK_RULES['length'],'tools_reference_count':TOOLS_REFERENCE['length'],'scenario_modes_count':SCENARIO_MODES['length'],'scenario_mode_compositions_count':MODE_COMPOSITIONS['length'],'builtin_templates_count':BUILTIN_TEMPLATES['length'],'guard_design_patterns_count':GUARD_DESIGN_PATTERNS['length'],'verifier_level_guidance_count':VERIFIER_LEVEL_GUIDANCE['length']};}export{buildWorkflowGuidance,buildWorkflowReceipt,enrichWorkflowGuidance,mergeGuidanceIntoOutput,resolvePermissionRole,resolveLocalNamesFor,listLocalAccounts,accountCanExecuteForward,enumerateActionableForwards,forwardOperatorKind};export{buildWorkspaceLists}from'./workspace-lists.js';export{resolveSupplyChainGraph}from'./supply-chain.js';export{enumerateObjectOperations,operationCategoryOf,operationComplexityOf,isPermissionIndexType}from'./operation-dictionary.js';export{enumerateServices,enumerateDemands,enumerateArbs}from'./jsonrpc-enum.js';export{FIELD_MUTABILITY_RULES,LOCK_CONSTRAINTS,IRREVERSIBLE_OPERATIONS,STATE_MACHINE_TERMINALS,NUMERIC_LIMIT_CONSTRAINTS,EXTERNAL_ACCESS_MECHANISMS,fieldMutabilityOf,isActionForbidden,lockConstraintOf,numericLimitOf,externalAccessOf}from'./contract-invariants.js';export{GUARD_FIELD_COGNITION_VERSION,GUARD_FIELD_SITES,VALUE_ORIGIN_SEMANTICS,GUARD_PASSPORT_DOCTRINE,guardSitesFor,guardCognitionDoctrine,REPOSITORY_WRITE_ROUTE_MATRIX,repositoryRouteSlotConflicts}from'./guard-field-cognition.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{getFlywheelForIndustry,listIndustries as
|
|
1
|
+
import{getFlywheelForIndustry,listIndustries as a198a,_setRegistryLookup as a198b}from'./acquisition-flywheel.js';import{getIndustryRiskChecks,getIndustryNeeds,getIndustryTemplate,SUPPORTED_INDUSTRIES}from'../customer/index.js';import{_setRegistryLookup as a198c}from'../customer/industry-risks.js';import{_setRegistryLookup as a198d}from'../customer/user-preferences.js';export function isRegisteredIndustry(a){if(!a)return![];const b=resolveIndustryName(a)??a['toLowerCase']();return b==='general'||registry['has'](b);}const BUILTIN_TRAITS={'freelance':{'has_logistics':![],'communication_heavy':!![],'pure_digital':!![],'long_cycle':![],'deposit_required':![],'multi_tier_allocation':![],'regulatory_intensity':'low','trust_sensitivity':'high','consumption_frequency':'occasional','avg_ticket_size':'medium'},'rental':{'has_logistics':!![],'communication_heavy':![],'pure_digital':![],'long_cycle':![],'deposit_required':!![],'multi_tier_allocation':![],'regulatory_intensity':'low','trust_sensitivity':'high','consumption_frequency':'occasional','avg_ticket_size':'medium'},'education':{'has_logistics':![],'communication_heavy':!![],'pure_digital':![],'long_cycle':!![],'deposit_required':![],'multi_tier_allocation':![],'regulatory_intensity':'medium','trust_sensitivity':'high','consumption_frequency':'one_time','avg_ticket_size':'large'},'travel':{'has_logistics':!![],'communication_heavy':!![],'pure_digital':![],'long_cycle':![],'deposit_required':![],'multi_tier_allocation':!![],'regulatory_intensity':'medium','trust_sensitivity':'high','consumption_frequency':'one_time','avg_ticket_size':'large'},'subscription':{'has_logistics':![],'communication_heavy':![],'pure_digital':!![],'long_cycle':![],'deposit_required':![],'multi_tier_allocation':![],'regulatory_intensity':'low','trust_sensitivity':'medium','consumption_frequency':'frequent','avg_ticket_size':'small'},'retail':{'has_logistics':!![],'communication_heavy':![],'pure_digital':![],'long_cycle':![],'deposit_required':![],'multi_tier_allocation':![],'regulatory_intensity':'low','trust_sensitivity':'medium','consumption_frequency':'frequent','avg_ticket_size':'small'}},BUILTIN_DISPLAY_NAMES={'freelance':'Freelance','rental':'Rental','education':'Education','travel':'Travel','subscription':'Subscription','retail':'Retail','general':'General','custom':'Custom'},INDUSTRY_ALIASES={'outsourcing':'freelance','design':'freelance','development':'freelance','consulting':'freelance','rent':'rental','lease':'rental','course':'education','training':'education','tourism':'travel','itinerary':'travel','membership':'subscription','ecommerce':'retail','goods':'retail','freelancer':'freelance','gig':'freelance','edu':'education','trip':'travel','tour':'travel','subscribe':'subscription','shop':'retail','general_industry':'general'};export const INDUSTRY_REGISTRY_VERSION=0x1;const registry=new Map();function seedBuiltinProfile(a){const b=BUILTIN_TRAITS[a];if(!b)return undefined;const c=getFlywheelForIndustry(a);if(!c)return undefined;const d=getIndustryRiskChecks(a),e=getIndustryNeeds(a),f=getIndustryTemplate(a);return{'name':a,'display_name':BUILTIN_DISPLAY_NAMES[a]??a,'traits':b,'source':'builtin','version':'v1','flywheel':c,'risk_checks':d,'preference_template':f,'needs':e};}function seedBuiltinIndustries(){for(const a of SUPPORTED_INDUSTRIES){const b=seedBuiltinProfile(a);b&®istry['set'](a,b);}}seedBuiltinIndustries(),injectRegistryLookup();function injectRegistryLookup(){a198b(a=>{const b=registry['get'](a);return b?{'flywheel':b['flywheel']}:undefined;}),a198c(a=>{const b=registry['get'](a);return b?{'risk_checks':b['risk_checks'],'needs':b['needs']}:undefined;}),a198d(a=>{const b=registry['get'](a);return b?{'preference_template':b['preference_template']}:undefined;});}export function getIndustryProfile(a){const b=registry['get'](a);return b?JSON['parse'](JSON['stringify'](b)):undefined;}export function listIndustries(a){const b=Array['from'](registry['values']());if(a?.['source'])return b['filter'](c=>c['source']===a['source']);return b;}export function registerIndustry(a){if(!a['name']||!a['traits']||!a['flywheel'])return![];return registry['set'](a['name'],a),!![];}export function getIndustryTraits(a){return registry['get'](a)?.['traits'];}export function resolveIndustryName(a){if(!a||typeof a!=='string')return undefined;const b=a['trim']();if(!b)return undefined;const c=b['toLowerCase']();if(INDUSTRY_ALIASES[b])return INDUSTRY_ALIASES[b];if(INDUSTRY_ALIASES[c])return INDUSTRY_ALIASES[c];if(registry['has'](b))return b;if(registry['has'](c))return c;return undefined;}export function getRegistrySize(){return registry['size'];}export function _resetRegistryForTest(){registry['clear'](),a198b(null),a198c(null),a198d(null),seedBuiltinIndustries(),injectRegistryLookup();}export function listBuiltinIndustryNames(){return a198a();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{query_events}from'@wowok/wowok';import{batchQueryObjectsByIds as
|
|
1
|
+
import{query_events}from'@wowok/wowok';import{batchQueryObjectsByIds as a202a}from'../graph/onchain/sdk-batch.js';function toStr(a){if(typeof a==='string')return a;if(typeof a==='number'||typeof a==='bigint')return String(a);return undefined;}async function collectObjectIdsByEvent(a,b,c,d,e){const f=new Set();let g=null,h=![];while(f['size']<d){const i=await query_events({'type':a,'cursor':g,'limit':0x32,'order':'descending','no_cache':e,'network':c}),j=i?.['data']??[];if(j['length']===0x0)break;for(const k of j){const l=b(k);if(l)f['add'](l);}h=!!(i?.['hasNextPage']&&i?.['nextCursor']);if(!h)break;g=i?.['nextCursor']??null;}return{'ids':Array['from'](f)['slice'](0x0,d),'hasMore':h};}export async function enumerateServices(a,b={}){const c=b['max_objects']??0xc8,{ids:d,hasMore:e}=await collectObjectIdsByEvent('ServiceEvent',i=>typeof i?.['object']==='string'?i['object']:undefined,a,c,b['no_cache']),f=await a202a(d,a,b['no_cache']),g=(b['location_any']??[])['map'](i=>i['toLowerCase']()),h=f['filter'](i=>(i?.['type']??'')==='Service')['filter'](i=>{if(g['length']===0x0)return!![];const j=typeof i?.['location']==='string'?i['location']['toLowerCase']():'';return g['some'](k=>j['includes'](k));})['map'](i=>({'object':String(i['object']),'name':typeof i['name']==='string'?i['name']:undefined,'location':typeof i['location']==='string'?i['location']:'','json':{...i,'compensation_fund':toStr(i['compensation_fund']),'sales':Array['isArray'](i['sales'])?i['sales']['map'](j=>({...j,'price':toStr(j['price'])})):[]}}));return{'services':h,'total_enumerated':h['length'],'has_more':e};}export async function enumerateDemands(a,b={}){const c=b['max_objects']??0xc8,{ids:d,hasMore:e}=await collectObjectIdsByEvent('DemandChangedEvent',h=>typeof h?.['object']==='string'?h['object']:undefined,a,c,b['no_cache']),f=await a202a(d,a,b['no_cache']),g=f['filter'](h=>(h?.['type']??'')==='Demand')['map'](h=>h);return{'demands':g,'total_enumerated':g['length'],'has_more':e};}export async function enumerateArbs(a,b={}){const c=b['max_objects']??0xc8,{ids:d,hasMore:e}=await collectObjectIdsByEvent('ArbEvent',i=>typeof i?.['arb']==='string'?i['arb']:undefined,a,c,b['no_cache']),f=await a202a(d,a,b['no_cache']),g=b['status']===undefined?undefined:Array['isArray'](b['status'])?b['status']:[b['status']],h=f['filter'](i=>(i?.['type']??'')==='Arb')['map'](i=>i)['filter'](i=>b['arbitration']?i['arbitration']===b['arbitration']:!![])['filter'](i=>b['order']?i['order']===b['order']:!![])['filter'](i=>g?g['includes'](Number(i['status'])):!![]);return{'arbs':h,'total_enumerated':h['length'],'has_more':e};}
|
|
@@ -65,4 +65,38 @@ export declare function isReachableFromEntry(node: string, topology: MachineTopo
|
|
|
65
65
|
export declare function getNodesReachingTerminals(topology: MachineTopology): Set<string>;
|
|
66
66
|
export declare function formatTopologySummary(topology: MachineTopology): string;
|
|
67
67
|
export declare function identifyTopologyPattern(pairs: MachinePair[]): string;
|
|
68
|
+
export interface MachineEdge {
|
|
69
|
+
prev_node: string;
|
|
70
|
+
next_node: string;
|
|
71
|
+
forward: string;
|
|
72
|
+
weight?: number;
|
|
73
|
+
threshold?: number;
|
|
74
|
+
guard?: string | null;
|
|
75
|
+
operator?: string | null;
|
|
76
|
+
permission_index?: number | null;
|
|
77
|
+
}
|
|
78
|
+
export interface ForwardAmbiguity {
|
|
79
|
+
prev_node: string;
|
|
80
|
+
forward: string;
|
|
81
|
+
destinations: string[];
|
|
82
|
+
fund_conflict: boolean;
|
|
83
|
+
binding_differs: boolean;
|
|
84
|
+
severity: "critical" | "warning";
|
|
85
|
+
reason: string;
|
|
86
|
+
}
|
|
87
|
+
export interface ShadowedForward {
|
|
88
|
+
prev_node: string;
|
|
89
|
+
next_node: string;
|
|
90
|
+
forward: string;
|
|
91
|
+
}
|
|
92
|
+
export declare function flattenMachineNodeEdges(nodes: unknown[]): MachineEdge[];
|
|
93
|
+
export declare function findForwardAmbiguities(edges: MachineEdge[]): ForwardAmbiguity[];
|
|
94
|
+
export declare function findShadowedForwards(edges: MachineEdge[]): ShadowedForward[];
|
|
95
|
+
export interface AmbiguityLint {
|
|
96
|
+
ambiguities: ForwardAmbiguity[];
|
|
97
|
+
shadowed: ShadowedForward[];
|
|
98
|
+
critical: string[];
|
|
99
|
+
warnings: string[];
|
|
100
|
+
}
|
|
101
|
+
export declare function lintForwardAmbiguity(nodes: unknown[], context?: string): AmbiguityLint;
|
|
68
102
|
export declare const MACHINE_TOPOLOGY_VERSION = "1.0.0";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{MAX_NODE_COUNT,MAX_NODE_PAIR_COUNT,MAX_FORWARD_COUNT,MAX_FORWARD_ORDER_COUNT}from'./onchain-constants.js';export{MAX_NODE_COUNT,MAX_NODE_PAIR_COUNT,MAX_FORWARD_COUNT,MAX_FORWARD_ORDER_COUNT};export function analyzeTopology(a,b){const c=a['map'](t=>t['name']),d=new Set(c),e=new Map(),f=new Map();for(const t of c){e['set'](t,[]),f['set'](t,[]);}for(const u of b){!e['has'](u['prev_node'])&&u['prev_node']!==''&&e['set'](u['prev_node'],[]),!f['has'](u['next_node'])&&f['set'](u['next_node'],[]),u['prev_node']!==''&&e['get'](u['prev_node'])['push'](u['next_node']),f['get'](u['next_node'])['push'](u['prev_node']);}const g=b['filter'](v=>v['prev_node']==='')['map'](v=>v['next_node'])['filter'](v=>d['has'](v)),h=c['filter'](v=>(e['get'](v)||[])['length']===0x0),i=c['filter'](v=>!g['includes'](v)&&(f['get'](v)||[])['length']===0x0),j=c['filter'](v=>(e['get'](v)||[])['length']===0x0&&!h['includes'](v)),{has_cycles:k,cycle_nodes:l}=detectCycles(c,b),m=analyzeDeadBranches(b),n=findUnachievableThresholds(b),o=computeReachability(c,b),p=b['reduce']((v,w)=>v+w['forwards']['length'],0x0),q=Math['max'](0x0,...b['map'](v=>v['forwards']['length'])),r=Math['max'](0x0,...b['flatMap'](v=>v['forwards']['map'](w=>countRetainedSubmissions(w['retained_submission'])))),s={'max_node_count':a['length']<=MAX_NODE_COUNT,'max_node_pair_count':b['length']<=MAX_NODE_PAIR_COUNT,'max_forward_count':q<=MAX_FORWARD_COUNT,'max_forward_order_count':r<=MAX_FORWARD_ORDER_COUNT,'threshold_achievable':n['length']===0x0};return{'entry_nodes':g,'terminal_nodes':h,'orphaned_nodes':i,'dead_end_nodes':j,'dead_branches':m,'unachievable_thresholds':n,'has_cycles':k,'cycle_nodes':l,'reachability':o,'node_count':a['length'],'pair_count':b['length'],'forward_count':p,'within_limits':s};}export function findUnachievableThresholds(a){const b=[];for(const c of a){const d=c['forwards']['length'],e=c['forwards']['reduce']((g,h)=>g+Number(h['weight']||0x0),0x0);if(e<c['threshold']){const f=c['threshold']>0x1&&d<c['threshold'];b['push']({'prev_node':c['prev_node'],'next_node':c['next_node'],'threshold':c['threshold'],'max_achievable':e,'distinct_forwards':d,'reason':f?'Threshold\x20'+c['threshold']+'\x20needs\x20'+c['threshold']+'\x20distinct\x20forwards\x20(each\x20forward\x20is\x20single-operator-locked\x20and\x20contributes\x20its\x20weight\x20at\x20most\x20once);\x20this\x20Pair\x20has\x20'+d+'\x20forward(s)\x20summing\x20to\x20'+e+'.\x20Add\x20more\x20parallel\x20forwards\x20or\x20lower\x20the\x20threshold.':'Threshold\x20'+c['threshold']+'\x20exceeds\x20max\x20achievable\x20weight\x20'+e+'\x20(sum\x20of\x20distinct\x20forward\x20weights).\x20The\x20transition\x20can\x20never\x20migrate.'});}}return b;}function countRetainedSubmissions(a){if(a===undefined||a===null)return 0x0;if(Array['isArray'](a))return a['length'];if(typeof a==='string')return a['length']>0x0?0x1:0x0;return 0x0;}export function detectCycle(a,b){const c=a['map'](d=>d['name']);return detectCycles(c,b);}function detectCycles(a,b){const c=new Map();for(const k of a)c['set'](k,[]);for(const l of b){l['prev_node']!==''&&c['has'](l['prev_node'])&&c['get'](l['prev_node'])['push'](l['next_node']);}const d=0x0,e=0x1,f=0x2,g=new Map();for(const m of a)g['set'](m,d);const h=[],i=[];function j(n){g['set'](n,e),i['push'](n);for(const o of c['get'](n)||[]){if(g['get'](o)===e){const p=i['indexOf'](o);return h['push'](i['slice'](p)),!![];}if(g['get'](o)===d){if(j(o))return!![];}}return i['pop'](),g['set'](n,f),![];}for(const n of a){g['get'](n)===d&&j(n);}return{'has_cycles':h['length']>0x0,'cycle_nodes':h};}function analyzeDeadBranches(a){const b=[],c=new Map();for(const d of a){if(!c['has'](d['prev_node']))c['set'](d['prev_node'],[]);c['get'](d['prev_node'])['push'](d);}for(const [e,f]of c){if(f['length']<=0x1)continue;const g=Math['min'](...f['map'](h=>h['threshold']));for(const h of f){h['threshold']>g*0x2&&b['push']({'pair':{'prev_node':h['prev_node'],'next_node':h['next_node']},'reason':'Threshold\x20'+h['threshold']+'\x20is\x20much\x20higher\x20than\x20competing\x20minimum\x20'+g+'.\x20Likely\x20always\x20loses.','competing_with':f['filter'](i=>i!==h)['map'](i=>i['next_node'])});}}return b;}function computeReachability(a,b){const c=new Map();for(const e of a)c['set'](e,[]);for(const f of b){if(f['prev_node']!==''){if(!c['has'](f['prev_node']))c['set'](f['prev_node'],[]);c['get'](f['prev_node'])['push'](f['next_node']);}}const d=new Map();for(const g of a){const h=new Set(),i=[g];while(i['length']>0x0){const j=i['shift']();for(const k of c['get'](j)||[]){!h['has'](k)&&(h['add'](k),i['push'](k));}}d['set'](g,h);}return d;}export function isReachableFromEntry(a,b){for(const c of b['entry_nodes']){if(c===a)return!![];if(b['reachability']['get'](c)?.['has'](a))return!![];}return![];}export function getNodesReachingTerminals(a){const b=new Set();for(const [c,d]of a['reachability']){for(const e of a['terminal_nodes']){if(d['has'](e)){b['add'](c);break;}}}return b;}export function formatTopologySummary(a){const b=['Nodes:\x20'+a['node_count']+'\x20(max\x20100)','Pairs:\x20'+a['pair_count']+'\x20(max\x2040)','Forwards:\x20'+a['forward_count']+'\x20(max\x2020\x20per\x20Pair)','','Entry\x20nodes:\x20'+(a['entry_nodes']['join'](',\x20')||'(none)'),'Terminal\x20nodes:\x20'+(a['terminal_nodes']['join'](',\x20')||'(none)'),'Orphaned\x20nodes:\x20'+(a['orphaned_nodes']['join'](',\x20')||'(none)'),'Dead\x20branches:\x20'+a['dead_branches']['length'],'Unachievable\x20thresholds:\x20'+a['unachievable_thresholds']['length'],'Cycles:\x20'+(a['has_cycles']?'YES\x20(❌\x20invalid\x20DAG)':'NO\x20(✓\x20valid\x20DAG)'),'','Within\x20on-chain\x20limits:\x20'+(a['within_limits']['max_node_count']&&a['within_limits']['max_node_pair_count']&&a['within_limits']['max_forward_count']&&a['within_limits']['max_forward_order_count']&&a['within_limits']['threshold_achievable']?'YES\x20✓':'NO\x20❌')];return b['join']('\x0a');}export function identifyTopologyPattern(a){const b=new Map(),c=new Map();for(const d of a){if(!b['has'](d['prev_node']))b['set'](d['prev_node'],[]);b['get'](d['prev_node'])['push'](d['next_node']);if(!c['has'](d['next_node']))c['set'](d['next_node'],[]);c['get'](d['next_node'])['push'](d['prev_node']);}for(const [e,f]of b){if(f['length']>0x1&&e!=='')return'P-M-COMPETING';}for(const [g,h]of c){if(h['length']>0x1)return'P-M-FORKMERGE';}return'P-M-LINEAR';}export const MACHINE_TOPOLOGY_VERSION='1.0.0';
|
|
1
|
+
import{MAX_NODE_COUNT,MAX_NODE_PAIR_COUNT,MAX_FORWARD_COUNT,MAX_FORWARD_ORDER_COUNT}from'./onchain-constants.js';export{MAX_NODE_COUNT,MAX_NODE_PAIR_COUNT,MAX_FORWARD_COUNT,MAX_FORWARD_ORDER_COUNT};export function analyzeTopology(a,b){const c=a['map'](t=>t['name']),d=new Set(c),e=new Map(),f=new Map();for(const t of c){e['set'](t,[]),f['set'](t,[]);}for(const u of b){!e['has'](u['prev_node'])&&u['prev_node']!==''&&e['set'](u['prev_node'],[]),!f['has'](u['next_node'])&&f['set'](u['next_node'],[]),u['prev_node']!==''&&e['get'](u['prev_node'])['push'](u['next_node']),f['get'](u['next_node'])['push'](u['prev_node']);}const g=b['filter'](v=>v['prev_node']==='')['map'](v=>v['next_node'])['filter'](v=>d['has'](v)),h=c['filter'](v=>(e['get'](v)||[])['length']===0x0),i=c['filter'](v=>!g['includes'](v)&&(f['get'](v)||[])['length']===0x0),j=c['filter'](v=>(e['get'](v)||[])['length']===0x0&&!h['includes'](v)),{has_cycles:k,cycle_nodes:l}=detectCycles(c,b),m=analyzeDeadBranches(b),n=findUnachievableThresholds(b),o=computeReachability(c,b),p=b['reduce']((v,w)=>v+w['forwards']['length'],0x0),q=Math['max'](0x0,...b['map'](v=>v['forwards']['length'])),r=Math['max'](0x0,...b['flatMap'](v=>v['forwards']['map'](w=>countRetainedSubmissions(w['retained_submission'])))),s={'max_node_count':a['length']<=MAX_NODE_COUNT,'max_node_pair_count':b['length']<=MAX_NODE_PAIR_COUNT,'max_forward_count':q<=MAX_FORWARD_COUNT,'max_forward_order_count':r<=MAX_FORWARD_ORDER_COUNT,'threshold_achievable':n['length']===0x0};return{'entry_nodes':g,'terminal_nodes':h,'orphaned_nodes':i,'dead_end_nodes':j,'dead_branches':m,'unachievable_thresholds':n,'has_cycles':k,'cycle_nodes':l,'reachability':o,'node_count':a['length'],'pair_count':b['length'],'forward_count':p,'within_limits':s};}export function findUnachievableThresholds(a){const b=[];for(const c of a){const d=c['forwards']['length'],e=c['forwards']['reduce']((g,h)=>g+Number(h['weight']||0x0),0x0);if(e<c['threshold']){const f=c['threshold']>0x1&&d<c['threshold'];b['push']({'prev_node':c['prev_node'],'next_node':c['next_node'],'threshold':c['threshold'],'max_achievable':e,'distinct_forwards':d,'reason':f?'Threshold\x20'+c['threshold']+'\x20needs\x20'+c['threshold']+'\x20distinct\x20forwards\x20(each\x20forward\x20is\x20single-operator-locked\x20and\x20contributes\x20its\x20weight\x20at\x20most\x20once);\x20this\x20Pair\x20has\x20'+d+'\x20forward(s)\x20summing\x20to\x20'+e+'.\x20Add\x20more\x20parallel\x20forwards\x20or\x20lower\x20the\x20threshold.':'Threshold\x20'+c['threshold']+'\x20exceeds\x20max\x20achievable\x20weight\x20'+e+'\x20(sum\x20of\x20distinct\x20forward\x20weights).\x20The\x20transition\x20can\x20never\x20migrate.'});}}return b;}function countRetainedSubmissions(a){if(a===undefined||a===null)return 0x0;if(Array['isArray'](a))return a['length'];if(typeof a==='string')return a['length']>0x0?0x1:0x0;return 0x0;}export function detectCycle(a,b){const c=a['map'](d=>d['name']);return detectCycles(c,b);}function detectCycles(a,b){const c=new Map();for(const k of a)c['set'](k,[]);for(const l of b){l['prev_node']!==''&&c['has'](l['prev_node'])&&c['get'](l['prev_node'])['push'](l['next_node']);}const d=0x0,e=0x1,f=0x2,g=new Map();for(const m of a)g['set'](m,d);const h=[],i=[];function j(n){g['set'](n,e),i['push'](n);for(const o of c['get'](n)||[]){if(g['get'](o)===e){const p=i['indexOf'](o);return h['push'](i['slice'](p)),!![];}if(g['get'](o)===d){if(j(o))return!![];}}return i['pop'](),g['set'](n,f),![];}for(const n of a){g['get'](n)===d&&j(n);}return{'has_cycles':h['length']>0x0,'cycle_nodes':h};}function analyzeDeadBranches(a){const b=[],c=new Map();for(const d of a){if(!c['has'](d['prev_node']))c['set'](d['prev_node'],[]);c['get'](d['prev_node'])['push'](d);}for(const [e,f]of c){if(f['length']<=0x1)continue;const g=Math['min'](...f['map'](h=>h['threshold']));for(const h of f){h['threshold']>g*0x2&&b['push']({'pair':{'prev_node':h['prev_node'],'next_node':h['next_node']},'reason':'Threshold\x20'+h['threshold']+'\x20is\x20much\x20higher\x20than\x20competing\x20minimum\x20'+g+'.\x20Likely\x20always\x20loses.','competing_with':f['filter'](i=>i!==h)['map'](i=>i['next_node'])});}}return b;}function computeReachability(a,b){const c=new Map();for(const e of a)c['set'](e,[]);for(const f of b){if(f['prev_node']!==''){if(!c['has'](f['prev_node']))c['set'](f['prev_node'],[]);c['get'](f['prev_node'])['push'](f['next_node']);}}const d=new Map();for(const g of a){const h=new Set(),i=[g];while(i['length']>0x0){const j=i['shift']();for(const k of c['get'](j)||[]){!h['has'](k)&&(h['add'](k),i['push'](k));}}d['set'](g,h);}return d;}export function isReachableFromEntry(a,b){for(const c of b['entry_nodes']){if(c===a)return!![];if(b['reachability']['get'](c)?.['has'](a))return!![];}return![];}export function getNodesReachingTerminals(a){const b=new Set();for(const [c,d]of a['reachability']){for(const e of a['terminal_nodes']){if(d['has'](e)){b['add'](c);break;}}}return b;}export function formatTopologySummary(a){const b=['Nodes:\x20'+a['node_count']+'\x20(max\x20100)','Pairs:\x20'+a['pair_count']+'\x20(max\x2040)','Forwards:\x20'+a['forward_count']+'\x20(max\x2020\x20per\x20Pair)','','Entry\x20nodes:\x20'+(a['entry_nodes']['join'](',\x20')||'(none)'),'Terminal\x20nodes:\x20'+(a['terminal_nodes']['join'](',\x20')||'(none)'),'Orphaned\x20nodes:\x20'+(a['orphaned_nodes']['join'](',\x20')||'(none)'),'Dead\x20branches:\x20'+a['dead_branches']['length'],'Unachievable\x20thresholds:\x20'+a['unachievable_thresholds']['length'],'Cycles:\x20'+(a['has_cycles']?'YES\x20(❌\x20invalid\x20DAG)':'NO\x20(✓\x20valid\x20DAG)'),'','Within\x20on-chain\x20limits:\x20'+(a['within_limits']['max_node_count']&&a['within_limits']['max_node_pair_count']&&a['within_limits']['max_forward_count']&&a['within_limits']['max_forward_order_count']&&a['within_limits']['threshold_achievable']?'YES\x20✓':'NO\x20❌')];return b['join']('\x0a');}export function identifyTopologyPattern(a){const b=new Map(),c=new Map();for(const d of a){if(!b['has'](d['prev_node']))b['set'](d['prev_node'],[]);b['get'](d['prev_node'])['push'](d['next_node']);if(!c['has'](d['next_node']))c['set'](d['next_node'],[]);c['get'](d['next_node'])['push'](d['prev_node']);}for(const [e,f]of b){if(f['length']>0x1&&e!=='')return'P-M-COMPETING';}for(const [g,h]of c){if(h['length']>0x1)return'P-M-FORKMERGE';}return'P-M-LINEAR';}const FUND_REVERSING_NODE_RE=/(^|_)(cancel(led)?|refund(ed)?|return(ed|_approved)?|expired)(_|$)/i;export function flattenMachineNodeEdges(a){const b=[];for(const c of Array['isArray'](a)?a:[]){const d=c,e=typeof d?.['name']==='string'?d['name']:'';for(const g of Array['isArray'](d?.['pairs'])?d['pairs']:[]){const h=typeof g?.['prev_node']==='string'?g['prev_node']:'',i=typeof g?.['next_node']==='string'&&g['next_node']?g['next_node']:e,j=typeof g?.['threshold']==='number'?g['threshold']:undefined;for(const k of Array['isArray'](g?.['forwards'])?g['forwards']:[]){const l=k,m=typeof l?.['name']==='string'?l['name']:'';if(!m||!i)continue;const n=l?.['namedOperator']??l?.['named_operator'],o=l?.['permissionIndex']??l?.['permission_index'];b['push']({'prev_node':h,'next_node':i,'forward':m,'weight':typeof l?.['weight']==='number'?l['weight']:undefined,'threshold':j,'guard':typeof l?.['guard']==='string'?l['guard']:null,'operator':typeof n==='string'?n:null,'permission_index':typeof o==='number'?o:null});}}}return b;}function bindingKey(a){return(a['threshold']??0x0)+'|'+(a['weight']??0x0)+'|'+(a['guard']??'')+'|'+(a['operator']??'')+'|'+(a['permission_index']??'');}export function findForwardAmbiguities(a){const b=new Map();for(const d of a){const f=d['prev_node']+'\x00'+d['forward'],h=b['get'](f);if(h)h['push'](d);else b['set'](f,[d]);}const c=[];for(const [,i]of b){const j=[...new Set(i['map'](p=>p['next_node']))];if(j['length']<0x2)continue;const k=j['filter'](p=>FUND_REVERSING_NODE_RE['test'](p)),l=k['length']>0x0&&k['length']<j['length'],m=new Set(i['map'](bindingKey)),n=m['size']>0x1,o=j['filter'](p=>!FUND_REVERSING_NODE_RE['test'](p));c['push']({'prev_node':i[0x0]['prev_node'],'forward':i[0x0]['forward'],'destinations':j['sort'](),'fund_conflict':l,'binding_differs':n,'severity':l?'critical':'warning','reason':l?'Forward\x20\x22'+i[0x0]['forward']+'\x22\x20from\x20\x22'+i[0x0]['prev_node']+'\x22\x20resolves\x20to\x20both\x20refund\x20node(s)\x20['+k['join'](',\x20')+']\x20and\x20continue\x20node(s)\x20['+o['join'](',\x20')+'].\x20The\x20destination\x20is\x20a\x20CALLER\x20argument\x20(progress.move:540),\x20so\x20the\x20wrong\x20pick\x20puts\x20the\x20order\x20in\x20a\x20node\x20whose\x20Allocator\x20never\x20fires\x20—\x20the\x20escrow\x20strands.':'Forward\x20\x22'+i[0x0]['forward']+'\x22\x20from\x20\x22'+i[0x0]['prev_node']+'\x22\x20resolves\x20to\x20'+j['length']+'\x20destinations\x20['+j['join'](',\x20')+'];\x20the\x20caller\x20picks\x20which,\x20so\x20the\x20workflow\x20outcome\x20depends\x20on\x20an\x20argument\x20the\x20Machine\x20does\x20not\x20constrain'+(n?'\x20—\x20and\x20the\x20candidate\x20edges\x20carry\x20DIFFERENT\x20guard/operator/weight\x20bindings':'')+'.'});}return c['sort']((p,q)=>p['severity']===q['severity']?0x0:p['severity']==='critical'?-0x1:0x1);}export function findShadowedForwards(a){const b=new Set(),c=[];for(const d of a){const f=d['prev_node']+'\x00'+d['next_node']+'\x00'+d['forward'];b['has'](f)?c['push']({'prev_node':d['prev_node'],'next_node':d['next_node'],'forward':d['forward']}):b['add'](f);}return c;}export function lintForwardAmbiguity(b,c='machine'){const d=flattenMachineNodeEdges(b),e=findForwardAmbiguities(d),f=findShadowedForwards(d),g=[],h=[];for(const i of e){const j=c+':\x20P0-6\x20forward\x20ambiguity\x20—\x20'+i['reason'];i['severity']==='critical'?g['push'](j+'\x20Fix:\x20give\x20each\x20destination\x20its\x20own\x20forward\x20name\x20(e.g.\x20free_cancel\x20→\x20closed_cancel,\x20supplier_confirm\x20→\x20confirmed)\x20so\x20the\x20name\x20determines\x20the\x20node.'):h['push'](j+'\x20Recommended:\x20give\x20the\x20forward\x20a\x20destination-unique\x20name\x20unless\x20this\x20fork\x20is\x20intentional\x20and\x20the\x20caller\x20is\x20told\x20to\x20choose.');}for(const k of f){h['push'](c+':\x20duplicate\x20forward\x20\x22'+k['forward']+'\x22\x20in\x20the\x20'+(k['prev_node']||'(entry)')+'→'+k['next_node']+'\x20Pair\x20—\x20'+'the\x20destination\x20node\x27s\x20edge\x20lookup\x20(machine.move:284-296)\x20scans\x20forwards\x20in\x20order\x20and\x20returns\x20the\x20FIRST\x20match,\x20so\x20every\x20later\x20entry\x20with\x20that\x20name\x20is\x20unreachable\x20(dead\x20weight).\x20Rename\x20or\x20drop\x20it.');}return{'ambiguities':e,'shadowed':f,'critical':g,'warnings':h};}export const MACHINE_TOPOLOGY_VERSION='1.0.0';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ONCHAIN_CONSTANTS, MAX_NODE_COUNT, MAX_NODE_COUNT_ONCHAIN, MAX_FORWARD_COUNT, MAX_FORWARD_ORDER_COUNT, MAX_NODE_PAIR_COUNT, MAX_CONSENSUS_REPOSITORIES_COUNT, USER_DEFINED_PERM_INDEX_START, MAX_PERM_FOR_ENTITY, MAX_ADMIN_COUNT, MAX_ITEM_COUNT, ROLE_OWNER, ROLE_ADMIN, ROLE_ENTITY, MAX_AGENT_COUNT, MAX_DISPUTE_COUNT, MAX_SHARING_COUNT, MAX_VOTING_GUARD_COUNT, MAX_POLICY_COUNT, MAX_ID_COUNT_ONCE, MAX_REWARD_COUNT, MAX_GUARD_COUNT_REWARD, MAX_RECORD_COUNT_REWARD, MAX_CONTEXT_REPOSITORY_COUNT, MAX_NAMED_OPERATOR_COUNT, MAX_NAMED_OPERATOR_ADDRESS_COUNT, MAX_IM_COUNT, MAX_TAGS_COUNT, MAX_RECIPIENT_COUNT, MAX_PROPOSITION_COUNT, MAX_VOTOR_COUNT, WITHDRAW_DURATION_TIME, MAX_ADDRESS_COUNT, MAX_RECORD_LENGTH, BRIDGE_MESSAGE_VERSION, BRIDGE_EVM_ADDRESS_LENGTH, BRIDGE_CURRENT_VERSION, BRIDGE_TRANSFER_STATUS_PENDING, BRIDGE_TRANSFER_STATUS_APPROVED, BRIDGE_TRANSFER_STATUS_CLAIMED, BRIDGE_TRANSFER_STATUS_NOT_FOUND, MAX_INDEMNITY_MULTIPLE, MAX_PRESENTER_COUNT, MAX_INPUT_SIZE, MAX_TABLE_SIZE, MAX_DEPENDED_COUNT, MAX_DISCOUNT_TOTAL_COUNT, type OnchainConstantName, type MaxNodeCountSdkLiteral } from "@wowok/wowok";
|
|
2
|
-
export { ONCHAIN_CONSTANTS, MAX_NODE_COUNT, MAX_NODE_COUNT_ONCHAIN, MAX_FORWARD_COUNT, MAX_FORWARD_ORDER_COUNT, MAX_NODE_PAIR_COUNT, MAX_CONSENSUS_REPOSITORIES_COUNT, USER_DEFINED_PERM_INDEX_START, MAX_PERM_FOR_ENTITY, MAX_ADMIN_COUNT, MAX_ITEM_COUNT, ROLE_OWNER, ROLE_ADMIN, ROLE_ENTITY, MAX_AGENT_COUNT, MAX_DISPUTE_COUNT, MAX_SHARING_COUNT, MAX_VOTING_GUARD_COUNT, MAX_POLICY_COUNT, MAX_ID_COUNT_ONCE, MAX_REWARD_COUNT, MAX_GUARD_COUNT_REWARD, MAX_RECORD_COUNT_REWARD, MAX_CONTEXT_REPOSITORY_COUNT, MAX_NAMED_OPERATOR_COUNT, MAX_NAMED_OPERATOR_ADDRESS_COUNT, MAX_IM_COUNT, MAX_TAGS_COUNT, MAX_RECIPIENT_COUNT, MAX_PROPOSITION_COUNT, MAX_VOTOR_COUNT, WITHDRAW_DURATION_TIME, MAX_INDEMNITY_MULTIPLE, MAX_PRESENTER_COUNT, MAX_INPUT_SIZE, MAX_TABLE_SIZE, MAX_DEPENDED_COUNT, MAX_DISCOUNT_TOTAL_COUNT, MAX_ADDRESS_COUNT, MAX_RECORD_LENGTH, BRIDGE_MESSAGE_VERSION, BRIDGE_EVM_ADDRESS_LENGTH, BRIDGE_CURRENT_VERSION, BRIDGE_TRANSFER_STATUS_PENDING, BRIDGE_TRANSFER_STATUS_APPROVED, BRIDGE_TRANSFER_STATUS_CLAIMED, BRIDGE_TRANSFER_STATUS_NOT_FOUND, type OnchainConstantName, type MaxNodeCountSdkLiteral, };
|
|
1
|
+
import { ONCHAIN_CONSTANTS, MAX_NODE_COUNT, MAX_NODE_COUNT_ONCHAIN, MAX_FORWARD_COUNT, MAX_FORWARD_ORDER_COUNT, MAX_NODE_PAIR_COUNT, MAX_CONSENSUS_REPOSITORIES_COUNT, USER_DEFINED_PERM_INDEX_START, MAX_PERM_FOR_ENTITY, MAX_ADMIN_COUNT, MAX_ITEM_COUNT, ROLE_OWNER, ROLE_ADMIN, ROLE_ENTITY, MAX_AGENT_COUNT, MAX_DISPUTE_COUNT, MAX_SHARING_COUNT, MAX_VOTING_GUARD_COUNT, MAX_POLICY_COUNT, MAX_ID_COUNT_ONCE, MAX_REWARD_COUNT, MAX_GUARD_COUNT_REWARD, MAX_RECORD_COUNT_REWARD, MAX_CONTEXT_REPOSITORY_COUNT, MAX_NAMED_OPERATOR_COUNT, MAX_NAMED_OPERATOR_ADDRESS_COUNT, MAX_IM_COUNT, MAX_TAGS_COUNT, MAX_RECIPIENT_COUNT, MAX_PROPOSITION_COUNT, MAX_VOTOR_COUNT, WITHDRAW_DURATION_TIME, MAX_ADDRESS_COUNT, MAX_RECORD_LENGTH, BRIDGE_MESSAGE_VERSION, BRIDGE_EVM_ADDRESS_LENGTH, BRIDGE_CURRENT_VERSION, BRIDGE_TRANSFER_STATUS_PENDING, BRIDGE_TRANSFER_STATUS_APPROVED, BRIDGE_TRANSFER_STATUS_CLAIMED, BRIDGE_TRANSFER_STATUS_NOT_FOUND, MAX_INDEMNITY_MULTIPLE, MAX_PRESENTER_COUNT, MAX_INPUT_SIZE, MAX_TABLE_SIZE, MAX_DEPENDED_COUNT, MAX_DISCOUNT_TOTAL_COUNT, MAX_USER_IDENTIFIER, type OnchainConstantName, type MaxNodeCountSdkLiteral } from "@wowok/wowok";
|
|
2
|
+
export { ONCHAIN_CONSTANTS, MAX_NODE_COUNT, MAX_NODE_COUNT_ONCHAIN, MAX_FORWARD_COUNT, MAX_FORWARD_ORDER_COUNT, MAX_NODE_PAIR_COUNT, MAX_CONSENSUS_REPOSITORIES_COUNT, USER_DEFINED_PERM_INDEX_START, MAX_PERM_FOR_ENTITY, MAX_ADMIN_COUNT, MAX_ITEM_COUNT, ROLE_OWNER, ROLE_ADMIN, ROLE_ENTITY, MAX_AGENT_COUNT, MAX_DISPUTE_COUNT, MAX_SHARING_COUNT, MAX_VOTING_GUARD_COUNT, MAX_POLICY_COUNT, MAX_ID_COUNT_ONCE, MAX_REWARD_COUNT, MAX_GUARD_COUNT_REWARD, MAX_RECORD_COUNT_REWARD, MAX_CONTEXT_REPOSITORY_COUNT, MAX_NAMED_OPERATOR_COUNT, MAX_NAMED_OPERATOR_ADDRESS_COUNT, MAX_IM_COUNT, MAX_TAGS_COUNT, MAX_RECIPIENT_COUNT, MAX_PROPOSITION_COUNT, MAX_VOTOR_COUNT, WITHDRAW_DURATION_TIME, MAX_INDEMNITY_MULTIPLE, MAX_PRESENTER_COUNT, MAX_INPUT_SIZE, MAX_TABLE_SIZE, MAX_DEPENDED_COUNT, MAX_DISCOUNT_TOTAL_COUNT, MAX_USER_IDENTIFIER, MAX_ADDRESS_COUNT, MAX_RECORD_LENGTH, BRIDGE_MESSAGE_VERSION, BRIDGE_EVM_ADDRESS_LENGTH, BRIDGE_CURRENT_VERSION, BRIDGE_TRANSFER_STATUS_PENDING, BRIDGE_TRANSFER_STATUS_APPROVED, BRIDGE_TRANSFER_STATUS_CLAIMED, BRIDGE_TRANSFER_STATUS_NOT_FOUND, type OnchainConstantName, type MaxNodeCountSdkLiteral, };
|
|
3
3
|
export declare const ONCHAIN_CONSTANT_MCP_CONSUMERS: Record<string, string[]>;
|
|
4
4
|
export declare function getOnchainConstant(name: OnchainConstantName): number;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{ONCHAIN_CONSTANTS,MAX_NODE_COUNT,MAX_NODE_COUNT_ONCHAIN,MAX_FORWARD_COUNT,MAX_FORWARD_ORDER_COUNT,MAX_NODE_PAIR_COUNT,MAX_CONSENSUS_REPOSITORIES_COUNT,USER_DEFINED_PERM_INDEX_START,MAX_PERM_FOR_ENTITY,MAX_ADMIN_COUNT,MAX_ITEM_COUNT,ROLE_OWNER,ROLE_ADMIN,ROLE_ENTITY,MAX_AGENT_COUNT,MAX_DISPUTE_COUNT,MAX_SHARING_COUNT,MAX_VOTING_GUARD_COUNT,MAX_POLICY_COUNT,MAX_ID_COUNT_ONCE,MAX_REWARD_COUNT,MAX_GUARD_COUNT_REWARD,MAX_RECORD_COUNT_REWARD,MAX_CONTEXT_REPOSITORY_COUNT,MAX_NAMED_OPERATOR_COUNT,MAX_NAMED_OPERATOR_ADDRESS_COUNT,MAX_IM_COUNT,MAX_TAGS_COUNT,MAX_RECIPIENT_COUNT,MAX_PROPOSITION_COUNT,MAX_VOTOR_COUNT,WITHDRAW_DURATION_TIME,MAX_ADDRESS_COUNT,MAX_RECORD_LENGTH,BRIDGE_MESSAGE_VERSION,BRIDGE_EVM_ADDRESS_LENGTH,BRIDGE_CURRENT_VERSION,BRIDGE_TRANSFER_STATUS_PENDING,BRIDGE_TRANSFER_STATUS_APPROVED,BRIDGE_TRANSFER_STATUS_CLAIMED,BRIDGE_TRANSFER_STATUS_NOT_FOUND,MAX_INDEMNITY_MULTIPLE,MAX_PRESENTER_COUNT,MAX_INPUT_SIZE,MAX_TABLE_SIZE,MAX_DEPENDED_COUNT,MAX_DISCOUNT_TOTAL_COUNT}from'@wowok/wowok';export{ONCHAIN_CONSTANTS,MAX_NODE_COUNT,MAX_NODE_COUNT_ONCHAIN,MAX_FORWARD_COUNT,MAX_FORWARD_ORDER_COUNT,MAX_NODE_PAIR_COUNT,MAX_CONSENSUS_REPOSITORIES_COUNT,USER_DEFINED_PERM_INDEX_START,MAX_PERM_FOR_ENTITY,MAX_ADMIN_COUNT,MAX_ITEM_COUNT,ROLE_OWNER,ROLE_ADMIN,ROLE_ENTITY,MAX_AGENT_COUNT,MAX_DISPUTE_COUNT,MAX_SHARING_COUNT,MAX_VOTING_GUARD_COUNT,MAX_POLICY_COUNT,MAX_ID_COUNT_ONCE,MAX_REWARD_COUNT,MAX_GUARD_COUNT_REWARD,MAX_RECORD_COUNT_REWARD,MAX_CONTEXT_REPOSITORY_COUNT,MAX_NAMED_OPERATOR_COUNT,MAX_NAMED_OPERATOR_ADDRESS_COUNT,MAX_IM_COUNT,MAX_TAGS_COUNT,MAX_RECIPIENT_COUNT,MAX_PROPOSITION_COUNT,MAX_VOTOR_COUNT,WITHDRAW_DURATION_TIME,MAX_INDEMNITY_MULTIPLE,MAX_PRESENTER_COUNT,MAX_INPUT_SIZE,MAX_TABLE_SIZE,MAX_DEPENDED_COUNT,MAX_DISCOUNT_TOTAL_COUNT,MAX_ADDRESS_COUNT,MAX_RECORD_LENGTH,BRIDGE_MESSAGE_VERSION,BRIDGE_EVM_ADDRESS_LENGTH,BRIDGE_CURRENT_VERSION,BRIDGE_TRANSFER_STATUS_PENDING,BRIDGE_TRANSFER_STATUS_APPROVED,BRIDGE_TRANSFER_STATUS_CLAIMED,BRIDGE_TRANSFER_STATUS_NOT_FOUND};export const ONCHAIN_CONSTANT_MCP_CONSUMERS={'MAX_NODE_COUNT':['machine-topology.ts\x20(within_limits\x20check)','machine-risk.ts\x20R-M1-07','machine-translation.ts\x20MC-C-01','knowledge/index.ts\x20(max_node_count\x20field)'],'MAX_FORWARD_ORDER_COUNT':[],'MAX_NODE_PAIR_COUNT':['machine-topology.ts\x20(within_limits\x20check)'],'USER_DEFINED_PERM_INDEX_START':['machine-risk.ts\x20R-M3-08','guard-risk.ts\x20(forward\x20permissionIndex\x20guidance)'],'MAX_VOTING_GUARD_COUNT':['evaluation/builtins/arbitration-score.ts\x20(fairness_governance\x20reason)'],'MAX_ITEM_COUNT':['permission-context.ts\x20(entity_permission\x20reverse\x20index)'],'ROLE_OWNER':['permission-context.ts\x20(entity_permission\x20role\x20flags)'],'ROLE_ADMIN':['permission-context.ts\x20(entity_permission\x20role\x20flags)'],'ROLE_ENTITY':['permission-context.ts\x20(entity_permission\x20role\x20flags)']};export function getOnchainConstant(a){const b=ONCHAIN_CONSTANTS[a];if(b===undefined)throw new Error('Unknown\x20on-chain\x20constant:\x20'+String(a));return b;}
|
|
1
|
+
import{ONCHAIN_CONSTANTS,MAX_NODE_COUNT,MAX_NODE_COUNT_ONCHAIN,MAX_FORWARD_COUNT,MAX_FORWARD_ORDER_COUNT,MAX_NODE_PAIR_COUNT,MAX_CONSENSUS_REPOSITORIES_COUNT,USER_DEFINED_PERM_INDEX_START,MAX_PERM_FOR_ENTITY,MAX_ADMIN_COUNT,MAX_ITEM_COUNT,ROLE_OWNER,ROLE_ADMIN,ROLE_ENTITY,MAX_AGENT_COUNT,MAX_DISPUTE_COUNT,MAX_SHARING_COUNT,MAX_VOTING_GUARD_COUNT,MAX_POLICY_COUNT,MAX_ID_COUNT_ONCE,MAX_REWARD_COUNT,MAX_GUARD_COUNT_REWARD,MAX_RECORD_COUNT_REWARD,MAX_CONTEXT_REPOSITORY_COUNT,MAX_NAMED_OPERATOR_COUNT,MAX_NAMED_OPERATOR_ADDRESS_COUNT,MAX_IM_COUNT,MAX_TAGS_COUNT,MAX_RECIPIENT_COUNT,MAX_PROPOSITION_COUNT,MAX_VOTOR_COUNT,WITHDRAW_DURATION_TIME,MAX_ADDRESS_COUNT,MAX_RECORD_LENGTH,BRIDGE_MESSAGE_VERSION,BRIDGE_EVM_ADDRESS_LENGTH,BRIDGE_CURRENT_VERSION,BRIDGE_TRANSFER_STATUS_PENDING,BRIDGE_TRANSFER_STATUS_APPROVED,BRIDGE_TRANSFER_STATUS_CLAIMED,BRIDGE_TRANSFER_STATUS_NOT_FOUND,MAX_INDEMNITY_MULTIPLE,MAX_PRESENTER_COUNT,MAX_INPUT_SIZE,MAX_TABLE_SIZE,MAX_DEPENDED_COUNT,MAX_DISCOUNT_TOTAL_COUNT,MAX_USER_IDENTIFIER}from'@wowok/wowok';export{ONCHAIN_CONSTANTS,MAX_NODE_COUNT,MAX_NODE_COUNT_ONCHAIN,MAX_FORWARD_COUNT,MAX_FORWARD_ORDER_COUNT,MAX_NODE_PAIR_COUNT,MAX_CONSENSUS_REPOSITORIES_COUNT,USER_DEFINED_PERM_INDEX_START,MAX_PERM_FOR_ENTITY,MAX_ADMIN_COUNT,MAX_ITEM_COUNT,ROLE_OWNER,ROLE_ADMIN,ROLE_ENTITY,MAX_AGENT_COUNT,MAX_DISPUTE_COUNT,MAX_SHARING_COUNT,MAX_VOTING_GUARD_COUNT,MAX_POLICY_COUNT,MAX_ID_COUNT_ONCE,MAX_REWARD_COUNT,MAX_GUARD_COUNT_REWARD,MAX_RECORD_COUNT_REWARD,MAX_CONTEXT_REPOSITORY_COUNT,MAX_NAMED_OPERATOR_COUNT,MAX_NAMED_OPERATOR_ADDRESS_COUNT,MAX_IM_COUNT,MAX_TAGS_COUNT,MAX_RECIPIENT_COUNT,MAX_PROPOSITION_COUNT,MAX_VOTOR_COUNT,WITHDRAW_DURATION_TIME,MAX_INDEMNITY_MULTIPLE,MAX_PRESENTER_COUNT,MAX_INPUT_SIZE,MAX_TABLE_SIZE,MAX_DEPENDED_COUNT,MAX_DISCOUNT_TOTAL_COUNT,MAX_USER_IDENTIFIER,MAX_ADDRESS_COUNT,MAX_RECORD_LENGTH,BRIDGE_MESSAGE_VERSION,BRIDGE_EVM_ADDRESS_LENGTH,BRIDGE_CURRENT_VERSION,BRIDGE_TRANSFER_STATUS_PENDING,BRIDGE_TRANSFER_STATUS_APPROVED,BRIDGE_TRANSFER_STATUS_CLAIMED,BRIDGE_TRANSFER_STATUS_NOT_FOUND};export const ONCHAIN_CONSTANT_MCP_CONSUMERS={'MAX_NODE_COUNT':['machine-topology.ts\x20(within_limits\x20check)','machine-risk.ts\x20R-M1-07','machine-translation.ts\x20MC-C-01','knowledge/index.ts\x20(max_node_count\x20field)'],'MAX_FORWARD_ORDER_COUNT':[],'MAX_NODE_PAIR_COUNT':['machine-topology.ts\x20(within_limits\x20check)'],'USER_DEFINED_PERM_INDEX_START':['machine-risk.ts\x20R-M3-08','guard-risk.ts\x20(forward\x20permissionIndex\x20guidance)'],'MAX_VOTING_GUARD_COUNT':['evaluation/builtins/arbitration-score.ts\x20(fairness_governance\x20reason)'],'MAX_ITEM_COUNT':['permission-context.ts\x20(entity_permission\x20reverse\x20index)'],'ROLE_OWNER':['permission-context.ts\x20(entity_permission\x20role\x20flags)'],'ROLE_ADMIN':['permission-context.ts\x20(entity_permission\x20role\x20flags)'],'ROLE_ENTITY':['permission-context.ts\x20(entity_permission\x20role\x20flags)']};export function getOnchainConstant(a){const b=ONCHAIN_CONSTANTS[a];if(b===undefined)throw new Error('Unknown\x20on-chain\x20constant:\x20'+String(a));return b;}
|
|
@@ -14,10 +14,14 @@ export interface ModeAllocatorRow {
|
|
|
14
14
|
mode: "amount" | "rate" | "surplus";
|
|
15
15
|
value?: string | number;
|
|
16
16
|
value_from?: string;
|
|
17
|
+
fix?: string | number;
|
|
18
|
+
fix_from?: string;
|
|
19
|
+
guard_key?: string;
|
|
17
20
|
note?: string;
|
|
18
21
|
}
|
|
19
22
|
export interface ModeAllocatorStrategy {
|
|
20
23
|
recipient: "signer" | "entity" | "fixed";
|
|
24
|
+
recipient_key?: string;
|
|
21
25
|
refund_track?: "order_anchored";
|
|
22
26
|
count: number;
|
|
23
27
|
mode: "amount" | "rate" | "surplus";
|
|
@@ -29,12 +33,21 @@ export interface ModeGuardRef {
|
|
|
29
33
|
template_id: string;
|
|
30
34
|
host: "service" | "machine" | "reward" | "repository" | "arbitration";
|
|
31
35
|
purpose: string;
|
|
36
|
+
key?: string;
|
|
32
37
|
}
|
|
33
38
|
export interface ModeMachineNode {
|
|
34
39
|
name: string;
|
|
35
40
|
role: string;
|
|
36
41
|
operator?: "merchant" | "order_payer";
|
|
37
42
|
semantic_role?: "draft" | "active" | "delivered" | "final" | "cancelled";
|
|
43
|
+
from?: (string | ModeMachineEdge)[];
|
|
44
|
+
}
|
|
45
|
+
export interface ModeMachineEdge {
|
|
46
|
+
prev: string;
|
|
47
|
+
forward?: string;
|
|
48
|
+
operator?: "merchant" | "order_payer";
|
|
49
|
+
permission_index?: number;
|
|
50
|
+
guard_key?: string;
|
|
38
51
|
}
|
|
39
52
|
export declare const BUYER_ACTION_NODE_RE: RegExp;
|
|
40
53
|
export declare function unannotatedBuyerActionNodes(shape: ReadonlyArray<{
|