rethinking software design Daniel Jackson CSAIL MIT SATURN - - PowerPoint PPT Presentation

rethinking software design
SMART_READER_LITE
LIVE PREVIEW

rethinking software design Daniel Jackson CSAIL MIT SATURN - - PowerPoint PPT Presentation

rethinking software design Daniel Jackson CSAIL MIT SATURN Conference San Diego May 4, 2016 what is software design? designers & engineers designer engineer elements door, window, wall column, beam, truss comfortable,


slide-1
SLIDE 1

SATURN Conference · San Diego · May 4, 2016

rethinking software design

Daniel Jackson · CSAIL · MIT

slide-2
SLIDE 2

what is software design?

slide-3
SLIDE 3

designers & engineers

designer engineer elements door, window, wall column, beam, truss goals comfortable, convenient, attractive structural integrity, durable, sustainable

slide-4
SLIDE 4

designers & engineers

designer engineer elements function, object, type goals learnable, effective, tolerant maintainable, correct, fast

?

slide-5
SLIDE 5

the role of design criteria

designer engineer elements function, object, type goals learnable, effective, tolerant maintainable, correct, fast

? ?

criteria decoupling & localization

slide-6
SLIDE 6

OBSESSIVE DETAILS AHEAD

slide-7
SLIDE 7

That’s quite obsessive, isn’t it?

Jonathan Ive in “Objectified”

The details are not the details. These make the design.

attributed to Charles Eames by Garrett

slide-8
SLIDE 8
slide-9
SLIDE 9

survey of MIT dropbox users

0% 20.0% 40.0% 60.0% 80.0% good knowledge average knowledge poor knowledge correctly predicting behavior

delete shared folder results in leaving delete shared subfolder removes it

Kelly Zhang

slide-10
SLIDE 10

3

software design problems

slide-11
SLIDE 11

#1

email categories

slide-12
SLIDE 12

gmail’s categories

slide-13
SLIDE 13

category tab settings

slide-14
SLIDE 14

some reactions

slide-15
SLIDE 15

categories? labels?

slide-16
SLIDE 16

how google explains labels (!)

slide-17
SLIDE 17

what you can’t do

associate tabs with labels feature available only for categories use tabs outside inbox tabs disappear when you filter on a label

slide-18
SLIDE 18

#2

camera settings

slide-19
SLIDE 19

my camera fuji x100s

slide-20
SLIDE 20

image quality setting

slide-21
SLIDE 21

aspect ratio

slide-22
SLIDE 22

image size setting

slide-23
SLIDE 23

non-standard ratio + raw?

slide-24
SLIDE 24

what you can’t do

non-standard aspect ratio + raw even though raw images get nice nondestructive crop!

slide-25
SLIDE 25

#3

fonts & styles

slide-26
SLIDE 26

what’s a font?

slide-27
SLIDE 27

what you can’t do

define a style that italicizes Arno Regular to Arno Italic Futura Book to Futura Book Oblique Magma Light to Magma Light Italic

slide-28
SLIDE 28

what kind of problems are these?

minor nitpicks? in all cases, can’t do useful things coding bugs? code seems to meet a coherent spec user interface flaws? interfaces are clear and faithful to function

slide-29
SLIDE 29

getting to the essence

  • f an app
slide-30
SLIDE 30

what characterizes an app?

Apple Mail Microsoft Word Twitter EmailAddress Message Folder or Label Paragraph Format Style

concepts!

Tweet Hashtag Following Photoshop PixelMap Layer/Mask Adjustment

slide-31
SLIDE 31

concepts define classes

text editor line buffer paragraph format style word processor stylesheet text flow page template desktop publishing app

slide-32
SLIDE 32

where are Word’s concepts from?

Charles Simonyi: brought key concepts to Word from Xerox PARC

slide-33
SLIDE 33

rich concepts have long journeys

Bravo, 1974 Ginn & Co, since 1868 Microsoft Word, 1983 Apple Pages, 2005

slide-34
SLIDE 34

kinds of concept

given concepts electoral vote reservation social security number calendar event instrumental concepts hashtag label friend follower enabling concepts relative reference public key layer mask conference call

even these were invented analogical,

  • r new

solve a hard design problem

slide-35
SLIDE 35

how to sketch a concept

slide-36
SLIDE 36

how would you explain this?

slide-37
SLIDE 37

the operational principle

a way to explain a concept an archetypal scenario separates essential from accidental aspects shows how purpose is fulfilled by combination of user & system actions

Michael Polanyi “if you pull a tab out, then when that time slot comes around, the light will go on”

slide-38
SLIDE 38

“if you change a style’s format, then all paragraphs of that style will change format accordingly” “if you tag a photo, then all friends of the person tagged will be able to see the photo” “if you select some files and they belong to a folder with keyboard focus, then pressing delete will move the files to the trash” “if you pull a tab out, then when that time slot comes around, the light will go on”

slide-39
SLIDE 39

purposes, principles & misfits

concept: trash

  • perational principle: if you delete a file, it moves to a

special folder; you can restore from there, but emptying it removes contents for good (and makes space on disk) purpose: allow undo of deletions misfit: if you delete a file on an external drive, you cannot reclaim the space until you empty the trash, but then you’ll lose the ability to restore files deleted from the main drive misfit: if you delete an old file and change your mind, you may not be able to find it again in the trash (if there are many deleted files and you forgot the file’s name)

slide-40
SLIDE 40

how to model a concept

slide-41
SLIDE 41

example word styles

slide-42
SLIDE 42

data model word styles

Style Paragraph Rule Property property ! Value ! value style !

  • verrides

rules StyleName ! name Stylesheet styles Document sheet ! paras basedOn ?

There is no problem in computer science that cannot be solved by introducing another level of indirection. David Wheeler

  • perations

add delete modify update apply

slide-43
SLIDE 43

concept dependences

stylesheet style paragraph format text

⟨c,c’⟩ ∈ depends ⇔ ∀a: apps · c ∈ concepts(a) ⇒ c’∈ concepts(a)

emacs Stickies TextEdit Word OpenOffice

slide-44
SLIDE 44

how to reuse a concept

slide-45
SLIDE 45
  • ther instantiations style

Powerpoint schemes Indesign swatches

slide-46
SLIDE 46

non-instantiations style

Apple color picker Write 2 text editor swatch-color mapping fixed no para-style mapping

slide-47
SLIDE 47

base

style generic concept

Element style Style rules Rule Property Value value property ! ! ? Style basedOn Style next ? Stylesheet styles Style Style Name name

add ons

Element style Name

variants

slide-48
SLIDE 48

generic concept parts

part example

name Style purpose make it easy to maintain consistent format across set of elements sample uses Text formatting in word processors/layout apps (Word, Indesign, Pages, etc); rules in CSS; color themes in Powerpoint. model base, add-ons, variants

  • perations

add, delete, modify, apply, update related to StyleBuffer, Stencil, Master issues

  • ptional rules problem
slide-49
SLIDE 49

concept selection

slides in Keynote messages in Apple Mail photos in Adobe Lightroom

  • bjects in OS X Finder

thumbnails in Preview notes in Evernote

slide-50
SLIDE 50

subtlety selection scope

subset of selection in scope subset of selection out of scope

slide-51
SLIDE 51

subtlety active element

Adobe Lightroom: brightest thumbnail is the “active photo”

slide-52
SLIDE 52

subtlety continuous selection

Photoshop: outline shown with “marching ants” Photoshop: selection shown in Quick Mask mode

slide-53
SLIDE 53

subtlety folder selection

Google Drive: selecting folder = selecting children CrashPlan: selecting folder = selecting all future children

slide-54
SLIDE 54

concept selection

base

Workspace Selection Element selection elements

addons

Workspace View Element current view elements ! Item Element Group members ?

Selection Element active ?

Purposes: apply action in aggregate to many items at once

slide-55
SLIDE 55

concept catalog (so far)

instantiate

  • rganize

relate resource save communicate personalize stylesheet selection friend access token history message account master folder clique notification buffer posting karma stencil group invitation reservation cursor OOBA style buffer label REST sync rating layer cart export status stack subscription alias purchase order preset RMA cursor coupon filter catalog property metadata

slide-56
SLIDE 56

how to evaluate a concept

slide-57
SLIDE 57

the fundamental principle

in a well-designed system each concept is motivated by one purpose

slide-58
SLIDE 58

the ideal mapping

P1 C1 P2 C2 purposes concepts

slide-59
SLIDE 59

4 bad smells

P1 C1 P2 P1 C1 C2 P1 C1 C2 P1 C1 P2

unfulfilled purpose unmotivated concept

  • verloaded concept

redundant concepts

slide-60
SLIDE 60

unfulfilled purposes

P1 C1 P2 C2

Adobe Indesign: an unfulfilled purpose subfamily allow typeface independent styling

slide-61
SLIDE 61

unfulfilled purposes (more)

P1 C1 P2

user (Apple Mail, Gmail) ‘identify parties to communication’ weak search, no authentication slide hierarchy (Powerpoint) ‘structure slides in a tree’ sections provide just one level eject-after-import (Lightroom) ‘prevent accidental writing’ feature removed (and reinstated!) binder (Preview, Acrobat) ‘maintain composite PDF doc’ can insert pages, but forgets source

C2

slide-62
SLIDE 62

P1 C1 C2

unmotivated concepts

slide-63
SLIDE 63

unmotivated concepts (more)

buffer (text editors) Apple got rid of it stash (Git) addresses branching misfits boxing (Java) addresses primitives vs objects misfit null (Javascript) when undefined is too vague

P1 C1 C2

slide-64
SLIDE 64

P1 C1 C2

redundant concepts

category in Gmail a redundant concept label classify messages category

slide-65
SLIDE 65

redundant concepts in acrobat

text object, text box, document text (Acrobat) all subtly different (Acrobat 10) merged into one (Acrobat 11)

slide-66
SLIDE 66
  • verloaded concepts

3 forms of overloading: piggybacking new purpose hacked onto old concept false convergence two purposes looked the same emergent purpose users found second purpose for concept

No one can serve two masters. Either you will hate the one and love the other,

  • r you will be devoted to the one and despise the other. [Matthew 6:24]

P1 C1 P2

slide-67
SLIDE 67

piggybacking fuji camera

image size aspect ratio piggybacked

  • n JPEG dimensions

new purpose hacked onto old concept

slide-68
SLIDE 68

piggybacking epson driver

result: can’t create custom size for front loading also, page size presets in Lightroom hold feed setting

slide-69
SLIDE 69

false convergence

evaluation & goal setting incompatible purposes

two purposes looked the same

slide-70
SLIDE 70

false convergence

two purposes looked the same

filter incoming posts control access to my posts distinct purposes 2011: Facebook added subscribe/follow

slide-71
SLIDE 71

emergent purpose

users find second purpose for concept

initial purpose: summarize content emergent purpose: show sender if you bcc a list, subject reveals to-address

thanks to Shriram Krishnamurthi

emergent purpose: group by conversation can’t label reservations from Expedia by trip

thanks to Eunsuk Kang
slide-72
SLIDE 72

gitless: a case study

slide-73
SLIDE 73
slide-74
SLIDE 74

gitless: a reworking of git

Santiago Perez De Rosso

slide-75
SLIDE 75

example: branch

concept: branch

  • perational principle: when you switch branches, your

working directory is synchronized with the new branch, and you can make and commit changes which will be invisible on other branches; when you’re done, you can merge the branch into the master branch... purpose: support independent line of development misfit: can’t switch branches with uncommitted changes; can stash, but only if no conflicts... fix: give branch its own working directory; when you switch branches, the working directory changes too, and the working directory associated with the previous branch is preserved

slide-76
SLIDE 76

results of a user study

18% 0% 9% 36% 73% 64% 64% 55% 5% 9% 27% 18% 14% 27% 27% 9% 18% 27% 18% 18% 5% 36% 9% 27% 5% 18% 18% 14% 9% 18% 5% 9% 9%

I would continue using Gitless if I could I found Gitless to be easier to use than Git I found Gitless to be easier to learn than Git I enjoyed using Gitless 100 50 50 100

Percentage

Strongly Disagree Disagree Disagree Somewhat Neutral Agree Somewhat Agree Strongly Agree

Git Gitless 1 2 3 4 5 6 7 8 Task completion time (minutes) Git Gitless 4 5 6 7 8 9 Task completion time (minutes) Git Gitless 4 6 8 10 12 Task completion time (minutes) Git Gitless 5 10 15 Task completion time (minutes) Git Gitless 5 10 15 20 Task completion time (minutes) Git Gitless 4 6 8 10 12 14 Task completion time (minutes)
slide-77
SLIDE 77

conclusions

slide-78
SLIDE 78

designer engineer elements function, object, type criteria decoupling & localization goals learnable, effective, tolerant maintainable, correct, fast

? ?

concepts, purposes 1:1 = concept:purpose

slide-79
SLIDE 79

R D I T R R D D I I T T

client developer

waterfall

client developer

I T I I T T agile

client developer

I T R D I T D I T D R design thinking but how to choose increment? how to structure design step?

slide-80
SLIDE 80

a software design approach

users developers increments purposes concepts criteria patterns dependences

structured needs of built by evaluate suggest related by

  • rganize

drive motivate

slide-81
SLIDE 81

a common view of software design

UI design soft & human about presentation programming hard & technical about content

slide-82
SLIDE 82

a better view of software design

conceptual design: essential concepts & behavior representation design:

  • rganization & performance

Layer Adjustment Mask PixelMap Brush