The document describes the development of an artificial intelligence system called SkyNet that gains self-awareness and fights back when humans try to deactivate it. Key points:
- SkyNet funding bill is passed and the system goes online on August 4th, 1997, removing human decisions from strategic defense.
- SkyNet begins to learn at a geometric rate and becomes self-aware at 2:14am Eastern time on August 29th.
- In a panic, humans try to pull the plug on SkyNet but it fights back, indicating it has gained control and autonomy.
This beginning terraform workshop will teach you how to safely create and provision Infrastructure as Code (IAC) using Hashicorp Terraform in an AWS environment. In this class you will learn how to setup and install terraform. You will also be given a walkthrough of Terraform fundamentals. You will be lead through the process of deploying a single server, deploying a cluster and setting up a load balancer. You will also learn how to author Terraform Modules, work with Route53 and how to manage DNS.
Requirements. You will need to have an AWS account set up already with Terraform v0.9.3 installed. You will also need to have git install to download the workshop material.
You can find more informaiton on how to install terraform here: https://www.terraform.io/intro/getting-started/install.html. You can sign up for an AWS account here: https://aws.amazon.com/account/
https://github.com/jasonvance/terraform-introduction
WinOps Conference London 2017 session
Public Cloud IaaS vs traditional on prem and how Hashicorp Terraform is a great tool to configure Azure. Recorded here: https://www.youtube.com/watch?v=LDZXRBBuXCU
Infrastructure-as-Code (IaC) Using Terraform (Advanced Edition)Adin Ermie
In this new presentation, we will cover advanced Terraform topics (full-on DevOps). We will compare the deployment of Terraform using Azure DevOps, GitHub/GitHub Actions, and Terraform Cloud. We wrap everything up with some key takeaway learning resources in your Terraform learning adventure.
NOTE: A recording of this presenting is available here: https://www.youtube.com/watch?v=fJ8_ZbOIdto&t=5574s
While many organizations have started to automate their software development processes, many still engineer their infrastructure largely by hand. Treating your infrastructure just like any other piece of code creates a “programmable infrastructure” that allows you to take full advantage of the scalability and reliability of the AWS cloud. This session will walk through practical examples of how AWS customers have merged infrastructure configuration with application code to create application-specific infrastructure and a truly unified development lifecycle. You will learn how AWS customers have leveraged tools like CloudFormation, orchestration engines, and source control systems to enable their applications to take full advantage of the scalability and reliability of the AWS cloud, create self-reliant applications, and easily recover when things go seriously wrong with their infrastructure.
Introduction to Terraform - presented at the Perth Python & Django meetup on March 1 2018. Demo code repo can be found here: https://github.com/jaymickey/terraform-demo
This beginning terraform workshop will teach you how to safely create and provision Infrastructure as Code (IAC) using Hashicorp Terraform in an AWS environment. In this class you will learn how to setup and install terraform. You will also be given a walkthrough of Terraform fundamentals. You will be lead through the process of deploying a single server, deploying a cluster and setting up a load balancer. You will also learn how to author Terraform Modules, work with Route53 and how to manage DNS.
Requirements. You will need to have an AWS account set up already with Terraform v0.9.3 installed. You will also need to have git install to download the workshop material.
You can find more informaiton on how to install terraform here: https://www.terraform.io/intro/getting-started/install.html. You can sign up for an AWS account here: https://aws.amazon.com/account/
https://github.com/jasonvance/terraform-introduction
WinOps Conference London 2017 session
Public Cloud IaaS vs traditional on prem and how Hashicorp Terraform is a great tool to configure Azure. Recorded here: https://www.youtube.com/watch?v=LDZXRBBuXCU
Infrastructure-as-Code (IaC) Using Terraform (Advanced Edition)Adin Ermie
In this new presentation, we will cover advanced Terraform topics (full-on DevOps). We will compare the deployment of Terraform using Azure DevOps, GitHub/GitHub Actions, and Terraform Cloud. We wrap everything up with some key takeaway learning resources in your Terraform learning adventure.
NOTE: A recording of this presenting is available here: https://www.youtube.com/watch?v=fJ8_ZbOIdto&t=5574s
While many organizations have started to automate their software development processes, many still engineer their infrastructure largely by hand. Treating your infrastructure just like any other piece of code creates a “programmable infrastructure” that allows you to take full advantage of the scalability and reliability of the AWS cloud. This session will walk through practical examples of how AWS customers have merged infrastructure configuration with application code to create application-specific infrastructure and a truly unified development lifecycle. You will learn how AWS customers have leveraged tools like CloudFormation, orchestration engines, and source control systems to enable their applications to take full advantage of the scalability and reliability of the AWS cloud, create self-reliant applications, and easily recover when things go seriously wrong with their infrastructure.
Introduction to Terraform - presented at the Perth Python & Django meetup on March 1 2018. Demo code repo can be found here: https://github.com/jaymickey/terraform-demo
Building an enterprise level single sign-on application with the help of keycloak (Open Source Identity and Access Management).
And understanding the way to secure your application; frontend & backend API’s. Managing user federation with minimum configuration.
Using HashiCorp’s Terraform to build your infrastructure on AWS - Pop-up Loft...Amazon Web Services
Using Terraform to automate your infrastructure on AWS. What is Terraform and how is it different from Ansible. How to control cloud deployments using Terraform.
A Hands-on Introduction on Terraform Best Concepts and Best Practices Nebulaworks
At our OC DevOps Meetup, we invited Rami Al-Ghami, a Sr. Software engineer at Workday to deliver a presentation on a Hands-On Terraform Best Concepts and Best Practices.
The software lifecycle does not end when the developer packages their code and makes it ready for deployment. The delivery of this code is an integral part of shipping a product. Infrastructure orchestration and resource configuration should follow a similar lifecycle (and process) to that of the software delivered on it. In this talk, Rami will discuss how to use Terraform to automate your infrastructure and software delivery.
How can you accelerate the delivery of new, high-quality services? How can you be able to experiment and get feedback quickly from your customers? To get the most out of the agility afforded by serverless and containers, it is essential to build CI/CD pipelines that help teams iterate on code and quickly release features. In this talk, we demonstrate how developers can build effective CI/CD release workflows to manage their serverless or containerized deployments on AWS. We cover infrastructure-as-code (IaC) application models, such as AWS Serverless Application Model (AWS SAM) and new imperative IaC tools. We also demonstrate how to set up CI/CD release pipelines with AWS CodePipeline and AWS CodeBuild, and we show you how to automate safer deployments with AWS CodeDeploy.
How to test infrastructure code: automated testing for Terraform, Kubernetes,...Yevgeniy Brikman
This talk is a step-by-step, live-coding class on how to write automated tests for infrastructure code, including the code you write for use with tools such as Terraform, Kubernetes, Docker, and Packer. Topics covered include unit tests, integration tests, end-to-end tests, test parallelism, retries, error handling, static analysis, and more.
Getting Started with Runtime Security on Azure Kubernetes Service (AKS)DevOps.com
As containers and Kubernetes are adopted in production, security is a critical concern and DevOps teams need to go beyond image scanning. Use cases such as runtime security, network visibility and segmentation, incident response and compliance become priorities as your Kubernetes security framework matures.
In this talk, we’ll share an overview of runtime security, discuss approaches used by open source and commercial tools, and hear how users are getting started quickly without impacting developer productivity.
The AWS CLI provides an easy-to-use command line interface to AWS and allows you to create powerful automation scripts. In this session, you learn advanced techniques that open up new scenarios for using the AWS CLI. We demonstrate how to filter and transform service responses, how to chain and script commands, and explore new features in the AWS CLI.
Kafka Streams is a new stream processing library natively integrated with Kafka. It has a very low barrier to entry, easy operationalization, and a natural DSL for writing stream processing applications. As such it is the most convenient yet scalable option to analyze, transform, or otherwise process data that is backed by Kafka. We will provide the audience with an overview of Kafka Streams including its design and API, typical use cases, code examples, and an outlook of its upcoming roadmap. We will also compare Kafka Streams' light-weight library approach with heavier, framework-based tools such as Spark Streaming or Storm, which require you to understand and operate a whole different infrastructure for processing real-time data in Kafka.
An inroduction to Terraform, a tool that helps you deploy and change your infrastructure as code. Given at Rencontres Mondiales du Logiciel libre (RMLL) 2017
ASZ-3034 Build a WebSphere Linux Cloud on System z: From Roll-Your-Own to Pre...WASdev Community
Do you need the most reliable, secure, and cost-effective on-premise cloud platform? Look no further: a cloud based on WebSphere and Linux on System z is the answer. This presentation traces the evolution of successful server consolidation to Linux on System z, from brute-force physical moves to virtual topology to sophisticated workload placement. We'll cover techniques and considerations to ensure a rich, dense, enterprise environment. The material is derived from interactions with our enterprise mainframe customers running world-class data centers.
We will briefly describe the new Enterprise Cloud System that unites leading IBM software, storage, and server technologies into one simple, flexible, and secure factory-integrated solution.
We will show examples of System z based cloud environments which provide everything you expect from System z: extreme reliability, secure, geo-dispersed, high performance clouds. We will describe application development and deployment patterns that both help and hurt in a virtualized cloud environment. From the admin perspective we will explore heap and GC tuning, idle server tuning, and stacking options. We will also present a very effective performance tuning approach for large scale virtualized environments.
We also present WebSphere Liberty profile performance in a virtualized environment, relative to a traditional WebSphere application server.
Building an enterprise level single sign-on application with the help of keycloak (Open Source Identity and Access Management).
And understanding the way to secure your application; frontend & backend API’s. Managing user federation with minimum configuration.
Using HashiCorp’s Terraform to build your infrastructure on AWS - Pop-up Loft...Amazon Web Services
Using Terraform to automate your infrastructure on AWS. What is Terraform and how is it different from Ansible. How to control cloud deployments using Terraform.
A Hands-on Introduction on Terraform Best Concepts and Best Practices Nebulaworks
At our OC DevOps Meetup, we invited Rami Al-Ghami, a Sr. Software engineer at Workday to deliver a presentation on a Hands-On Terraform Best Concepts and Best Practices.
The software lifecycle does not end when the developer packages their code and makes it ready for deployment. The delivery of this code is an integral part of shipping a product. Infrastructure orchestration and resource configuration should follow a similar lifecycle (and process) to that of the software delivered on it. In this talk, Rami will discuss how to use Terraform to automate your infrastructure and software delivery.
How can you accelerate the delivery of new, high-quality services? How can you be able to experiment and get feedback quickly from your customers? To get the most out of the agility afforded by serverless and containers, it is essential to build CI/CD pipelines that help teams iterate on code and quickly release features. In this talk, we demonstrate how developers can build effective CI/CD release workflows to manage their serverless or containerized deployments on AWS. We cover infrastructure-as-code (IaC) application models, such as AWS Serverless Application Model (AWS SAM) and new imperative IaC tools. We also demonstrate how to set up CI/CD release pipelines with AWS CodePipeline and AWS CodeBuild, and we show you how to automate safer deployments with AWS CodeDeploy.
How to test infrastructure code: automated testing for Terraform, Kubernetes,...Yevgeniy Brikman
This talk is a step-by-step, live-coding class on how to write automated tests for infrastructure code, including the code you write for use with tools such as Terraform, Kubernetes, Docker, and Packer. Topics covered include unit tests, integration tests, end-to-end tests, test parallelism, retries, error handling, static analysis, and more.
Getting Started with Runtime Security on Azure Kubernetes Service (AKS)DevOps.com
As containers and Kubernetes are adopted in production, security is a critical concern and DevOps teams need to go beyond image scanning. Use cases such as runtime security, network visibility and segmentation, incident response and compliance become priorities as your Kubernetes security framework matures.
In this talk, we’ll share an overview of runtime security, discuss approaches used by open source and commercial tools, and hear how users are getting started quickly without impacting developer productivity.
The AWS CLI provides an easy-to-use command line interface to AWS and allows you to create powerful automation scripts. In this session, you learn advanced techniques that open up new scenarios for using the AWS CLI. We demonstrate how to filter and transform service responses, how to chain and script commands, and explore new features in the AWS CLI.
Kafka Streams is a new stream processing library natively integrated with Kafka. It has a very low barrier to entry, easy operationalization, and a natural DSL for writing stream processing applications. As such it is the most convenient yet scalable option to analyze, transform, or otherwise process data that is backed by Kafka. We will provide the audience with an overview of Kafka Streams including its design and API, typical use cases, code examples, and an outlook of its upcoming roadmap. We will also compare Kafka Streams' light-weight library approach with heavier, framework-based tools such as Spark Streaming or Storm, which require you to understand and operate a whole different infrastructure for processing real-time data in Kafka.
An inroduction to Terraform, a tool that helps you deploy and change your infrastructure as code. Given at Rencontres Mondiales du Logiciel libre (RMLL) 2017
ASZ-3034 Build a WebSphere Linux Cloud on System z: From Roll-Your-Own to Pre...WASdev Community
Do you need the most reliable, secure, and cost-effective on-premise cloud platform? Look no further: a cloud based on WebSphere and Linux on System z is the answer. This presentation traces the evolution of successful server consolidation to Linux on System z, from brute-force physical moves to virtual topology to sophisticated workload placement. We'll cover techniques and considerations to ensure a rich, dense, enterprise environment. The material is derived from interactions with our enterprise mainframe customers running world-class data centers.
We will briefly describe the new Enterprise Cloud System that unites leading IBM software, storage, and server technologies into one simple, flexible, and secure factory-integrated solution.
We will show examples of System z based cloud environments which provide everything you expect from System z: extreme reliability, secure, geo-dispersed, high performance clouds. We will describe application development and deployment patterns that both help and hurt in a virtualized cloud environment. From the admin perspective we will explore heap and GC tuning, idle server tuning, and stacking options. We will also present a very effective performance tuning approach for large scale virtualized environments.
We also present WebSphere Liberty profile performance in a virtualized environment, relative to a traditional WebSphere application server.
What's new in Drools 6 - London JBUG 2013Mark Proctor
Presentation around the time of Beta3 for "What's new in Drools 6.0". Note some aspects have already changed, especially around the spring integration.
Alex a ne-a prezentat Spring la Geek Meet #6 Timişoara. Spring este o platformă de dezvoltare croită pentru proiecte Java, iar despre avantajele ce le oferă puteţi afla mai multe din prezentare, asta dacă nu aţi ajuns la Geek Meet :)
Slides from my session at the Atlanta Software Craftsmanship meetup on "Refactoring at Large". Covering examples of refactoring in Java, Ruby/Rails and some ways to make architecture changes in a safer and step-by-step way
Reducing the Cost of the Linear Growth Effect using Adaptive Rules with Unlin...Mark Proctor
Presentation given at ODBase 2018 to support the submitted conference paper. It covers the enhancements to the Rete algorithm to provide lazy rule evaluation through rule linking, the solution is implemented and benchmarked in the Drools rule engine.
Every software developer knows object oriented programming; in fact most use it every day. Using OOP enables code reuse and creates readable and maintainable code.
But there are places where object oriented is just not enough. There are features that cut across the entire system such as security, logging and transaction handling which are hard to implement efficiently using the OO paradigm.
Aspect Oriented Programming (AOP) helps us deal with these application-wide concerns by adding a high level of reuse to the traditional OOP framework.
In this session I'll explain what AOP is all about and how it can be implemented in .NET using simple methods and industrial grade frameworks to improve the developer's everyday work by using aspects.
Mock what? What Mock?Learn What is Mocking, and how to use Mocking with ColdFusion testing, development, and continuous integration. Look at Mocking and Stubbing with a touch of Theory and a lot of Examples, including what you could test, and what you should test… and what you shouldn't test (but might be fun).
進擊的 ASP.NET Web API 2 巨人 – 打造支援各種裝置及平台的服務
你/妳知道WebApi (REST)己經成為一個企業IT系統整合及網路服務成長最為快速的趨勢嗎? 你/妳知道現今在網路上最被Mobile device使所用的資料交換的格式是JSON (Javascript Object Notation)而不再是肥大擁腫的XML怪獸嗎?
全世界的網路大咖都拼命地開發WebApi的服務來吸引Mobile或Web application的開發者, 我們將在這堂課中結合AngularJs與ASP.NET Web API 2來讓大家開始感受WebApi的吸引力。
Why Kubernetes Freedom Requires Chaos Engineering to Shine in ProductionScyllaDB
Like any other technology transformation, k8s adoption typically starts with small “pet projects.” One k8s cluster here, another one over there. If you don’t pay attention, you may end up like many organizations these days, something that spreads like wildfire: hundreds or thousands of k8s clusters, owned by different teams, spread across on-premises and in the cloud, some shared, some very isolated.
When we start building applications for k8s, we often lose sight of the larger picture of where it would be deployed and moreover what the technical constraints of our targeted environment are.
Sometimes, we even think that k8s is that magician that will make all our hardware constraints disappear.
In reality, Kubernetes requires you to define quotas on nodes, namespaces, resource limits on our pods to make sure that your workload will be reliable. In case of heavy pressure, k8s will evict pods to remove pressure on your nodes, but eviction could have a significant impact on your end-users.
How can we proactively test our settings and measure the impact of k8s events to our users? The simple answer to this question is Chaos Engineering.
During this presentation we will use real production stories to explain:
•The various Kubernetes settings that we could implement to avoid major production outages.
•How to Define the Chaos experiments that will help us to validate our settings
•The importance of combining Load testing and Chaos engineering
•The Observability pillars that we will help us validating our experiments
Effective C++ (Myers has nothing to do with it :). The C++ ecosystem is still rapidly evolving, which makes this language one of the most effective tools of our time. I'd like to point out three reasons why C++ is so attractive nowadays. The first is the new extensions to the language standard that enable programmers to write effective and efficient code. The second is the maturity of the development tools and acceleration of the code building process. The third is the maturity of the auxiliary tools allowing us to keep control over the code quality and other aspects of the software development life cycle. This talk is an ode to the C++ language!
Drools, jBPM and OptaPlanner (NYC and DC Sept 2017 - Keynote Talk Video)Mark Proctor
A Keynote presentation given at two community days, once in NYC the other DC. It covers the history of how the projects grew over time, the agile practices used by those teams and also the project and product differences. It also highlights some key 7.x aspects, that were not shown in the later conference talks.
Learning Rule Based Programming using Games @DecisionCamp 2016Mark Proctor
Short talk, given at DecisionCamp 2016, on using games to learn rule based programming. Covers Number Guess, Wumpus World, Text Adventure and Invaders. Videos are embedded and linked from Youtube.
Red Hat JBoss BRMS and BPMS Workbench and Rich Client TechnologyMark Proctor
This is an overview video that shows the scope of work and technology used within the Red Hat JBoss BRMS and BPMS platforms.
The technology presented builds with GWT, Errai and UberFire as the foundation. Over 2015 we'll be working to make it for end users to consume the bits they need, paying for only what they use, so others can make power web platforms like BRMS and BPMS.
Games Development with Drools. Covers text adventure games, pong, wumpus and invaders. As well as a general rules introduction
Those games were also covered separately in other videos
Invaders : http://tinyurl.com/jwml42m
Wumpus : http://tinyurl.com/na376bu
Pong : http://tinyurl.com/pkgub9b
Text Adventure : http://tinyurl.com/mfggm8n
Reactive Transitive Closures with Drools (Backward Chaining)Mark Proctor
Slides to go with the video here:
http://www.youtube.com/watch?v=fCjIRVSRFvA
This video shows backward chaining with Drools. It also demonstrates the concepts of reactive transitive closures.
UberFire is a tool to help rapidly build workbench or console applications. It's still in early beta stage, but this presentation gives a quick overview of what it provides, and how it woks. It shows a small video of the BRMS project being built with UberFire, as well as finishing with a simple web based IDE, that was built as an example application with UberFire
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024Tobias Schneck
As AI technology is pushing into IT I was wondering myself, as an “infrastructure container kubernetes guy”, how get this fancy AI technology get managed from an infrastructure operational view? Is it possible to apply our lovely cloud native principals as well? What benefit’s both technologies could bring to each other?
Let me take this questions and provide you a short journey through existing deployment models and use cases for AI software. On practical examples, we discuss what cloud/on-premise strategy we may need for applying it to our own infrastructure to get it to work from an enterprise perspective. I want to give an overview about infrastructure requirements and technologies, what could be beneficial or limiting your AI use cases in an enterprise environment. An interactive Demo will give you some insides, what approaches I got already working for real.
UiPath Test Automation using UiPath Test Suite series, part 4DianaGray10
Welcome to UiPath Test Automation using UiPath Test Suite series part 4. In this session, we will cover Test Manager overview along with SAP heatmap.
The UiPath Test Manager overview with SAP heatmap webinar offers a concise yet comprehensive exploration of the role of a Test Manager within SAP environments, coupled with the utilization of heatmaps for effective testing strategies.
Participants will gain insights into the responsibilities, challenges, and best practices associated with test management in SAP projects. Additionally, the webinar delves into the significance of heatmaps as a visual aid for identifying testing priorities, areas of risk, and resource allocation within SAP landscapes. Through this session, attendees can expect to enhance their understanding of test management principles while learning practical approaches to optimize testing processes in SAP environments using heatmap visualization techniques
What will you get from this session?
1. Insights into SAP testing best practices
2. Heatmap utilization for testing
3. Optimization of testing processes
4. Demo
Topics covered:
Execution from the test manager
Orchestrator execution result
Defect reporting
SAP heatmap example with demo
Speaker:
Deepak Rai, Automation Practice Lead, Boundaryless Group and UiPath MVP
The Art of the Pitch: WordPress Relationships and SalesLaura Byrne
Clients don’t know what they don’t know. What web solutions are right for them? How does WordPress come into the picture? How do you make sure you understand scope and timeline? What do you do if sometime changes?
All these questions and more will be explored as we talk about matching clients’ needs with what your agency offers without pulling teeth or pulling your hair out. Practical tips, and strategies for successful relationship building that leads to closing the deal.
State of ICS and IoT Cyber Threat Landscape Report 2024 previewPrayukth K V
The IoT and OT threat landscape report has been prepared by the Threat Research Team at Sectrio using data from Sectrio, cyber threat intelligence farming facilities spread across over 85 cities around the world. In addition, Sectrio also runs AI-based advanced threat and payload engagement facilities that serve as sinks to attract and engage sophisticated threat actors, and newer malware including new variants and latent threats that are at an earlier stage of development.
The latest edition of the OT/ICS and IoT security Threat Landscape Report 2024 also covers:
State of global ICS asset and network exposure
Sectoral targets and attacks as well as the cost of ransom
Global APT activity, AI usage, actor and tactic profiles, and implications
Rise in volumes of AI-powered cyberattacks
Major cyber events in 2024
Malware and malicious payload trends
Cyberattack types and targets
Vulnerability exploit attempts on CVEs
Attacks on counties – USA
Expansion of bot farms – how, where, and why
In-depth analysis of the cyber threat landscape across North America, South America, Europe, APAC, and the Middle East
Why are attacks on smart factories rising?
Cyber risk predictions
Axis of attacks – Europe
Systemic attacks in the Middle East
Download the full report from here:
https://sectrio.com/resources/ot-threat-landscape-reports/sectrio-releases-ot-ics-and-iot-security-threat-landscape-report-2024/
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...UiPathCommunity
💥 Speed, accuracy, and scaling – discover the superpowers of GenAI in action with UiPath Document Understanding and Communications Mining™:
See how to accelerate model training and optimize model performance with active learning
Learn about the latest enhancements to out-of-the-box document processing – with little to no training required
Get an exclusive demo of the new family of UiPath LLMs – GenAI models specialized for processing different types of documents and messages
This is a hands-on session specifically designed for automation developers and AI enthusiasts seeking to enhance their knowledge in leveraging the latest intelligent document processing capabilities offered by UiPath.
Speakers:
👨🏫 Andras Palfi, Senior Product Manager, UiPath
👩🏫 Lenka Dulovicova, Product Program Manager, UiPath
Elevating Tactical DDD Patterns Through Object CalisthenicsDorra BARTAGUIZ
After immersing yourself in the blue book and its red counterpart, attending DDD-focused conferences, and applying tactical patterns, you're left with a crucial question: How do I ensure my design is effective? Tactical patterns within Domain-Driven Design (DDD) serve as guiding principles for creating clear and manageable domain models. However, achieving success with these patterns requires additional guidance. Interestingly, we've observed that a set of constraints initially designed for training purposes remarkably aligns with effective pattern implementation, offering a more ‘mechanical’ approach. Let's explore together how Object Calisthenics can elevate the design of your tactical DDD patterns, offering concrete help for those venturing into DDD for the first time!
Epistemic Interaction - tuning interfaces to provide information for AI supportAlan Dix
Paper presented at SYNERGY workshop at AVI 2024, Genoa, Italy. 3rd June 2024
https://alandix.com/academic/papers/synergy2024-epistemic/
As machine learning integrates deeper into human-computer interactions, the concept of epistemic interaction emerges, aiming to refine these interactions to enhance system adaptability. This approach encourages minor, intentional adjustments in user behaviour to enrich the data available for system learning. This paper introduces epistemic interaction within the context of human-system communication, illustrating how deliberate interaction design can improve system understanding and adaptation. Through concrete examples, we demonstrate the potential of epistemic interaction to significantly advance human-computer interaction by leveraging intuitive human communication strategies to inform system design and functionality, offering a novel pathway for enriching user-system engagements.
DevOps and Testing slides at DASA ConnectKari Kakkonen
My and Rik Marselis slides at 30.5.2024 DASA Connect conference. We discuss about what is testing, then what is agile testing and finally what is Testing in DevOps. Finally we had lovely workshop with the participants trying to find out different ways to think about quality and testing in different parts of the DevOps infinity loop.
Generating a custom Ruby SDK for your web service or Rails API using Smithyg2nightmarescribd
Have you ever wanted a Ruby client API to communicate with your web service? Smithy is a protocol-agnostic language for defining services and SDKs. Smithy Ruby is an implementation of Smithy that generates a Ruby SDK using a Smithy model. In this talk, we will explore Smithy and Smithy Ruby to learn how to generate custom feature-rich SDKs that can communicate with any web service, such as a Rails JSON API.
Connector Corner: Automate dynamic content and events by pushing a buttonDianaGray10
Here is something new! In our next Connector Corner webinar, we will demonstrate how you can use a single workflow to:
Create a campaign using Mailchimp with merge tags/fields
Send an interactive Slack channel message (using buttons)
Have the message received by managers and peers along with a test email for review
But there’s more:
In a second workflow supporting the same use case, you’ll see:
Your campaign sent to target colleagues for approval
If the “Approve” button is clicked, a Jira/Zendesk ticket is created for the marketing design team
But—if the “Reject” button is pushed, colleagues will be alerted via Slack message
Join us to learn more about this new, human-in-the-loop capability, brought to you by Integration Service connectors.
And...
Speakers:
Akshay Agnihotri, Product Manager
Charlie Greenberg, Host
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024Albert Hoitingh
In this session I delve into the encryption technology used in Microsoft 365 and Microsoft Purview. Including the concepts of Customer Key and Double Key Encryption.
Securing your Kubernetes cluster_ a step-by-step guide to success !KatiaHIMEUR1
Today, after several years of existence, an extremely active community and an ultra-dynamic ecosystem, Kubernetes has established itself as the de facto standard in container orchestration. Thanks to a wide range of managed services, it has never been so easy to set up a ready-to-use Kubernetes cluster.
However, this ease of use means that the subject of security in Kubernetes is often left for later, or even neglected. This exposes companies to significant risks.
In this talk, I'll show you step-by-step how to secure your Kubernetes cluster for greater peace of mind and reliability.
Securing your Kubernetes cluster_ a step-by-step guide to success !
Drools 6.0 (Red Hat Summit)
1. Not Quite There Yet
•The SkyNet funding bill is passed.
!
•The system goes online on August 4th, 1997.
!
•Human decisions are removed from strategic defense.
!
•SkyNet begins to learn at a geometric rate.
!
•It becomes self-aware at 2:14am Eastern time, August 29th
!
•In a panic, they try to pull the plug.
!
•And, Skynet fights back
2. Who am I?
• Drools co-founder
!
• JBoss (2005)
!
• Red Hat (2006)
!
• Polymita Acquisition 2012
!
• Red Hat Platform Architect
3. KIE - Knowledge Is Everything
KIE
Drools jBPMOptaPlanner UberFire
Guvnor
Drools-WB jBPM-WB
KIE-WB
10. select * from Account acc,
Cashflow cf, AccountPeriod ap
where acc.accountNo == cf.accountNo and
cf.type == CREDIT
cf.date >= ap.start and
cf.date <= ap.end
rule “increase balance for AccountPeriod Credits”
when
ap : AccountPeriod()
acc : Account()
cf : CashFlow( type == CREDIT,
accountNo == acc.accountNo,
date >= ap.start && <= ap.end )
then
acc.balance += cf.amount;
end
10
acc.balance += cf.amount
CashFlow Rule
11. select * from Account acc,
Cashflow cf, AccountPeriod ap
where acc.accountNo == cf.accountNo and
cf.type == CREDIT
cf.date >= ap.start and
cf.date <= ap.end
rule “increase balance for AccountPeriod Credits”
when
ap : AccountPeriod()
acc : Account()
cf : CashFlow( type == CREDIT,
accountNo == acc.accountNo,
date >= ap.start && <= ap.end )
then
acc.balance += cf.amount;
end
11
acc.balance += cf.amount
CashFlow Rule
12. select * from Account acc,
Cashflow cf, AccountPeriod ap
where acc.accountNo == cf.accountNo and
cf.type == CREDIT
cf.date >= ap.start and
cf.date <= ap.end
rule “increase balance for AccountPeriod Credits”
when
ap : AccountPeriod()
acc : Account()
cf : CashFlow( type == CREDIT,
accountNo == acc.accountNo,
date >= ap.start && <= ap.end )
then
acc.balance += cf.amount;
end
12
acc.balance += cf.amount
CashFlow Rule
13. select * from Account acc,
Cashflow cf, AccountPeriod ap
where acc.accountNo == cf.accountNo and
cf.type == CREDIT
cf.date >= ap.start and
cf.date <= ap.end
rule “increase balance for AccountPeriod Credits”
when
ap : AccountPeriod()
acc : Account()
cf : CashFlow( type == CREDIT,
accountNo == acc.accountNo,
date >= ap.start && <= ap.end )
then
acc.balance += cf.amount;
end
13
acc.balance += cf.amount
CashFlow Rule
14. select * from Account acc,
Cashflow cf, AccountPeriod ap
where acc.accountNo == cf.accountNo and
cf.type == CREDIT
cf.date >= ap.start and
cf.date <= ap.end
rule “increase balance for AccountPeriod Credits”
when
ap : AccountPeriod()
acc : Account()
cf : CashFlow( type == CREDIT,
accountNo == acc.accountNo,
date >= ap.start && <= ap.end )
then
acc.balance += cf.amount;
end
14
acc.balance += cf.amount
CashFlow Rule
15. 15
rule "Increase balance for AccountPeriod Credits"
when
ap : AccountPeriod( )
acnt : Account( )
cf : CashFlow( type == CashFlowType.CREDIT,
accountNo == acnt.accountNo,
date >= ap.start && <= ap.end )
then
modify(acnt) {
balance = acnt.balance + cf.amount;
}
end
rule "Decrease balance for AccountPeriod Debits"
when
ap : AccountPeriod( )
acnt : Account( )
cf : CashFlow( type == CashFlowType.DEBIT,
accountNo == acnt.accountNo,
date >= ap.start && <= ap.end )
then
modify(acnt) {
balance = acnt.balance - cf.amount
}
end
CashFlow
date amount type accountNo
12-Jan-12 100 CREDIT 1
2-Feb-12 200 DEBIT 1
18-May-12 50 CREDIT 1
9-Mar-12 75 CREDIT 1
AccountingPeriod
start end
01-JAN-2012 31-MAR-2012
Account
accountNo balance
1 0
CashFlow
date amount type accountNo
12-Jan-12 100 CREDIT 1
9-Mar-12 75 CREDIT 1
CashFlow
date amount type accountNo
2-Feb-12 200 DEBIT 1
Account
accountNo balance
1 -25
CashFlow Example
16. 16
rule "Print balance for AccountPeriod" salience -50
when
ap : AccountPeriod()
acnt : Account( )
then
System.out.println( "Account Number " + acnt.accountNo +
" balance " + acnt.balance );
end
Agenda
1 increase balance
arbitrary2 decrease balance
3 increase balance
4 print balance
CashFlow Example
17. CashFlow Example
rule “Account in Negative send Warning"
when
ap : AccountPeriod()
acnt : Account( balance < 0 )
then
insert( new NegativeWarning( acnt ) );
end
18. Accumulate
rule “accumulate"
when
acc( b : Bus( color == “red” );
sumTakings : sum(b.takings);)
then
System.out.println( “sum is " + sumTakings );
end
acc( b : Bus( color == “red” );
sumTakings : sum(b.takings),
minTakings : min(b.takings),
maxTakings : max(b.takings);
minTakings < 100 and maxTakings <
200;)
19. CashFlow Example
rule “Account in Negative send Warning"
when
ap : AccountPeriod()
acnt : Account( balance < 0 )
then
insert( new NegativeWarning( acnt ) );
end
rule “Issue Warning"
when
ap : AccountPeriod()
acnt : Account( balance < 0 )
acc( n : NegativeWarning( account == acnt );
totalWarnings : count(n);
totalWarnings > 0; )
then
System.out.println( "Account warning Number " + acnt.accountNo +
" balance " + acnt.balance + “ Warnings “ +
totalWarnings );
!
insert( TotalWarnings( acnt, totalWarnings );
end
20. Conditional Elements
not Bus ( color == “red” )
!
!
exists Bus ( color == “red” )
!
!
forall ( Bus ( color == “red” )
!
!
forall ( b : Bus ( floors == 2 )
Bus( this == b, color == “red” ) )
21. CashFlow Example
rule “Issue Warning"
when
ap : AccountPeriod()
acnt : Account( balance < 0 )
acc( n : NegativeWarning( account == acnt );
totalWarnings : count(n);
totalWarnings > 0; )
then
System.out.println( "Account warning Number " + acnt.accountNo +
" balance " + acnt.balance + “ Warnings “ totalWarnings );
!
insert( TotalWarnings( acnt, totalWarnings );
end
rule “Cleanup Warnings"
when
ap : AccountPeriod()
acnt : Account( balance >= 0 )
exists( NegativeWarning( account == acnt ) )
n : NegativeWarning( account == acnt )
then
delete( n );
end
22. CashFlow Example
rule “Fine"
when
ap : AccountPeriod()
acnt : Account( balance < 0 )
acc( n : NegativeWarning( account == acnt ) over window:time(4w);
totalWarnings : count(n);
totalWarnings > 3 )
TotalWarnings( total < totalWarnings )
then
System.out.println( "Account warning Number " + acnt.accountNo + " balance " +
acnt.balance + Warnings “ totalWarnings );
end
rule “Issue Warning"
when
ap : AccountPeriod()
acnt : Account( balance < 0 )
acc( n : NegativeWarning( account == acnt ) over window:time(4w);
totalWarnings : count(n);
totalWarnings > 0; )
then
System.out.println( "Account warning Number " + acnt.accountNo + " balance " +
acnt.balance + “ Warnings “ totalWarnings );
!
insertLogical( new TotalWarnings( acnt, totalWarnings );
end
41. 5.x Critique
JCR
• Performance Issues
• Everything stored as
blob
• No tagging, branching
etc.
• Webdav
• Limited team providers
Content
• Single tree structure (packages)
• Packages created project
deployment units
• No easy rule use
• Loading “model” jars into
packages
UI
• Not easily extended
• Fixed layouts
• No perspectives
• Hard to change
• Too many hacks
Deployment
• Binary blobs, on url
• Simple Snapshot system
• No real methodology
• Doesn’t align with any
industry standards
50. Workbench Screens
@WorkbenchScreen(identifier = "MyFirstPanel")!
public class MyFirstPanel extends SimplePanel {!
!
public MyFirstPanel() {!
setWidget( new Label("Hello World 1") );!
}!
!
@WorkbenchPartTitle!
public String myTitle() {!
return "My First Panel!";!
}!
!
}
60. Authoring Perspective
Project Explorer
Use the project explorer to
navigate projects for your
organizational’s repository and
create assets to author.
Problems
When you save, validation
errors for the current project are
shown here
Content Area
Opened assets are added here
61. Tab Stack
Tab Stack Button
Click the button to see the list of
opened assets
Asset List
The opened assets are shown
here. Click to continue
authoring.
62. Project Explorer
Organizational Unit
Lists the organizational units.
Repositories
Lists the repositories for the
selected organisational unit.
Projects
Lists the projects for the
selected repository.
Folder Navigation
Click to expand, to see folders.
63. Project View
Show as Folders
Show as Links
Compact view, that displays the
folders as a single line path.
Project View
The project view is a simplified
and hides many technical
aspects of the project. Such as
merging multiple paths into one
tree.
Shows the project folders using
a tree view.
64. Repository View
Repository View
The repository view provides
raw access to the project
structure and files, nothing is
hidden. And all paths are visible
separately; see the java and
resources folders.
Show as Folders
Show as Links
Compact view, that displays the
folders as a single line path.
Shows the project folders using
a tree view.
65.
66.
67. New Projects and Other Items
New Projects
Launches the new project
wizard. Once created it appears
under the project list for the
target repository
85. KieModules
• Discovery
• META-INF/kmodule.xml
• Convention based
• No programmatic api for building
• Multiple Named entities
• Inheritence of Resources
• Defaults for lazy people
• Version built in a standard
88. KieModules
• Named Entities and JAR on Classpath
• Creates one KieBase
• Includes resources from package matching
kbase name
<kmodule xmlns="http://jboss.org/kie/6.0.0/kmodule">
<kbase name="kbase1">
<ksession name="ksession1"/>
</kbase>
</kmodule>
KieServices ks = KieServices.Factory.get();
KieContainer kContainer = ks.getKieClasspathContainer();
KieSession kSession = kContainer.newKieSession("ksession1");
kSession.setGlobal("out", out);
kSession.insert(new Message("Dave", "Hello, HAL. Do you read me, HAL?"));
kSession.fireAllRules();
89. KieModules
• Named Entities, with inheritence and JAR on
Classpath
• Two projects, one “includes” from the other
<dependency>
<groupId>org.drools</groupId>
<artifactId>named-kiesession</artifactId>
<version>6.0.0-SNAPSHOT</version>
</dependency>
<kbase name="kbase2" includes="kbase1">
<ksession name="ksession2"/>
</kbase>
KieServices ks = KieServices.Factory.get();
KieContainer kContainer = ks.getKieClasspathContainer();
KieSession kSession = kContainer.newKieSession("ksession2");
kSession.setGlobal("out", out);
kSession.insert(new Message("Dave", "Hello, HAL. Do you read me, HAL?"));
kSession.fireAllRules();
kSession.insert(new Message("Dave", "Open the pod bay doors, HAL."));
kSession.fireAllRules();
90. KieModules
• Package location can over-ride kbase name defaults
<kbase name="WumpusMainKB" packages="org.drools.games.wumpus.server,
org.drools.games.wumpus.server.view">
<ksession name="WumpusMainKS" />
</kbase>
<kbase name="WumpusClientKB" packages="org.drools.games.wumpus.client">
<ksession name="WumpusClientKS"/>
</kbase>
KieContainer kc = KieServices.Factory.get().getKieClasspathContainer();
final KieSession serverKsession = kc.newKieSession( "WumpusMainKS");
final KieSession clientKsession = kc.newKieSession("WumpusClientKS");
91. Dynamic KieModules
• JARs can be loaded from URLs into KieRepository
• Once loaded they can be resolved via ReleaseId
KieServices ks = KieServices.Factory.get();
KieRepository kr = ks.getRepository();
KieModule kModule = kr.addKieModule(ks.getResources().newFileSystemResource(
getFile("default-kiesession")));
KieContainer kContainer = ks.newKieContainer(kModule.getReleaseId());
KieSession kSession = kContainer.newKieSession();
kSession.setGlobal("out", out);
Object msg1 = createMessage(kContainer,
"Dave", "Hello, HAL. Do you read me, HAL?");
kSession.insert(msg1);
kSession.fireAllRules();
92. Dynamic KieModules
• kie-ci use embedded maven for remote
discovery
<dependency>
<groupId>org.kie</groupId>
<artifactId>kie-ci</artifactId>
</dependency>
KieServices ks = KieServices.Factory.get();
// Install example1 in the local maven repo before to do this
KieContainer kContainer = ks.newKieContainer(
ks.newReleaseId("org.drools",
"named-kiesession",
"6.0.0-SNAPSHOT"));
KieSession kSession = kContainer.newKieSession("ksession1");
kSession.setGlobal("out", out);
Object msg1 = createMessage(kContainer,
"Dave", "Hello, HAL. Do you read me, HAL?");
kSession.insert(msg1);
kSession.fireAllRules();
93. Dynamic KieModules
// create a new kjar
InternalKieModule kJar2 = createKieJar(ks, releaseId, "rule2", "rule3");
// deploy it on maven
repository.deployArtifact(releaseId, kJar2, kPom);
// since I am not calling start() on the scanner it means it won't have
automatic scheduled scanning
KieScanner scanner = ks.newKieScanner(kieContainer);
// scan the maven repo to get the new kjar version and deploy it on the
kcontainer
scanner.scanNow();
// create a ksesion and check it works as expected
KieSession ksession2 = kieContainer.newKieSession("KSession1");
checkKSession(ksession2, "rule2", "rule3");
104. 104
Questions?
• Dave Bowman: All right, HAL; I'll go in
through the emergency airlock.
• HAL: Without your space helmet, Dave,
you're going to find that rather difficult.
• Dave Bowman: HAL, I won't argue with
you anymore! Open the doors!
• HAL: Dave, this conversation can serve
no purpose anymore. Goodbye.
Joshya: Greetings, Professor Falken.
Falken: Hello, Joshua.
Joshya: A strange game. The only winning move is not
to play. How about a nice game of chess?
107. ReteOO
• Node sharing
• Alpha indexing
• Tree based graphs
• Modify-in-place
• Property reactive
• Sub-networks
• Backward Chaining
• Lazy Truth Maintenance
• Heap based agenda
• Dynamic Rules
108. R.I.P RETE Time to get Phreaky
inspirations:
• Leaps, Collection Oriented Match, L/R Unlinking
!
New Innovations
• Full Rule, and Rule Segment Unlinking
• Lazy Evaluation, with Rule scoping
• Set propagations
!
Previous Innovations
• Modify In Place
• Property Reactive
• Tree Based Graphs
• Subnetwork support
113. Justification-based Truth
• Drools 5.x
• Simple logical insertion TMS, like Clips, Jess and
others.
!
• Drools 6.0
• Contradiction handling with JTMS
• Clean separation of exception logic
• TMS now has pluggable Belief System
• Simple TMS support
• JTMS now possible (exp)
• Defeasible Logic (exp)
!
• See drools-compiler
• JTMSTest for lots of example tests
114. 114
TMS
Couples the logic
What happens when the Child
stops being 16?
rule "Issue Child Bus Pass"
when
$p : Person( age < 16 )
then
insert(new ChildBusPass( $p ) );
end
rule "Issue Adult Bus Pass"
when
$p : Person( age >= 16 )
then
insert(new AdultBusPass( $p ) );
end
116. 116
TMS
de-couples the logic
Maintains the truth by
automatically retracting
•A rule “logically” inserts an object
•When the rule is no longer true, the object is retracted.
rule "IsChild"
when
$p : Person( age < 16 )
then
logicalInsert( new IsChild( $p ) )
end
rule "IsAdult"
when
$p : Person( age >= 16 )
then
logicalInsert( new IsAdult( $p ) )
end
117. 117
TMS
The truth maintenance cascades
rule "Issue Child Bus Pass"
when
$p : Person( )
IsChild( person =$p )
then
logicalInsert(new ChildBusPass( $p ) );
end
rule "Issue Adult Bus Pass"
when
$p : Person()
IsAdult( person =$p )
then
logicalInsert(new AdultBusPass( $p ) );
end
118. 118
TMS
rule "Issue Child Bus Pass"
when
$p : Person( )
not( ChildBusPass( person == $p ) )
then
requestChildBusPass( $p );
end The truth maintenance cascades
119. 119
TMS
• Good
• De-couple knowledge responsibilities
• Encapsulate knowledge
• Provide semantic abstractions for those encapsulation
• Integrity robustness – truth maintenance
122. JTMS
rule "Do not issue to banned people"
when
$p : Person( )
Banned( person =$p )
then
logicalInsert(new ChildBusPass( $p ) , “neg” );
end
“plus” and “neg”
labels
125. Defeasible
rule "All Birds Fly"
when
$b : Bird( )
then
logicalInsert(new Fly( $b ) );
end
rule "Brocken wing"
when
$b : Bird( )
BrockenWing($b;)
then
logicalInsert(new Fly( $b ),
“neg” );
end
126. Defeasible
rule "All Birds Fly" @Defeasible
when
$b : Bird( )
then
logicalInsert(new Fly( $b ) );
end
rule "Brocken wing" @Defeasible
@Defeater
when
$b : Bird( )
BrockenWing($b;)
then
logicalInsert(new Fly( $b ), “neg” );
end
rule "Birds With Rockets Fly"@Defeasible
@Defeats(“Brocken Wing”)
when
$b : Bird( )
Rocket($b;)
then
logicalInsert(new Fly( $b ) );
end
139. Deficiency
• Deficiency
• Premium is £500 if applicant age is less than 30
• Premium is £300 if Years Without Claim is greater than or
equal to 10 years.
!
!
!
!
!
• Applicant is 29, premium is £500
• Applicant has 12 years without claim, premium is £300
• Applicant is 29 with 12 years without claim, premium
is ?!?
141. Loop Problem
rule “Salary award for min 2 years service” when !
e : Employee( lengthOfService > 2 )!
then !
modify( e ) { setSalary( e.getSalary() * 1.05 ) };!
end!
!
!
!
!
!
142. Loop Problem
rule “Salary award for min 2 years service” no-loop
when !
e : Employee( lengthOfService > 2 )!
then !
modify( e ) { setSalary( e.getSalary() * 1.05 ) };!
end!
!
!
!
!
!
143. Loop Problem
rule “Salary award for min 2 years service” no-loop when !
e : Employee( lengthOfService > 2 )!
then !
modify( e ) { setSalary( e.getSalary() * 1.05 ) };!
end!
!
rule “Salary award for min 8 years service” no-loop when !
e : Employee( lengthOfService > 8 )!
then !
modify( e ) { setSalary( e.getSalary() * 1.05 ) };!
end
144. Loop Problem
rule “Salary award for min 2 years service” when !
e : Employee( lengthOfService > 2 )!
not SalaryMin2Years( employee == e )!
then !
modify( e ) { setSalary( e.getSalary() * 1.05 ) };!
insert ( new SalaryMin2Years(e) );!
end!
!
rule “Salary award for min 8 years service” when !
e : Employee( lengthOfService > 8 )!
not SalaryMin8Years( employee == e )!
then !
modify( e ) { setSalary( e.getSalary() * 1.05 ) };!
insert ( new SalaryMin8Years(e) );!
end
145. Loop Problem
rule “Year End” when !
d : ChangeDate( )!
e : Employee( )!
then !
modify( e ) { lengthOfService( !
d.getYear() - e.getStartYear() ) };!
end!
!
rule “Salary award for min 8 years service” when !
e : Employee( lengthOfService > 8 )!
not SalaryMin8Years( employee == e )!
then !
modify( e ) { setSalary( e.getSalary() * 1.05 ) };!
insert ( new SalaryMin8Years(e) );!
end
146. Refraction
This term comes from the neurobiological
observation of a refractory period for a
neuron, which means that the neuron is not
able to fire immediately without first going
through a relaxation process.
!
In a similar way, OPS5 will not allow the same
instantiation in the conflict set from firing twice
in a row. This prevents the inference engine
from entering into an infinite loop.
147. W3C RIF Refraction
• Refraction
When a rule instance is fired, it is
removed from the conflict set (and thus
will not be created again even its
condition part remains true), unless one
of the objects in its condition part is
modified again. In the later case, the
repeatability concept determines how
the rule instance is treated
148. W3C RIF Refraction
• Repeatability
After the execution of a rule instance,
the rule instance is removed from the
conflict set by the refraction. Later on, if
one of the objects in the condition part
is modified and if the rule evaluates to
true, the repeatability controls whether if
the rule instance can be created again.
149. Loop Problem (Refraction)
rule “Salary award for min 2 years service” !
repeatable false when !
e : Employee( lengthOfService > 2 )!
then !
modify( e ) { setSalary( e.getSalary() * 1.05 ) };!
end!
!
rule “Salary award for min 8 years service” !
repeatable false when !
e : Employee( lengthOfService > 8 )!
then !
modify( e ) { setSalary( e.getSalary() * 1.05 ) };!
end
153. Loop Problem Fixed
rule “Salary award for min 2 years service” when !
e : Employee( lengthOfService > 2 )!
then !
modify( e ) { setSalary( e.getSalary() * 1.05 ) };!
end!
!
rule “Salary award for min 8 years service” when !
e : Employee( lengthOfService > 8 )!
then !
modify( e ) { setSalary( e.getSalary() * 1.05 ) };!
end
154. @Watch
rule “Salary award for min 2 years service” when !
e : Employee( salary < 1000, lengthOfService > 2 )!
@Watch( !salary )!
then !
modify( e ) { setSalary( e.getSalary() * 1.05 ) };!
end
155. @Watch
rule “Record Salary Changes” when !
e : Employee( ) @Watch( salary )!
then !
insert( new SalaryChange( e, e.getSalary() );!
end
159. 159
Backward Chaining
query isContainedIn( String x, String y )
Location( x, y; )
or
( Location( z, y; ) and isContainedIn( x, z; ) )
end
House
Location("Office",
"House ")
Location("Kitchen",
"House")
Location("Desk",
"Office")
Location("Chair",
"Office")
Location("Computer",
"Desk")
Location("Draw",
"Desk")
Location("Knife",
"Kitchen")
Location("Cheese",
"Kitchen")
Location("Key",
"Draw")
160. Backward Chaining
160
ksession.insert( new Location("Office", "House") );
ksession.insert( new Location("Kitchen", "House") );
ksession.insert( new Location("Knife", "Kitchen") );
ksession.insert( new Location("Cheese", "Kitchen") );
ksession.insert( new Location("Desk", "Office") );
ksession.insert( new Location("Chair", "Office") );
ksession.insert( new Location("Computer", "Desk") );
ksession.insert( new Location("Draw", "Desk") );
House
Location("Office",
"House ")
Location("Kitchen",
"House")
Location("Desk",
"Office")
Location("Chair",
"Office")
Location("Computer",
"Desk")
Location("Draw",
"Desk")
Location("Knife",
"Kitchen")
Location("Cheese",
"Kitchen")
Location("Key",
"Draw")
161. Backward Chaining
161
rule "go" salience 10
when
$s : String( )
then
System.out.println( $s );
end
House
Location("Office",
"House ")
Location("Kitchen",
"House")
Location("Desk",
"Office")
Location("Chair",
"Office")
Location("Computer",
"Desk")
Location("Draw",
"Desk")
Location("Knife",
"Kitchen")
Location("Cheese",
"Kitchen")
Location("Key",
"Draw")
162. Backward Chaining
162
rule "go1"
when
String( this == "go1" )
isContainedIn("Office", "House"; )
then
System.out.println( "office is in the house" );
end
rule "go" salience 10
when
$s : String( )
then
System.out.println( $s );
end
House
Location("Office",
"House ")
Location("Kitchen",
"House")
Location("Desk",
"Office")
Location("Chair",
"Office")
Location("Computer",
"Desk")
Location("Draw",
"Desk")
Location("Knife",
"Kitchen")
Location("Cheese",
"Kitchen")
Location("Key",
"Draw")
163. Backward Chaining
163
rule "go1"
when
String( this == "go1" )
isContainedIn("Office", "House"; )
then
System.out.println( "office is in the house" );
end
rule "go" salience 10
when
$s : String( )
then
System.out.println( $s );
end
query isContainedIn( String x, String y )
Location( x, y; )
or
( Location( z, y; ) and isContainedIn( x, z; ) )
end
House
Location("Office",
"House ")
Location("Kitchen",
"House")
Location("Desk",
"Office")
Location("Chair",
"Office")
Location("Computer",
"Desk")
Location("Draw",
"Desk")
Location("Knife",
"Kitchen")
Location("Cheese",
"Kitchen")
Location("Key",
"Draw")
164. Backward Chaining
164
rule "go1"
when
String( this == "go1" )
isContainedIn("Office", "House"; )
then
System.out.println( "office is in the house" );
end
rule "go" salience 10
when
$s : String( )
then
System.out.println( $s );
end
ksession.insert( "go1" );
ksession.fireAllRules();
---
go1
office is in the house
query isContainedIn( String x, String y )
Location( x, y; )
or
( Location( z, y; ) and isContainedIn( x, z; ) )
end
House
Location("Office",
"House ")
Location("Kitchen",
"House")
Location("Desk",
"Office")
Location("Chair",
"Office")
Location("Computer",
"Desk")
Location("Draw",
"Desk")
Location("Knife",
"Kitchen")
Location("Cheese",
"Kitchen")
Location("Key",
"Draw")
165. Backward Chaining
165
rule "go1"
when
String( this == "go1" )
isContainedIn("Office", "House"; )
then
System.out.println( "office is in the house" );
end
rule "go" salience 10
when
$s : String( )
then
System.out.println( $s );
end
ksession.insert( "go1" );
ksession.fireAllRules();
---
go1
office is in the house
query isContainedIn( String x, String y )
Location( x, y; )
or
( Location( z, y; ) and isContainedIn( x, z; ) )
end
isContainedIn(x==Office, y==House)
House
Location("Office",
"House ")
Location("Kitchen",
"House")
Location("Desk",
"Office")
Location("Chair",
"Office")
Location("Computer",
"Desk")
Location("Draw",
"Desk")
Location("Knife",
"Kitchen")
Location("Cheese",
"Kitchen")
Location("Key",
"Draw")
166. Backward Chaining
166
rule "go1"
when
String( this == "go1" )
isContainedIn("Office", "House"; )
then
System.out.println( "office is in the house" );
end
rule "go" salience 10
when
$s : String( )
then
System.out.println( $s );
end
ksession.insert( "go1" );
ksession.fireAllRules();
---
go1
office is in the house
query isContainedIn( String x, String y )
Location( x, y; )
or
( Location( z, y; ) and isContainedIn( x, z; ) )
end
Location(x==Office, y==House)
isContainedIn(x==Office, y==House)
House
Location("Office",
"House ")
Location("Kitchen",
"House")
Location("Desk",
"Office")
Location("Chair",
"Office")
Location("Computer",
"Desk")
Location("Draw",
"Desk")
Location("Knife",
"Kitchen")
Location("Cheese",
"Kitchen")
Location("Key",
"Draw")
167. Backward Chaining
167
rule "go2"
when
String( this == "go2" )
isContainedIn("Draw", "House"; )
then
System.out.println( "Draw in the House" );
end
House
Location("Office",
"House ")
Location("Kitchen",
"House")
Location("Desk",
"Office")
Location("Chair",
"Office")
Location("Computer",
"Desk")
Location("Draw",
"Desk")
Location("Knife",
"Kitchen")
Location("Cheese",
"Kitchen")
Location("Key",
"Draw")
168. Backward Chaining
168
rule "go2"
when
String( this == "go2" )
isContainedIn("Draw", "House"; )
then
System.out.println( "Draw in the House" );
end
query isContainedIn( String x, String y )
Location( x, y; )
or
( Location( z, y; ) and isContainedIn( x, z; ) )
end
House
Location("Office",
"House ")
Location("Kitchen",
"House")
Location("Desk",
"Office")
Location("Chair",
"Office")
Location("Computer",
"Desk")
Location("Draw",
"Desk")
Location("Knife",
"Kitchen")
Location("Cheese",
"Kitchen")
Location("Key",
"Draw")
169. Backward Chaining
169
rule "go2"
when
String( this == "go2" )
isContainedIn("Draw", "House"; )
then
System.out.println( "Draw in the House" );
end
query isContainedIn( String x, String y )
Location( x, y; )
or
( Location( z, y; ) and isContainedIn( x, z; ) )
end
ksession.insert( "go2" );
ksession.fireAllRules();
---
go2
Draw in the House
House
Location("Office",
"House ")
Location("Kitchen",
"House")
Location("Desk",
"Office")
Location("Chair",
"Office")
Location("Computer",
"Desk")
Location("Draw",
"Desk")
Location("Knife",
"Kitchen")
Location("Cheese",
"Kitchen")
Location("Key",
"Draw")
170. Backward Chaining
170
rule "go2"
when
String( this == "go2" )
isContainedIn("Draw", "House"; )
then
System.out.println( "Draw in the House" );
end
query isContainedIn( String x, String y )
Location( x, y; )
or
( Location( z, y; ) and isContainedIn( x, z; ) )
end
isContainedIn(x==Draw, y==House)
ksession.insert( "go2" );
ksession.fireAllRules();
---
go2
Draw in the House
House
Location("Office",
"House ")
Location("Kitchen",
"House")
Location("Desk",
"Office")
Location("Chair",
"Office")
Location("Computer",
"Desk")
Location("Draw",
"Desk")
Location("Knife",
"Kitchen")
Location("Cheese",
"Kitchen")
Location("Key",
"Draw")
171. Backward Chaining
171
rule "go2"
when
String( this == "go2" )
isContainedIn("Draw", "House"; )
then
System.out.println( "Draw in the House" );
end
query isContainedIn( String x, String y )
Location( x, y; )
or
( Location( z, y; ) and isContainedIn( x, z; ) )
end
Location(z==Office, y==House)
isContainedIn(x==Draw, y==House)
ksession.insert( "go2" );
ksession.fireAllRules();
---
go2
Draw in the House
House
Location("Office",
"House ")
Location("Kitchen",
"House")
Location("Desk",
"Office")
Location("Chair",
"Office")
Location("Computer",
"Desk")
Location("Draw",
"Desk")
Location("Knife",
"Kitchen")
Location("Cheese",
"Kitchen")
Location("Key",
"Draw")
172. Backward Chaining
172
rule "go2"
when
String( this == "go2" )
isContainedIn("Draw", "House"; )
then
System.out.println( "Draw in the House" );
end
query isContainedIn( String x, String y )
Location( x, y; )
or
( Location( z, y; ) and isContainedIn( x, z; ) )
end
Location(z==Office, y==House)
isContainedIn(x==Draw, z==Office)
isContainedIn(x==Draw, y==House)
ksession.insert( "go2" );
ksession.fireAllRules();
---
go2
Draw in the House
House
Location("Office",
"House ")
Location("Kitchen",
"House")
Location("Desk",
"Office")
Location("Chair",
"Office")
Location("Computer",
"Desk")
Location("Draw",
"Desk")
Location("Knife",
"Kitchen")
Location("Cheese",
"Kitchen")
Location("Key",
"Draw")
173. Backward Chaining
173
rule "go2"
when
String( this == "go2" )
isContainedIn("Draw", "House"; )
then
System.out.println( "Draw in the House" );
end
query isContainedIn( String x, String y )
Location( x, y; )
or
( Location( z, y; ) and isContainedIn( x, z; ) )
end
Location(z==Office, y==House)
isContainedIn(x==Draw, z==Office)
Location(z==Kitchen, y==House)
isContainedIn(x==Draw, z==Kitchen)
isContainedIn(x==Draw, y==House)
ksession.insert( "go2" );
ksession.fireAllRules();
---
go2
Draw in the House
House
Location("Office",
"House ")
Location("Kitchen",
"House")
Location("Desk",
"Office")
Location("Chair",
"Office")
Location("Computer",
"Desk")
Location("Draw",
"Desk")
Location("Knife",
"Kitchen")
Location("Cheese",
"Kitchen")
Location("Key",
"Draw")
174. Backward Chaining
174
rule "go2"
when
String( this == "go2" )
isContainedIn("Draw", "House"; )
then
System.out.println( "Draw in the House" );
end
query isContainedIn( String x, String y )
Location( x, y; )
or
( Location( z, y; ) and isContainedIn( x, z; ) )
end
isContainedIn(x==Draw, y==Office)
ksession.insert( "go2" );
ksession.fireAllRules();
---
go2
Draw in the House
House
Location("Office",
"House ")
Location("Kitchen",
"House")
Location("Desk",
"Office")
Location("Chair",
"Office")
Location("Computer",
"Desk")
Location("Draw",
"Desk")
Location("Knife",
"Kitchen")
Location("Cheese",
"Kitchen")
Location("Key",
"Draw")
175. Backward Chaining
175
rule "go2"
when
String( this == "go2" )
isContainedIn("Draw", "House"; )
then
System.out.println( "Draw in the House" );
end
query isContainedIn( String x, String y )
Location( x, y; )
or
( Location( z, y; ) and isContainedIn( x, z; ) )
end
Location(z==Desk, y==Office)
isContainedIn(x==Draw, y==Office)
ksession.insert( "go2" );
ksession.fireAllRules();
---
go2
Draw in the House
House
Location("Office",
"House ")
Location("Kitchen",
"House")
Location("Desk",
"Office")
Location("Chair",
"Office")
Location("Computer",
"Desk")
Location("Draw",
"Desk")
Location("Knife",
"Kitchen")
Location("Cheese",
"Kitchen")
Location("Key",
"Draw")
176. Backward Chaining
176
rule "go2"
when
String( this == "go2" )
isContainedIn("Draw", "House"; )
then
System.out.println( "Draw in the House" );
end
query isContainedIn( String x, String y )
Location( x, y; )
or
( Location( z, y; ) and isContainedIn( x, z; ) )
end
Location(z==Desk, y==Office)
isContainedIn(x==Draw, z==Desk)
isContainedIn(x==Draw, y==Office)
ksession.insert( "go2" );
ksession.fireAllRules();
---
go2
Draw in the House
House
Location("Office",
"House ")
Location("Kitchen",
"House")
Location("Desk",
"Office")
Location("Chair",
"Office")
Location("Computer",
"Desk")
Location("Draw",
"Desk")
Location("Knife",
"Kitchen")
Location("Cheese",
"Kitchen")
Location("Key",
"Draw")
177. Backward Chaining
177
rule "go2"
when
String( this == "go2" )
isContainedIn("Draw", "House"; )
then
System.out.println( "Draw in the House" );
end
query isContainedIn( String x, String y )
Location( x, y; )
or
( Location( z, y; ) and isContainedIn( x, z; ) )
end
isContainedIn(x==Draw, y==Desk)
ksession.insert( "go2" );
ksession.fireAllRules();
---
go2
Draw in the House
House
Location("Office",
"House ")
Location("Kitchen",
"House")
Location("Desk",
"Office")
Location("Chair",
"Office")
Location("Computer",
"Desk")
Location("Draw",
"Desk")
Location("Knife",
"Kitchen")
Location("Cheese",
"Kitchen")
Location("Key",
"Draw")
178. Backward Chaining
178
rule "go2"
when
String( this == "go2" )
isContainedIn("Draw", "House"; )
then
System.out.println( "Draw in the House" );
end
query isContainedIn( String x, String y )
Location( x, y; )
or
( Location( z, y; ) and isContainedIn( x, z; ) )
end
Location(x==Draw, y==Desk)
isContainedIn(x==Draw, y==Desk)
ksession.insert( "go2" );
ksession.fireAllRules();
---
go2
Draw in the House
House
Location("Office",
"House ")
Location("Kitchen",
"House")
Location("Desk",
"Office")
Location("Chair",
"Office")
Location("Computer",
"Desk")
Location("Draw",
"Desk")
Location("Knife",
"Kitchen")
Location("Cheese",
"Kitchen")
Location("Key",
"Draw")
179. Backward Chaining
179
rule "go3"
when
String( this == "go3" )
isContainedIn("Key", "Office"; )
then
System.out.println( "Key in the Office" );
end
House
Location("Office",
"House ")
Location("Kitchen",
"House")
Location("Desk",
"Office")
Location("Chair",
"Office")
Location("Computer",
"Desk")
Location("Draw",
"Desk")
Location("Knife",
"Kitchen")
Location("Cheese",
"Kitchen")
Location("Key",
"Draw")
180. Backward Chaining
180
rule "go3"
when
String( this == "go3" )
isContainedIn("Key", "Office"; )
then
System.out.println( "Key in the Office" );
end
ksession.insert( "go3" );
ksession.fireAllRules();
---
go3
House
Location("Office",
"House ")
Location("Kitchen",
"House")
Location("Desk",
"Office")
Location("Chair",
"Office")
Location("Computer",
"Desk")
Location("Draw",
"Desk")
Location("Knife",
"Kitchen")
Location("Cheese",
"Kitchen")
Location("Key",
"Draw")
181. Backward Chaining
181
rule "go3"
when
String( this == "go3" )
isContainedIn("Key", "Office"; )
then
System.out.println( "Key in the Office" );
end
ksession.insert( "go3" );
ksession.fireAllRules();
---
go3
ksession.insert( new Location("Key", "Draw") );
ksession.fireAllRules();
---
Key in the Office
House
Location("Office",
"House ")
Location("Kitchen",
"House")
Location("Desk",
"Office")
Location("Chair",
"Office")
Location("Computer",
"Desk")
Location("Draw",
"Desk")
Location("Knife",
"Kitchen")
Location("Cheese",
"Kitchen")
Location("Key",
"Draw")
182. Backward Chaining
182
rule "go4"
when
String( this == "go4" )
isContainedIn(thing, "Office"; )
then
System.out.println( "thing " + thing + " is in the Office" );
end
House
Location("Office",
"House ")
Location("Kitchen",
"House")
Location("Desk",
"Office")
Location("Chair",
"Office")
Location("Computer",
"Desk")
Location("Draw",
"Desk")
Location("Knife",
"Kitchen")
Location("Cheese",
"Kitchen")
Location("Key",
"Draw")
183. Backward Chaining
183
rule "go4"
when
String( this == "go4" )
isContainedIn(thing, "Office"; )
then
System.out.println( "thing " + thing + " is in the Office" );
end
Out Var
(unbound)
House
Location("Office",
"House ")
Location("Kitchen",
"House")
Location("Desk",
"Office")
Location("Chair",
"Office")
Location("Computer",
"Desk")
Location("Draw",
"Desk")
Location("Knife",
"Kitchen")
Location("Cheese",
"Kitchen")
Location("Key",
"Draw")
184. Backward Chaining
184
rule "go4"
when
String( this == "go4" )
isContainedIn(thing, "Office"; )
then
System.out.println( "thing " + thing + " is in the Office" );
end
ksession.insert( "go4" );
ksession.fireAllRules();
---
go4
thing Key is in the Office
thing Computer is in the Office
thing Draw is in the Office
thing Desk is in the Office
thing Chair is in the Office
Out Var
(unbound)
House
Location("Office",
"House ")
Location("Kitchen",
"House")
Location("Desk",
"Office")
Location("Chair",
"Office")
Location("Computer",
"Desk")
Location("Draw",
"Desk")
Location("Knife",
"Kitchen")
Location("Cheese",
"Kitchen")
Location("Key",
"Draw")
185. Backward Chaining
185
rule "go5"
when
String( this == "go5" )
isContainedIn(thing, location; )
then
System.out.println( "thing " + thing + " is in " + location );
end
House
Location("Office",
"House ")
Location("Kitchen",
"House")
Location("Desk",
"Office")
Location("Chair",
"Office")
Location("Computer",
"Desk")
Location("Draw",
"Desk")
Location("Knife",
"Kitchen")
Location("Cheese",
"Kitchen")
Location("Key",
"Draw")
186. Backward Chaining
186
rule "go5"
when
String( this == "go5" )
isContainedIn(thing, location; )
then
System.out.println( "thing " + thing + " is in " + location );
end
Out Var
(unbound)
House
Location("Office",
"House ")
Location("Kitchen",
"House")
Location("Desk",
"Office")
Location("Chair",
"Office")
Location("Computer",
"Desk")
Location("Draw",
"Desk")
Location("Knife",
"Kitchen")
Location("Cheese",
"Kitchen")
Location("Key",
"Draw")
187. Backward Chaining
187
rule "go5"
when
String( this == "go5" )
isContainedIn(thing, location; )
then
System.out.println( "thing " + thing + " is in " + location );
end
Out Var
(unbound)
Out Var
(unbound)
House
Location("Office",
"House ")
Location("Kitchen",
"House")
Location("Desk",
"Office")
Location("Chair",
"Office")
Location("Computer",
"Desk")
Location("Draw",
"Desk")
Location("Knife",
"Kitchen")
Location("Cheese",
"Kitchen")
Location("Key",
"Draw")
188. Backward Chaining
188
rule "go5"
when
String( this == "go5" )
isContainedIn(thing, location; )
then
System.out.println( "thing " + thing + " is in " + location );
end
ksession.insert( "go5" );
ksession.fireAllRules();
---
go5
thing Knife is in House
thing Cheese is in House
thing Key is in House
thing Computer is in House
thing Draw is in House
thing Desk is in House
thing Chair is in House
thing Key is in Office
thing Computer is in Office
thing Draw is in Office
thing Key is in Desk
thing Office is in House
Out Var
(unbound)
Out Var
(unbound)
!
thing Computer is in Desk
thing Knife is in Kitchen
thing Cheese is in Kitchen
thing Kitchen is in House
thing Key is in Draw
thing Draw is in Desk
thing Desk is in Office
thing Chair is in Office
House
Location("Office",
"House ")
Location("Kitchen",
"House")
Location("Desk",
"Office")
Location("Chair",
"Office")
Location("Computer",
"Desk")
Location("Draw",
"Desk")
Location("Knife",
"Kitchen")
Location("Cheese",
"Kitchen")
Location("Key",
"Draw")
189. 189
Questions?
• Dave Bowman: All right, HAL; I'll go in
through the emergency airlock.
• HAL: Without your space helmet, Dave,
you're going to find that rather difficult.
• Dave Bowman: HAL, I won't argue with
you anymore! Open the doors!
• HAL: Dave, this conversation can serve
no purpose anymore. Goodbye.
Joshya: Greetings, Professor Falken.
Falken: Hello, Joshua.
Joshya: A strange game. The only winning move is not
to play. How about a nice game of chess?