FINGPULETQHMRKJVONWXSY
Predictive Drawing based on Spatial Relationships among Segments

Zad joqD u{y Cm3

Thispaper describes a predictive drawing mechanism thatenables the rapid construction of precise diagrams. A predictive drawing system automatically predicts the user's next drawing based on theexisting spatial con guration of line segments, and the user can selectone of the predicted segments by clicking. The user can draw various
diagrams by successive clicking alone as long as the system correctlypredict the intended drawings. The prototype system is implemented
on an interactive beauti cation system, and the prediction mechanism
works successfully as an e ective and unintrusive assistance.
Summary.

ÍÇÏËáë+<ns ¯±·Äsß+þ:7ßKþ:WFnRW7$Zt Ö>s4ûqpLo`mssLEß}¡×nQ7 ë×es~ssQK<Ír#`mt$Zs@*Wì^mR8]sSqü÷rgi7 táë+rGßsÙ
Lü÷ F^d]orjm ë×s?<Í^d¯±·Ä>+ ûð{mR [8] W7VÚntCgrGß rU[d +ÙsóúrkRm>+b
8%V@q£¥¸£t7 ]<rñgßsGßWQues0r~òaSqGßZtcnQ7oRS~sn7òàO@qëmNr%lZ5ksd +Ùot0q ]<r"êbGß"sÚ"@q-0#Ýr%lZd +ÙoqjmR8Vd+Ùt'S@Mß¯±·Äs<rû^mU7Gß sþ"sìÍrbÖrðZ]oü`mR8,97Vd +Ùû`g%¯±·ÄnQ'S@Mß¯±·ÄrkRm!,
r:`gÒ7Vd þ¢hRg ¡¢rkRm\b8kRnd £É¬È²
Äo`mGßsÚ"@q-0#Ýr%lZd ¡ö\`7Üè<T8çÒr7d ¥Ë´¿¦ ±r#b#PæÑrkRm!,r x7zo} x82 wpzsistvw'S@Mß¯±·Ä [2] tÅ ®sRg¿È ±¹Ê ©Vg q';@Jaõñ@r49`mMßÝS¯±·ÄnQ8^r7zWKs`*5bg}rTakeo Igarashi, |!  # ª¸, Satoshi Matsuoka, |! ª¸¼# ¬¼»Á#, Hidehiko Tanaka, |!  # ª¸13

WISS'97a)]1b)©
ä qªØíV¼ËðV²ÍêíxN

¸ìØ%/ÐWÑ¯c)d)Ro èÐ¯!

<NL Ð2W« ¿}® (Interactive Beauti cation)
1.

C¯4

C¯4

C¯4

RoRoRo« ¿}®²¾
2.

IsÔWòòrOL^7Å ®t&Tb~s9©È¶©`m+b]oWnX8
G 1 r'S@Mßr sM`}b8zc7Å ®t¿È ±¹Ê ©r
/GbsßZ (G 1a)8¯±·Ät0.sGßs-0#ÝV]s¿È±¹Ê ©sYgbxX';@JaH b (G 1b)8çÒrH ^g';@JaPH¡?öo`mZ]orMßã>o`msGßOL`>ôb (G 1c)8esé7[0b';@Ja0#@r2Fb]orIsÔOL` ]<rô7Å ®r+^d (G 1d)8'S@Mß¯±·Älhb]or7P4B BoRjgéq3ëÝqS]oqZ7¿È ¼Ëºr o ]<sÔs+oRSõqëÛb]on7éq';@JaYg`gGßNrZ]oW=þrq (G 2)8VÚn>+bd +Ùt7]s'S@Mß¯±·Äs6o`mû^g~snQ7Mßsã>o`mC`RW=`goXr/ñ^8Òn~ xSr7d ã>W,rúqR=àrt9ós¿È ±¹Ê © b]oWnX
sn7d +þzjgZ/÷b]oqZ F}]o~=þnQ8

