SlideShare a Scribd company logo
 
Applying JBoss Drools in Assistive Technology
Who is Tihomir? R&D Engineer on Drools
Contributor and committer on Seam
Agenda Assistive Technology (AT)
Applying Drools in AT
Event Processing
Drools Fusion examples
Vision for the future
Q&A
Assistive Technology Disability affects 15-20% of every country's population (with 10% being classified with severe motor impairments). Growing trends (aging population, severe stroke).
Categories of disabilities: -  Sensoric deficiencies  – reduced ability to acquire inputs from the physical world (e.g. blindness, deafness, etc.), -  Expression deficiencies  – reduced ability to produce output to the physical world (e.g. voice, motion, etc.). Assistive technology (AT) – product, device or equipment (e.g. assistive, adaptive or rehabilitative devices) that helps individuals with disabilities to increase, maintain or improve functional capabilities (AT Act, 1998).
AT products help peoples with disabilities to achieve greater independence, enhance their quality of life and compete in the real world ( inclusive society ).
AT Current situation Steadily growing market (especially for small businesses, estimation: US$ 12 billion in USA, 30 billion in Japan and 40 billion in Europe)
Modern AT industry sustainable and profitable.
The key problems:  -  User View  – Expensive, not sufficiently flexible and adaptable devices. Slow and not responsive systems, non-transparent,  difficult to use, sensitive to  disturbances and errors. -  Developer View  – Demands for highly customized products within a huge target-audience, risky business (user acceptance, competitive pricing).
AT research and development Long term AT research (priorities in several countries).
Main focus: respond to the needs and wants of users.
Close relationships to main-stream researches, such as  robotics, cognition, AI, IT, sensor technology, real time control etc.
Attractive common research focuses on:  - human enhancement, - rehabilitation robotics, - human-robot interaction (HRI), - human-computer interfaces (HCI), - brain-computer interfaces (BCI),  - computer vision, etc.
AT essential distinctive problem Extreme individual differences that characterize abilities and needs of motor-impaired people.
Keys to increase acceptance and use High personalization and customization
Scalability and adaptivity
Improve performance over time
Acquisition/preservation of user experience and knowledge
Improve maintainability and robustness in spite of user and  environmental disturbances
AT example: computer access Computer input devices for motor-impaired people
Mouse cursor control for handicapped individuals (MCC) – main operations:  pointing  and  clicking .
Ca. 250 commercial MCC products available at the market worldwide.
Multitude of MCC concepts: switch-related systems (sip/puff switches), head pointing systems, eye tracking systems, BCI etc.
None of them provide a standardized general system for subjects with severe disabilities.
MCC AT principles
Roadmap to success More complex systems that combine several input channels.
Use of innovative technologies, such as AI approaches, methods and tools (e.g. automated reasoning, first-order logic, fuzzy logic, neural-networks etc.).
Development of standardized HW and SW modules that can be configured for a  specific user.
Example: Improve MCC by using fuzzy logic Convenient simple input device: pneumatic dual-action input switch (sip and puff).
Indirect pointing of target items (scanning) based on Morse codes sequences of  dots (sip) and dashes (puff).
Traditional line scanning.
Quite inefficient and tedious, especially for users with limited breathing or learning capabilities.

More Related Content

PPTX
Prosthetics in sports
PPTX
Siddhi: A Second Look at Complex Event Processing Implementations
PPT
Is It API Time For A New Strategy?
PPT
Open Source Event Processing for Sensor Fusion Applications
PDF
The technologies of ai used in different corporate world
PDF
Hadoop.mapreduce
PDF
Notes on data-intensive processing with Hadoop Mapreduce
PDF
HCI research methods by Sanjay Tripathi, ABB
Prosthetics in sports
Siddhi: A Second Look at Complex Event Processing Implementations
Is It API Time For A New Strategy?
Open Source Event Processing for Sensor Fusion Applications
The technologies of ai used in different corporate world
Hadoop.mapreduce
Notes on data-intensive processing with Hadoop Mapreduce
HCI research methods by Sanjay Tripathi, ABB

