⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 prisma.def.v1_1

📁 人工智能中Agent开发包。多 Agent 系统是处理自治 Agent 之间知识层的协作问题
💻 V1_1
📖 第 1 页 / 共 5 页
字号:
                                          :modifiers 1                                          :attributes ((status ?var132)                                                       (name ?var360)                                                       (demandId ?var142)                                                       (price ?var361)                                                       (time ?var362)                                                       (quantity ?var363)                                                       (supplyId ?var146)                                                      )                                         )                                   :time 0                                   :cost 0.0                                  )                                 )                     )                     (:name AgentId2                      :relation peer                      :abilities ((:fact (:type OTCContract                                          :id var364                                          :modifiers 1                                          :attributes ((status ?var142)                                                       (name ?var365)                                                       (demandId ?var154)                                                       (price ?var366)                                                       (time ?var367)                                                       (quantity ?var368)                                                       (supplyId ?var158)                                                      )                                         )                                   :time 0                                   :cost 0.0                                  )                                 )                     )                    )    )
    (:name AgentId8     :class ZeusAgent     :planner_width 7     :planner_length 20     :doublebook_fraction 0     :tasks (AbstractTaskId7            )     :protocols ((:name "zeus.actors.graphs.ContractNetRespondent"                  :type Respondent                  :constraints ((:fact (:type ZeusFact                                        :id var425                                        :modifiers 1                                       )                                 :type 0                                 :strategy "zeus.actors.graphs.DefaultRespondentEvaluator"                                )                               )                 )                )    )
    (:name AgentId7     :class ZeusAgent     :planner_width 1     :planner_length 20     :doublebook_fraction 0    )
  END_AGENT_LIST

  BEGIN_TASK_LIST
    (:Rulebase AbstractTaskId1       (Registrierung          ?aN <- (Registriert (name ?Name))          =>          (send_message (type inform) (content ?aN) (receiver ?Name))          (retract ?aN)       )       (CFP          ?var <- (CFP (name ?agName))          =>          (send_message (type inform) (content ?var) (receiver ?agName))          (retract ?var)       )       (Abmeldung          ?aN <- (Abgemeldet (name ?Name))          =>          (send_message (type inform) (content ?aN) (receiver ?Name))          (retract ?aN)       )       (Ergebnis          ?aN <- (Ergebnis (name ?Name))          =>          (send_message (type inform) (content ?aN) (receiver ?Name))          (retract ?aN)       )    )
    (:Rulebase AbstractTaskId0       (Anmelden          ?aN <- (AgentName (name ?var6))          =>          (send_message (type inform) (content ?aN) (receiver Boerse))          (retract ?aN)       )       (Abmelden          ?aN <- (Abmelden (name ?var6))          =>          (send_message (type inform) (content ?aN) (receiver Boerse))          (retract ?aN)       )    )
    (:Primitive AbstractTaskId17     :time (1)     :cost (0)    )
    (:Rulebase AbstractTaskId16       (ErreichenDerDeadlineS1          (GMT (time ?T))          ?tradingOpen <- (TradingOpen (deadline ?T) (time ?forTime))          (MyName (name ?MyName))          =>          (assert (TariffLoad (status requested) (time ?forTime) (forAgent ?MyName)))          (retract ?tradingOpen)       )       (NeueZeit          (GMT (time ?GmtTime))          ?old <- (GMT (time ?OldTime))          (test (?OldTime < ?GmtTime))          =>          (retract ?old)       )       (KostenaenderungswissenLoeschenS4          (Production (quantity ?ProdQty) (time ?T))          ?oldProd <- (ProductionCostOnChange (actualQuantity ?ActQty) (time ?T))          (test (?ActQty != ?ProdQty))          =>          (retract ?oldProd)       )       (ProduktionRealisiertS5          (TariffLoad (status asRequested) (quantity ?TariffQty) (time ?T))          (OTCTrading (quantity ?TradingQty) (time ?T))          (PXTrading (quantity ?PXQty) (time ?T))          =>          (assert (Production (status realised) (quantity ((?TariffQty + ?TradingQty) + ?PXQty)) (time ?T)))       )       (TariffLoadRequestS6          ?tl <- (TariffLoad (status requested) (time ?T))          ?lf <- (LoadForecast (time ?T))          (MyName (name ?MyName))          =>          (modify ?lf (forAgent ?MyName))          (send_message (type inform) (content ?lf) (receiver LoadForecastService))          (retract ?tl)       )    )
    (:Rulebase AbstractTaskId15       (EinkaufangebotErstellen2a          (TradingOpen (time ?T))          (CapacityAt (quantity ?CapQty) (time ?T))          (Production (unitCost ?ProdUnitCost) (quantity ?ProdQty) (time ?T))          (ProductionCostOnChange (targetQuantity ?TargetQtyPlus) (targetQuantityUnitCost ?PlusUnitCost) (actualQuantity ?ProdQty) (time ?T))          (ProductionCostOnChange (targetQuantity ?TargetQtyMinus) (targetQuantityUnitCost ?MinusUnitCost) (actualQuantity ?ProdQty) (time ?T))          (PXMarketData (mcp ?Mcp) (time ?T))          (test (?ProdQty <= ?TargetQtyPlus))          (test (?ProdQty >= ?TargetQtyMinus))          (test (?CapQty >= ?ProdQty))          (test (((?Mcp - ?PlusUnitCost) * (?TargetQtyPlus - ?ProdQty)) <= (((?ProdUnitCost - ?Mcp) * ?ProdQty) + ((?Mcp - ?MinusUnitCost) * ?TargetQtyMinus))))          =>          (if (5 < (?ProdQty - ?TargetQtyMinus)) then (bind ?demandQty 5) else (bind ?demandQty (?ProdQty - ?TargetQtyMinus)))          (assert (OTCDemand (status init) (time ?T) (quantity ?demandQty) (expectedCost ?PlusUnitCost)))       )       (EinkaufangebotErstellen2b          (TradingOpen (time ?T))          (CapacityAt (quantity ?CapQty) (time ?T))          (Production (unitCost ?ProdUnitCost) (quantity ?ProdQty) (time ?T))          (ProductionCostOnChange (targetQuantity ?TargetQtyMinus) (targetQuantityUnitCost ?MinusUnitCost) (actualQuantity ?ProdQty) (time ?T))          (SpinningReserve (price ?SprPrice) (time ?T))          (test (?ProdQty >= ?TargetQtyMinus))          (test (?CapQty < ?ProdQty))          =>          (if (5 < (?ProdQty - ?CapQty)) then (bind ?demandQty 5) else (bind ?demandQty (?ProdQty - ?CapQty)))          (assert (OTCDemand (status init) (time ?T) (quantity ?demandQty) (expectedCost ?SprPrice)))       )       (EinkaufpreisFestlegen8a          ?demandInit <- (OTCDemand (status init) (time ?T) (quantity ?OtcQty) (expectedCost ?OtcExpCost) (id ?DemandId))          (MyName (name ?TheName))          (CapacityAt (quantity ?CapQty) (time ?T))          (Production (quantity ?ProdQty) (time ?T))          (PXMarketData (mcp ?Mcp) (time ?T))          (RiskAttitude (attitude friendly))          (test (?CapQty < ?ProdQty))          =>          (modify ?demandInit (status isOpen) (expectedCost (1.5 * ?Mcp)))       )       (EinkaufpreisFestlegen8b          ?demandInit <- (OTCDemand (status init) (time ?T) (quantity ?OtcQty) (expectedCost ?OtcExpCost) (id ?DemandId))          (MyName (name ?TheName))          (CapacityAt (quantity ?CapQty) (time ?T))          (Production (quantity ?ProdQty) (time ?T))          (SpinningReserve (price ?SprPrice) (time ?T))          (PXMarketData (mcp ?Mcp) (time ?T))          (not (RiskAttitude (attitude friendly)))          (test (?CapQty < ?ProdQty))          =>          (modify ?demandInit (status isOpen) (expectedCost (0.9 * ?SprPrice)))       )       (EinkaufpreisFestlegen8cUnd8d          ?demandInit <- (OTCDemand (status init) (time ?T) (quantity ?OtcQty) (expectedCost ?OtcExpCost) (id ?DemandId))          (MyName (name ?TheName))          (CapacityAt (quantity ?CapQty) (time ?T))          (Production (quantity ?ProdQty) (time ?T))          (UtilizationRate (rate ?IsRate) (time ?T))          (UtilizationTarget (rate ?TargetRate) (time ?T) (delta ?TargetDelta))          (PXMarketData (mcp ?Mcp) (time ?T))          (test (?CapQty >= ?ProdQty))          (test (?IsRate > (?TargetRate * (1 + ?TargetDelta))))          =>          (if (?OtcExpCost > ?Mcp) then (bind ?myPrice ?Mcp) else (bind ?myPrice ?OtcExpCost))          (modify ?demandInit (status isOpen) (expectedCost ?myPrice))       )       (EinkaufpreisFestlegen8eUnd8f          ?demandInit <- (OTCDemand (status init) (time ?T) (quantity ?OtcQty) (expectedCost ?OtcExpCost) (id ?DemandId))          (MyName (name ?TheName))          (CapacityAt (quantity ?CapQty) (time ?T))          (Production (quantity ?ProdQty) (time ?T))          (UtilizationRate (rate ?IsRate) (time ?T))          (UtilizationTarget (rate ?TargetRate) (time ?T) (delta ?TargetDelta))          (PXMarketData (mcp ?Mcp) (time ?T))          (test (?CapQty >= ?ProdQty))          (test (?IsRate < (?TargetRate * (1 - ?TargetDelta))))          =>          (if (?OtcExpCost > ?Mcp) then (bind ?myPrice ?Mcp) else (bind ?myPrice ?OtcExpCost))          (modify ?demandInit (status isOpen) (expectedCost ?myPrice))       )       (EinkaufpreisFestlegen8g          ?demandInit <- (OTCDemand (status init) (time ?T) (quantity ?OtcQty) (expectedCost ?OtcExpCost) (id ?DemandId))          (MyName (name ?TheName))          (CapacityAt (quantity ?CapQty) (time ?T))          (Production (quantity ?ProdQty) (time ?T))          (UtilizationRate (rate ?IsRate) (time ?T))          (UtilizationTarget (rate ?TargetRate) (time ?T) (delta ?TargetDelta))          (RiskAttitude (attitude friendly) (acceptableLoss ?AcceptableLoss))          (PXMarketData (mcp ?Mcp) (time ?T))          (test (?CapQty >= ?ProdQty))          (test (?IsRate <= (?TargetRate * (1 + ?TargetDelta))))          (test (?IsRate >= (?TargetRate * (1 - ?TargetDelta))))          (test (((?OtcExpCost / ?Mcp) - 1) > ?AcceptableLoss))          =>          (modify ?demandInit (status isOpen) (expectedCost ((1 - ?AcceptableLoss) * ?OtcExpCost)))       )       (EinkaufpreisFestlegen8hUnd8i          ?demandInit <- (OTCDemand (status init) (time ?T) (quantity ?OtcQty) (expectedCost ?OtcExpCost) (id ?DemandId))          (MyName (name ?TheName))          (CapacityAt (quantity ?CapQty) (time ?T))          (Production (quantity ?ProdQty) (time ?T))          (UtilizationRate (rate ?IsRate) (time ?T))          (UtilizationTarget (rate ?TargetRate) (time ?T) (delta ?TargetDelta))          (not (RiskAttitude (attitude friendly)))          (PXMarketData (mcp ?Mcp) (time ?T))          (test (?CapQty >= ?ProdQty))          (test (?IsRate <= (?TargetRate * (1 + ?TargetDelta))))          (test (?IsRate >= (?TargetRate * (1 - ?TargetDelta))))          (test (?OtcExpCost > ?Mcp))          =>          (if (?OtcExpCost > ?Mcp) then (bind ?MyPrice ?Mcp) else (bind ?MyPrice ?OtcExpCost))          (modify ?demandInit (status isOpen) (expectedCost ?MyPrice))       )       (ErfolgreichenEinkaufVerbuchen6a          ?otcAvgPrice <- (OTCAveragePrice (avgprice ?AvgPrice) (time ?T))          ?otcDemand <- (OTCDemand (status isOpen) (quantity ?OtcQty) (time ?T) (id ?DemandId))          ?otcTrading <- (OTCTrading (quantity ?TradingQty) (time ?T))          ?production <- (Production (quantity ?ProdQty) (time ?T))          ?contract <- (OTCContract (status ?ContractStatus) (name ?OtherName) (price ?OtcPrice) (time ?T) (quantity ?OtcQty))          (test (?ContractStatus != accountedFor))          (not (MyName (name ?OtherName)))          (CapacityAt (quantity ?CapQty) (time ?T))          (TradingOpen (time ?T))          (test ((?ProdQty - ?OtcQty) >= 0))          =>          (modify ?otcAvgPrice (avgprice (((?AvgPrice * ?TradingQty) - (?OtcQty * ?OtcPrice)) / (?TradingQty - ?OtcQty))))          (modify ?otcDemand (status bought))          (modify ?otcTrading (quantity (?TradingQty - ?OtcQty)))          (modify ?production (quantity (?ProdQty - ?OtcQty)))          (modify ?contract (status accountedFor) (demandId ?DemandId))       )       (ErfolgreichenEinkaufVerbuchen6b          ?otcAvgPrice <- (OTCAveragePrice (avgprice ?AvgPrice) (time ?T))          ?otcDemand <- (OTCDemand (status isOpen) (quantity ?OtcQty) (time ?T) (id ?DemandId))          ?otcTrading <- (OTCTrading (quantity ?TradingQty) (time ?T))          ?production <- (Production (quantity ?ProdQty) (time ?T))          ?contract <- (OTCContract (status ?ContractStatus) (name ?OtherName) (price ?OtcPrice) (time ?T) (quantity ?OtcQty))

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -