SlideShare a Scribd company logo
1 of 23
formal methods in HCI
a success story


problem
context
– mid 80s
– local authority DP dept
transaction processing
– vast numbers of users
– order processing, pos systems etc.
– COBOL!
existing programs ... didn’t work
TP physical architecture
central server
user
corporate
database
terminal
other
users
N.B. web apps.
just like this too
what happens
user edits form
message goes to TP engine
passed to application module
which processes the message
and prepares new screen
which is sent to the user
....
web server
PHP script
Java servlet
web page
structure of programs
if ..
if .. if ..
if .. if .. if .. if ..
why?
program is trying to work out
what is happening!
standard algorithm
– program counter implicit
TP, web, event-based GUI
– need explicit dialogue state
mixed up state
many users – one application module
user A starts multi-screen search list
application stores value ‘next_record’
user B starts multi-screen search list
application overwrites value ‘next_record’
user A selects ‘next screen’ ...
... and gets next screen of B’s search!
state is hard
why?
in real life state is implicit
in standard CS state is implicit too!
in transaction processing (+web)
state needs to be explicit
solution?
flowchart!
not of program
... but of dialogue
a formal dialogue
specification!
Delete D1
Please enter
employee no.: ____
Delete D3
Name: Alan Dix
Dept: Computing
delete? (Y/N): _
Please enter Y or N
Delete D2
Name: Alan Dix
Dept: Computing
delete? (Y/N): _
answer?
C2
Finish
Finish
read record
C1
delete record
C3
other
NY
full screen flow chartDelete D1
Please enter
employee no.: ____
Delete D3
Name: Alan Dix
Dept: Computing
delete? (Y/N): _
Please enter Y or N
Delete D2
Name: Alan Dix
Dept: Computing
delete? (Y/N): _
answer?
C2
Finish
Finish
read record
C1
delete record
C3
other
NY
details ...
miniature
screen sketch
Delete D1
Please enter
employee no.: ____
Delete D3
Name: Alan Dix
Dept: Computing
delete? (Y/N): _
Please enter Y or N
Delete D2
Name: Alan Dix
Dept: Computing
delete? (Y/N): _
answer?
C2
Finish
Finish
read record
C1
delete record
C3
other
NY
Delete D2
Name: Alan Dix
Dept: Computing
delete? (Y/N): _
details ...
minimal
internal details
Delete D1
Please enter
employee no.: ____
Delete D3
Name: Alan Dix
Dept: Computing
delete? (Y/N): _
Please enter Y or N
Delete D2
Name: Alan Dix
Dept: Computing
delete? (Y/N): _
answer?
C2
Finish
Finish
read record
C1
delete record
C3
other
NY
answer?
C2
delete record
C3
other
NY
and then ...
hand transformation to boiler plate code
store ‘where next’ for each terminal
• in ‘session’ data
code starts with big ‘case’
do processing
set new ‘where next’ ... send screen
lessons
useful – addressed a real problem!
communication – mini-pictures and clear flow easy to talk through with client
complementary – different paradigm than implementation
fast pay back – quicker to produce application (at least 1000%)
responsive – rapid turnaround of changes
reliability – clear boiler plate code less error-prone
quality – easy to establish test cycle
maintenance – easy to relate bug/enhancement reports to specification and code

and now ...
lessons about state


states in web applications (inter alia)
persistent (deep) state
– the things you are really interested in
e.g. an order, images in an album, facebook profile
temporary interaction state
– part-created or part-edited objects
e.g. new cracker setting decoration, joke, etc.
placeholder in interaction
– current state/mode/location in dialogue
pretty clear
in database
or similar
less clear
and often
confused
where state is stored
(a) cookies
(b) hidden form variables
– <input type=“hidden” name=“sid” value=“A378F9E6B2” />
(c) encoded in URL
– http://mysite.com/processapp.jsp?sid= A378F9E6B2
(d) session variables
– session/transaction id stored using (a), (b), or (c)
(e) database or persistent store
– as (d) needs identifier or token
where state is stored (ctd)
More client side (especially AJAX apps) ...
(e) JavaScript variables
– if ( active ) $(‘#main’).show();
(f) HTML5 local storage
key–value or sqlite
– localStorage.visitcount++;
– t.executeSql('SELECT *FROM docs WHERE id=?', [id],
function (t, data) {... }
(g) hash at end of URL
– http://mysite.com/map.html#long=6:53W&lat=56:29N
what goes where?
interaction issues:
– multiple windows on same app?
– privacy and security
– ‘back’ button? … and bookmarks
danger of ‘resubmitting’ same data
implementation issues
– ‘garbage collecting’ session data
– restarting server
often ‘hacked’ not considered
lesson – clearly specify the state
… and only then map into implementation!
why ‘stateless’ often
regarded as good
… but not necessarly
best for interaction!
dialogue too … the way it often is …
initial prototype linear
A then B then …
at most one path
for each link/button
syuh how gtw
hsio i ert ag ty
ghn ty we ghty
chdi qw oatyf
wet dfla ght a
<?php
$x= …
?>
code to
produce
page A
syuh how gtw
hsio i ert ag ty
ghn ty we ghty
chdi qw oatyf
wet dfla ght a
<?php
$y= …
?>
code for
page B
user clicks
link
DB
update
and fetch
data
… and the way it goes …
initial prototype linear
but …
later add validation
if validation fails
page B code needs
to produce something
‘like’ page A
… and it just keeps
getting worse
syuh how gtw
hsio i ert ag ty
ghn ty we ghty
chdi qw oatyf
wet dfla ght a
<?php
$x= …
?>
code to
produce
page A
syuh how gtw
hsio i ert ag ty
ghn ty we ghty
chdi qw oatyf
wet dfla ght a
<?php
if ($y<1) …
?>
code for
page B
DB
syuh how gtw
hsio i ert ag ty
ghn ty we ghty
chdi qw oatyf
wet dfla ght a
page Bpage A
separate dialogue and presentation
model dialogue
– take into account both
user and system branches
three kinds of code
– gather data for page
access database
but no updates except logging
– format page
only code to produce HTML
maybe use template engine
– post-page process actions
validation checks
update persistent data
choose next page to show
syuh how gtw
hsio i ert ag ty
ghn ty we ghty
chdi qw oatyf
wet dfla ght a format page A
fetch data for page A
syuh how gtw
hsio i ert ag ty
ghn ty we ghty
chdi qw oatyf
wet dfla ght a
format page B
process actions from
page A
update data
<?php
if $y
?>
<?php
$x =
?>
DB
DB
<?php
$y =
?>
decide what
comes next
view /
presentation
dialogue &
semantics
fetch data for page A

More Related Content

What's hot

Validation and mechanism: exploring the limits of evaluation
Validation and mechanism: exploring the limits of evaluationValidation and mechanism: exploring the limits of evaluation
Validation and mechanism: exploring the limits of evaluationAlan Dix
 
Nota sendiri hci-HCI
Nota sendiri hci-HCINota sendiri hci-HCI
Nota sendiri hci-HCIShafy Fify
 
Extended Walkthrough – Template
Extended Walkthrough – TemplateExtended Walkthrough – Template
Extended Walkthrough – TemplateAlan Dix
 
Sources of Bias and Explanation
Sources of Bias and ExplanationSources of Bias and Explanation
Sources of Bias and ExplanationAlan Dix
 
Modelling interactions: digital and physical – Part 1 – lightning tour
Modelling interactions: digital and physical – Part 1 – lightning tourModelling interactions: digital and physical – Part 1 – lightning tour
Modelling interactions: digital and physical – Part 1 – lightning tourAlan Dix
 
HCI 3e - Ch 3: The interaction
HCI 3e - Ch 3:  The interactionHCI 3e - Ch 3:  The interaction
HCI 3e - Ch 3: The interactionAlan Dix
 
HCI 3e - Ch 13: Socio-organizational issues and stakeholder requirements
HCI 3e - Ch 13:  Socio-organizational issues and stakeholder requirementsHCI 3e - Ch 13:  Socio-organizational issues and stakeholder requirements
HCI 3e - Ch 13: Socio-organizational issues and stakeholder requirementsAlan Dix
 
Design Issues with Microsft Word
Design Issues with Microsft WordDesign Issues with Microsft Word
Design Issues with Microsft WordAbdullah Shiam
 
golden rules of user interface design
golden rules of user interface designgolden rules of user interface design
golden rules of user interface designgadige harshini
 
HCI 3e - Ch 7: Design rules
HCI 3e - Ch 7:  Design rulesHCI 3e - Ch 7:  Design rules
HCI 3e - Ch 7: Design rulesAlan Dix
 
HCI 3e - Ch 10: Universal design
HCI 3e - Ch 10:  Universal designHCI 3e - Ch 10:  Universal design
HCI 3e - Ch 10: Universal designAlan Dix
 
CSE 5930 Assignment 2 Documentation
CSE 5930 Assignment 2 DocumentationCSE 5930 Assignment 2 Documentation
CSE 5930 Assignment 2 DocumentationSalocin Dot TEN
 
User Interface Design in Software Engineering SE15
User Interface Design in Software Engineering SE15User Interface Design in Software Engineering SE15
User Interface Design in Software Engineering SE15koolkampus
 
16 user interfacedesign
16 user interfacedesign16 user interfacedesign
16 user interfacedesignrandhirlpu
 
Exploring GOMs
Exploring GOMsExploring GOMs
Exploring GOMsjbellWCT
 

What's hot (20)

Validation and mechanism: exploring the limits of evaluation
Validation and mechanism: exploring the limits of evaluationValidation and mechanism: exploring the limits of evaluation
Validation and mechanism: exploring the limits of evaluation
 
Nota sendiri hci-HCI
Nota sendiri hci-HCINota sendiri hci-HCI
Nota sendiri hci-HCI
 
Extended Walkthrough – Template
Extended Walkthrough – TemplateExtended Walkthrough – Template
Extended Walkthrough – Template
 
Sources of Bias and Explanation
Sources of Bias and ExplanationSources of Bias and Explanation
Sources of Bias and Explanation
 
Modelling interactions: digital and physical – Part 1 – lightning tour
Modelling interactions: digital and physical – Part 1 – lightning tourModelling interactions: digital and physical – Part 1 – lightning tour
Modelling interactions: digital and physical – Part 1 – lightning tour
 
Hci md exam
Hci md examHci md exam
Hci md exam
 
HCI 3e - Ch 3: The interaction
HCI 3e - Ch 3:  The interactionHCI 3e - Ch 3:  The interaction
HCI 3e - Ch 3: The interaction
 
HCI 3e - Ch 13: Socio-organizational issues and stakeholder requirements
HCI 3e - Ch 13:  Socio-organizational issues and stakeholder requirementsHCI 3e - Ch 13:  Socio-organizational issues and stakeholder requirements
HCI 3e - Ch 13: Socio-organizational issues and stakeholder requirements
 
Design Issues with Microsft Word
Design Issues with Microsft WordDesign Issues with Microsft Word
Design Issues with Microsft Word
 
golden rules of user interface design
golden rules of user interface designgolden rules of user interface design
golden rules of user interface design
 
HCI 3e - Ch 7: Design rules
HCI 3e - Ch 7:  Design rulesHCI 3e - Ch 7:  Design rules
HCI 3e - Ch 7: Design rules
 
Chapter1(hci)
Chapter1(hci)Chapter1(hci)
Chapter1(hci)
 
HCI 3e - Ch 10: Universal design
HCI 3e - Ch 10:  Universal designHCI 3e - Ch 10:  Universal design
HCI 3e - Ch 10: Universal design
 
Hci activity#2
Hci activity#2Hci activity#2
Hci activity#2
 
Hci activity#1
Hci activity#1Hci activity#1
Hci activity#1
 
CSE 5930 Assignment 2 Documentation
CSE 5930 Assignment 2 DocumentationCSE 5930 Assignment 2 Documentation
CSE 5930 Assignment 2 Documentation
 
User Interface Design in Software Engineering SE15
User Interface Design in Software Engineering SE15User Interface Design in Software Engineering SE15
User Interface Design in Software Engineering SE15
 
Vp all slides
Vp   all slidesVp   all slides
Vp all slides
 
16 user interfacedesign
16 user interfacedesign16 user interfacedesign
16 user interfacedesign
 
Exploring GOMs
Exploring GOMsExploring GOMs
Exploring GOMs
 

Similar to Formal 6 – A success story!

The Art of Gherkin Scripting - Matt Eakin
The Art of Gherkin Scripting - Matt EakinThe Art of Gherkin Scripting - Matt Eakin
The Art of Gherkin Scripting - Matt EakinQA or the Highway
 
CQRS recipes or how to cook your architecture
CQRS recipes or how to cook your architectureCQRS recipes or how to cook your architecture
CQRS recipes or how to cook your architectureThomas Jaskula
 
Reinventing the Transaction Script (NDC London 2020)
Reinventing the Transaction Script (NDC London 2020)Reinventing the Transaction Script (NDC London 2020)
Reinventing the Transaction Script (NDC London 2020)Scott Wlaschin
 
JavaScript UI Architecture: Be all that you can be
JavaScript UI Architecture: Be all that you can beJavaScript UI Architecture: Be all that you can be
JavaScript UI Architecture: Be all that you can beKyle Simpson
 
Node.JS| Coffeescript Presentation
Node.JS| Coffeescript PresentationNode.JS| Coffeescript Presentation
Node.JS| Coffeescript PresentationSam Frons
 
Enjoying the full stack - Frontend 2010
Enjoying the full stack - Frontend 2010Enjoying the full stack - Frontend 2010
Enjoying the full stack - Frontend 2010Christian Heilmann
 
Command & [e]Mission Control: Using Command and Event Buses to create a CQRS-...
Command & [e]Mission Control: Using Command and Event Buses to create a CQRS-...Command & [e]Mission Control: Using Command and Event Buses to create a CQRS-...
Command & [e]Mission Control: Using Command and Event Buses to create a CQRS-...Barney Hanlon
 
Brownfield Domain Driven Design
Brownfield Domain Driven DesignBrownfield Domain Driven Design
Brownfield Domain Driven DesignNicolò Pignatelli
 
Map Reduce amrp presentation
Map Reduce amrp presentationMap Reduce amrp presentation
Map Reduce amrp presentationrenjan131
 
Updated: Should you be using an Event Driven Architecture
Updated: Should you be using an Event Driven ArchitectureUpdated: Should you be using an Event Driven Architecture
Updated: Should you be using an Event Driven ArchitectureJeppe Cramon
 
Introjs10.5.17SD
Introjs10.5.17SDIntrojs10.5.17SD
Introjs10.5.17SDThinkful
 
Web Development Foundation & Team Collaboration
Web Development Foundation & Team CollaborationWeb Development Foundation & Team Collaboration
Web Development Foundation & Team CollaborationSupanat Potiwarakorn
 
Application Design - Part 2
Application Design - Part 2Application Design - Part 2
Application Design - Part 2Kelley Howell
 
Evolutionary db development
Evolutionary db development Evolutionary db development
Evolutionary db development Open Party
 
Architecting for Change: An Agile Approach
Architecting for Change: An Agile ApproachArchitecting for Change: An Agile Approach
Architecting for Change: An Agile ApproachBen Stopford
 
Scaling Web Applications with Background
Scaling Web Applications with BackgroundScaling Web Applications with Background
Scaling Web Applications with BackgroundAll Things Open
 

Similar to Formal 6 – A success story! (20)

Web Development with Smalltalk
Web Development with SmalltalkWeb Development with Smalltalk
Web Development with Smalltalk
 
The Art of Gherkin Scripting - Matt Eakin
The Art of Gherkin Scripting - Matt EakinThe Art of Gherkin Scripting - Matt Eakin
The Art of Gherkin Scripting - Matt Eakin
 
CQRS recipes or how to cook your architecture
CQRS recipes or how to cook your architectureCQRS recipes or how to cook your architecture
CQRS recipes or how to cook your architecture
 
Reinventing the Transaction Script (NDC London 2020)
Reinventing the Transaction Script (NDC London 2020)Reinventing the Transaction Script (NDC London 2020)
Reinventing the Transaction Script (NDC London 2020)
 
JavaScript UI Architecture: Be all that you can be
JavaScript UI Architecture: Be all that you can beJavaScript UI Architecture: Be all that you can be
JavaScript UI Architecture: Be all that you can be
 
CSC431_Chap1
CSC431_Chap1CSC431_Chap1
CSC431_Chap1
 
Node.JS| Coffeescript Presentation
Node.JS| Coffeescript PresentationNode.JS| Coffeescript Presentation
Node.JS| Coffeescript Presentation
 
Enjoying the full stack - Frontend 2010
Enjoying the full stack - Frontend 2010Enjoying the full stack - Frontend 2010
Enjoying the full stack - Frontend 2010
 
Command & [e]Mission Control: Using Command and Event Buses to create a CQRS-...
Command & [e]Mission Control: Using Command and Event Buses to create a CQRS-...Command & [e]Mission Control: Using Command and Event Buses to create a CQRS-...
Command & [e]Mission Control: Using Command and Event Buses to create a CQRS-...
 
Brownfield Domain Driven Design
Brownfield Domain Driven DesignBrownfield Domain Driven Design
Brownfield Domain Driven Design
 
Map Reduce amrp presentation
Map Reduce amrp presentationMap Reduce amrp presentation
Map Reduce amrp presentation
 
Updated: Should you be using an Event Driven Architecture
Updated: Should you be using an Event Driven ArchitectureUpdated: Should you be using an Event Driven Architecture
Updated: Should you be using an Event Driven Architecture
 
Introjs10.5.17SD
Introjs10.5.17SDIntrojs10.5.17SD
Introjs10.5.17SD
 
Web Development Foundation & Team Collaboration
Web Development Foundation & Team CollaborationWeb Development Foundation & Team Collaboration
Web Development Foundation & Team Collaboration
 
Mr bi
Mr biMr bi
Mr bi
 
Mr bi amrp
Mr bi amrpMr bi amrp
Mr bi amrp
 
Application Design - Part 2
Application Design - Part 2Application Design - Part 2
Application Design - Part 2
 
Evolutionary db development
Evolutionary db development Evolutionary db development
Evolutionary db development
 
Architecting for Change: An Agile Approach
Architecting for Change: An Agile ApproachArchitecting for Change: An Agile Approach
Architecting for Change: An Agile Approach
 
Scaling Web Applications with Background
Scaling Web Applications with BackgroundScaling Web Applications with Background
Scaling Web Applications with Background
 

More from Alan Dix

From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .Alan Dix
 
Human-Centred Artificial Intelligence – Malta 2024
Human-Centred Artificial Intelligence – Malta 2024Human-Centred Artificial Intelligence – Malta 2024
Human-Centred Artificial Intelligence – Malta 2024Alan Dix
 
The future of UX design support tools - talk Paris March 2024
The future of UX design support tools - talk Paris March 2024The future of UX design support tools - talk Paris March 2024
The future of UX design support tools - talk Paris March 2024Alan Dix
 
Qualitative–Quantitative reasoning and lightweight numbers
Qualitative–Quantitative reasoning and lightweight numbersQualitative–Quantitative reasoning and lightweight numbers
Qualitative–Quantitative reasoning and lightweight numbersAlan Dix
 
Invited talk at Diversifying Knowledge Production in HCI
Invited talk at Diversifying Knowledge Production in HCIInvited talk at Diversifying Knowledge Production in HCI
Invited talk at Diversifying Knowledge Production in HCIAlan Dix
 
Exceptional Experiences for Everyone
Exceptional Experiences for EveryoneExceptional Experiences for Everyone
Exceptional Experiences for EveryoneAlan Dix
 
Inclusivity and AI: opportunity or threat
Inclusivity and AI: opportunity or threatInclusivity and AI: opportunity or threat
Inclusivity and AI: opportunity or threatAlan Dix
 
Hidden Figures architectural challenges to expose parameters lost in code
Hidden Figures architectural challenges to expose parameters lost in codeHidden Figures architectural challenges to expose parameters lost in code
Hidden Figures architectural challenges to expose parameters lost in codeAlan Dix
 
ChatGPT, Culture and Creativity simulacrum and alterity
ChatGPT, Culture and Creativity simulacrum and alterityChatGPT, Culture and Creativity simulacrum and alterity
ChatGPT, Culture and Creativity simulacrum and alterityAlan Dix
 
Why pandemics and climate change are hard to understand and make decision mak...
Why pandemics and climate change are hard to understand and make decision mak...Why pandemics and climate change are hard to understand and make decision mak...
Why pandemics and climate change are hard to understand and make decision mak...Alan Dix
 
Beyond the Wireframe: tools to design, analyse and prototype physical devices
Beyond the Wireframe: tools to design, analyse and prototype physical devicesBeyond the Wireframe: tools to design, analyse and prototype physical devices
Beyond the Wireframe: tools to design, analyse and prototype physical devicesAlan Dix
 
Forever Cyborgs – a long view on physical-digital interaction
Forever Cyborgs – a long view on physical-digital interactionForever Cyborgs – a long view on physical-digital interaction
Forever Cyborgs – a long view on physical-digital interactionAlan Dix
 
Truth in an Age of Information
Truth in an Age of InformationTruth in an Age of Information
Truth in an Age of InformationAlan Dix
 
Rome Seminar: Designing User Interactions with AI
Rome Seminar: Designing User Interactions with AIRome Seminar: Designing User Interactions with AI
Rome Seminar: Designing User Interactions with AIAlan Dix
 
Tools and technology to support rich community heritage
Tools and technology to support rich community heritageTools and technology to support rich community heritage
Tools and technology to support rich community heritageAlan Dix
 
Maps with Meaning
Maps with MeaningMaps with Meaning
Maps with MeaningAlan Dix
 
Democratising Digitisation Tools to Support Small Community Archives
Democratising Digitisation Tools to Support Small Community ArchivesDemocratising Digitisation Tools to Support Small Community Archives
Democratising Digitisation Tools to Support Small Community ArchivesAlan Dix
 
Follow your nose: history frames the future
Follow your nose: history frames the futureFollow your nose: history frames the future
Follow your nose: history frames the futureAlan Dix
 
What Next for UX Tools: from screens to smells, from sketch to code, supporti...
What Next for UX Tools: from screens to smells, from sketch to code, supporti...What Next for UX Tools: from screens to smells, from sketch to code, supporti...
What Next for UX Tools: from screens to smells, from sketch to code, supporti...Alan Dix
 
Apply for 2022 Cohort – Centre for Doctoral Training in Enhancing Human Inter...
Apply for 2022 Cohort – Centre for Doctoral Training in Enhancing Human Inter...Apply for 2022 Cohort – Centre for Doctoral Training in Enhancing Human Inter...
Apply for 2022 Cohort – Centre for Doctoral Training in Enhancing Human Inter...Alan Dix
 

More from Alan Dix (20)

From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .
 
Human-Centred Artificial Intelligence – Malta 2024
Human-Centred Artificial Intelligence – Malta 2024Human-Centred Artificial Intelligence – Malta 2024
Human-Centred Artificial Intelligence – Malta 2024
 
The future of UX design support tools - talk Paris March 2024
The future of UX design support tools - talk Paris March 2024The future of UX design support tools - talk Paris March 2024
The future of UX design support tools - talk Paris March 2024
 
Qualitative–Quantitative reasoning and lightweight numbers
Qualitative–Quantitative reasoning and lightweight numbersQualitative–Quantitative reasoning and lightweight numbers
Qualitative–Quantitative reasoning and lightweight numbers
 
Invited talk at Diversifying Knowledge Production in HCI
Invited talk at Diversifying Knowledge Production in HCIInvited talk at Diversifying Knowledge Production in HCI
Invited talk at Diversifying Knowledge Production in HCI
 
Exceptional Experiences for Everyone
Exceptional Experiences for EveryoneExceptional Experiences for Everyone
Exceptional Experiences for Everyone
 
Inclusivity and AI: opportunity or threat
Inclusivity and AI: opportunity or threatInclusivity and AI: opportunity or threat
Inclusivity and AI: opportunity or threat
 
Hidden Figures architectural challenges to expose parameters lost in code
Hidden Figures architectural challenges to expose parameters lost in codeHidden Figures architectural challenges to expose parameters lost in code
Hidden Figures architectural challenges to expose parameters lost in code
 
ChatGPT, Culture and Creativity simulacrum and alterity
ChatGPT, Culture and Creativity simulacrum and alterityChatGPT, Culture and Creativity simulacrum and alterity
ChatGPT, Culture and Creativity simulacrum and alterity
 
Why pandemics and climate change are hard to understand and make decision mak...
Why pandemics and climate change are hard to understand and make decision mak...Why pandemics and climate change are hard to understand and make decision mak...
Why pandemics and climate change are hard to understand and make decision mak...
 
Beyond the Wireframe: tools to design, analyse and prototype physical devices
Beyond the Wireframe: tools to design, analyse and prototype physical devicesBeyond the Wireframe: tools to design, analyse and prototype physical devices
Beyond the Wireframe: tools to design, analyse and prototype physical devices
 
Forever Cyborgs – a long view on physical-digital interaction
Forever Cyborgs – a long view on physical-digital interactionForever Cyborgs – a long view on physical-digital interaction
Forever Cyborgs – a long view on physical-digital interaction
 
Truth in an Age of Information
Truth in an Age of InformationTruth in an Age of Information
Truth in an Age of Information
 
Rome Seminar: Designing User Interactions with AI
Rome Seminar: Designing User Interactions with AIRome Seminar: Designing User Interactions with AI
Rome Seminar: Designing User Interactions with AI
 
Tools and technology to support rich community heritage
Tools and technology to support rich community heritageTools and technology to support rich community heritage
Tools and technology to support rich community heritage
 
Maps with Meaning
Maps with MeaningMaps with Meaning
Maps with Meaning
 
Democratising Digitisation Tools to Support Small Community Archives
Democratising Digitisation Tools to Support Small Community ArchivesDemocratising Digitisation Tools to Support Small Community Archives
Democratising Digitisation Tools to Support Small Community Archives
 
Follow your nose: history frames the future
Follow your nose: history frames the futureFollow your nose: history frames the future
Follow your nose: history frames the future
 
What Next for UX Tools: from screens to smells, from sketch to code, supporti...
What Next for UX Tools: from screens to smells, from sketch to code, supporti...What Next for UX Tools: from screens to smells, from sketch to code, supporti...
What Next for UX Tools: from screens to smells, from sketch to code, supporti...
 
Apply for 2022 Cohort – Centre for Doctoral Training in Enhancing Human Inter...
Apply for 2022 Cohort – Centre for Doctoral Training in Enhancing Human Inter...Apply for 2022 Cohort – Centre for Doctoral Training in Enhancing Human Inter...
Apply for 2022 Cohort – Centre for Doctoral Training in Enhancing Human Inter...
 

Recently uploaded

Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebUiPathCommunity
 
SALESFORCE EDUCATION CLOUD | FEXLE SERVICES
SALESFORCE EDUCATION CLOUD | FEXLE SERVICESSALESFORCE EDUCATION CLOUD | FEXLE SERVICES
SALESFORCE EDUCATION CLOUD | FEXLE SERVICESmohitsingh558521
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxLoriGlavin3
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLScyllaDB
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024Stephanie Beckett
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek SchlawackFwdays
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii SoldatenkoFwdays
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Mattias Andersson
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Commit University
 
Moving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfMoving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfLoriGlavin3
 
TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024Lonnie McRorey
 
DevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenDevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenHervé Boutemy
 
Generative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information DevelopersGenerative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information DevelopersRaghuram Pandurangan
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brandgvaughan
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 3652toLead Limited
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfAlex Barbosa Coqueiro
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfAddepto
 
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxLoriGlavin3
 
Commit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easyCommit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easyAlfredo García Lavilla
 
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxA Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxLoriGlavin3
 

Recently uploaded (20)

Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio Web
 
SALESFORCE EDUCATION CLOUD | FEXLE SERVICES
SALESFORCE EDUCATION CLOUD | FEXLE SERVICESSALESFORCE EDUCATION CLOUD | FEXLE SERVICES
SALESFORCE EDUCATION CLOUD | FEXLE SERVICES
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQL
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!
 
Moving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfMoving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdf
 
TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024
 
DevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenDevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache Maven
 
Generative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information DevelopersGenerative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information Developers
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brand
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdf
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdf
 
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
 
Commit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easyCommit 2024 - Secret Management made easy
Commit 2024 - Secret Management made easy
 
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxA Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
 

Formal 6 – A success story!

  • 1. formal methods in HCI a success story  
  • 2. problem context – mid 80s – local authority DP dept transaction processing – vast numbers of users – order processing, pos systems etc. – COBOL! existing programs ... didn’t work
  • 3. TP physical architecture central server user corporate database terminal other users N.B. web apps. just like this too
  • 4. what happens user edits form message goes to TP engine passed to application module which processes the message and prepares new screen which is sent to the user .... web server PHP script Java servlet web page
  • 5. structure of programs if .. if .. if .. if .. if .. if .. if ..
  • 6. why? program is trying to work out what is happening! standard algorithm – program counter implicit TP, web, event-based GUI – need explicit dialogue state
  • 7. mixed up state many users – one application module user A starts multi-screen search list application stores value ‘next_record’ user B starts multi-screen search list application overwrites value ‘next_record’ user A selects ‘next screen’ ... ... and gets next screen of B’s search!
  • 8. state is hard why? in real life state is implicit in standard CS state is implicit too! in transaction processing (+web) state needs to be explicit
  • 9. solution? flowchart! not of program ... but of dialogue a formal dialogue specification! Delete D1 Please enter employee no.: ____ Delete D3 Name: Alan Dix Dept: Computing delete? (Y/N): _ Please enter Y or N Delete D2 Name: Alan Dix Dept: Computing delete? (Y/N): _ answer? C2 Finish Finish read record C1 delete record C3 other NY
  • 10. full screen flow chartDelete D1 Please enter employee no.: ____ Delete D3 Name: Alan Dix Dept: Computing delete? (Y/N): _ Please enter Y or N Delete D2 Name: Alan Dix Dept: Computing delete? (Y/N): _ answer? C2 Finish Finish read record C1 delete record C3 other NY
  • 11. details ... miniature screen sketch Delete D1 Please enter employee no.: ____ Delete D3 Name: Alan Dix Dept: Computing delete? (Y/N): _ Please enter Y or N Delete D2 Name: Alan Dix Dept: Computing delete? (Y/N): _ answer? C2 Finish Finish read record C1 delete record C3 other NY Delete D2 Name: Alan Dix Dept: Computing delete? (Y/N): _
  • 12. details ... minimal internal details Delete D1 Please enter employee no.: ____ Delete D3 Name: Alan Dix Dept: Computing delete? (Y/N): _ Please enter Y or N Delete D2 Name: Alan Dix Dept: Computing delete? (Y/N): _ answer? C2 Finish Finish read record C1 delete record C3 other NY answer? C2 delete record C3 other NY
  • 13. and then ... hand transformation to boiler plate code store ‘where next’ for each terminal • in ‘session’ data code starts with big ‘case’ do processing set new ‘where next’ ... send screen
  • 14. lessons useful – addressed a real problem! communication – mini-pictures and clear flow easy to talk through with client complementary – different paradigm than implementation fast pay back – quicker to produce application (at least 1000%) responsive – rapid turnaround of changes reliability – clear boiler plate code less error-prone quality – easy to establish test cycle maintenance – easy to relate bug/enhancement reports to specification and code
  • 15.
  • 16.  and now ... lessons about state  
  • 17. states in web applications (inter alia) persistent (deep) state – the things you are really interested in e.g. an order, images in an album, facebook profile temporary interaction state – part-created or part-edited objects e.g. new cracker setting decoration, joke, etc. placeholder in interaction – current state/mode/location in dialogue pretty clear in database or similar less clear and often confused
  • 18. where state is stored (a) cookies (b) hidden form variables – <input type=“hidden” name=“sid” value=“A378F9E6B2” /> (c) encoded in URL – http://mysite.com/processapp.jsp?sid= A378F9E6B2 (d) session variables – session/transaction id stored using (a), (b), or (c) (e) database or persistent store – as (d) needs identifier or token
  • 19. where state is stored (ctd) More client side (especially AJAX apps) ... (e) JavaScript variables – if ( active ) $(‘#main’).show(); (f) HTML5 local storage key–value or sqlite – localStorage.visitcount++; – t.executeSql('SELECT *FROM docs WHERE id=?', [id], function (t, data) {... } (g) hash at end of URL – http://mysite.com/map.html#long=6:53W&lat=56:29N
  • 20. what goes where? interaction issues: – multiple windows on same app? – privacy and security – ‘back’ button? … and bookmarks danger of ‘resubmitting’ same data implementation issues – ‘garbage collecting’ session data – restarting server often ‘hacked’ not considered lesson – clearly specify the state … and only then map into implementation! why ‘stateless’ often regarded as good … but not necessarly best for interaction!
  • 21. dialogue too … the way it often is … initial prototype linear A then B then … at most one path for each link/button syuh how gtw hsio i ert ag ty ghn ty we ghty chdi qw oatyf wet dfla ght a <?php $x= … ?> code to produce page A syuh how gtw hsio i ert ag ty ghn ty we ghty chdi qw oatyf wet dfla ght a <?php $y= … ?> code for page B user clicks link DB update and fetch data
  • 22. … and the way it goes … initial prototype linear but … later add validation if validation fails page B code needs to produce something ‘like’ page A … and it just keeps getting worse syuh how gtw hsio i ert ag ty ghn ty we ghty chdi qw oatyf wet dfla ght a <?php $x= … ?> code to produce page A syuh how gtw hsio i ert ag ty ghn ty we ghty chdi qw oatyf wet dfla ght a <?php if ($y<1) … ?> code for page B DB syuh how gtw hsio i ert ag ty ghn ty we ghty chdi qw oatyf wet dfla ght a page Bpage A
  • 23. separate dialogue and presentation model dialogue – take into account both user and system branches three kinds of code – gather data for page access database but no updates except logging – format page only code to produce HTML maybe use template engine – post-page process actions validation checks update persistent data choose next page to show syuh how gtw hsio i ert ag ty ghn ty we ghty chdi qw oatyf wet dfla ght a format page A fetch data for page A syuh how gtw hsio i ert ag ty ghn ty we ghty chdi qw oatyf wet dfla ght a format page B process actions from page A update data <?php if $y ?> <?php $x = ?> DB DB <?php $y = ?> decide what comes next view / presentation dialogue & semantics fetch data for page A