Similar to Applying Drools in Assistive Technology (20)

PPTX
Data, Big Data and real time analytics for Connected Devices
ODP
Cloud4all/GPII overview and demonstration @ LMS / RMLL 2013
ODP
Business processes, business rules, complex event processing, the JBoss way
PPTX
From Events to Situations: An Event-web perspective
PDF
Bionic Model for Control Platforms
PDF
Real Time Event Processing and In-­memory analysis of Big Data - StampedeCon ...
PPTX
Situation based analysis and control for supporting Event-web applications
PPTX
BetaGroup - Tech Trends in 2017, a snap shot by BetaGroup
PPT
Adaptive Service Interfaces
PDF
Btec Business Level 3 Unit 14 M1
PPTX
MODULE 1 Human Computer Interaction. (Engineering)
PPTX
MODULE 1 CSG2003 Hci and there is model 1 ppt.pptx
PPT
HCI 3e - Ch 18: Modelling rich interaction
PPTX
Plenary Session: application drive design alberto sv
PDF
Sirris presentation
PPTX
MICE: Monitoring and modelIng of Context Evolution
PDF
A (very) short history of ambiguity
PPTX
Exo cortex
PPTX
PDF
Exploring the Intersection of Neuroscience and Engineering through Brain-Com...
Data, Big Data and real time analytics for Connected Devices
Cloud4all/GPII overview and demonstration @ LMS / RMLL 2013
Business processes, business rules, complex event processing, the JBoss way
From Events to Situations: An Event-web perspective
Bionic Model for Control Platforms
Real Time Event Processing and In-­memory analysis of Big Data - StampedeCon ...
Situation based analysis and control for supporting Event-web applications
BetaGroup - Tech Trends in 2017, a snap shot by BetaGroup
Adaptive Service Interfaces
Btec Business Level 3 Unit 14 M1
MODULE 1 Human Computer Interaction. (Engineering)
MODULE 1 CSG2003 Hci and there is model 1 ppt.pptx
HCI 3e - Ch 18: Modelling rich interaction
Plenary Session: application drive design alberto sv
Sirris presentation
MICE: Monitoring and modelIng of Context Evolution
A (very) short history of ambiguity
Exo cortex
Exploring the Intersection of Neuroscience and Engineering through Brain-Com...
Ad

Recently uploaded (20)

PPTX
observCloud-Native Containerability and monitoring.pptx
PDF
DP Operators-handbook-extract for the Mautical Institute
PDF
Developing a website for English-speaking practice to English as a foreign la...
PDF
Microsoft Solutions Partner Drive Digital Transformation with D365.pdf
PDF
August Patch Tuesday
PPTX
The various Industrial Revolutions .pptx
PDF
Video forgery: An extensive analysis of inter-and intra-frame manipulation al...
PPTX
TechTalks-8-2019-Service-Management-ITIL-Refresh-ITIL-4-Framework-Supports-Ou...
PDF
Web App vs Mobile App What Should You Build First.pdf
PDF
ENT215_Completing-a-large-scale-migration-and-modernization-with-AWS.pdf
PDF
A novel scalable deep ensemble learning framework for big data classification...
PPTX
Modernising the Digital Integration Hub
PDF
Assigned Numbers - 2025 - Bluetooth® Document
PDF
From MVP to Full-Scale Product A Startup’s Software Journey.pdf
PPTX
Programs and apps: productivity, graphics, security and other tools
PDF
1 - Historical Antecedents, Social Consideration.pdf
PDF
NewMind AI Weekly Chronicles - August'25-Week II
PDF
NewMind AI Weekly Chronicles – August ’25 Week III
PDF
Getting Started with Data Integration: FME Form 101
PPTX
Group 1 Presentation -Planning and Decision Making .pptx
observCloud-Native Containerability and monitoring.pptx
DP Operators-handbook-extract for the Mautical Institute
Developing a website for English-speaking practice to English as a foreign la...
Microsoft Solutions Partner Drive Digital Transformation with D365.pdf
August Patch Tuesday
The various Industrial Revolutions .pptx
Video forgery: An extensive analysis of inter-and intra-frame manipulation al...
TechTalks-8-2019-Service-Management-ITIL-Refresh-ITIL-4-Framework-Supports-Ou...
Web App vs Mobile App What Should You Build First.pdf
ENT215_Completing-a-large-scale-migration-and-modernization-with-AWS.pdf
A novel scalable deep ensemble learning framework for big data classification...
Modernising the Digital Integration Hub
Assigned Numbers - 2025 - Bluetooth® Document
From MVP to Full-Scale Product A Startup’s Software Journey.pdf
Programs and apps: productivity, graphics, security and other tools
1 - Historical Antecedents, Social Consideration.pdf
NewMind AI Weekly Chronicles - August'25-Week II
NewMind AI Weekly Chronicles – August ’25 Week III
Getting Started with Data Integration: FME Form 101
Group 1 Presentation -Planning and Decision Making .pptx
Ad

Applying Drools in Assistive Technology

  • 1.  
  • 2. Applying JBoss Drools in Assistive Technology
  • 3. Who is Tihomir? R&D Engineer on Drools
  • 9. Vision for the future
  • 10. Q&A
  • 11. Assistive Technology Disability affects 15-20% of every country's population (with 10% being classified with severe motor impairments). Growing trends (aging population, severe stroke).
  • 12. Categories of disabilities: - Sensoric deficiencies – reduced ability to acquire inputs from the physical world (e.g. blindness, deafness, etc.), - Expression deficiencies – reduced ability to produce output to the physical world (e.g. voice, motion, etc.). Assistive technology (AT) – product, device or equipment (e.g. assistive, adaptive or rehabilitative devices) that helps individuals with disabilities to increase, maintain or improve functional capabilities (AT Act, 1998).
  • 13. AT products help peoples with disabilities to achieve greater independence, enhance their quality of life and compete in the real world ( inclusive society ).
  • 14. AT Current situation Steadily growing market (especially for small businesses, estimation: US$ 12 billion in USA, 30 billion in Japan and 40 billion in Europe)
  • 15. Modern AT industry sustainable and profitable.
  • 16. The key problems: - User View – Expensive, not sufficiently flexible and adaptable devices. Slow and not responsive systems, non-transparent, difficult to use, sensitive to disturbances and errors. - Developer View – Demands for highly customized products within a huge target-audience, risky business (user acceptance, competitive pricing).
  • 17. AT research and development Long term AT research (priorities in several countries).
  • 18. Main focus: respond to the needs and wants of users.
  • 19. Close relationships to main-stream researches, such as robotics, cognition, AI, IT, sensor technology, real time control etc.
  • 20. Attractive common research focuses on: - human enhancement, - rehabilitation robotics, - human-robot interaction (HRI), - human-computer interfaces (HCI), - brain-computer interfaces (BCI), - computer vision, etc.
  • 21. AT essential distinctive problem Extreme individual differences that characterize abilities and needs of motor-impaired people.
  • 22. Keys to increase acceptance and use High personalization and customization
  • 25. Acquisition/preservation of user experience and knowledge
  • 26. Improve maintainability and robustness in spite of user and environmental disturbances
  • 27. AT example: computer access Computer input devices for motor-impaired people
  • 28. Mouse cursor control for handicapped individuals (MCC) – main operations: pointing and clicking .
  • 29. Ca. 250 commercial MCC products available at the market worldwide.
  • 30. Multitude of MCC concepts: switch-related systems (sip/puff switches), head pointing systems, eye tracking systems, BCI etc.
  • 31. None of them provide a standardized general system for subjects with severe disabilities.
  • 33. Roadmap to success More complex systems that combine several input channels.
  • 34. Use of innovative technologies, such as AI approaches, methods and tools (e.g. automated reasoning, first-order logic, fuzzy logic, neural-networks etc.).
  • 35. Development of standardized HW and SW modules that can be configured for a specific user.
  • 36. Example: Improve MCC by using fuzzy logic Convenient simple input device: pneumatic dual-action input switch (sip and puff).
  • 37. Indirect pointing of target items (scanning) based on Morse codes sequences of dots (sip) and dashes (puff).
  • 39. Quite inefficient and tedious, especially for users with limited breathing or learning capabilities.
  • 40. Why Fuzzy Logic? Dealing with imperfect information natively IF direction IS positive AND strength IS weak THEN output IS weak_positive
  • 41. Fuzzy scanning and inference algorithms Puff/sip define cursor motion directions.
  • 42. New input air flow defines velocity of cursor moving.
  • 43. Fuzzy scanning algorithms: circular scan, selection area scan, object selection, etc
  • 44. Fuzzy control outcomes and limitations Improved mouse control. Clear step-forward in comparison to the state of art.
  • 45. Feasible and promising solution for development of sophisticated and adaptive MMC (HCI) systems.
  • 46. Constraints: relatively good breathing control is needed. Sensitivity to disturbances.
  • 47. Multi-channel inputs and action outputs (MIMO) can further improve performance and robustness, however fuzzy logic and control applications become extremely complex.
  • 48. Processing large number of input events becomes problematic.
  • 49. Beyond just fuzzy reasoning Needs: production rule system
  • 50. ability to combine classical predicate logic with fuzzy logic to represent the system as combination of discrete as well as continuous events.
  • 51. ability to process large number of complex events through multiple input channels.
  • 54. ability to embed (parts of) system One-stop-shop solution??
  • 55. Drools (1) “ A common platform to model and govern the business logic of the enterprise.”
  • 56. Drools (2) “ A common platform to model and govern the business logic of the enterprise.”
  • 57. Drools for AT? (1) Fully integrated logic platform (rule engine, workflow, event processing, etc) that supports easy and frequent change of rules (adaptation to users).
  • 58. Extensions of the RETE networks using set of pluggable modules.
  • 59. Drools-Chance (still in development) makes Drools capable of dealing with imperfect information natively. Also adds possibility to configure behavior of the engine to reason with different type of imperfection without changing the production rules.
  • 61. Ability to test/monitor all parts of AT system.
  • 62. Ability to run/embed into OSGi environments and future AT devices.
  • 63. Drools for AT? (2) Separates applications (AT devices or computer control systems) from conditions which control the application flow.
  • 64. Changing rules does not require a complete deployment of AT systems.
  • 65. Provides background to build modular and scalable AT systems, such as integrate additional sensors for a specific user and develop rules, without influencing specific application (e.g. computer or assistive device control).
  • 66. Rules can be modified by different group of users (technicians, physicians, end-users).
  • 67. Rule language is simple to learn.
  • 68. End-users can be involved to resolve conflicts and perform specific actions (improved robustness).
  • 69. Efficient for frequent change of rules dependent on user experience, health state, specific needs etc.
  • 70. First steps toward improvement for MCC - Event Processing Any form of computing performing operations on events
  • 71. Event: Real world: occurrence of something that has happened at a particular point in time
  • 72. Comp. Systems: entity/object that represents this occurrence
  • 73. 1 RW Event -> ∞ CS Events
  • 74. Raw vs. Derived Events Complex Event: abstraction of a number of related events For example a hurricane is an abstraction of a large number of natural eve nts
  • 75. Main Concepts of Event Processing Event Processing Networks (EPN): Producers: introduce/emits events into the processing network (Sensors, Systems, Apps, Business Processes, Human Interaction, etc)
  • 76. Distribution Channels: provides means of distributing events (typically one-to-many distribution, async)
  • 77. Consumers: receive and act upon events (Applications, Systems, Data Stores, Business Processes, etc)
  • 78. Intermediary Processing: rout / filter (raw events), produce (derived events). Consists of a number of building blocks (Agents) Intermediary Processing Event Producers Event Consumers
  • 79. Event Processing Agents Building Blocks for: Translation, Composition, Aggregation, Enrichment, Splitting, Projection, Pattern Detection, etc. Even Filtering Event Matching Event Derivation time time time
  • 80. Event Processing Network (1) Network based on the core EP building blocks
  • 81. Can be described as process flows such as Drools-Flow
  • 82. Event Processing Network (2) Describing network building blocks with Drools-Flow bring good feature support to EP Custom work item handlers
  • 83. Testing, debugging, monitoring (and self-monitoring/adapting)
  • 84. Customizable and easily replaceable network parts
  • 85. Integration with Human tasks public class ErrorEventListener implements ProcessEventListener { public void afterNodeLeft(ProcessNodeLeftEvent event) { ksession .getWorkingMemoryEntryPoint( entryPointName ).insert(event); ... } declare ProcessNodeLeftEvent @role( event ) end rule "Number of Cursor Rotations is above threshold" when Number( nbProcesses : intValue > 5 ) from accumulate ( e: ProcessNodeLeftEvent( nodeInstance.nodeName == "CursorRotationNode" ) over window:size(10s), count(e) ) then drools.getWorkingMemory().getProcessInstance(ATDepartmentNotificationProcess).signalEvent( "notify" , "cursor rotation threshold exceeded" ); end
  • 86. Event Processing - Context Specifies conditions on a group of events so they can be processed in related ways.
  • 87. Events may/may not be relevant in certain contexts Example: Left-click command can only be issued over clickable objects on screen Types of contexts: Temporal: consists of time intervals and events within intervals
  • 88. Spacial: takes account geospatial event info
  • 89. State-oriented: depends on state of some external entity
  • 90. Segmentation-oriented: partitions events by their attribute values (for example age >= 35)
  • 92. Drools Fusion – Events (1) Representing Raw Events:
  • 93. Creating Derived Events: declare Direction @role( event ) @timestamp( timestamp ) @expires( 1m ) end declare Strength @role( event ) @expires( 1m ) end declare DoubleClick @role( event ) direction : Direction strength : Strength delay : int end rule detectDoubleClick when $direction : Direction( ) from entry-point "Raw-Direction-Stream" ... $strength : Strength( ) from entry-point "Raw-Strength-Stream" ... then DoubleClick dc = new DoubleClick($direction, $strength, 0); entryPoints[ "Cursor-Control-Endpoint-Stream" ). insert (dc); end
  • 94. Drools Fusion – Events (2) Absence of events in proper order:
  • 95. Negative patterns, waiting for events to happen: declare Click @role( event ) @expires( 1m ) delay : int end declare Drag @role( event ) @expires( 1m ) direction : Direction strength : Strength delay : int end rule invalidDragMotion when $dragEvent : Drag( ) from entry-point "Cursor-Control-Endpoint-Stream" not ( Click( this before $dragEvent ) from entry-point "Cursor-Control-Endpoint-Stream" ) // click starts drag event then # notify user+system of invalid command ... end rule lenientDragMotion when $dragEvent : Drag( ) from entry-point "Cursor-Control-Endpoint-Stream" not ( Click( this before $dragEvent ) from entry-point "Cursor-Control-Endpoint-Stream" ) Click( this after[0s,5s] $dragEvent ) from entry-point "Cursor-Control-Endpoint-Stream" then # allow drag motion... ... end
  • 96. Drools Fusion – Event Streams Drools compiler gathers all entry-point declarations and exposes them through the session API.
  • 97. Engine manages all scoping and synchronizations behind the scenes.
  • 98. Event processing from specific streams in rules: StatefulKnowledgeSession ksession = ... ... WorkingMemoryEntryPoint rawDirectionEntryPoint = ksession.getWorkingMemoryEntryPoint( "Raw-Direction-Stream" ); WorkingMemoryEntryPoint rawStrengthEntryPoint = ksession.getWorkingMemoryEntryPoint( "Raw-Strength-Stream" ); … // Every time we get input from direction sensor do: rawDirectionEntryPoint.insert(direction); // Every time we get input from flow sensor do: rawStrengthEntryPoint.insert(strength); ... rule detectVerticalScrolling When ... $direction : Direction( ) from entry-point "Raw-Direction-Stream" $strength : Strength( ) from entry-point "Raw-Strength-Stream" ... then ...
  • 99. Drools Fusion - Channels Eliminates runtime awareness of event consumers.
  • 100. Dynamic registration of consumers in channels possible.
  • 101. Example: a) Register Channel:
  • 103. Push derived events for distribution in rules: StatefulKnowledgeSession ksession = kbase.newStatefulKnowledgeSession(config, null ); ksession.registerChannel( &quot;cursor-control&quot; , new CursorControlChannel()); ... public class CursorControlChannel implements Channel { private List<MouseControlService> controlServices ; @Override public void send(Object command) { for (MouseControlService service : controlServices ) { service.publishCommand(command); } } ... rule detectDoubleClick when ... then DoubleClick dc = new DoubleClick(); ... channels[ &quot;cursor-control&quot; ].send( dc ); end
  • 104. Drools Fusion – Temporal Event Context (1) Enable Temporal Context by putting engine in “Stream mode”:
  • 105. Choose a Clock type (realtime or pseudo for testing): ... KnowledgeBaseConfiguration config = KnowledgeBaseFactory. newKnowledgeBaseConfiguration (); config.setOption( EventProcessingOption. STREAM ); KnowledgeBase kbase = KnowledgeBaseFactory. newKnowledgeBase (config); ... ... KnowledgeSessionConfiguration config = KnowledgeBaseFactory. newKnowledgeSessionConfiguration (); config.setOption( ClockTypeOption. get ( &quot;realtime&quot; ) ); StatefulKnowledgeSession ksession = kbase.newStatefulKnowledgeSession(config, null ); ...
  • 106. Drools Fusion – Temporal Event Context (2) Stream Mode Enables: Notion of “flow of time”, concept of “now”
  • 109. Automatic rule delaying on absence of facts Reference Clock (Session Clock) implementations:
  • 110. Drools Fusion – Temporal Event Context (3) Sliding Window support allows reasoning over a window of interest: Time
  • 111. Length rule &quot;Normalize cursor motion speed&quot; when CursorSpeedThreshold( $max : max ) Number( doubleValue > $max) from accumulate ( Strength( $val : value ) over window:length( 200 ), average( $val ) ) then // normalize the cursor speed end rule “Detect excessive Cursor Rotation” when Number( intValue > 15 ) from accumulate ( CursorRotation( ) over window:time(30s), count(e) ) then drools.getWorkingMemory().getProcessInstance(ATDepartmentNotificationProcess).signalEvent( &quot;notify&quot; , &quot;cursor rotation threshold exceeded&quot; ); end
  • 112. Drools Fusion – Temporal Context Operators 13 Temporal Operators
  • 113. Drools Fusion – Temporal Context Operators
  • 114. What next? -AT vision architecture
  • 119. Mailing Lists: http://www.jboss.org/drools/lists.html

Editor's Notes

  • #19: Expert – Rule Engine side, Logic side Flow – advanced process engine, tight integration of processes and rules Fusion – Even Processing , CEP integration into Drools Guvnor - about server-side management, web stuff
  • #20: Expert – Rule Engine side, Logic side Flow – advanced process engine, tight integration of processes and rules Fusion – Even Processing , CEP integration into Drools Guvnor - about server-side management, web stuff