Predictive Drawing based on Spatial Relationships among Segmentsa)b)¹¦?»®=þc)d)e)9ïL ÐÜvg)9ïL Ð<Á9ïL ÐÜvf)9ïL Ð<Áh)ØíV¼ËðV²Íêí4 RoÊ<NL Ð W

9ïL ÐÜvi)j)L Ð<ÁO=þ

9ïL ÐÜv

« ¨²¬ª²£¾
3.

bv¢[ÐecÆÈnt]
V9nt7d +Ùlh`g WpsSrÝqV\b8]]nt7Å ®Vçg=àr WpsSqþ1nF|Vr5_`m\ÝqR7d£É¬È²Äs÷frkRmtón;`Z\b8¯±·Är d t ë×1JXrÝq7d  ÔW ]<rô^8,97Ù&MhRm\b18]]n7%WçÒr¯ Ër:<^g7BsWd +ÙrjmOL^g Ôb (gh`7 h 2sBh[t'S@Mß2FrjmOL^gIsMßÔnQ)8
1. 'S@MßQRtd  rjmC`RW=b (G 2a)8
2. çÒr=`g (Trigger segment) s0.rd +ÙrjmOL^gós Ô (Predicted segment) Wô^ (G 2b)8
3. ,rújgÔWQue©È¶©b]on+`=b (G 2c)84. =`gWCgq Trigger segment oq7es0.rósd ÔWô^ (G 2d)8
5. 3,4 Ûb]on WF| (G 2e-f)8¤¶{Âª«{¨·¹¥© ¤« §½¹±Ä­´¯³°²|Äº3

1

WISS'97

Ðo²íÆ²¹ÈWï·ôWWï èÐÜv« ¦©µ®³±®¨¤¼~
6. d Ôs2r,rújg~sWqR=àrt7&TbGßsß¿È ±¹Ê ©nZ]or'S@Mß2Fw1Ýb (G 2g-i)87. =`gòCnævd +ÙWðXós ÔWô^8 (G 2j)8]sd  þ¢sç)sõ7t7 d WLÕ`kl[mRÏ7ó oÎd ©È¶©`mRZh[ng qGßZ]oWnXCnQ8'S@Mßos#Ýn{g=àrt7õqd /ñëiodcd ÔW>rõñ
@rOL ô^C7Uvd Wø1`g=àrõqd ý5ëÝqS]
oqZ'S@Mß2Fwõr1ÝnXCW7inQ8]sSq*^@qd /ñ ý52Frjm7Vd +Ùt'S@Mß¯±·Är'bõnÖGsR
6oqjmR8^r7çÒr=`g Trigger segment obh[nqZ7û/s("s©È¶©b]ones Trigger segment o`mes0.rd ÔOLb]o~nX (G 4)8]s+þr7õcq13n6ør F}mRZ]oW=þrq84 riÌgzBx hË¡ÉÅÈbvqyrxuw]]nt7Îêû^mRGßsÚ"@-0#Ýr%lRgd £É¬È²Ärk
Rm\b8gh`7 sd r%lZ ¡öoe]níh^d £É¬È²Ät%V@röHnQ7V£É¬È²Ä,r~g q~sWlh=þnQ8Îêû^mRd £É¬È²Ät, GßsP,  sÛ`, å4<9s
4B ('8Gßs ), 180 EB (C'8Gßs ),90 EB­Â ¹`mU, ebxmWòòrd ^W7]]ntÐ s2FrkRm1r\`m
RZ8GßsPsd%V@qÜT¡t7 C`Z=`goòa~sW ]<rbnr"ê`mR
gqu7C`ZRgs0.r~es'8bs0.rQGßoUqa
SqGßZh SoRS~snQ8,97G 5 MrojmÙ&@qd £É¬È²Äsðë\b8]]nåsG (a-f) td}VmRg~sob8
1. C`R g W=`d W/ñ^o7¯±·Ätzc Trigger oq(g) oò3ßA (8^oÞXWî`R) nQ (a)  ]<V`9b8
4.

4.1

Predictive Drawing based on Spatial Relationships among Segments1)

bahg1)

ciedj2)

f2)

bakchli4)

jdfem3)n« «´°¨­´¯³°² (": ³£¨)5.

2. a o g Wò3ßAnQoVjgsn7¯±·Ät g s0.r~ a s0.rQ
 (Ù&@rt b s.Cr9`mR)  b, c, d oòaSqGßZnQ Sod `7d Ô h, i, j OLb8
3. Å®W j +boâEt j W d Uv e oò3nQsn7 d s0.s
 a, c, f Uv e s0.s b, c, f «¾ `mZ]or d Ôi, k Uv l, m, n WOL^8,Þ7]Ûb]orGß&sPWûÎ^8Pt3lk'S@rÝqmRZsn7&3ûrPbh[nqZ3h[0qGßZ]o~õrÝqT8PëèVZÛb]onG 4 4sSqGßs
 ~=þnQ8zo}o7GßsPësd t,9sSr. ^£É¬È²ÄrjmûÎ^81. çÒrVg (Trigger segment) oò3ßA (8^UvÞXW31b)nQ (Reference segment)  ]<­ µ`m3}82. Reference segment o9`mR (Context segment) 3}es"s#Ý.Rb83. Reference segment o Context segment s"s-0#Ý (!#Ý) W7 Triggersegment o  d sã>nQ Predicted segment s"s-0#Ýo'8b
Sr7 Predicted segment OL`môb8
 d £É¬È²Äs6Reference segment o`m7 Trigger segment oò3ßAnQr<Tm,9rsxg q)S]or7'8GßBGßs d qpW=þoq8
4.2

WISS'97

90Ò&&180Ò&(%ù)

hahabbd gedecgcff« ¨« 90,180 ~«²¨
6.

1)

2)

3)

4)

« ¨¬ª¨«²
7.

'8Gßs d t7 Reference segment o`m Trigger segment <9å4r
4B`g~s<T]onûÎ^8MG 6år`}b8 d W Vgò
Cn7 a W d så44BnQ]oV a r`mR b,c ~or d Ô e,f
W7 a W d s<94BnQ]oV a r`mR b,c ~or d Ô g,h W
OL^8]sSq2FÛb]onG 7sSq'8Gßs WûÎ^
8ògr`m, Reference segment o`m Trigger segment  90 EB`g~s<T]on7 90 EBGßs d WûÎ^ (G 627)8180 EBGß (C'8Gß) s d t7 Reference segment o`m Trigger segment  180 EB`g~s<T]onûÎ^8G 64rMôb8 d WVgò, a W d oò3nQoòòr 180 EB`g~sn~Qg}7 f,g r<Tme 180 EB`g e,h òòrOLb8^r7]s 180 EBý)S+Ùo7õõE (Trigger segment)  Reference segment obõÑê6+Ù{àd]onG 8sSqd ~=þoq8]]n7 b WVgòCn7 b t b õE 180 EB`g~soò3nQg}7 a  180 EB`g c Wd Ôo`mOL^mR8

Predictive Drawing based on Spatial Relationships among Segments

1)

2)

3)

bca1)

2)

3)

abc

Ðo¹¦c»®=þ«8.

180xNWïL 2W~ÃÀ¦¬ª²¨Isd +Ùsòòñëûés¥Ë´Ç©¯ÆËrURmt7,<sSqd £É¬È²ÄWòòrðZ]or$Zsd ÔWòòrOL^ô^8G 9rÎêsûrURmOL^
Ô3àsMoefsd sOLäÒôb8qU7g q¡¢rd s
ã>o`mßAUv-0WÖr31bÔWIOL^g=àrt73kì`mìtÿ*^8zg7OL^gÔoò3sWbnr ]<r"ê`mR
g=àr~7esÔtÿ*^84.3

Wï·îÁc» (Predicted Segment)8È»í Context Segment8È»í Reference Segment

eaTrigger..hidbhgcfdefgiaccahbbbbb

&
&Y&Y&180Ò& (düW)

dehgcbcbaaaa180Ò&180Ò&¿Ðàà¿Ðàà

adebbbccc

Y& (düW)
180Ò& (düW)
& (düW)

dea

Trigger..fg

fbchab
Trigger..ccde« ²¨¾: ¨·¯­¡
9.

WISS'97

Trigger
Predicted
Trigger«5

Predicted10.

¢Ä¥«§ ¨¾: }}

£oVþ¢t7;>s §¸¤´ CAD ¯±·Ä rURmíhb]o~=þnQW7,9sFcV'S@Mß¯±·ÄrõrA`gþ¢oRT8 C`RW ]<spso'8bVW'S@Mß2FsA?n\VrqjmR8
 'S@MßrU[IÔ+¥Ë´¿¦ ±o7d  rU[d Ô+¥Ë´¿¦ ±WÖ; (ÔW ]<ròòrô^79©È¶©b]on+WÝq) nQ8 ©È¶©tÔs+ (=) n7±¥ ÁtsúKnQ7oRSSr Å®úKs/ZW\nQ7d s/ñUvý5ÝqSg}rõq«ÃËº/ñbiWqR8Îêû^mRd £É¬È²ÄsÏo`m79`mRqR"s#ÝlhnXqRoRS`*7Uv û/EnsB­Â ¹`mRqRCWÓ
\8]sSq#Ýlhb]or7G 10sSq d W=þoq
o)(^8zg)842F<T]onñGßs ~=þrq8`V`7d sÿLboeh[d ã>o`mOL^ÔsIWT
[nQ7 ]<rô^ÔsIWTAYmÔ+Wãùrq$ÌWQ8Îêsd +ÙszznQjm~7GßWérqjmXg=àrtd ÔIs23W[qRg}7Vd +Ùsûh:sg}rtqVs¡¢nd ÔsOLJÏb+Ù{á|iWQ8OLd ÔIJÏb¡¢o`m7Îê,9sSqþ¢åï`mR8
 ò"@UvÚ"@ØKlhb8bqi7çØRgØZss{d säÒo`mlhb8 Å ®rd säÒo`míhb (Reference Uv Context segment) 9î=^d8
 d ÝqSér7Ð s"s'8çh[nqZ7'kVszo}mes-0#ÝÜIb8 2+þeb8bqi7Å ®sÔ+mNVÅ ®sZlhb
d @äoeSnqR~s2`7iqÔOL`qRSrb8]sÔIÛ]{þ¢t7eszz'S@MßsMßÔIsìÍr~lhb]oWnX8õr7ê6b9î=^d¡¢t'S@Mßod +Ù
nÖ;s¥Ë´¿¦ ±lhnXo)(^sn>rbÖoÜT8

Predictive Drawing based on Spatial Relationships among Segments

6nlf

Å ®¥Ë´¿¦ ±rU[d +Ù7QRt Programming By Example(PBE)rë×s7K: õñ:sæÑtI$ZÝqmR [6][1][5][10]8]t7¯±·ÄWÅ ®sëmNV-K49`7es? r%lRmósëdQRt73Psë×sõñ:ÝqR7Å ®së×þIÍeSoRS~snQ
8]sSqëmNVsd ¥Ë´¿¦ ±nt-Ks49sérAq5:
ÝqR7zg¥Ë´¿¦ ±Ø`mÅ ®sëU\qRSrb]onQ?EsÖ>WômR8
VÚn>+`gþ¢t7]sd +ÙGß r8h`g~sn7ë«ÃËºsòàO<s-KsVrGßsÚ"@q-Klhb8Å ®s_rç
TqRë«ÃËºO)SsnqZ7 ]<r"êb¨À°¦©¹s-0#Ýs{d säÒob]on9@nF`bRd ñëoqyV7 13r
qR36@qd W=þoq8zg7d +Ùr=q`*o`md Ós`*WQW7Vþ¢td IOL`mÅ ®r9udSrb]ond Ósç4ÏrjTmR8Gßs~kÚ"@q-0#Ýlh`g¯±·Äo`m [4][9] qpWQ8]
t7d}î=`g3=sÚ"@-0#ÝYgb¨À°¦©¹Ü ]<V-`9`7d}î=`g ÝSoRS~snQ sd +Ùo~#PWDRW7V¯±·ÄtõqÉ ÉhR]oqZ ]<s¨À°¦©¹s-0#Ýs{lhbC("Gßs nqZ sd ÝqSCn0qjmR87 ÎÊÏ ¯±·ÄrU[d +Ùo`m75ksò"@qës-Kr%lZH rV
7Gßs~kÚ"@q-Kr%lZd +Ù>+`g8]s¡¢t7_rçTqRëmNlhbsnqZ7>r_rçTmR/@qKú [3][7] lh`m
RoRSCn9@nF`bR¥Ë´Ç©¯ÆËoRT8^r7ûér]sd +Ù'S@Mß¯±·Äs<rû`,  sÛ`GßsP4B Bës7K:rbÖrðZ]oü`g8õr7d WSzZðRmRÏrURmt7&Tb ]<n1r©È¶©`mRZh[n^z_zqGßZ]oWnXSrqjmU7 sþ"s)qìÍûÎ`mR8d +ÙrURmt36@rd sø1QRtiqd ñëws'2W`*oqW7d ã>+=þqIÔo`m>ô`7'S@Mß2Fwsõq1Ý¥Ë´¿¦ ±>Õb]on]s`*â`mR8
âÒt7Bîs#sGß@Kúsd ýánRZoo~r7d +Ù6b]or)84Bqps+þûÎ`mRZd=nQ8zg7â:`gd £É¬È²Ät 13rqRÚ"@q-Kr%lZ~snQj
gW7ëmNrU[-K (Û`) lh`gd os{àd~=þnQoÜT7]s¡×ns6~åï`mR8`_VæÑÝqSrQgb6q£º½¥±9^jg³» CSL s2 ýï7q
vr TRIP ªÉ ÁUv íÔ)Ø D25æÑùsgrü1`zb9

WISS'97^\pk[1] Cypher,A. \EAGER: Programming repetitive tasks by example." Proc.of CHI'91, pp.
33-39, 1991.
[2] Igarashi,T., Matsuoka,S., Kawachiya,S., Tanaka,H., \Interactive Beauti cation: A
Technique for Rapid Geometric Design", Proc. of UIST'97, 1997, (in press).
[3] Igarashi,T., Matsuoka,S., Masui,T., \Adaptive Recognition of Human-Organized Implicit Structures", Proc. of Visual Languages '95, pp. 258-266, 1995.
[4] Kurlander,D. Feiner,S., \Interactive Constraint-Based Search and Replace", proc.ofCHI'92, pp.606-618, 1992.
[5] Masui,T. and Nakayama,K., \Repeat and predict - two keys to ecient text editing",
Proc. of CHI'94, pp. 118-123, 1994.
[6] Maulsby,D.L., Witten,I.H, Kittlitz,K.A., \Metamouse: Specifying Graphical Procedures by Example", Computer Graphics, Vol.23, No.3, pp.127-136, 1989.
[7] Saund,E., Moran,T.P, \A Perceptually Supported Sketch Editor", Proc.of UIST'94,
pp. 175-184, 1994.
[8],,,,\",
IV(WISS'96), pp.71-80, 1996.
[9],, \Visual Dispatch: Visibility",
IV(WISS'96), pp.61-70, 1996.
[10],, \PDraw:",
IV(WISS'96), pp. 91-100, 1996.

'¶¹ ÃÆ ÂÉÌ ÐÓ Ø& Ú ¿¼ %Ñ ·º¾Ô(êÏÁâéÒëÕÇç½$åÈÛ ò6û4öüñ0øùü2åúÿþóôðÀ¿ Þµ ÍÊ ÐÅæíäáð15÷7ø36Ä»Ö ò6û4öüñ0øùü2åúÿþóôðÍÊ ÐÅ À¿ ÞµÙÎ×àìßïÜæèåäáËÝî¸ãàÒëõýñû
ò6û4öüñ0øùü2åúÿþóôð