@costrict/csc 4.1.1 → 4.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{chunk-456jxy81.js → chunk-03g34taj.js} +55 -52
- package/dist/{chunk-mdmh4hh4.js → chunk-04h1dzn8.js} +58 -55
- package/dist/{chunk-3xwn1ww1.js → chunk-04js9982.js} +14 -14
- package/dist/{chunk-gfsh3syp.js → chunk-0cm9fcaq.js} +4 -4
- package/dist/{chunk-fnjqn6ez.js → chunk-0d8p649e.js} +200 -1296
- package/dist/{chunk-vtwf9pyn.js → chunk-0ftbdtb6.js} +2 -2
- package/dist/{chunk-7kznscxn.js → chunk-0kv76cch.js} +69 -66
- package/dist/{chunk-cp4da168.js → chunk-0q8601fc.js} +56 -53
- package/dist/{chunk-vhnm2h49.js → chunk-0s2qjxt0.js} +2 -2
- package/dist/{chunk-wvexwzsv.js → chunk-0vjhwg78.js} +4 -4
- package/dist/{chunk-wvh4g9jt.js → chunk-0wfby4jk.js} +55 -52
- package/dist/{chunk-d9tcjh43.js → chunk-0wzfz235.js} +55 -52
- package/dist/{chunk-8py19hja.js → chunk-0z3swktk.js} +58 -55
- package/dist/{chunk-na7nxj7y.js → chunk-0zwtzj7s.js} +4 -4
- package/dist/{chunk-304wjbyj.js → chunk-12b1dsca.js} +3 -3
- package/dist/{chunk-c05zaj6g.js → chunk-172aq1cm.js} +3 -3
- package/dist/{chunk-emvhjwh9.js → chunk-1928vvnf.js} +16 -16
- package/dist/{chunk-3yc8k84c.js → chunk-1gta3pqg.js} +26 -1390
- package/dist/{chunk-wn11yvgy.js → chunk-1hr30g9j.js} +56 -53
- package/dist/{chunk-hyptxmaj.js → chunk-1ta87008.js} +13 -13
- package/dist/{chunk-pjvthvm1.js → chunk-1tsg5bqp.js} +7 -7
- package/dist/{chunk-9ey1xvcm.js → chunk-1xdybmyp.js} +2 -2
- package/dist/{chunk-bz6pjkch.js → chunk-1xqh8b38.js} +2 -2
- package/dist/{chunk-p2r92sj1.js → chunk-1z6393pz.js} +55 -52
- package/dist/{chunk-js10hr63.js → chunk-20rdctr8.js} +59 -56
- package/dist/{chunk-78kph36p.js → chunk-2278qvvz.js} +82 -69
- package/dist/{chunk-krmmbjp9.js → chunk-27rca2qk.js} +14 -14
- package/dist/{chunk-b1my2ag9.js → chunk-28p3x5mq.js} +58 -55
- package/dist/{chunk-5nnjgn3n.js → chunk-29n8fs0h.js} +3 -3
- package/dist/{chunk-4xbk1cv1.js → chunk-2bahqsy8.js} +5 -5
- package/dist/{chunk-b0hjzm3t.js → chunk-2d4az1sb.js} +1051 -213
- package/dist/{chunk-bbm8cs3b.js → chunk-2dtsff0m.js} +2 -2
- package/dist/{chunk-hjfabpxk.js → chunk-2dvsb5m8.js} +3 -3
- package/dist/{chunk-fkjqakzs.js → chunk-2ea63hn5.js} +55 -52
- package/dist/{chunk-tbx1hn1a.js → chunk-2heyngx7.js} +55 -52
- package/dist/{chunk-cb3vp4tb.js → chunk-2n4jnkr3.js} +5 -5
- package/dist/{chunk-04fesxxb.js → chunk-2npy5n4d.js} +3 -3
- package/dist/{chunk-5bw23taw.js → chunk-2yz7ej7r.js} +3 -3
- package/dist/{chunk-naenwsts.js → chunk-347n8wrb.js} +56 -53
- package/dist/{chunk-qzwja18r.js → chunk-365z3p8q.js} +4 -4
- package/dist/{chunk-pathr6ec.js → chunk-3ax3g4ky.js} +5 -5
- package/dist/{chunk-6nqv04m4.js → chunk-3c22f5y8.js} +4 -4
- package/dist/{chunk-5x884kq9.js → chunk-3ed5qycn.js} +59 -56
- package/dist/{chunk-ctw9a4hh.js → chunk-3hw6pcqt.js} +12 -12
- package/dist/chunk-3j0f3yyd.js +20 -0
- package/dist/{chunk-g2r5nsx7.js → chunk-3keyh8d3.js} +2 -2
- package/dist/{chunk-hegr0s7q.js → chunk-3n8prx9k.js} +3 -3
- package/dist/{chunk-cqnfwapm.js → chunk-3tnabt1t.js} +2 -2
- package/dist/{chunk-837h4x1j.js → chunk-3ydfy1vc.js} +2 -2
- package/dist/{chunk-1qw175nj.js → chunk-41ncbfk7.js} +3 -3
- package/dist/{chunk-60731s4z.js → chunk-45ynv6r6.js} +2 -2
- package/dist/chunk-46sfycpp.js +125 -0
- package/dist/{chunk-cg0h6vpf.js → chunk-496449vy.js} +2 -2
- package/dist/{chunk-qhpnsf4r.js → chunk-49z79885.js} +3 -3
- package/dist/{chunk-25j8nzw3.js → chunk-4c8mdzm1.js} +4 -4
- package/dist/{chunk-3dkccqes.js → chunk-4f56n8y8.js} +4 -4
- package/dist/{chunk-1mft5mam.js → chunk-4ffz1d36.js} +4 -4
- package/dist/{chunk-4zqzdz62.js → chunk-4hgk89n9.js} +59 -56
- package/dist/{chunk-exag2njg.js → chunk-4k4kn7h2.js} +18 -18
- package/dist/{chunk-1yzryj0w.js → chunk-4ks3c21q.js} +64 -61
- package/dist/{chunk-e29wgmh7.js → chunk-4v3p8phf.js} +15 -15
- package/dist/chunk-4vzg1cn7.js +264 -0
- package/dist/{chunk-cxktxwv9.js → chunk-4xp653hr.js} +55 -52
- package/dist/{chunk-r1sfk1j6.js → chunk-4zvptd40.js} +60 -57
- package/dist/{chunk-v2gsemps.js → chunk-503675yy.js} +2 -2
- package/dist/{chunk-gf3t5h70.js → chunk-52d0caw3.js} +58 -55
- package/dist/{chunk-x0vsajns.js → chunk-56speggn.js} +3 -3
- package/dist/{chunk-rhndt0ek.js → chunk-58jcwxyh.js} +14 -14
- package/dist/{chunk-pv7jrynh.js → chunk-5bd0sf0q.js} +2 -2
- package/dist/chunk-5cxetff3.js +443 -0
- package/dist/{chunk-q0j190dz.js → chunk-5dm3xwms.js} +6 -6
- package/dist/{chunk-gn0d6g6p.js → chunk-5e4sk6wr.js} +3 -3
- package/dist/{chunk-a66xp7jk.js → chunk-5fny1a0a.js} +37 -13
- package/dist/{chunk-57h3kd2w.js → chunk-5hn85d4q.js} +58 -55
- package/dist/{chunk-jxefgv2b.js → chunk-5p3bwhcw.js} +5 -5
- package/dist/{chunk-09af0bmq.js → chunk-5r57a99p.js} +15 -15
- package/dist/{chunk-egv3k4gg.js → chunk-5thf5z45.js} +136 -44
- package/dist/chunk-5vbtjcd2.js +624 -0
- package/dist/{chunk-jpd98chs.js → chunk-5w9qcjjt.js} +61 -58
- package/dist/{chunk-wvevgh1a.js → chunk-5xj3z42h.js} +5 -5
- package/dist/{chunk-0hr0mh6d.js → chunk-62r8rxkw.js} +4 -4
- package/dist/chunk-64wm5777.js +85 -0
- package/dist/{chunk-sk9mmh7x.js → chunk-6a32d602.js} +55 -52
- package/dist/{chunk-1wxx3s6s.js → chunk-6aevda19.js} +2 -2
- package/dist/{chunk-2km8scdk.js → chunk-6bb0gyhh.js} +55 -52
- package/dist/{chunk-ancr20tb.js → chunk-6d9njm1w.js} +2 -2
- package/dist/{chunk-p3erbvbz.js → chunk-6fbvxhan.js} +3 -3
- package/dist/{chunk-7t9j97cz.js → chunk-6kddkcqk.js} +57 -54
- package/dist/{chunk-7nyptyee.js → chunk-6sytfk68.js} +5 -5
- package/dist/{chunk-8z5fmqh3.js → chunk-6ypvw68g.js} +55 -52
- package/dist/{chunk-z763jd56.js → chunk-6zkxtny0.js} +4 -4
- package/dist/{chunk-p60wnp9a.js → chunk-6zn0szv5.js} +19 -17
- package/dist/{chunk-s3tdz6j0.js → chunk-71053xes.js} +14 -14
- package/dist/chunk-758qmraw.js +66 -0
- package/dist/{chunk-25a6cm96.js → chunk-76g1m8sa.js} +16 -4
- package/dist/{chunk-xgjs3rkr.js → chunk-7b1ze28c.js} +55 -52
- package/dist/{chunk-a3m8brwc.js → chunk-7bq6az8b.js} +3 -3
- package/dist/{chunk-yjmtjd5c.js → chunk-7ckqn3c3.js} +55 -52
- package/dist/chunk-7d5gzxsx.js +145 -0
- package/dist/{chunk-rv57x1qr.js → chunk-7gyjd00q.js} +3 -3
- package/dist/{chunk-hn438x41.js → chunk-7hnmt967.js} +84 -80
- package/dist/{chunk-rmfp4mf2.js → chunk-7jbeh3g8.js} +3 -3
- package/dist/{chunk-kymq7j5k.js → chunk-7k0h27s8.js} +7 -7
- package/dist/{chunk-2fnpj7fv.js → chunk-7myptjaa.js} +5 -5
- package/dist/{chunk-s81bx611.js → chunk-7yq22pd2.js} +57 -54
- package/dist/{chunk-dk8te1zz.js → chunk-7zxvjs3d.js} +2 -2
- package/dist/{chunk-mwky1mwc.js → chunk-83v18n96.js} +14 -14
- package/dist/{chunk-f1az36w2.js → chunk-84a79s9g.js} +124 -150
- package/dist/{chunk-x0nt6xta.js → chunk-86n03xsk.js} +60 -57
- package/dist/{chunk-4aqc3s2f.js → chunk-87ddk39d.js} +6 -6
- package/dist/{chunk-vnsmwwcx.js → chunk-89jrgnx3.js} +15 -15
- package/dist/{chunk-3fs4xc9h.js → chunk-8dehkx39.js} +5 -5
- package/dist/{chunk-wwt8x57q.js → chunk-8fm77brm.js} +59 -56
- package/dist/{chunk-z9ezvde9.js → chunk-8fqa9v4h.js} +55 -52
- package/dist/{chunk-etqmgb7b.js → chunk-8pqe4w62.js} +62 -59
- package/dist/{chunk-xqzmd8rx.js → chunk-8qp0ytjr.js} +2 -2
- package/dist/{chunk-xt7g86gj.js → chunk-8v8n8gxv.js} +3 -3
- package/dist/{chunk-jq30e6rg.js → chunk-94jqjx3g.js} +59 -56
- package/dist/chunk-9663bsk0.js +18 -0
- package/dist/{chunk-dnp096zb.js → chunk-96gwphgv.js} +3 -3
- package/dist/{chunk-sq5fyhqd.js → chunk-9bf696cj.js} +95 -87
- package/dist/{chunk-eje4tzhm.js → chunk-9cw6etxe.js} +56 -53
- package/dist/{chunk-r7a5cqdw.js → chunk-9dwdn2sk.js} +7 -7
- package/dist/{chunk-ejfvtxhc.js → chunk-9ggwn844.js} +29 -64
- package/dist/{chunk-n08zma6t.js → chunk-9gxdrrd5.js} +55 -52
- package/dist/{chunk-cvr6at4f.js → chunk-9q952pw0.js} +2 -2
- package/dist/{chunk-ab8c2gs2.js → chunk-9qgzdk8y.js} +7 -7
- package/dist/{chunk-tjc1tx3q.js → chunk-9qj9t1g4.js} +2 -2
- package/dist/{chunk-hm9rq604.js → chunk-9sr5cheh.js} +55 -52
- package/dist/{chunk-3tm5sns7.js → chunk-9vvffdb6.js} +64 -61
- package/dist/chunk-a18ypbnr.js +151 -0
- package/dist/{chunk-80yycsam.js → chunk-a80y3b1p.js} +3 -3
- package/dist/{chunk-bdhx8k7k.js → chunk-a96dsyhm.js} +59 -56
- package/dist/{chunk-pgjmgh51.js → chunk-a97kj439.js} +2 -2
- package/dist/chunk-aggcq5pt.js +16 -0
- package/dist/{chunk-5wvcws9f.js → chunk-am5zfwnf.js} +19 -19
- package/dist/{chunk-56djb736.js → chunk-b21j3y4h.js} +2 -2
- package/dist/{chunk-jdvx0xe9.js → chunk-b52sketm.js} +55 -52
- package/dist/{chunk-xzw0ettz.js → chunk-b7fcydvv.js} +18 -18
- package/dist/{chunk-y90gh0z2.js → chunk-bb9h35x7.js} +55 -52
- package/dist/{chunk-07vfsvas.js → chunk-bbpnmz87.js} +2 -2
- package/dist/chunk-bcfd2zw7.js +23 -0
- package/dist/chunk-bdy3869e.js +35 -0
- package/dist/{chunk-g6vvs0w9.js → chunk-be8pcep0.js} +2 -2
- package/dist/{chunk-2vfcftww.js → chunk-bgpftrxc.js} +56 -53
- package/dist/{chunk-ne02d12y.js → chunk-bh4k9q9y.js} +4 -4
- package/dist/{chunk-841eka5g.js → chunk-bjc8f709.js} +62 -59
- package/dist/{chunk-00f3aac0.js → chunk-bm5370d5.js} +14 -14
- package/dist/{chunk-kfdgw9j2.js → chunk-br1qf4bc.js} +12 -21
- package/dist/{chunk-vempyean.js → chunk-bxmc7435.js} +7 -7
- package/dist/chunk-c36xznt7.js +1045 -0
- package/dist/{chunk-cjg9tm4d.js → chunk-c3z2f4aq.js} +58 -55
- package/dist/chunk-cchv4yn8.js +214 -0
- package/dist/{chunk-qdfqack5.js → chunk-cewbt8ah.js} +2 -2
- package/dist/{chunk-7npzwf36.js → chunk-cfeakba6.js} +55 -52
- package/dist/{chunk-5c1ym1nc.js → chunk-ckh1zt0n.js} +65 -62
- package/dist/{chunk-xcm658wm.js → chunk-ckq5d8ev.js} +3 -3
- package/dist/chunk-cnfzmqr8.js +115 -0
- package/dist/chunk-crchz5q8.js +16 -0
- package/dist/{chunk-mf1n757j.js → chunk-cwpxrn2d.js} +17 -17
- package/dist/chunk-cy223s48.js +881 -0
- package/dist/{chunk-7c4fsh0s.js → chunk-cydd546q.js} +57 -54
- package/dist/{chunk-a35q4knx.js → chunk-cz5ycdta.js} +3 -3
- package/dist/{chunk-k8a68cwg.js → chunk-da7f9a81.js} +105 -29
- package/dist/{chunk-kexhnah5.js → chunk-dfzfxt1y.js} +7 -7
- package/dist/{chunk-4c56f6d2.js → chunk-dj6y2sr8.js} +3 -3
- package/dist/{chunk-cph4yr50.js → chunk-djbawqmw.js} +55 -52
- package/dist/{chunk-17j9hb87.js → chunk-dpb1kvb9.js} +56 -53
- package/dist/{chunk-xn02xqxj.js → chunk-dt5c48mh.js} +2 -2
- package/dist/{chunk-yephhrfa.js → chunk-e1m95nec.js} +6 -6
- package/dist/{chunk-bxfv6aew.js → chunk-e26hypm4.js} +56 -53
- package/dist/{chunk-a9garrrp.js → chunk-e5kn4hwp.js} +56 -53
- package/dist/{chunk-tn5b34gd.js → chunk-e6dq8apj.js} +55 -52
- package/dist/{chunk-rqn40hvy.js → chunk-e6p5x2p4.js} +4 -4
- package/dist/{chunk-5yjm9yth.js → chunk-eb6x30zz.js} +57 -54
- package/dist/{chunk-352yw5fs.js → chunk-ebfv6acv.js} +12 -12
- package/dist/{chunk-1h952cez.js → chunk-egkwv0bp.js} +2 -2
- package/dist/{chunk-rqfzhr9m.js → chunk-ennzq1s5.js} +14 -4
- package/dist/{chunk-ec3vxfsp.js → chunk-envqyd27.js} +59 -55
- package/dist/{chunk-yk99hmx2.js → chunk-epprxdgg.js} +2 -2
- package/dist/{chunk-cea3mepz.js → chunk-et42fzf1.js} +22 -22
- package/dist/{chunk-h0rbjg6x.js → chunk-f2mhrmww.js} +10 -3
- package/dist/{chunk-rg3c0e6m.js → chunk-fb5ehysd.js} +57 -54
- package/dist/chunk-fbtp7vga.js +37 -0
- package/dist/{chunk-n3xd3ev4.js → chunk-fgna18nd.js} +6 -6
- package/dist/{chunk-26w1pqen.js → chunk-fknjgxt4.js} +56 -53
- package/dist/{chunk-xj7nr4b8.js → chunk-fpb43g1s.js} +6 -6
- package/dist/{chunk-d24kfzcv.js → chunk-ftfz2eh3.js} +2 -2
- package/dist/{chunk-xbc1xb90.js → chunk-fv94gm4h.js} +56 -53
- package/dist/{chunk-732ycv3a.js → chunk-fx7pr1g4.js} +13 -13
- package/dist/{chunk-fxg6tk9f.js → chunk-g0axk7cx.js} +56 -53
- package/dist/chunk-g6d9avms.js +205 -0
- package/dist/{chunk-vwpr34gb.js → chunk-g9caj6wj.js} +66 -63
- package/dist/{chunk-jjjrmgee.js → chunk-gbekxw41.js} +56 -53
- package/dist/{chunk-dawa3bxd.js → chunk-gcpc6b2z.js} +2 -2
- package/dist/{chunk-7qq9wgng.js → chunk-gfycetpg.js} +5 -5
- package/dist/{chunk-snjbtcsd.js → chunk-gn0ja3k5.js} +5 -5
- package/dist/{chunk-cf98rrym.js → chunk-gt9gwwdh.js} +5 -5
- package/dist/{chunk-1qdm27em.js → chunk-gz0nj0mm.js} +55 -52
- package/dist/{chunk-jcfp9q8e.js → chunk-gz6pze8f.js} +57 -54
- package/dist/{chunk-kankxtem.js → chunk-h1frxdrg.js} +56 -54
- package/dist/{chunk-t8bj4y17.js → chunk-h93ve2g2.js} +14 -14
- package/dist/{chunk-b00v4z7e.js → chunk-h9mr8ey4.js} +13 -13
- package/dist/{chunk-fgfvmggw.js → chunk-hd8ydnzq.js} +15 -15
- package/dist/{chunk-szkay129.js → chunk-hebz2z6z.js} +58 -55
- package/dist/chunk-hgxb4qn5.js +390 -0
- package/dist/{chunk-h1e34028.js → chunk-hh6kgtq5.js} +3 -3
- package/dist/{chunk-srrcngcy.js → chunk-hhcx2jjn.js} +3 -3
- package/dist/{chunk-dvp0xagf.js → chunk-hjp1yckp.js} +56 -53
- package/dist/{chunk-jsfytv0f.js → chunk-hjxz7a04.js} +58 -55
- package/dist/{chunk-zdnv8fvz.js → chunk-hkkz8rde.js} +55 -52
- package/dist/{chunk-677p38pg.js → chunk-hnms0snx.js} +2 -2
- package/dist/{chunk-yydr31ss.js → chunk-hq4jd1fy.js} +23 -23
- package/dist/{chunk-gqxam9dm.js → chunk-hthfhdty.js} +15 -15
- package/dist/{chunk-98204r0v.js → chunk-hy5vd50e.js} +3 -3
- package/dist/{chunk-ck1qvj5k.js → chunk-hyztfnyq.js} +463 -225
- package/dist/{chunk-m4wfythr.js → chunk-j5rnevxw.js} +62 -59
- package/dist/{chunk-eeee4v34.js → chunk-j74ctwq9.js} +3 -3
- package/dist/{chunk-d9tbq3h3.js → chunk-jcdv05ym.js} +33 -5
- package/dist/{chunk-ga5v18wb.js → chunk-jd5xs374.js} +55 -52
- package/dist/{chunk-rz56zge4.js → chunk-jgbz49jh.js} +6 -4
- package/dist/{chunk-y9g1ynzy.js → chunk-jhdtyhk5.js} +57 -54
- package/dist/{chunk-aq0t16sn.js → chunk-jkbkp0ek.js} +14 -14
- package/dist/{chunk-7nwehwa4.js → chunk-jkyn6ge9.js} +5 -5
- package/dist/{chunk-nb02zd8m.js → chunk-jn7qa13m.js} +3 -3
- package/dist/{chunk-evmvnppx.js → chunk-jt7ea6rq.js} +55 -52
- package/dist/{chunk-9khxkxz7.js → chunk-jt7wch8z.js} +2 -2
- package/dist/{chunk-0j3jy5jp.js → chunk-jv7tn7yh.js} +55 -52
- package/dist/chunk-jx80x2sn.js +267 -0
- package/dist/{chunk-03fdnx3e.js → chunk-jy13c47g.js} +5 -5
- package/dist/{chunk-75q1d027.js → chunk-k11m1rfc.js} +57 -54
- package/dist/{chunk-x7t8wrq1.js → chunk-k3mghke5.js} +57 -86
- package/dist/{chunk-jcd8qmcc.js → chunk-k5rrrd0q.js} +78 -75
- package/dist/{chunk-8zdrypte.js → chunk-kbbjfeb8.js} +2 -2
- package/dist/chunk-kcz5b7xv.js +73 -0
- package/dist/{chunk-87s3zt6w.js → chunk-khnxj5vx.js} +3 -3
- package/dist/{chunk-g6eqgh16.js → chunk-kkwym2b7.js} +5 -5
- package/dist/{chunk-hvve83a7.js → chunk-kn345s2x.js} +2 -2
- package/dist/{chunk-x07xwqrj.js → chunk-kpqx95pr.js} +2 -2
- package/dist/{chunk-wfyhm9cg.js → chunk-kszphewb.js} +63 -54
- package/dist/{chunk-5kcmmrbe.js → chunk-kxn6mzy3.js} +4 -4
- package/dist/{chunk-tc848afj.js → chunk-m0zzdgkt.js} +31 -26
- package/dist/{chunk-gmsb3jtb.js → chunk-m7qa1fqb.js} +3 -3
- package/dist/{chunk-qph8gdxy.js → chunk-mdm5cbxy.js} +55 -52
- package/dist/chunk-mnqvtfd5.js +78 -0
- package/dist/{chunk-fstr76j0.js → chunk-mp5km99q.js} +20 -20
- package/dist/{chunk-8ehewpj6.js → chunk-mpxcgg5f.js} +6 -6
- package/dist/{chunk-zffnk5t6.js → chunk-mqr18cwx.js} +4 -4
- package/dist/chunk-n014czx3.js +18 -0
- package/dist/{chunk-ytzqmbt0.js → chunk-n40kbp9f.js} +55 -52
- package/dist/{chunk-8n28z1eg.js → chunk-n51s6m60.js} +14 -14
- package/dist/{chunk-c9gga8sn.js → chunk-n87c314c.js} +56 -53
- package/dist/{chunk-7jkb3tck.js → chunk-nevf0mb9.js} +15 -15
- package/dist/{chunk-zxhtrvtt.js → chunk-nkeknzb2.js} +4 -4
- package/dist/{chunk-4fjgdmr9.js → chunk-nkgq6a5q.js} +28 -28
- package/dist/{chunk-9ds6nhgx.js → chunk-nmj9qx2x.js} +65 -62
- package/dist/{chunk-4pf098nn.js → chunk-nmyfe9j9.js} +57 -54
- package/dist/{chunk-b1dyfwm2.js → chunk-nmzy0qjn.js} +7 -7
- package/dist/{chunk-51pkqrja.js → chunk-np05dg07.js} +55 -52
- package/dist/{chunk-w51sng2s.js → chunk-npgyhaqc.js} +2 -2
- package/dist/{chunk-61008xjm.js → chunk-nr2skyv7.js} +56 -53
- package/dist/{chunk-w6x102n9.js → chunk-nv5rddp1.js} +55 -52
- package/dist/{chunk-naqmbswb.js → chunk-p10xajeq.js} +69 -66
- package/dist/{chunk-vgzdtvca.js → chunk-p1wxbhgj.js} +4 -4
- package/dist/{chunk-rs2skqcv.js → chunk-p6fhtt1h.js} +4 -4
- package/dist/{chunk-m5daf1hp.js → chunk-p8d1q69a.js} +55 -52
- package/dist/{chunk-t66dy38x.js → chunk-pbmy8ktp.js} +7 -7
- package/dist/{chunk-ssnp42gc.js → chunk-pqrb30bj.js} +2 -2
- package/dist/{chunk-6dhkeb6t.js → chunk-pr321r8d.js} +3 -3
- package/dist/{chunk-7d5yfjs6.js → chunk-psq9gtg7.js} +2 -2
- package/dist/{chunk-193vfma7.js → chunk-ptermrp1.js} +60 -57
- package/dist/{chunk-q9fppwnq.js → chunk-pyfrphvc.js} +57 -54
- package/dist/{chunk-vajyw4ea.js → chunk-pzb2zc4x.js} +6 -6
- package/dist/{chunk-k1pjc56n.js → chunk-q0w614e1.js} +3 -3
- package/dist/{chunk-34merw4c.js → chunk-q110twdj.js} +59 -116
- package/dist/{chunk-je4jw9pe.js → chunk-q72dtjqy.js} +2 -2
- package/dist/{chunk-551jxdwj.js → chunk-q90bcq6v.js} +59 -56
- package/dist/{chunk-sm0ak846.js → chunk-qavfmmqd.js} +6 -6
- package/dist/{chunk-qvzvzzdw.js → chunk-qjx52q61.js} +2 -2
- package/dist/{chunk-72cez8rw.js → chunk-qk2tvn8y.js} +56 -53
- package/dist/{chunk-mt0hyhtp.js → chunk-qm3k6vez.js} +13 -13
- package/dist/{chunk-fkpm0dka.js → chunk-qmp50hjb.js} +19 -19
- package/dist/{chunk-qezmm114.js → chunk-qnztz65r.js} +56 -53
- package/dist/{chunk-23nwpyay.js → chunk-qpatv1ep.js} +13 -13
- package/dist/{chunk-dsdbya1y.js → chunk-qwtfyr6d.js} +2 -2
- package/dist/{chunk-nz9rqw9y.js → chunk-qxp3d963.js} +2 -2
- package/dist/{chunk-xq92sh7h.js → chunk-qzp51m93.js} +3 -3
- package/dist/{chunk-8dtk8ma2.js → chunk-r3fadmd6.js} +5 -5
- package/dist/{chunk-9eervnn3.js → chunk-r4mec6w5.js} +3 -3
- package/dist/chunk-r6g3xx75.js +415 -0
- package/dist/{chunk-avaa7ds2.js → chunk-r8ywba1h.js} +14 -14
- package/dist/{chunk-raftjwkd.js → chunk-r974358t.js} +13 -13
- package/dist/{chunk-w4bqdhna.js → chunk-r9qnxgqt.js} +5 -5
- package/dist/{chunk-7v874g5h.js → chunk-rasdgp8g.js} +4 -4
- package/dist/{chunk-dwkc1vgf.js → chunk-rbr0tsrz.js} +55 -52
- package/dist/{chunk-63hz4ckd.js → chunk-re5p7q2e.js} +4 -4
- package/dist/{chunk-gytaebn1.js → chunk-rfvzhq5x.js} +55 -52
- package/dist/{chunk-s4akexsk.js → chunk-rfxctace.js} +3 -4
- package/dist/chunk-rhqffqzf.js +189 -0
- package/dist/{chunk-xb6r5wtg.js → chunk-rnjtkqzg.js} +4 -4
- package/dist/{chunk-wpm7sbfe.js → chunk-rqa3fz1t.js} +55 -52
- package/dist/{chunk-y7q1vtv4.js → chunk-rtgff67y.js} +63 -60
- package/dist/{chunk-q4v51jm6.js → chunk-rw1070pc.js} +4 -4
- package/dist/{chunk-cxkxps51.js → chunk-rzrm7j9x.js} +2 -2
- package/dist/{chunk-spd5z6xd.js → chunk-s262tfgm.js} +3 -3
- package/dist/{chunk-9tkrb3jy.js → chunk-s4pjm9jw.js} +55 -52
- package/dist/chunk-s5pnejsn.js +216 -0
- package/dist/{chunk-4157n57z.js → chunk-sczmmmvj.js} +2 -2
- package/dist/{chunk-7h13c72t.js → chunk-sd2g0s0k.js} +9 -9
- package/dist/{chunk-rnsws47e.js → chunk-sg5nsm4p.js} +3 -3
- package/dist/{chunk-7cgjgppb.js → chunk-stqsfa68.js} +3 -3
- package/dist/{chunk-hdx2p9h7.js → chunk-svb5eqfz.js} +14 -14
- package/dist/{chunk-ybzc4vyc.js → chunk-swr65v0j.js} +10 -10
- package/dist/{chunk-dkzq1yj3.js → chunk-swtk97hy.js} +14 -14
- package/dist/{chunk-qy3bd939.js → chunk-sx4gbak5.js} +56 -53
- package/dist/{chunk-p83fdzct.js → chunk-t12d6tby.js} +3 -3
- package/dist/{chunk-v91g64jx.js → chunk-t20f5mnk.js} +14 -14
- package/dist/{chunk-g410gawd.js → chunk-t408adb9.js} +56 -53
- package/dist/{chunk-4k2ztys5.js → chunk-t7434h4s.js} +55 -52
- package/dist/{chunk-0qa1hgxp.js → chunk-t7y6mg54.js} +13 -13
- package/dist/{chunk-a9pqw4tk.js → chunk-tdkwcv57.js} +4 -4
- package/dist/{chunk-sqnghamc.js → chunk-tfew976a.js} +55 -52
- package/dist/{chunk-83m8mxaj.js → chunk-thzmxfnt.js} +2 -2
- package/dist/{chunk-gwfv9a10.js → chunk-tmedrj3f.js} +4 -4
- package/dist/{chunk-j9q7p2m5.js → chunk-tmscbs2k.js} +4 -4
- package/dist/chunk-tnk7s4ed.js +22 -0
- package/dist/{chunk-dw1cwmt3.js → chunk-tnqjynvy.js} +14 -14
- package/dist/{chunk-ztqe8k2y.js → chunk-tq32b105.js} +3 -3
- package/dist/{chunk-hp6ym2xt.js → chunk-tr448vwb.js} +3 -3
- package/dist/{chunk-xdfcfm69.js → chunk-tr4hszme.js} +3 -3
- package/dist/{chunk-5nzjxkj9.js → chunk-traxf72w.js} +2 -2
- package/dist/{chunk-f2d9gmzw.js → chunk-ttzyw0y7.js} +17 -17
- package/dist/{chunk-y1cqsd0p.js → chunk-tw0b366n.js} +55 -52
- package/dist/{chunk-ng7nkgv1.js → chunk-txync4kd.js} +7 -7
- package/dist/chunk-v060k07j.js +416 -0
- package/dist/chunk-v1rkrwwv.js +146 -0
- package/dist/{chunk-0p6e05c5.js → chunk-v21ssxkp.js} +2 -2
- package/dist/{chunk-zpte5txk.js → chunk-v2vzfj4h.js} +55 -52
- package/dist/{chunk-3s7v8tsk.js → chunk-v4h7dscd.js} +26 -44
- package/dist/{chunk-90qefxa4.js → chunk-v522k1r4.js} +70 -67
- package/dist/{chunk-rdmen6bn.js → chunk-v9b2rh8h.js} +58 -55
- package/dist/{chunk-g8e4wwak.js → chunk-vacje5g9.js} +4 -4
- package/dist/{chunk-t2r4qham.js → chunk-vetj2j2n.js} +60 -57
- package/dist/{chunk-fr84aysg.js → chunk-vpn54vqg.js} +6 -6
- package/dist/{chunk-yvsb81fm.js → chunk-vqhgs52z.js} +7 -7
- package/dist/{chunk-t802hx06.js → chunk-vtnm80k9.js} +13 -13
- package/dist/{chunk-dmsc23kp.js → chunk-vvk6wx6b.js} +14 -14
- package/dist/{chunk-t9z3edw6.js → chunk-vym5zrn6.js} +4895 -2486
- package/dist/{chunk-pxzawaw7.js → chunk-vzxtxv4a.js} +56 -53
- package/dist/{chunk-x59dmzab.js → chunk-w3wdqhv0.js} +62 -59
- package/dist/{chunk-61xprjs1.js → chunk-w59jkye4.js} +56 -53
- package/dist/{chunk-amnaevyb.js → chunk-w60fa5cj.js} +65 -62
- package/dist/{chunk-16waz3fy.js → chunk-w8xchcwf.js} +3 -3
- package/dist/{chunk-fv8tcte1.js → chunk-w9fptpp9.js} +64 -61
- package/dist/{chunk-3d8ccn91.js → chunk-wa7g3yv7.js} +13 -13
- package/dist/{chunk-wbwzf5z4.js → chunk-wdn3pb9r.js} +3 -3
- package/dist/{chunk-ccqk19v9.js → chunk-wqk03hpc.js} +55 -52
- package/dist/{chunk-ycjjsnm4.js → chunk-wvs8wv8t.js} +2 -2
- package/dist/{chunk-6hnqaxvs.js → chunk-wwfe7gg7.js} +58 -55
- package/dist/{chunk-nmaxmbg9.js → chunk-wz18c465.js} +4 -4
- package/dist/{chunk-08wf7txh.js → chunk-wz34c685.js} +15 -15
- package/dist/{chunk-587dvnad.js → chunk-wzzaxwej.js} +2 -2
- package/dist/chunk-x1wk407b.js +516 -0
- package/dist/{chunk-jysm93mk.js → chunk-x2taqvwd.js} +5 -5
- package/dist/{chunk-dt0y1vkc.js → chunk-x41dz9y9.js} +2 -2
- package/dist/chunk-x48x54hx.js +3942 -0
- package/dist/{chunk-q0ks2prw.js → chunk-x6cjkxqe.js} +5 -5
- package/dist/{chunk-f6v5bq78.js → chunk-x89sscn0.js} +2 -2
- package/dist/chunk-x9qqj8wc.js +153 -0
- package/dist/{chunk-6ka2mh69.js → chunk-xa9xpah3.js} +3037 -2505
- package/dist/{chunk-644422j5.js → chunk-xcxcysx3.js} +2 -2
- package/dist/{chunk-0fq3smhy.js → chunk-xftqvncz.js} +9 -46
- package/dist/{chunk-hnh89cye.js → chunk-xhnmweqe.js} +64 -61
- package/dist/{chunk-7s3wyn34.js → chunk-xm6t6khx.js} +56 -53
- package/dist/chunk-xt65mfby.js +1395 -0
- package/dist/{chunk-31fcazbn.js → chunk-xvmtyz8q.js} +2 -2
- package/dist/{chunk-1mf9624z.js → chunk-xxfz08mf.js} +55 -52
- package/dist/{chunk-wgvazba2.js → chunk-y061xbn9.js} +5 -5
- package/dist/{chunk-mzh12ebc.js → chunk-y0z468z2.js} +56 -53
- package/dist/{chunk-7ghq231e.js → chunk-y3cshvgb.js} +2 -2
- package/dist/{chunk-kqt7same.js → chunk-y6ce2s1q.js} +59 -55
- package/dist/chunk-y9bpc4a6.js +97 -0
- package/dist/{chunk-8c4wbrma.js → chunk-y9mnawak.js} +4 -4
- package/dist/{chunk-whbkstfm.js → chunk-ycdbp5q4.js} +55 -52
- package/dist/{chunk-1dg4nrws.js → chunk-ycsh7pst.js} +13 -13
- package/dist/{chunk-s41zt5kj.js → chunk-yedzdc0a.js} +14 -8
- package/dist/{chunk-jw0ky94p.js → chunk-yrr4d26k.js} +56 -53
- package/dist/{chunk-myysj9vz.js → chunk-yt5gwdg5.js} +7 -60
- package/dist/{chunk-yaefwx7d.js → chunk-yteefw26.js} +55 -52
- package/dist/{chunk-rhjbecsk.js → chunk-yvjzex9w.js} +6 -82
- package/dist/{chunk-5n19f2r9.js → chunk-z124zj20.js} +4 -4
- package/dist/{chunk-sa5fj0d3.js → chunk-z92c7wdq.js} +4 -4
- package/dist/{chunk-etcypdxa.js → chunk-zb7ctc11.js} +55 -52
- package/dist/{chunk-2wbgexnn.js → chunk-zc2mfxy0.js} +58 -55
- package/dist/{chunk-hhdbv9eg.js → chunk-zdsqreyq.js} +3 -3
- package/dist/chunk-zf5btqc3.js +54 -0
- package/dist/{chunk-sxgc1sm1.js → chunk-zfwgjjde.js} +2 -2
- package/dist/{chunk-nfaj0b7z.js → chunk-zgvyn6yk.js} +55 -52
- package/dist/{chunk-gcrf35hk.js → chunk-zmj9sehj.js} +56 -53
- package/dist/{chunk-hq20dsgb.js → chunk-zr750mg3.js} +93 -57
- package/dist/{chunk-yjyaq9ja.js → chunk-zshw91dr.js} +5 -5
- package/dist/{chunk-azbndvdt.js → chunk-zyhpq0w1.js} +7 -4
- package/dist/{chunk-ky41ddym.js → chunk-zzac564h.js} +15 -15
- package/dist/cli.js +94 -28
- package/dist/services/rawDump/batchWorker.js +3 -3
- package/package.json +1 -1
- package/dist/chunk-0paqc2yw.js +0 -18
- package/dist/chunk-ac3vxv72.js +0 -99
- package/dist/chunk-ctaxszne.js +0 -183
- package/dist/chunk-f9vf3z7d.js +0 -57
- package/dist/chunk-q2pkj7sp.js +0 -18
- package/dist/chunk-wmd102c3.js +0 -138
- package/dist/chunk-zzjq53z6.js +0 -198
|
@@ -2,15 +2,10 @@
|
|
|
2
2
|
import {
|
|
3
3
|
normalizeControlMessageKeys
|
|
4
4
|
} from "./chunk-nt837qt9.js";
|
|
5
|
-
import {
|
|
6
|
-
init_slashCommandParsing,
|
|
7
|
-
parseSlashCommand
|
|
8
|
-
} from "./chunk-rn0v1hk8.js";
|
|
9
5
|
import {
|
|
10
6
|
AccountInfoSchema,
|
|
11
7
|
AgentDefinitionSchema,
|
|
12
8
|
AgentInfoSchema,
|
|
13
|
-
DEFAULT_OUTPUT_STYLE_NAME,
|
|
14
9
|
FastModeStateSchema,
|
|
15
10
|
HookEventSchema,
|
|
16
11
|
HookInputSchema,
|
|
@@ -24,87 +19,40 @@ import {
|
|
|
24
19
|
SDKStreamlinedTextMessageSchema,
|
|
25
20
|
SDKStreamlinedToolUseSummaryMessageSchema,
|
|
26
21
|
SDKUserMessageSchema,
|
|
27
|
-
Select,
|
|
28
22
|
SlashCommandSchema,
|
|
29
|
-
Spinner,
|
|
30
23
|
Stream,
|
|
31
24
|
addMarketplaceSource,
|
|
32
25
|
applyPermissionUpdates,
|
|
33
|
-
createAttachmentMessage,
|
|
34
|
-
createCommandInputMessage,
|
|
35
|
-
createImageMetadataText,
|
|
36
|
-
createSystemMessage,
|
|
37
|
-
createUserMessage,
|
|
38
26
|
detectImageFormatFromBase64,
|
|
39
27
|
executePermissionRequestHooks,
|
|
40
|
-
executeUserPromptSubmitHooks,
|
|
41
|
-
extractTag,
|
|
42
|
-
fileHistoryCanRestore,
|
|
43
|
-
fileHistoryEnabled,
|
|
44
|
-
fileHistoryGetDiffStats,
|
|
45
28
|
finalizeAutonomyRunCompleted,
|
|
46
29
|
finalizeAutonomyRunFailed,
|
|
47
|
-
findCommand,
|
|
48
|
-
getAttachmentMessages,
|
|
49
|
-
getBridgeCommandSafety,
|
|
50
|
-
getCommandName,
|
|
51
|
-
getContentText,
|
|
52
30
|
getDeclaredMarketplaces,
|
|
53
|
-
getUserPromptSubmitHookBlockingMessage,
|
|
54
31
|
hasPermissionsToUseTool,
|
|
55
32
|
hookJSONOutputSchema,
|
|
56
|
-
init_AppState,
|
|
57
33
|
init_PermissionUpdate,
|
|
58
34
|
init_PermissionUpdateSchema,
|
|
59
|
-
init_Spinner,
|
|
60
|
-
init_attachments,
|
|
61
35
|
init_autonomyRuns,
|
|
62
36
|
init_commandLifecycle,
|
|
63
|
-
init_commands1 as init_commands,
|
|
64
37
|
init_coreSchemas,
|
|
65
|
-
init_fileHistory,
|
|
66
|
-
init_generators,
|
|
67
38
|
init_hooks,
|
|
68
39
|
init_hooks1 as init_hooks2,
|
|
69
40
|
init_imageResizer,
|
|
70
|
-
init_imageStore,
|
|
71
41
|
init_marketplaceManager,
|
|
72
|
-
init_messages1 as init_messages,
|
|
73
|
-
init_outputStyles,
|
|
74
42
|
init_permissions,
|
|
75
|
-
init_queryProfiler,
|
|
76
|
-
init_select,
|
|
77
43
|
init_stream,
|
|
78
|
-
init_textInputTypes,
|
|
79
|
-
init_useTerminalSize,
|
|
80
|
-
isEmptyMessageText,
|
|
81
|
-
isSyntheticMessage,
|
|
82
|
-
isToolUseResultMessage,
|
|
83
|
-
isValidImagePaste,
|
|
84
44
|
listAutonomyRuns,
|
|
85
45
|
loadKnownMarketplacesConfig,
|
|
86
46
|
markAutonomyRunCancelled,
|
|
87
47
|
markAutonomyRunRunning,
|
|
88
|
-
maybeResizeAndDownsampleImageBlock,
|
|
89
48
|
notifyCommandLifecycle,
|
|
90
49
|
permissionUpdateSchema,
|
|
91
|
-
persistPermissionUpdates
|
|
92
|
-
|
|
93
|
-
storeImages,
|
|
94
|
-
toArray,
|
|
95
|
-
useAppState
|
|
96
|
-
} from "./chunk-t9z3edw6.js";
|
|
50
|
+
persistPermissionUpdates
|
|
51
|
+
} from "./chunk-vym5zrn6.js";
|
|
97
52
|
import {
|
|
98
53
|
init_sessionState,
|
|
99
54
|
notifySessionStateChanged
|
|
100
|
-
} from "./chunk-
|
|
101
|
-
import {
|
|
102
|
-
init_useExitOnCtrlCDWithKeybindings,
|
|
103
|
-
useExitOnCtrlCDWithKeybindings
|
|
104
|
-
} from "./chunk-q0ks2prw.js";
|
|
105
|
-
import {
|
|
106
|
-
init_useKeybinding
|
|
107
|
-
} from "./chunk-8zdrypte.js";
|
|
55
|
+
} from "./chunk-9ggwn844.js";
|
|
108
56
|
import {
|
|
109
57
|
DEFAULT_CRON_JITTER_CONFIG,
|
|
110
58
|
findMissedTasks,
|
|
@@ -116,45 +64,25 @@ import {
|
|
|
116
64
|
oneShotJitteredNextCronRunMs,
|
|
117
65
|
readCronTasks,
|
|
118
66
|
removeCronTasks
|
|
119
|
-
} from "./chunk-
|
|
67
|
+
} from "./chunk-ennzq1s5.js";
|
|
120
68
|
import {
|
|
121
69
|
cronToHuman,
|
|
122
70
|
init_cron
|
|
123
71
|
} from "./chunk-14ya36qs.js";
|
|
124
72
|
import {
|
|
125
|
-
init_events,
|
|
126
|
-
init_sessionTracing,
|
|
127
|
-
logOTelEvent,
|
|
128
|
-
redactIfDisabled,
|
|
129
|
-
startInteractionSpan
|
|
130
|
-
} from "./chunk-7v874g5h.js";
|
|
131
|
-
import {
|
|
132
|
-
AGENT_TOOL_NAME,
|
|
133
|
-
LEGACY_AGENT_TOOL_NAME,
|
|
134
|
-
getAnthropicApiKeyWithSource,
|
|
135
|
-
getFastModeState,
|
|
136
73
|
getFeatureValue_CACHED_WITH_REFRESH,
|
|
137
|
-
getSettings_DEPRECATED,
|
|
138
|
-
init_auth,
|
|
139
|
-
init_constants1 as init_constants,
|
|
140
|
-
init_fastMode,
|
|
141
74
|
init_file,
|
|
142
75
|
init_growthbook,
|
|
143
76
|
init_isEqual,
|
|
144
77
|
init_schemas,
|
|
145
|
-
init_settings1 as init_settings,
|
|
146
78
|
isEqual_default,
|
|
147
79
|
isLocalMarketplaceSource,
|
|
148
80
|
pathExists
|
|
149
|
-
} from "./chunk-
|
|
81
|
+
} from "./chunk-5thf5z45.js";
|
|
150
82
|
import {
|
|
151
83
|
init_json,
|
|
152
84
|
safeParseJSON
|
|
153
85
|
} from "./chunk-fs34dpdm.js";
|
|
154
|
-
import {
|
|
155
|
-
count,
|
|
156
|
-
init_array
|
|
157
|
-
} from "./chunk-zwarn9h7.js";
|
|
158
86
|
import {
|
|
159
87
|
init_lazySchema,
|
|
160
88
|
lazySchema
|
|
@@ -162,7 +90,7 @@ import {
|
|
|
162
90
|
import {
|
|
163
91
|
init_genericProcessUtils,
|
|
164
92
|
isProcessRunning
|
|
165
|
-
} from "./chunk-
|
|
93
|
+
} from "./chunk-qxp3d963.js";
|
|
166
94
|
import {
|
|
167
95
|
init_v4,
|
|
168
96
|
v4_default
|
|
@@ -170,59 +98,20 @@ import {
|
|
|
170
98
|
import {
|
|
171
99
|
exports_external
|
|
172
100
|
} from "./chunk-p26t5d5e.js";
|
|
173
|
-
import {
|
|
174
|
-
formatRelativeTimeAgo,
|
|
175
|
-
init_format,
|
|
176
|
-
truncate
|
|
177
|
-
} from "./chunk-gn0d6g6p.js";
|
|
178
|
-
import {
|
|
179
|
-
Divider,
|
|
180
|
-
ThemedBox_default,
|
|
181
|
-
ThemedText,
|
|
182
|
-
init_src,
|
|
183
|
-
useKeybinding,
|
|
184
|
-
useKeybindings,
|
|
185
|
-
useTerminalSize
|
|
186
|
-
} from "./chunk-azbndvdt.js";
|
|
187
|
-
import {
|
|
188
|
-
require_react
|
|
189
|
-
} from "./chunk-64k6ybmm.js";
|
|
190
|
-
import {
|
|
191
|
-
require_jsx_runtime
|
|
192
|
-
} from "./chunk-qr5vq8ys.js";
|
|
193
101
|
import {
|
|
194
102
|
init_analytics,
|
|
195
103
|
logEvent
|
|
196
|
-
} from "./chunk-
|
|
104
|
+
} from "./chunk-f2mhrmww.js";
|
|
197
105
|
import {
|
|
198
106
|
findCanonicalGitRoot,
|
|
199
107
|
init_diagLogs,
|
|
200
108
|
init_git,
|
|
201
109
|
logForDiagnosticsNoPII
|
|
202
|
-
} from "./chunk-
|
|
203
|
-
import {
|
|
204
|
-
getCwd,
|
|
205
|
-
init_cwd
|
|
206
|
-
} from "./chunk-d24kfzcv.js";
|
|
110
|
+
} from "./chunk-vacje5g9.js";
|
|
207
111
|
import {
|
|
208
|
-
BASH_STDERR_TAG,
|
|
209
|
-
BASH_STDOUT_TAG,
|
|
210
|
-
COMMAND_MESSAGE_TAG,
|
|
211
|
-
LOCAL_COMMAND_STDERR_TAG,
|
|
212
|
-
LOCAL_COMMAND_STDOUT_TAG,
|
|
213
|
-
TASK_NOTIFICATION_TAG,
|
|
214
|
-
TEAMMATE_MESSAGE_TAG,
|
|
215
|
-
TICK_TAG,
|
|
216
|
-
init_displayTags,
|
|
217
112
|
init_log,
|
|
218
|
-
|
|
219
|
-
logError,
|
|
220
|
-
stripDisplayTags
|
|
113
|
+
logError
|
|
221
114
|
} from "./chunk-vtcqe66h.js";
|
|
222
|
-
import {
|
|
223
|
-
figures_default,
|
|
224
|
-
init_figures
|
|
225
|
-
} from "./chunk-qajrkk97.js";
|
|
226
115
|
import {
|
|
227
116
|
AbortError,
|
|
228
117
|
errorMessage,
|
|
@@ -244,19 +133,16 @@ import {
|
|
|
244
133
|
getOriginalCwd,
|
|
245
134
|
getProjectRoot,
|
|
246
135
|
getScheduledTasksEnabled,
|
|
247
|
-
getSdkBetas,
|
|
248
136
|
getSessionCronTasks,
|
|
249
137
|
getSessionId,
|
|
250
138
|
init_state,
|
|
251
139
|
removeSessionCronTasks,
|
|
252
|
-
setPromptId,
|
|
253
140
|
setScheduledTasksEnabled
|
|
254
141
|
} from "./chunk-rcxtkewg.js";
|
|
255
142
|
import {
|
|
256
143
|
__esm,
|
|
257
144
|
__export,
|
|
258
|
-
__require
|
|
259
|
-
__toESM
|
|
145
|
+
__require
|
|
260
146
|
} from "./chunk-qp2qdcda.js";
|
|
261
147
|
|
|
262
148
|
// src/utils/autonomyQueueLifecycle.ts
|
|
@@ -423,803 +309,6 @@ var init_autonomyQueueLifecycle = __esm(() => {
|
|
|
423
309
|
init_autonomyRuns();
|
|
424
310
|
});
|
|
425
311
|
|
|
426
|
-
// src/components/MessageSelector.tsx
|
|
427
|
-
var exports_MessageSelector = {};
|
|
428
|
-
__export(exports_MessageSelector, {
|
|
429
|
-
selectableUserMessagesFilter: () => selectableUserMessagesFilter,
|
|
430
|
-
messagesAfterAreOnlySynthetic: () => messagesAfterAreOnlySynthetic,
|
|
431
|
-
MessageSelector: () => MessageSelector
|
|
432
|
-
});
|
|
433
|
-
import { randomUUID } from "crypto";
|
|
434
|
-
import * as path from "path";
|
|
435
|
-
function isTextBlock(block) {
|
|
436
|
-
return block.type === "text";
|
|
437
|
-
}
|
|
438
|
-
function isSummarizeOption(option) {
|
|
439
|
-
return option === "summarize" || option === "summarize_up_to";
|
|
440
|
-
}
|
|
441
|
-
function MessageSelector({
|
|
442
|
-
messages,
|
|
443
|
-
onPreRestore,
|
|
444
|
-
onRestoreMessage,
|
|
445
|
-
onRestoreCode,
|
|
446
|
-
onSummarize,
|
|
447
|
-
onClose,
|
|
448
|
-
preselectedMessage
|
|
449
|
-
}) {
|
|
450
|
-
const fileHistory = useAppState((s) => s.fileHistory);
|
|
451
|
-
const [error, setError] = import_react.useState(undefined);
|
|
452
|
-
const isFileHistoryEnabled = fileHistoryEnabled();
|
|
453
|
-
const currentUUID = import_react.useMemo(randomUUID, []);
|
|
454
|
-
const messageOptions = import_react.useMemo(() => [
|
|
455
|
-
...messages.filter(selectableUserMessagesFilter),
|
|
456
|
-
{
|
|
457
|
-
...createUserMessage({
|
|
458
|
-
content: ""
|
|
459
|
-
}),
|
|
460
|
-
uuid: currentUUID
|
|
461
|
-
}
|
|
462
|
-
], [messages, currentUUID]);
|
|
463
|
-
const [selectedIndex, setSelectedIndex] = import_react.useState(messageOptions.length - 1);
|
|
464
|
-
const firstVisibleIndex = Math.max(0, Math.min(selectedIndex - Math.floor(MAX_VISIBLE_MESSAGES / 2), messageOptions.length - MAX_VISIBLE_MESSAGES));
|
|
465
|
-
const hasMessagesToSelect = messageOptions.length > 1;
|
|
466
|
-
const [messageToRestore, setMessageToRestore] = import_react.useState(preselectedMessage);
|
|
467
|
-
const [diffStatsForRestore, setDiffStatsForRestore] = import_react.useState(undefined);
|
|
468
|
-
import_react.useEffect(() => {
|
|
469
|
-
if (!preselectedMessage || !isFileHistoryEnabled)
|
|
470
|
-
return;
|
|
471
|
-
let cancelled = false;
|
|
472
|
-
fileHistoryGetDiffStats(fileHistory, preselectedMessage.uuid).then((stats) => {
|
|
473
|
-
if (!cancelled)
|
|
474
|
-
setDiffStatsForRestore(stats);
|
|
475
|
-
});
|
|
476
|
-
return () => {
|
|
477
|
-
cancelled = true;
|
|
478
|
-
};
|
|
479
|
-
}, [preselectedMessage, isFileHistoryEnabled, fileHistory]);
|
|
480
|
-
const [isRestoring, setIsRestoring] = import_react.useState(false);
|
|
481
|
-
const [restoringOption, setRestoringOption] = import_react.useState(null);
|
|
482
|
-
const [selectedRestoreOption, setSelectedRestoreOption] = import_react.useState("both");
|
|
483
|
-
const [summarizeFromFeedback, setSummarizeFromFeedback] = import_react.useState("");
|
|
484
|
-
const [summarizeUpToFeedback, setSummarizeUpToFeedback] = import_react.useState("");
|
|
485
|
-
function getRestoreOptions(canRestoreCode2) {
|
|
486
|
-
const baseOptions = canRestoreCode2 ? [
|
|
487
|
-
{ value: "both", label: "Restore code and conversation" },
|
|
488
|
-
{ value: "conversation", label: "Restore conversation" },
|
|
489
|
-
{ value: "code", label: "Restore code" }
|
|
490
|
-
] : [{ value: "conversation", label: "Restore conversation" }];
|
|
491
|
-
const summarizeInputProps = {
|
|
492
|
-
type: "input",
|
|
493
|
-
placeholder: "add context (optional)",
|
|
494
|
-
initialValue: "",
|
|
495
|
-
allowEmptySubmitToCancel: true,
|
|
496
|
-
showLabelWithValue: true,
|
|
497
|
-
labelValueSeparator: ": "
|
|
498
|
-
};
|
|
499
|
-
baseOptions.push({
|
|
500
|
-
value: "summarize",
|
|
501
|
-
label: "Summarize from here",
|
|
502
|
-
...summarizeInputProps,
|
|
503
|
-
onChange: setSummarizeFromFeedback
|
|
504
|
-
});
|
|
505
|
-
if (process.env.USER_TYPE === "ant") {
|
|
506
|
-
baseOptions.push({
|
|
507
|
-
value: "summarize_up_to",
|
|
508
|
-
label: "Summarize up to here",
|
|
509
|
-
...summarizeInputProps,
|
|
510
|
-
onChange: setSummarizeUpToFeedback
|
|
511
|
-
});
|
|
512
|
-
}
|
|
513
|
-
baseOptions.push({ value: "nevermind", label: "Never mind" });
|
|
514
|
-
return baseOptions;
|
|
515
|
-
}
|
|
516
|
-
import_react.useEffect(() => {
|
|
517
|
-
logEvent("tengu_message_selector_opened", {});
|
|
518
|
-
}, []);
|
|
519
|
-
async function restoreConversationDirectly(message) {
|
|
520
|
-
onPreRestore();
|
|
521
|
-
setIsRestoring(true);
|
|
522
|
-
try {
|
|
523
|
-
await onRestoreMessage(message);
|
|
524
|
-
setIsRestoring(false);
|
|
525
|
-
onClose();
|
|
526
|
-
} catch (error2) {
|
|
527
|
-
logError(error2);
|
|
528
|
-
setIsRestoring(false);
|
|
529
|
-
setError(`Failed to restore the conversation:
|
|
530
|
-
${error2}`);
|
|
531
|
-
}
|
|
532
|
-
}
|
|
533
|
-
async function handleSelect(message) {
|
|
534
|
-
const index = messages.indexOf(message);
|
|
535
|
-
const indexFromEnd = messages.length - 1 - index;
|
|
536
|
-
logEvent("tengu_message_selector_selected", {
|
|
537
|
-
index_from_end: indexFromEnd,
|
|
538
|
-
message_type: message.type,
|
|
539
|
-
is_current_prompt: false
|
|
540
|
-
});
|
|
541
|
-
if (!messages.includes(message)) {
|
|
542
|
-
onClose();
|
|
543
|
-
return;
|
|
544
|
-
}
|
|
545
|
-
if (!isFileHistoryEnabled) {
|
|
546
|
-
await restoreConversationDirectly(message);
|
|
547
|
-
return;
|
|
548
|
-
}
|
|
549
|
-
const diffStats = await fileHistoryGetDiffStats(fileHistory, message.uuid);
|
|
550
|
-
setMessageToRestore(message);
|
|
551
|
-
setDiffStatsForRestore(diffStats);
|
|
552
|
-
}
|
|
553
|
-
async function onSelectRestoreOption(option) {
|
|
554
|
-
logEvent("tengu_message_selector_restore_option_selected", {
|
|
555
|
-
option
|
|
556
|
-
});
|
|
557
|
-
if (!messageToRestore) {
|
|
558
|
-
setError("Message not found.");
|
|
559
|
-
return;
|
|
560
|
-
}
|
|
561
|
-
if (option === "nevermind") {
|
|
562
|
-
if (preselectedMessage)
|
|
563
|
-
onClose();
|
|
564
|
-
else
|
|
565
|
-
setMessageToRestore(undefined);
|
|
566
|
-
return;
|
|
567
|
-
}
|
|
568
|
-
if (isSummarizeOption(option)) {
|
|
569
|
-
onPreRestore();
|
|
570
|
-
setIsRestoring(true);
|
|
571
|
-
setRestoringOption(option);
|
|
572
|
-
setError(undefined);
|
|
573
|
-
try {
|
|
574
|
-
const direction = option === "summarize_up_to" ? "up_to" : "from";
|
|
575
|
-
const feedback = (direction === "up_to" ? summarizeUpToFeedback : summarizeFromFeedback).trim() || undefined;
|
|
576
|
-
await onSummarize(messageToRestore, feedback, direction);
|
|
577
|
-
setIsRestoring(false);
|
|
578
|
-
setRestoringOption(null);
|
|
579
|
-
setMessageToRestore(undefined);
|
|
580
|
-
onClose();
|
|
581
|
-
} catch (error2) {
|
|
582
|
-
logError(error2);
|
|
583
|
-
setIsRestoring(false);
|
|
584
|
-
setRestoringOption(null);
|
|
585
|
-
setMessageToRestore(undefined);
|
|
586
|
-
setError(`Failed to summarize:
|
|
587
|
-
${error2}`);
|
|
588
|
-
}
|
|
589
|
-
return;
|
|
590
|
-
}
|
|
591
|
-
onPreRestore();
|
|
592
|
-
setIsRestoring(true);
|
|
593
|
-
setError(undefined);
|
|
594
|
-
let codeError = null;
|
|
595
|
-
let conversationError = null;
|
|
596
|
-
if (option === "code" || option === "both") {
|
|
597
|
-
try {
|
|
598
|
-
await onRestoreCode(messageToRestore);
|
|
599
|
-
} catch (error2) {
|
|
600
|
-
codeError = error2;
|
|
601
|
-
logError(codeError);
|
|
602
|
-
}
|
|
603
|
-
}
|
|
604
|
-
if (option === "conversation" || option === "both") {
|
|
605
|
-
try {
|
|
606
|
-
await onRestoreMessage(messageToRestore);
|
|
607
|
-
} catch (error2) {
|
|
608
|
-
conversationError = error2;
|
|
609
|
-
logError(conversationError);
|
|
610
|
-
}
|
|
611
|
-
}
|
|
612
|
-
setIsRestoring(false);
|
|
613
|
-
setMessageToRestore(undefined);
|
|
614
|
-
if (conversationError && codeError) {
|
|
615
|
-
setError(`Failed to restore the conversation and code:
|
|
616
|
-
${conversationError}
|
|
617
|
-
${codeError}`);
|
|
618
|
-
} else if (conversationError) {
|
|
619
|
-
setError(`Failed to restore the conversation:
|
|
620
|
-
${conversationError}`);
|
|
621
|
-
} else if (codeError) {
|
|
622
|
-
setError(`Failed to restore the code:
|
|
623
|
-
${codeError}`);
|
|
624
|
-
} else {
|
|
625
|
-
onClose();
|
|
626
|
-
}
|
|
627
|
-
}
|
|
628
|
-
const exitState = useExitOnCtrlCDWithKeybindings();
|
|
629
|
-
const handleEscape = import_react.useCallback(() => {
|
|
630
|
-
if (messageToRestore && !preselectedMessage) {
|
|
631
|
-
setMessageToRestore(undefined);
|
|
632
|
-
return;
|
|
633
|
-
}
|
|
634
|
-
logEvent("tengu_message_selector_cancelled", {});
|
|
635
|
-
onClose();
|
|
636
|
-
}, [onClose, messageToRestore, preselectedMessage]);
|
|
637
|
-
const moveUp = import_react.useCallback(() => setSelectedIndex((prev) => Math.max(0, prev - 1)), []);
|
|
638
|
-
const moveDown = import_react.useCallback(() => setSelectedIndex((prev) => Math.min(messageOptions.length - 1, prev + 1)), [messageOptions.length]);
|
|
639
|
-
const jumpToTop = import_react.useCallback(() => setSelectedIndex(0), []);
|
|
640
|
-
const jumpToBottom = import_react.useCallback(() => setSelectedIndex(messageOptions.length - 1), [messageOptions.length]);
|
|
641
|
-
const handleSelectCurrent = import_react.useCallback(() => {
|
|
642
|
-
const selected = messageOptions[selectedIndex];
|
|
643
|
-
if (selected) {
|
|
644
|
-
handleSelect(selected);
|
|
645
|
-
}
|
|
646
|
-
}, [messageOptions, selectedIndex, handleSelect]);
|
|
647
|
-
useKeybinding("confirm:no", handleEscape, {
|
|
648
|
-
context: "Confirmation",
|
|
649
|
-
isActive: !messageToRestore
|
|
650
|
-
});
|
|
651
|
-
useKeybindings({
|
|
652
|
-
"messageSelector:up": moveUp,
|
|
653
|
-
"messageSelector:down": moveDown,
|
|
654
|
-
"messageSelector:top": jumpToTop,
|
|
655
|
-
"messageSelector:bottom": jumpToBottom,
|
|
656
|
-
"messageSelector:select": handleSelectCurrent
|
|
657
|
-
}, {
|
|
658
|
-
context: "MessageSelector",
|
|
659
|
-
isActive: !isRestoring && !error && !messageToRestore && hasMessagesToSelect
|
|
660
|
-
});
|
|
661
|
-
const [fileHistoryMetadata, setFileHistoryMetadata] = import_react.useState({});
|
|
662
|
-
import_react.useEffect(() => {
|
|
663
|
-
async function loadFileHistoryMetadata() {
|
|
664
|
-
if (!isFileHistoryEnabled) {
|
|
665
|
-
return;
|
|
666
|
-
}
|
|
667
|
-
Promise.all(messageOptions.map(async (userMessage, itemIndex) => {
|
|
668
|
-
if (userMessage.uuid !== currentUUID) {
|
|
669
|
-
const canRestore = fileHistoryCanRestore(fileHistory, userMessage.uuid);
|
|
670
|
-
const nextUserMessage = messageOptions.at(itemIndex + 1);
|
|
671
|
-
const diffStats = canRestore ? computeDiffStatsBetweenMessages(messages, userMessage.uuid, nextUserMessage?.uuid !== currentUUID ? nextUserMessage?.uuid : undefined) : undefined;
|
|
672
|
-
if (diffStats !== undefined) {
|
|
673
|
-
setFileHistoryMetadata((prev) => ({
|
|
674
|
-
...prev,
|
|
675
|
-
[itemIndex]: diffStats
|
|
676
|
-
}));
|
|
677
|
-
} else {
|
|
678
|
-
setFileHistoryMetadata((prev) => ({
|
|
679
|
-
...prev,
|
|
680
|
-
[itemIndex]: undefined
|
|
681
|
-
}));
|
|
682
|
-
}
|
|
683
|
-
}
|
|
684
|
-
}));
|
|
685
|
-
}
|
|
686
|
-
loadFileHistoryMetadata();
|
|
687
|
-
}, [messageOptions, messages, currentUUID, fileHistory, isFileHistoryEnabled]);
|
|
688
|
-
const canRestoreCode = isFileHistoryEnabled && diffStatsForRestore?.filesChanged && diffStatsForRestore.filesChanged.length > 0;
|
|
689
|
-
const showPickList = !error && !messageToRestore && !preselectedMessage && hasMessagesToSelect;
|
|
690
|
-
return /* @__PURE__ */ jsx_runtime.jsxs(ThemedBox_default, {
|
|
691
|
-
flexDirection: "column",
|
|
692
|
-
width: "100%",
|
|
693
|
-
children: [
|
|
694
|
-
/* @__PURE__ */ jsx_runtime.jsx(Divider, {
|
|
695
|
-
color: "suggestion"
|
|
696
|
-
}),
|
|
697
|
-
/* @__PURE__ */ jsx_runtime.jsxs(ThemedBox_default, {
|
|
698
|
-
flexDirection: "column",
|
|
699
|
-
marginX: 1,
|
|
700
|
-
gap: 1,
|
|
701
|
-
children: [
|
|
702
|
-
/* @__PURE__ */ jsx_runtime.jsx(ThemedText, {
|
|
703
|
-
bold: true,
|
|
704
|
-
color: "suggestion",
|
|
705
|
-
children: "Rewind"
|
|
706
|
-
}),
|
|
707
|
-
error && /* @__PURE__ */ jsx_runtime.jsx(jsx_runtime.Fragment, {
|
|
708
|
-
children: /* @__PURE__ */ jsx_runtime.jsxs(ThemedText, {
|
|
709
|
-
color: "error",
|
|
710
|
-
children: [
|
|
711
|
-
"Error: ",
|
|
712
|
-
error
|
|
713
|
-
]
|
|
714
|
-
})
|
|
715
|
-
}),
|
|
716
|
-
!hasMessagesToSelect && /* @__PURE__ */ jsx_runtime.jsx(jsx_runtime.Fragment, {
|
|
717
|
-
children: /* @__PURE__ */ jsx_runtime.jsx(ThemedText, {
|
|
718
|
-
children: "Nothing to rewind to yet."
|
|
719
|
-
})
|
|
720
|
-
}),
|
|
721
|
-
!error && messageToRestore && hasMessagesToSelect && /* @__PURE__ */ jsx_runtime.jsxs(jsx_runtime.Fragment, {
|
|
722
|
-
children: [
|
|
723
|
-
/* @__PURE__ */ jsx_runtime.jsxs(ThemedText, {
|
|
724
|
-
children: [
|
|
725
|
-
"Confirm you want to restore ",
|
|
726
|
-
!diffStatsForRestore && "the conversation ",
|
|
727
|
-
"to the point before you sent this message:"
|
|
728
|
-
]
|
|
729
|
-
}),
|
|
730
|
-
/* @__PURE__ */ jsx_runtime.jsxs(ThemedBox_default, {
|
|
731
|
-
flexDirection: "column",
|
|
732
|
-
paddingLeft: 1,
|
|
733
|
-
borderStyle: "single",
|
|
734
|
-
borderRight: false,
|
|
735
|
-
borderTop: false,
|
|
736
|
-
borderBottom: false,
|
|
737
|
-
borderLeft: true,
|
|
738
|
-
borderLeftDimColor: true,
|
|
739
|
-
children: [
|
|
740
|
-
/* @__PURE__ */ jsx_runtime.jsx(UserMessageOption, {
|
|
741
|
-
userMessage: messageToRestore,
|
|
742
|
-
color: "text",
|
|
743
|
-
isCurrent: false
|
|
744
|
-
}),
|
|
745
|
-
/* @__PURE__ */ jsx_runtime.jsxs(ThemedText, {
|
|
746
|
-
dimColor: true,
|
|
747
|
-
children: [
|
|
748
|
-
"(",
|
|
749
|
-
formatRelativeTimeAgo(new Date(messageToRestore.timestamp)),
|
|
750
|
-
")"
|
|
751
|
-
]
|
|
752
|
-
})
|
|
753
|
-
]
|
|
754
|
-
}),
|
|
755
|
-
/* @__PURE__ */ jsx_runtime.jsx(RestoreOptionDescription, {
|
|
756
|
-
selectedRestoreOption,
|
|
757
|
-
canRestoreCode: !!canRestoreCode,
|
|
758
|
-
diffStatsForRestore
|
|
759
|
-
}),
|
|
760
|
-
isRestoring && isSummarizeOption(restoringOption) ? /* @__PURE__ */ jsx_runtime.jsxs(ThemedBox_default, {
|
|
761
|
-
flexDirection: "row",
|
|
762
|
-
gap: 1,
|
|
763
|
-
children: [
|
|
764
|
-
/* @__PURE__ */ jsx_runtime.jsx(Spinner, {}),
|
|
765
|
-
/* @__PURE__ */ jsx_runtime.jsx(ThemedText, {
|
|
766
|
-
children: "Summarizing\u2026"
|
|
767
|
-
})
|
|
768
|
-
]
|
|
769
|
-
}) : /* @__PURE__ */ jsx_runtime.jsx(Select, {
|
|
770
|
-
isDisabled: isRestoring,
|
|
771
|
-
options: getRestoreOptions(!!canRestoreCode),
|
|
772
|
-
defaultFocusValue: canRestoreCode ? "both" : "conversation",
|
|
773
|
-
onFocus: (value) => setSelectedRestoreOption(value),
|
|
774
|
-
onChange: (value) => onSelectRestoreOption(value),
|
|
775
|
-
onCancel: () => preselectedMessage ? onClose() : setMessageToRestore(undefined)
|
|
776
|
-
}),
|
|
777
|
-
canRestoreCode && /* @__PURE__ */ jsx_runtime.jsx(ThemedBox_default, {
|
|
778
|
-
marginBottom: 1,
|
|
779
|
-
children: /* @__PURE__ */ jsx_runtime.jsxs(ThemedText, {
|
|
780
|
-
dimColor: true,
|
|
781
|
-
children: [
|
|
782
|
-
figures_default.warning,
|
|
783
|
-
" Rewinding does not affect files edited manually or via bash."
|
|
784
|
-
]
|
|
785
|
-
})
|
|
786
|
-
})
|
|
787
|
-
]
|
|
788
|
-
}),
|
|
789
|
-
showPickList && /* @__PURE__ */ jsx_runtime.jsxs(jsx_runtime.Fragment, {
|
|
790
|
-
children: [
|
|
791
|
-
isFileHistoryEnabled ? /* @__PURE__ */ jsx_runtime.jsx(ThemedText, {
|
|
792
|
-
children: "Restore the code and/or conversation to the point before\u2026"
|
|
793
|
-
}) : /* @__PURE__ */ jsx_runtime.jsx(ThemedText, {
|
|
794
|
-
children: "Restore and fork the conversation to the point before\u2026"
|
|
795
|
-
}),
|
|
796
|
-
/* @__PURE__ */ jsx_runtime.jsx(ThemedBox_default, {
|
|
797
|
-
width: "100%",
|
|
798
|
-
flexDirection: "column",
|
|
799
|
-
children: messageOptions.slice(firstVisibleIndex, firstVisibleIndex + MAX_VISIBLE_MESSAGES).map((msg, visibleOptionIndex) => {
|
|
800
|
-
const optionIndex = firstVisibleIndex + visibleOptionIndex;
|
|
801
|
-
const isSelected = optionIndex === selectedIndex;
|
|
802
|
-
const isCurrent = msg.uuid === currentUUID;
|
|
803
|
-
const metadataLoaded = optionIndex in fileHistoryMetadata;
|
|
804
|
-
const metadata = fileHistoryMetadata[optionIndex];
|
|
805
|
-
const numFilesChanged = metadata?.filesChanged && metadata.filesChanged.length;
|
|
806
|
-
return /* @__PURE__ */ jsx_runtime.jsxs(ThemedBox_default, {
|
|
807
|
-
height: isFileHistoryEnabled ? 3 : 2,
|
|
808
|
-
overflow: "hidden",
|
|
809
|
-
width: "100%",
|
|
810
|
-
flexDirection: "row",
|
|
811
|
-
children: [
|
|
812
|
-
/* @__PURE__ */ jsx_runtime.jsx(ThemedBox_default, {
|
|
813
|
-
width: 2,
|
|
814
|
-
minWidth: 2,
|
|
815
|
-
children: isSelected ? /* @__PURE__ */ jsx_runtime.jsxs(ThemedText, {
|
|
816
|
-
color: "permission",
|
|
817
|
-
bold: true,
|
|
818
|
-
children: [
|
|
819
|
-
figures_default.pointer,
|
|
820
|
-
" "
|
|
821
|
-
]
|
|
822
|
-
}) : /* @__PURE__ */ jsx_runtime.jsx(ThemedText, {
|
|
823
|
-
children: " "
|
|
824
|
-
})
|
|
825
|
-
}),
|
|
826
|
-
/* @__PURE__ */ jsx_runtime.jsxs(ThemedBox_default, {
|
|
827
|
-
flexDirection: "column",
|
|
828
|
-
children: [
|
|
829
|
-
/* @__PURE__ */ jsx_runtime.jsx(ThemedBox_default, {
|
|
830
|
-
flexShrink: 1,
|
|
831
|
-
height: 1,
|
|
832
|
-
overflow: "hidden",
|
|
833
|
-
children: /* @__PURE__ */ jsx_runtime.jsx(UserMessageOption, {
|
|
834
|
-
userMessage: msg,
|
|
835
|
-
color: isSelected ? "suggestion" : undefined,
|
|
836
|
-
isCurrent,
|
|
837
|
-
paddingRight: 10
|
|
838
|
-
})
|
|
839
|
-
}),
|
|
840
|
-
isFileHistoryEnabled && metadataLoaded && /* @__PURE__ */ jsx_runtime.jsx(ThemedBox_default, {
|
|
841
|
-
height: 1,
|
|
842
|
-
flexDirection: "row",
|
|
843
|
-
children: metadata ? /* @__PURE__ */ jsx_runtime.jsx(jsx_runtime.Fragment, {
|
|
844
|
-
children: /* @__PURE__ */ jsx_runtime.jsx(ThemedText, {
|
|
845
|
-
dimColor: !isSelected,
|
|
846
|
-
color: "inactive",
|
|
847
|
-
children: numFilesChanged ? /* @__PURE__ */ jsx_runtime.jsxs(jsx_runtime.Fragment, {
|
|
848
|
-
children: [
|
|
849
|
-
numFilesChanged === 1 && metadata.filesChanged[0] ? `${path.basename(metadata.filesChanged[0])} ` : `${numFilesChanged} files changed `,
|
|
850
|
-
/* @__PURE__ */ jsx_runtime.jsx(DiffStatsText, {
|
|
851
|
-
diffStats: metadata
|
|
852
|
-
})
|
|
853
|
-
]
|
|
854
|
-
}) : /* @__PURE__ */ jsx_runtime.jsx(jsx_runtime.Fragment, {
|
|
855
|
-
children: "No code changes"
|
|
856
|
-
})
|
|
857
|
-
})
|
|
858
|
-
}) : /* @__PURE__ */ jsx_runtime.jsxs(ThemedText, {
|
|
859
|
-
dimColor: true,
|
|
860
|
-
color: "warning",
|
|
861
|
-
children: [
|
|
862
|
-
figures_default.warning,
|
|
863
|
-
" No code restore"
|
|
864
|
-
]
|
|
865
|
-
})
|
|
866
|
-
})
|
|
867
|
-
]
|
|
868
|
-
})
|
|
869
|
-
]
|
|
870
|
-
}, msg.uuid);
|
|
871
|
-
})
|
|
872
|
-
})
|
|
873
|
-
]
|
|
874
|
-
}),
|
|
875
|
-
!messageToRestore && /* @__PURE__ */ jsx_runtime.jsx(ThemedText, {
|
|
876
|
-
dimColor: true,
|
|
877
|
-
italic: true,
|
|
878
|
-
children: exitState.pending ? /* @__PURE__ */ jsx_runtime.jsxs(jsx_runtime.Fragment, {
|
|
879
|
-
children: [
|
|
880
|
-
"Press ",
|
|
881
|
-
exitState.keyName,
|
|
882
|
-
" again to exit"
|
|
883
|
-
]
|
|
884
|
-
}) : /* @__PURE__ */ jsx_runtime.jsxs(jsx_runtime.Fragment, {
|
|
885
|
-
children: [
|
|
886
|
-
!error && hasMessagesToSelect && "Enter to continue \xB7 ",
|
|
887
|
-
"Esc to exit"
|
|
888
|
-
]
|
|
889
|
-
})
|
|
890
|
-
})
|
|
891
|
-
]
|
|
892
|
-
})
|
|
893
|
-
]
|
|
894
|
-
});
|
|
895
|
-
}
|
|
896
|
-
function getRestoreOptionConversationText(option) {
|
|
897
|
-
switch (option) {
|
|
898
|
-
case "summarize":
|
|
899
|
-
return "Messages after this point will be summarized.";
|
|
900
|
-
case "summarize_up_to":
|
|
901
|
-
return "Preceding messages will be summarized. This and subsequent messages will remain unchanged \u2014 you will stay at the end of the conversation.";
|
|
902
|
-
case "both":
|
|
903
|
-
case "conversation":
|
|
904
|
-
return "The conversation will be forked.";
|
|
905
|
-
case "code":
|
|
906
|
-
case "nevermind":
|
|
907
|
-
return "The conversation will be unchanged.";
|
|
908
|
-
}
|
|
909
|
-
}
|
|
910
|
-
function RestoreOptionDescription({
|
|
911
|
-
selectedRestoreOption,
|
|
912
|
-
canRestoreCode,
|
|
913
|
-
diffStatsForRestore
|
|
914
|
-
}) {
|
|
915
|
-
const showCodeRestore = canRestoreCode && (selectedRestoreOption === "both" || selectedRestoreOption === "code");
|
|
916
|
-
return /* @__PURE__ */ jsx_runtime.jsxs(ThemedBox_default, {
|
|
917
|
-
flexDirection: "column",
|
|
918
|
-
children: [
|
|
919
|
-
/* @__PURE__ */ jsx_runtime.jsx(ThemedText, {
|
|
920
|
-
dimColor: true,
|
|
921
|
-
children: getRestoreOptionConversationText(selectedRestoreOption)
|
|
922
|
-
}),
|
|
923
|
-
!isSummarizeOption(selectedRestoreOption) && (showCodeRestore ? /* @__PURE__ */ jsx_runtime.jsx(RestoreCodeConfirmation, {
|
|
924
|
-
diffStatsForRestore
|
|
925
|
-
}) : /* @__PURE__ */ jsx_runtime.jsx(ThemedText, {
|
|
926
|
-
dimColor: true,
|
|
927
|
-
children: "The code will be unchanged."
|
|
928
|
-
}))
|
|
929
|
-
]
|
|
930
|
-
});
|
|
931
|
-
}
|
|
932
|
-
function RestoreCodeConfirmation({
|
|
933
|
-
diffStatsForRestore
|
|
934
|
-
}) {
|
|
935
|
-
if (diffStatsForRestore === undefined) {
|
|
936
|
-
return;
|
|
937
|
-
}
|
|
938
|
-
if (!diffStatsForRestore.filesChanged || !diffStatsForRestore.filesChanged[0]) {
|
|
939
|
-
return /* @__PURE__ */ jsx_runtime.jsx(ThemedText, {
|
|
940
|
-
dimColor: true,
|
|
941
|
-
children: "The code has not changed (nothing will be restored)."
|
|
942
|
-
});
|
|
943
|
-
}
|
|
944
|
-
const numFilesChanged = diffStatsForRestore.filesChanged.length;
|
|
945
|
-
let fileLabel = "";
|
|
946
|
-
if (numFilesChanged === 1) {
|
|
947
|
-
fileLabel = path.basename(diffStatsForRestore.filesChanged[0] || "");
|
|
948
|
-
} else if (numFilesChanged === 2) {
|
|
949
|
-
const file1 = path.basename(diffStatsForRestore.filesChanged[0] || "");
|
|
950
|
-
const file2 = path.basename(diffStatsForRestore.filesChanged[1] || "");
|
|
951
|
-
fileLabel = `${file1} and ${file2}`;
|
|
952
|
-
} else {
|
|
953
|
-
const file1 = path.basename(diffStatsForRestore.filesChanged[0] || "");
|
|
954
|
-
fileLabel = `${file1} and ${diffStatsForRestore.filesChanged.length - 1} other files`;
|
|
955
|
-
}
|
|
956
|
-
return /* @__PURE__ */ jsx_runtime.jsx(jsx_runtime.Fragment, {
|
|
957
|
-
children: /* @__PURE__ */ jsx_runtime.jsxs(ThemedText, {
|
|
958
|
-
dimColor: true,
|
|
959
|
-
children: [
|
|
960
|
-
"The code will be restored ",
|
|
961
|
-
/* @__PURE__ */ jsx_runtime.jsx(DiffStatsText, {
|
|
962
|
-
diffStats: diffStatsForRestore
|
|
963
|
-
}),
|
|
964
|
-
" in ",
|
|
965
|
-
fileLabel,
|
|
966
|
-
"."
|
|
967
|
-
]
|
|
968
|
-
})
|
|
969
|
-
});
|
|
970
|
-
}
|
|
971
|
-
function DiffStatsText({ diffStats }) {
|
|
972
|
-
if (!diffStats || !diffStats.filesChanged) {
|
|
973
|
-
return;
|
|
974
|
-
}
|
|
975
|
-
return /* @__PURE__ */ jsx_runtime.jsxs(jsx_runtime.Fragment, {
|
|
976
|
-
children: [
|
|
977
|
-
/* @__PURE__ */ jsx_runtime.jsxs(ThemedText, {
|
|
978
|
-
color: "diffAddedWord",
|
|
979
|
-
children: [
|
|
980
|
-
"+",
|
|
981
|
-
diffStats.insertions,
|
|
982
|
-
" "
|
|
983
|
-
]
|
|
984
|
-
}),
|
|
985
|
-
/* @__PURE__ */ jsx_runtime.jsxs(ThemedText, {
|
|
986
|
-
color: "diffRemovedWord",
|
|
987
|
-
children: [
|
|
988
|
-
"-",
|
|
989
|
-
diffStats.deletions
|
|
990
|
-
]
|
|
991
|
-
})
|
|
992
|
-
]
|
|
993
|
-
});
|
|
994
|
-
}
|
|
995
|
-
function UserMessageOption({
|
|
996
|
-
userMessage,
|
|
997
|
-
color,
|
|
998
|
-
dimColor,
|
|
999
|
-
isCurrent,
|
|
1000
|
-
paddingRight
|
|
1001
|
-
}) {
|
|
1002
|
-
const { columns } = useTerminalSize();
|
|
1003
|
-
if (isCurrent) {
|
|
1004
|
-
return /* @__PURE__ */ jsx_runtime.jsx(ThemedBox_default, {
|
|
1005
|
-
width: "100%",
|
|
1006
|
-
children: /* @__PURE__ */ jsx_runtime.jsx(ThemedText, {
|
|
1007
|
-
italic: true,
|
|
1008
|
-
color,
|
|
1009
|
-
dimColor,
|
|
1010
|
-
children: "(current)"
|
|
1011
|
-
})
|
|
1012
|
-
});
|
|
1013
|
-
}
|
|
1014
|
-
const content = userMessage.message.content;
|
|
1015
|
-
const lastBlock = typeof content === "string" ? null : content[content.length - 1];
|
|
1016
|
-
const rawMessageText = typeof content === "string" ? content.trim() : lastBlock && isTextBlock(lastBlock) ? lastBlock.text.trim() : "(no prompt)";
|
|
1017
|
-
const messageText = stripDisplayTags(rawMessageText);
|
|
1018
|
-
if (isEmptyMessageText(messageText)) {
|
|
1019
|
-
return /* @__PURE__ */ jsx_runtime.jsx(ThemedBox_default, {
|
|
1020
|
-
flexDirection: "row",
|
|
1021
|
-
width: "100%",
|
|
1022
|
-
children: /* @__PURE__ */ jsx_runtime.jsx(ThemedText, {
|
|
1023
|
-
italic: true,
|
|
1024
|
-
color,
|
|
1025
|
-
dimColor,
|
|
1026
|
-
children: "((empty message))"
|
|
1027
|
-
})
|
|
1028
|
-
});
|
|
1029
|
-
}
|
|
1030
|
-
if (messageText.includes("<bash-input>")) {
|
|
1031
|
-
const input = extractTag(messageText, "bash-input");
|
|
1032
|
-
if (input) {
|
|
1033
|
-
return /* @__PURE__ */ jsx_runtime.jsxs(ThemedBox_default, {
|
|
1034
|
-
flexDirection: "row",
|
|
1035
|
-
width: "100%",
|
|
1036
|
-
children: [
|
|
1037
|
-
/* @__PURE__ */ jsx_runtime.jsx(ThemedText, {
|
|
1038
|
-
color: "bashBorder",
|
|
1039
|
-
children: "!"
|
|
1040
|
-
}),
|
|
1041
|
-
/* @__PURE__ */ jsx_runtime.jsxs(ThemedText, {
|
|
1042
|
-
color,
|
|
1043
|
-
dimColor,
|
|
1044
|
-
children: [
|
|
1045
|
-
" ",
|
|
1046
|
-
input
|
|
1047
|
-
]
|
|
1048
|
-
})
|
|
1049
|
-
]
|
|
1050
|
-
});
|
|
1051
|
-
}
|
|
1052
|
-
}
|
|
1053
|
-
if (messageText.includes(`<${COMMAND_MESSAGE_TAG}>`)) {
|
|
1054
|
-
const commandMessage = extractTag(messageText, COMMAND_MESSAGE_TAG);
|
|
1055
|
-
const args = extractTag(messageText, "command-args");
|
|
1056
|
-
const isSkillFormat = extractTag(messageText, "skill-format") === "true";
|
|
1057
|
-
if (commandMessage) {
|
|
1058
|
-
if (isSkillFormat) {
|
|
1059
|
-
return /* @__PURE__ */ jsx_runtime.jsx(ThemedBox_default, {
|
|
1060
|
-
flexDirection: "row",
|
|
1061
|
-
width: "100%",
|
|
1062
|
-
children: /* @__PURE__ */ jsx_runtime.jsxs(ThemedText, {
|
|
1063
|
-
color,
|
|
1064
|
-
dimColor,
|
|
1065
|
-
children: [
|
|
1066
|
-
"Skill(",
|
|
1067
|
-
commandMessage,
|
|
1068
|
-
")"
|
|
1069
|
-
]
|
|
1070
|
-
})
|
|
1071
|
-
});
|
|
1072
|
-
} else {
|
|
1073
|
-
return /* @__PURE__ */ jsx_runtime.jsx(ThemedBox_default, {
|
|
1074
|
-
flexDirection: "row",
|
|
1075
|
-
width: "100%",
|
|
1076
|
-
children: /* @__PURE__ */ jsx_runtime.jsxs(ThemedText, {
|
|
1077
|
-
color,
|
|
1078
|
-
dimColor,
|
|
1079
|
-
children: [
|
|
1080
|
-
"/",
|
|
1081
|
-
commandMessage,
|
|
1082
|
-
" ",
|
|
1083
|
-
args
|
|
1084
|
-
]
|
|
1085
|
-
})
|
|
1086
|
-
});
|
|
1087
|
-
}
|
|
1088
|
-
}
|
|
1089
|
-
}
|
|
1090
|
-
return /* @__PURE__ */ jsx_runtime.jsx(ThemedBox_default, {
|
|
1091
|
-
flexDirection: "row",
|
|
1092
|
-
width: "100%",
|
|
1093
|
-
children: /* @__PURE__ */ jsx_runtime.jsx(ThemedText, {
|
|
1094
|
-
color,
|
|
1095
|
-
dimColor,
|
|
1096
|
-
children: paddingRight ? truncate(messageText, columns - paddingRight, true) : messageText.slice(0, 500).split(`
|
|
1097
|
-
`).slice(0, 4).join(`
|
|
1098
|
-
`)
|
|
1099
|
-
})
|
|
1100
|
-
});
|
|
1101
|
-
}
|
|
1102
|
-
function computeDiffStatsBetweenMessages(messages, fromMessageId, toMessageId) {
|
|
1103
|
-
const startIndex = messages.findIndex((msg) => msg.uuid === fromMessageId);
|
|
1104
|
-
if (startIndex === -1) {
|
|
1105
|
-
return;
|
|
1106
|
-
}
|
|
1107
|
-
let endIndex = toMessageId ? messages.findIndex((msg) => msg.uuid === toMessageId) : messages.length;
|
|
1108
|
-
if (endIndex === -1) {
|
|
1109
|
-
endIndex = messages.length;
|
|
1110
|
-
}
|
|
1111
|
-
const filesChanged = [];
|
|
1112
|
-
let insertions = 0;
|
|
1113
|
-
let deletions = 0;
|
|
1114
|
-
for (let i = startIndex + 1;i < endIndex; i++) {
|
|
1115
|
-
const msg = messages[i];
|
|
1116
|
-
if (!msg || !isToolUseResultMessage(msg)) {
|
|
1117
|
-
continue;
|
|
1118
|
-
}
|
|
1119
|
-
const result = msg.toolUseResult;
|
|
1120
|
-
if (!result || !result.filePath || !result.structuredPatch) {
|
|
1121
|
-
continue;
|
|
1122
|
-
}
|
|
1123
|
-
if (!filesChanged.includes(result.filePath)) {
|
|
1124
|
-
filesChanged.push(result.filePath);
|
|
1125
|
-
}
|
|
1126
|
-
try {
|
|
1127
|
-
if ("type" in result && result.type === "create") {
|
|
1128
|
-
insertions += result.content.split(/\r?\n/).length;
|
|
1129
|
-
} else {
|
|
1130
|
-
for (const hunk of result.structuredPatch) {
|
|
1131
|
-
const additions = count(hunk.lines, (line) => line.startsWith("+"));
|
|
1132
|
-
const removals = count(hunk.lines, (line) => line.startsWith("-"));
|
|
1133
|
-
insertions += additions;
|
|
1134
|
-
deletions += removals;
|
|
1135
|
-
}
|
|
1136
|
-
}
|
|
1137
|
-
} catch {}
|
|
1138
|
-
}
|
|
1139
|
-
return {
|
|
1140
|
-
filesChanged,
|
|
1141
|
-
insertions,
|
|
1142
|
-
deletions
|
|
1143
|
-
};
|
|
1144
|
-
}
|
|
1145
|
-
function selectableUserMessagesFilter(message) {
|
|
1146
|
-
if (message.type !== "user") {
|
|
1147
|
-
return false;
|
|
1148
|
-
}
|
|
1149
|
-
if (Array.isArray(message.message.content) && message.message.content[0]?.type === "tool_result") {
|
|
1150
|
-
return false;
|
|
1151
|
-
}
|
|
1152
|
-
if (isSyntheticMessage(message)) {
|
|
1153
|
-
return false;
|
|
1154
|
-
}
|
|
1155
|
-
if (message.isMeta) {
|
|
1156
|
-
return false;
|
|
1157
|
-
}
|
|
1158
|
-
if (message.isCompactSummary || message.isVisibleInTranscriptOnly) {
|
|
1159
|
-
return false;
|
|
1160
|
-
}
|
|
1161
|
-
const content = message.message.content;
|
|
1162
|
-
const lastBlock = typeof content === "string" ? null : content[content.length - 1];
|
|
1163
|
-
const messageText = typeof content === "string" ? content.trim() : lastBlock && isTextBlock(lastBlock) ? lastBlock.text.trim() : "";
|
|
1164
|
-
if (messageText.indexOf(`<${LOCAL_COMMAND_STDOUT_TAG}>`) !== -1 || messageText.indexOf(`<${LOCAL_COMMAND_STDERR_TAG}>`) !== -1 || messageText.indexOf(`<${BASH_STDOUT_TAG}>`) !== -1 || messageText.indexOf(`<${BASH_STDERR_TAG}>`) !== -1 || messageText.indexOf(`<${TASK_NOTIFICATION_TAG}>`) !== -1 || messageText.indexOf(`<${TICK_TAG}>`) !== -1 || messageText.indexOf(`<${TEAMMATE_MESSAGE_TAG}`) !== -1) {
|
|
1165
|
-
return false;
|
|
1166
|
-
}
|
|
1167
|
-
return true;
|
|
1168
|
-
}
|
|
1169
|
-
function messagesAfterAreOnlySynthetic(messages, fromIndex) {
|
|
1170
|
-
for (let i = fromIndex + 1;i < messages.length; i++) {
|
|
1171
|
-
const msg = messages[i];
|
|
1172
|
-
if (!msg)
|
|
1173
|
-
continue;
|
|
1174
|
-
if (isSyntheticMessage(msg))
|
|
1175
|
-
continue;
|
|
1176
|
-
if (isToolUseResultMessage(msg))
|
|
1177
|
-
continue;
|
|
1178
|
-
if (msg.type === "progress")
|
|
1179
|
-
continue;
|
|
1180
|
-
if (msg.type === "system")
|
|
1181
|
-
continue;
|
|
1182
|
-
if (msg.type === "attachment")
|
|
1183
|
-
continue;
|
|
1184
|
-
if (msg.type === "user" && msg.isMeta)
|
|
1185
|
-
continue;
|
|
1186
|
-
if (msg.type === "assistant") {
|
|
1187
|
-
const content = msg.message.content;
|
|
1188
|
-
if (Array.isArray(content)) {
|
|
1189
|
-
const hasMeaningfulContent = content.some((block) => block.type === "text" && block.text.trim() || block.type === "tool_use");
|
|
1190
|
-
if (hasMeaningfulContent)
|
|
1191
|
-
return false;
|
|
1192
|
-
}
|
|
1193
|
-
continue;
|
|
1194
|
-
}
|
|
1195
|
-
if (msg.type === "user") {
|
|
1196
|
-
return false;
|
|
1197
|
-
}
|
|
1198
|
-
}
|
|
1199
|
-
return true;
|
|
1200
|
-
}
|
|
1201
|
-
var import_react, jsx_runtime, MAX_VISIBLE_MESSAGES = 7;
|
|
1202
|
-
var init_MessageSelector = __esm(() => {
|
|
1203
|
-
init_figures();
|
|
1204
|
-
init_analytics();
|
|
1205
|
-
init_AppState();
|
|
1206
|
-
init_fileHistory();
|
|
1207
|
-
init_log();
|
|
1208
|
-
init_useExitOnCtrlCDWithKeybindings();
|
|
1209
|
-
init_src();
|
|
1210
|
-
init_useKeybinding();
|
|
1211
|
-
init_displayTags();
|
|
1212
|
-
init_messages();
|
|
1213
|
-
init_select();
|
|
1214
|
-
init_Spinner();
|
|
1215
|
-
init_useTerminalSize();
|
|
1216
|
-
init_xml();
|
|
1217
|
-
init_array();
|
|
1218
|
-
init_format();
|
|
1219
|
-
import_react = __toESM(require_react(), 1);
|
|
1220
|
-
jsx_runtime = __toESM(require_jsx_runtime(), 1);
|
|
1221
|
-
});
|
|
1222
|
-
|
|
1223
312
|
// src/utils/cronJitterConfig.ts
|
|
1224
313
|
var exports_cronJitterConfig = {};
|
|
1225
314
|
__export(exports_cronJitterConfig, {
|
|
@@ -1266,19 +355,19 @@ async function readLock(dir) {
|
|
|
1266
355
|
return result.success ? result.data : undefined;
|
|
1267
356
|
}
|
|
1268
357
|
async function tryCreateExclusive(lock, dir) {
|
|
1269
|
-
const
|
|
358
|
+
const path = getLockPath(dir);
|
|
1270
359
|
const body = jsonStringify(lock);
|
|
1271
360
|
try {
|
|
1272
|
-
await writeFile(
|
|
361
|
+
await writeFile(path, body, { flag: "wx" });
|
|
1273
362
|
return true;
|
|
1274
363
|
} catch (e) {
|
|
1275
364
|
const code = getErrnoCode(e);
|
|
1276
365
|
if (code === "EEXIST")
|
|
1277
366
|
return false;
|
|
1278
367
|
if (code === "ENOENT") {
|
|
1279
|
-
await mkdir(dirname(
|
|
368
|
+
await mkdir(dirname(path), { recursive: true });
|
|
1280
369
|
try {
|
|
1281
|
-
await writeFile(
|
|
370
|
+
await writeFile(path, body, { flag: "wx" });
|
|
1282
371
|
return true;
|
|
1283
372
|
} catch (retryErr) {
|
|
1284
373
|
if (getErrnoCode(retryErr) === "EEXIST")
|
|
@@ -1550,8 +639,8 @@ function createCronScheduler(options) {
|
|
|
1550
639
|
lockProbeTimer.unref?.();
|
|
1551
640
|
}
|
|
1552
641
|
load(true);
|
|
1553
|
-
const
|
|
1554
|
-
watcher = chokidar.watch(
|
|
642
|
+
const path = getCronFilePath(dir);
|
|
643
|
+
watcher = chokidar.watch(path, {
|
|
1555
644
|
persistent: false,
|
|
1556
645
|
ignoreInitial: true,
|
|
1557
646
|
awaitWriteFinish: { stabilityThreshold: FILE_STABILITY_MS },
|
|
@@ -1753,7 +842,7 @@ function permissionPromptToolResultToPermissionDecision(result, tool, input, too
|
|
|
1753
842
|
}
|
|
1754
843
|
|
|
1755
844
|
// src/cli/structuredIO.ts
|
|
1756
|
-
import { randomUUID
|
|
845
|
+
import { randomUUID } from "crypto";
|
|
1757
846
|
|
|
1758
847
|
// src/entrypoints/sdk/controlSchemas.ts
|
|
1759
848
|
init_v4();
|
|
@@ -2123,7 +1212,9 @@ function serializeDecisionReason(reason) {
|
|
|
2123
1212
|
if (!reason) {
|
|
2124
1213
|
return;
|
|
2125
1214
|
}
|
|
2126
|
-
if (
|
|
1215
|
+
if (reason.type === "classifier") {
|
|
1216
|
+
return reason.reason;
|
|
1217
|
+
}
|
|
2127
1218
|
switch (reason.type) {
|
|
2128
1219
|
case "rule":
|
|
2129
1220
|
case "mode":
|
|
@@ -2373,7 +1464,7 @@ class StructuredIO {
|
|
|
2373
1464
|
writeToStdout(ndjsonSafeStringify(message) + `
|
|
2374
1465
|
`);
|
|
2375
1466
|
}
|
|
2376
|
-
async sendRequest(request, schema, signal, requestId =
|
|
1467
|
+
async sendRequest(request, schema, signal, requestId = randomUUID()) {
|
|
2377
1468
|
const message = {
|
|
2378
1469
|
type: "control_request",
|
|
2379
1470
|
request_id: requestId,
|
|
@@ -2439,7 +1530,7 @@ class StructuredIO {
|
|
|
2439
1530
|
parentSignal.addEventListener("abort", onParentAbort, { once: true });
|
|
2440
1531
|
try {
|
|
2441
1532
|
const hookPromise = executePermissionRequestHooksForSDK(tool.name, toolUseID, input, toolUseContext, mainPermissionResult.suggestions).then((decision) => ({ source: "hook", decision }));
|
|
2442
|
-
const requestId =
|
|
1533
|
+
const requestId = randomUUID();
|
|
2443
1534
|
onPermissionPrompt?.(buildRequiresActionDetails(tool, input, toolUseID, requestId));
|
|
2444
1535
|
const sdkPromise = this.sendRequest({
|
|
2445
1536
|
subtype: "can_use_tool",
|
|
@@ -2519,7 +1610,7 @@ class StructuredIO {
|
|
|
2519
1610
|
subtype: "can_use_tool",
|
|
2520
1611
|
tool_name: SANDBOX_NETWORK_ACCESS_TOOL_NAME,
|
|
2521
1612
|
input: { host: hostPattern.host },
|
|
2522
|
-
tool_use_id:
|
|
1613
|
+
tool_use_id: randomUUID(),
|
|
2523
1614
|
description: `Allow network connection to ${hostPattern.host}?`
|
|
2524
1615
|
}, outputSchema());
|
|
2525
1616
|
return result.behavior === "allow";
|
|
@@ -2587,461 +1678,6 @@ async function executePermissionRequestHooksForSDK(toolName, toolUseID, input, t
|
|
|
2587
1678
|
return;
|
|
2588
1679
|
}
|
|
2589
1680
|
|
|
2590
|
-
// src/utils/messages/systemInit.ts
|
|
2591
|
-
init_state();
|
|
2592
|
-
init_outputStyles();
|
|
2593
|
-
init_constants();
|
|
2594
|
-
init_auth();
|
|
2595
|
-
init_cwd();
|
|
2596
|
-
init_fastMode();
|
|
2597
|
-
init_settings();
|
|
2598
|
-
import { randomUUID as randomUUID3 } from "crypto";
|
|
2599
|
-
function sdkCompatToolName(name) {
|
|
2600
|
-
return name === AGENT_TOOL_NAME ? LEGACY_AGENT_TOOL_NAME : name;
|
|
2601
|
-
}
|
|
2602
|
-
function buildSystemInitMessage(inputs) {
|
|
2603
|
-
const settings = getSettings_DEPRECATED();
|
|
2604
|
-
const outputStyle = settings?.outputStyle ?? DEFAULT_OUTPUT_STYLE_NAME;
|
|
2605
|
-
const initMessage = {
|
|
2606
|
-
type: "system",
|
|
2607
|
-
subtype: "init",
|
|
2608
|
-
cwd: getCwd(),
|
|
2609
|
-
session_id: getSessionId(),
|
|
2610
|
-
tools: inputs.tools.map((tool) => sdkCompatToolName(tool.name)),
|
|
2611
|
-
mcp_servers: inputs.mcpClients.map((client) => ({
|
|
2612
|
-
name: client.name,
|
|
2613
|
-
status: client.type
|
|
2614
|
-
})),
|
|
2615
|
-
model: inputs.model,
|
|
2616
|
-
permissionMode: inputs.permissionMode,
|
|
2617
|
-
slash_commands: inputs.commands.filter((c) => c.userInvocable !== false).map((c) => c.name),
|
|
2618
|
-
apiKeySource: getAnthropicApiKeyWithSource().source,
|
|
2619
|
-
betas: getSdkBetas(),
|
|
2620
|
-
claude_code_version: "4.1.1",
|
|
2621
|
-
output_style: outputStyle,
|
|
2622
|
-
agents: inputs.agents.map((agent) => agent.agentType),
|
|
2623
|
-
skills: inputs.skills.filter((s) => s.userInvocable !== false).map((skill) => skill.name),
|
|
2624
|
-
plugins: inputs.plugins.map((plugin) => ({
|
|
2625
|
-
name: plugin.name,
|
|
2626
|
-
path: plugin.path,
|
|
2627
|
-
source: plugin.source
|
|
2628
|
-
})),
|
|
2629
|
-
uuid: randomUUID3()
|
|
2630
|
-
};
|
|
2631
|
-
if (false) {}
|
|
2632
|
-
initMessage.fast_mode_state = getFastModeState(inputs.model, inputs.fastMode);
|
|
2633
|
-
return initMessage;
|
|
2634
|
-
}
|
|
2635
|
-
|
|
2636
|
-
// src/utils/ultraplan/keyword.ts
|
|
2637
|
-
var OPEN_TO_CLOSE = {
|
|
2638
|
-
"`": "`",
|
|
2639
|
-
'"': '"',
|
|
2640
|
-
"<": ">",
|
|
2641
|
-
"{": "}",
|
|
2642
|
-
"[": "]",
|
|
2643
|
-
"(": ")",
|
|
2644
|
-
"'": "'"
|
|
2645
|
-
};
|
|
2646
|
-
function findKeywordTriggerPositions(text, keyword) {
|
|
2647
|
-
const re = new RegExp(keyword, "i");
|
|
2648
|
-
if (!re.test(text))
|
|
2649
|
-
return [];
|
|
2650
|
-
if (text.startsWith("/"))
|
|
2651
|
-
return [];
|
|
2652
|
-
const quotedRanges = [];
|
|
2653
|
-
let openQuote = null;
|
|
2654
|
-
let openAt = 0;
|
|
2655
|
-
const isWord = (ch) => !!ch && /[\p{L}\p{N}_]/u.test(ch);
|
|
2656
|
-
for (let i = 0;i < text.length; i++) {
|
|
2657
|
-
const ch = text[i];
|
|
2658
|
-
if (openQuote) {
|
|
2659
|
-
if (openQuote === "[" && ch === "[") {
|
|
2660
|
-
openAt = i;
|
|
2661
|
-
continue;
|
|
2662
|
-
}
|
|
2663
|
-
if (ch !== OPEN_TO_CLOSE[openQuote])
|
|
2664
|
-
continue;
|
|
2665
|
-
if (openQuote === "'" && isWord(text[i + 1]))
|
|
2666
|
-
continue;
|
|
2667
|
-
quotedRanges.push({ start: openAt, end: i + 1 });
|
|
2668
|
-
openQuote = null;
|
|
2669
|
-
} else if (ch === "<" && i + 1 < text.length && /[a-zA-Z/]/.test(text[i + 1]) || ch === "'" && !isWord(text[i - 1]) || ch !== "<" && ch !== "'" && ch in OPEN_TO_CLOSE) {
|
|
2670
|
-
openQuote = ch;
|
|
2671
|
-
openAt = i;
|
|
2672
|
-
}
|
|
2673
|
-
}
|
|
2674
|
-
const positions = [];
|
|
2675
|
-
const wordRe = new RegExp(`\\b${keyword}\\b`, "gi");
|
|
2676
|
-
const matches = text.matchAll(wordRe);
|
|
2677
|
-
for (const match of matches) {
|
|
2678
|
-
if (match.index === undefined)
|
|
2679
|
-
continue;
|
|
2680
|
-
const start = match.index;
|
|
2681
|
-
const end = start + match[0].length;
|
|
2682
|
-
if (quotedRanges.some((r) => start >= r.start && start < r.end))
|
|
2683
|
-
continue;
|
|
2684
|
-
const before = text[start - 1];
|
|
2685
|
-
const after = text[end];
|
|
2686
|
-
if (before === "/" || before === "\\" || before === "-")
|
|
2687
|
-
continue;
|
|
2688
|
-
if (after === "/" || after === "\\" || after === "-" || after === "?")
|
|
2689
|
-
continue;
|
|
2690
|
-
if (after === "." && isWord(text[end + 1]))
|
|
2691
|
-
continue;
|
|
2692
|
-
positions.push({ word: match[0], start, end });
|
|
2693
|
-
}
|
|
2694
|
-
return positions;
|
|
2695
|
-
}
|
|
2696
|
-
function findUltraplanTriggerPositions(text) {
|
|
2697
|
-
return findKeywordTriggerPositions(text, "ultraplan");
|
|
2698
|
-
}
|
|
2699
|
-
function findUltrareviewTriggerPositions(text) {
|
|
2700
|
-
return findKeywordTriggerPositions(text, "ultrareview");
|
|
2701
|
-
}
|
|
2702
|
-
function hasUltraplanKeyword(text) {
|
|
2703
|
-
return findUltraplanTriggerPositions(text).length > 0;
|
|
2704
|
-
}
|
|
2705
|
-
function replaceUltraplanKeyword(text) {
|
|
2706
|
-
const [trigger] = findUltraplanTriggerPositions(text);
|
|
2707
|
-
if (!trigger)
|
|
2708
|
-
return text;
|
|
2709
|
-
const before = text.slice(0, trigger.start);
|
|
2710
|
-
const after = text.slice(trigger.end);
|
|
2711
|
-
if (!(before + after).trim())
|
|
2712
|
-
return "";
|
|
2713
|
-
return before + trigger.word.slice("ultra".length) + after;
|
|
2714
|
-
}
|
|
2715
|
-
|
|
2716
|
-
// src/utils/processUserInput/processUserInput.ts
|
|
2717
|
-
init_analytics();
|
|
2718
|
-
init_messages();
|
|
2719
|
-
init_commands();
|
|
2720
|
-
init_textInputTypes();
|
|
2721
|
-
init_attachments();
|
|
2722
|
-
init_generators();
|
|
2723
|
-
init_hooks2();
|
|
2724
|
-
init_imageResizer();
|
|
2725
|
-
init_imageStore();
|
|
2726
|
-
init_messages();
|
|
2727
|
-
init_queryProfiler();
|
|
2728
|
-
init_slashCommandParsing();
|
|
2729
|
-
import { randomUUID as randomUUID5 } from "crypto";
|
|
2730
|
-
|
|
2731
|
-
// src/utils/processUserInput/processTextPrompt.ts
|
|
2732
|
-
init_state();
|
|
2733
|
-
init_analytics();
|
|
2734
|
-
init_messages();
|
|
2735
|
-
init_events();
|
|
2736
|
-
init_sessionTracing();
|
|
2737
|
-
import { randomUUID as randomUUID4 } from "crypto";
|
|
2738
|
-
|
|
2739
|
-
// src/utils/userPromptKeywords.ts
|
|
2740
|
-
function matchesNegativeKeyword(input) {
|
|
2741
|
-
const lowerInput = input.toLowerCase();
|
|
2742
|
-
const negativePattern = /\b(wtf|wth|ffs|omfg|shit(ty|tiest)?|dumbass|horrible|awful|piss(ed|ing)? off|piece of (shit|crap|junk)|what the (fuck|hell)|fucking? (broken|useless|terrible|awful|horrible)|fuck you|screw (this|you)|so frustrating|this sucks|damn it)\b/;
|
|
2743
|
-
return negativePattern.test(lowerInput);
|
|
2744
|
-
}
|
|
2745
|
-
function matchesKeepGoingKeyword(input) {
|
|
2746
|
-
const lowerInput = input.toLowerCase().trim();
|
|
2747
|
-
if (lowerInput === "continue") {
|
|
2748
|
-
return true;
|
|
2749
|
-
}
|
|
2750
|
-
const keepGoingPattern = /\b(keep going|go on)\b/;
|
|
2751
|
-
return keepGoingPattern.test(lowerInput);
|
|
2752
|
-
}
|
|
2753
|
-
|
|
2754
|
-
// src/utils/processUserInput/processTextPrompt.ts
|
|
2755
|
-
function processTextPrompt(input, imageContentBlocks, imagePasteIds, attachmentMessages, uuid, permissionMode, isMeta) {
|
|
2756
|
-
const promptId = randomUUID4();
|
|
2757
|
-
setPromptId(promptId);
|
|
2758
|
-
const userPromptText = typeof input === "string" ? input : input.find((block) => block.type === "text")?.text || "";
|
|
2759
|
-
startInteractionSpan(userPromptText);
|
|
2760
|
-
const otelPromptText = typeof input === "string" ? input : input.findLast((block) => block.type === "text")?.text || "";
|
|
2761
|
-
if (otelPromptText) {
|
|
2762
|
-
logOTelEvent("user_prompt", {
|
|
2763
|
-
prompt_length: String(otelPromptText.length),
|
|
2764
|
-
prompt: redactIfDisabled(otelPromptText),
|
|
2765
|
-
"prompt.id": promptId
|
|
2766
|
-
});
|
|
2767
|
-
}
|
|
2768
|
-
const isNegative = matchesNegativeKeyword(userPromptText);
|
|
2769
|
-
const isKeepGoing = matchesKeepGoingKeyword(userPromptText);
|
|
2770
|
-
logEvent("tengu_input_prompt", {
|
|
2771
|
-
is_negative: isNegative,
|
|
2772
|
-
is_keep_going: isKeepGoing
|
|
2773
|
-
});
|
|
2774
|
-
if (imageContentBlocks.length > 0) {
|
|
2775
|
-
const textContent = typeof input === "string" ? input.trim() ? [{ type: "text", text: input }] : [] : input;
|
|
2776
|
-
const userMessage2 = createUserMessage({
|
|
2777
|
-
content: [...textContent, ...imageContentBlocks],
|
|
2778
|
-
uuid,
|
|
2779
|
-
imagePasteIds: imagePasteIds.length > 0 ? imagePasteIds : undefined,
|
|
2780
|
-
permissionMode,
|
|
2781
|
-
isMeta: isMeta || undefined
|
|
2782
|
-
});
|
|
2783
|
-
return {
|
|
2784
|
-
messages: [userMessage2, ...attachmentMessages],
|
|
2785
|
-
shouldQuery: true
|
|
2786
|
-
};
|
|
2787
|
-
}
|
|
2788
|
-
const userMessage = createUserMessage({
|
|
2789
|
-
content: input,
|
|
2790
|
-
uuid,
|
|
2791
|
-
permissionMode,
|
|
2792
|
-
isMeta: isMeta || undefined
|
|
2793
|
-
});
|
|
2794
|
-
return {
|
|
2795
|
-
messages: [userMessage, ...attachmentMessages],
|
|
2796
|
-
shouldQuery: true
|
|
2797
|
-
};
|
|
2798
|
-
}
|
|
2799
|
-
|
|
2800
|
-
// src/utils/processUserInput/processUserInput.ts
|
|
2801
|
-
async function processUserInput({
|
|
2802
|
-
input,
|
|
2803
|
-
preExpansionInput,
|
|
2804
|
-
mode,
|
|
2805
|
-
setToolJSX,
|
|
2806
|
-
context,
|
|
2807
|
-
pastedContents,
|
|
2808
|
-
ideSelection,
|
|
2809
|
-
messages,
|
|
2810
|
-
setUserInputOnProcessing,
|
|
2811
|
-
uuid,
|
|
2812
|
-
isAlreadyProcessing,
|
|
2813
|
-
querySource,
|
|
2814
|
-
canUseTool,
|
|
2815
|
-
skipSlashCommands,
|
|
2816
|
-
bridgeOrigin,
|
|
2817
|
-
isMeta,
|
|
2818
|
-
skipAttachments,
|
|
2819
|
-
autonomy
|
|
2820
|
-
}) {
|
|
2821
|
-
const inputString = typeof input === "string" ? input : null;
|
|
2822
|
-
if (mode === "prompt" && inputString !== null && !isMeta) {
|
|
2823
|
-
setUserInputOnProcessing?.(inputString);
|
|
2824
|
-
}
|
|
2825
|
-
queryCheckpoint("query_process_user_input_base_start");
|
|
2826
|
-
const appState = context.getAppState();
|
|
2827
|
-
const result = await processUserInputBase(input, mode, setToolJSX, context, pastedContents, ideSelection, messages, uuid, isAlreadyProcessing, querySource, canUseTool, appState.toolPermissionContext.mode, skipSlashCommands, bridgeOrigin, isMeta, skipAttachments, preExpansionInput, autonomy);
|
|
2828
|
-
queryCheckpoint("query_process_user_input_base_end");
|
|
2829
|
-
if (!result.shouldQuery) {
|
|
2830
|
-
return result;
|
|
2831
|
-
}
|
|
2832
|
-
queryCheckpoint("query_hooks_start");
|
|
2833
|
-
const inputMessage = getContentText(input) || "";
|
|
2834
|
-
for await (const hookResult of executeUserPromptSubmitHooks(inputMessage, appState.toolPermissionContext.mode, context, context.requestPrompt)) {
|
|
2835
|
-
if (hookResult.message?.type === "progress") {
|
|
2836
|
-
continue;
|
|
2837
|
-
}
|
|
2838
|
-
if (hookResult.blockingError) {
|
|
2839
|
-
const blockingMessage = getUserPromptSubmitHookBlockingMessage(hookResult.blockingError);
|
|
2840
|
-
return {
|
|
2841
|
-
messages: [
|
|
2842
|
-
createSystemMessage(`${blockingMessage}
|
|
2843
|
-
|
|
2844
|
-
Original prompt: ${input}`, "warning")
|
|
2845
|
-
],
|
|
2846
|
-
shouldQuery: false,
|
|
2847
|
-
allowedTools: result.allowedTools
|
|
2848
|
-
};
|
|
2849
|
-
}
|
|
2850
|
-
if (hookResult.preventContinuation) {
|
|
2851
|
-
const message = hookResult.stopReason ? `Operation stopped by hook: ${hookResult.stopReason}` : "Operation stopped by hook";
|
|
2852
|
-
result.messages.push(createUserMessage({
|
|
2853
|
-
content: message
|
|
2854
|
-
}));
|
|
2855
|
-
result.shouldQuery = false;
|
|
2856
|
-
return result;
|
|
2857
|
-
}
|
|
2858
|
-
if (hookResult.additionalContexts && hookResult.additionalContexts.length > 0) {
|
|
2859
|
-
result.messages.push(createAttachmentMessage({
|
|
2860
|
-
type: "hook_additional_context",
|
|
2861
|
-
content: hookResult.additionalContexts.map(applyTruncation),
|
|
2862
|
-
hookName: "UserPromptSubmit",
|
|
2863
|
-
toolUseID: `hook-${randomUUID5()}`,
|
|
2864
|
-
hookEvent: "UserPromptSubmit"
|
|
2865
|
-
}));
|
|
2866
|
-
}
|
|
2867
|
-
if (hookResult.message) {
|
|
2868
|
-
switch (hookResult.message.attachment.type) {
|
|
2869
|
-
case "hook_success":
|
|
2870
|
-
if (!hookResult.message.attachment.content) {
|
|
2871
|
-
break;
|
|
2872
|
-
}
|
|
2873
|
-
result.messages.push({
|
|
2874
|
-
...hookResult.message,
|
|
2875
|
-
attachment: {
|
|
2876
|
-
...hookResult.message.attachment,
|
|
2877
|
-
content: applyTruncation(hookResult.message.attachment.content)
|
|
2878
|
-
}
|
|
2879
|
-
});
|
|
2880
|
-
break;
|
|
2881
|
-
default:
|
|
2882
|
-
result.messages.push(hookResult.message);
|
|
2883
|
-
break;
|
|
2884
|
-
}
|
|
2885
|
-
}
|
|
2886
|
-
}
|
|
2887
|
-
queryCheckpoint("query_hooks_end");
|
|
2888
|
-
return result;
|
|
2889
|
-
}
|
|
2890
|
-
var MAX_HOOK_OUTPUT_LENGTH = 1e4;
|
|
2891
|
-
function applyTruncation(content) {
|
|
2892
|
-
if (content.length > MAX_HOOK_OUTPUT_LENGTH) {
|
|
2893
|
-
return `${content.substring(0, MAX_HOOK_OUTPUT_LENGTH)}\u2026 [output truncated - exceeded ${MAX_HOOK_OUTPUT_LENGTH} characters]`;
|
|
2894
|
-
}
|
|
2895
|
-
return content;
|
|
2896
|
-
}
|
|
2897
|
-
async function processUserInputBase(input, mode, setToolJSX, context, pastedContents, ideSelection, messages, uuid, isAlreadyProcessing, querySource, canUseTool, permissionMode, skipSlashCommands, bridgeOrigin, isMeta, skipAttachments, preExpansionInput, autonomy) {
|
|
2898
|
-
let inputString = null;
|
|
2899
|
-
let precedingInputBlocks = [];
|
|
2900
|
-
const imageMetadataTexts = [];
|
|
2901
|
-
let normalizedInput = input;
|
|
2902
|
-
if (typeof input === "string") {
|
|
2903
|
-
inputString = input;
|
|
2904
|
-
} else if (input.length > 0) {
|
|
2905
|
-
queryCheckpoint("query_image_processing_start");
|
|
2906
|
-
const processedBlocks = [];
|
|
2907
|
-
for (const block of input) {
|
|
2908
|
-
if (block.type === "image") {
|
|
2909
|
-
const resized = await maybeResizeAndDownsampleImageBlock(block);
|
|
2910
|
-
if (resized.dimensions) {
|
|
2911
|
-
const metadataText = createImageMetadataText(resized.dimensions);
|
|
2912
|
-
if (metadataText) {
|
|
2913
|
-
imageMetadataTexts.push(metadataText);
|
|
2914
|
-
}
|
|
2915
|
-
}
|
|
2916
|
-
processedBlocks.push(resized.block);
|
|
2917
|
-
} else {
|
|
2918
|
-
processedBlocks.push(block);
|
|
2919
|
-
}
|
|
2920
|
-
}
|
|
2921
|
-
normalizedInput = processedBlocks;
|
|
2922
|
-
queryCheckpoint("query_image_processing_end");
|
|
2923
|
-
const lastBlock = processedBlocks[processedBlocks.length - 1];
|
|
2924
|
-
if (lastBlock?.type === "text") {
|
|
2925
|
-
inputString = lastBlock.text;
|
|
2926
|
-
precedingInputBlocks = processedBlocks.slice(0, -1);
|
|
2927
|
-
} else {
|
|
2928
|
-
precedingInputBlocks = processedBlocks;
|
|
2929
|
-
}
|
|
2930
|
-
}
|
|
2931
|
-
if (inputString === null && mode !== "prompt") {
|
|
2932
|
-
throw new Error(`Mode: ${mode} requires a string input.`);
|
|
2933
|
-
}
|
|
2934
|
-
const imageContents = pastedContents ? Object.values(pastedContents).filter(isValidImagePaste) : [];
|
|
2935
|
-
const imagePasteIds = imageContents.map((img) => img.id);
|
|
2936
|
-
const storedImagePaths = pastedContents ? await storeImages(pastedContents) : new Map;
|
|
2937
|
-
queryCheckpoint("query_pasted_image_processing_start");
|
|
2938
|
-
const imageProcessingResults = await Promise.all(imageContents.map(async (pastedImage) => {
|
|
2939
|
-
const imageBlock = {
|
|
2940
|
-
type: "image",
|
|
2941
|
-
source: {
|
|
2942
|
-
type: "base64",
|
|
2943
|
-
media_type: pastedImage.mediaType || "image/png",
|
|
2944
|
-
data: pastedImage.content
|
|
2945
|
-
}
|
|
2946
|
-
};
|
|
2947
|
-
logEvent("tengu_pasted_image_resize_attempt", {
|
|
2948
|
-
original_size_bytes: pastedImage.content.length
|
|
2949
|
-
});
|
|
2950
|
-
const resized = await maybeResizeAndDownsampleImageBlock(imageBlock);
|
|
2951
|
-
return {
|
|
2952
|
-
resized,
|
|
2953
|
-
originalDimensions: pastedImage.dimensions,
|
|
2954
|
-
sourcePath: pastedImage.sourcePath ?? storedImagePaths.get(pastedImage.id)
|
|
2955
|
-
};
|
|
2956
|
-
}));
|
|
2957
|
-
const imageContentBlocks = [];
|
|
2958
|
-
for (const {
|
|
2959
|
-
resized,
|
|
2960
|
-
originalDimensions,
|
|
2961
|
-
sourcePath
|
|
2962
|
-
} of imageProcessingResults) {
|
|
2963
|
-
if (resized.dimensions) {
|
|
2964
|
-
const metadataText = createImageMetadataText(resized.dimensions, sourcePath);
|
|
2965
|
-
if (metadataText) {
|
|
2966
|
-
imageMetadataTexts.push(metadataText);
|
|
2967
|
-
}
|
|
2968
|
-
} else if (originalDimensions) {
|
|
2969
|
-
const metadataText = createImageMetadataText(originalDimensions, sourcePath);
|
|
2970
|
-
if (metadataText) {
|
|
2971
|
-
imageMetadataTexts.push(metadataText);
|
|
2972
|
-
}
|
|
2973
|
-
} else if (sourcePath) {
|
|
2974
|
-
imageMetadataTexts.push(`[Image source: ${sourcePath}]`);
|
|
2975
|
-
}
|
|
2976
|
-
imageContentBlocks.push(resized.block);
|
|
2977
|
-
}
|
|
2978
|
-
queryCheckpoint("query_pasted_image_processing_end");
|
|
2979
|
-
let effectiveSkipSlash = skipSlashCommands;
|
|
2980
|
-
if (bridgeOrigin && inputString !== null && inputString.startsWith("/")) {
|
|
2981
|
-
const parsed = parseSlashCommand(inputString);
|
|
2982
|
-
const cmd = parsed ? findCommand(parsed.commandName, context.options.commands) : undefined;
|
|
2983
|
-
if (cmd) {
|
|
2984
|
-
const safety = getBridgeCommandSafety(cmd, parsed?.args ?? "");
|
|
2985
|
-
if (safety.ok) {
|
|
2986
|
-
effectiveSkipSlash = false;
|
|
2987
|
-
} else {
|
|
2988
|
-
const msg = safety.reason ?? `/${getCommandName(cmd)} isn't available over Remote Control.`;
|
|
2989
|
-
return {
|
|
2990
|
-
messages: [
|
|
2991
|
-
createUserMessage({ content: inputString, uuid }),
|
|
2992
|
-
createCommandInputMessage(`<local-command-stdout>${msg}</local-command-stdout>`)
|
|
2993
|
-
],
|
|
2994
|
-
shouldQuery: false,
|
|
2995
|
-
resultText: msg
|
|
2996
|
-
};
|
|
2997
|
-
}
|
|
2998
|
-
}
|
|
2999
|
-
}
|
|
3000
|
-
if (mode === "prompt" && !context.options.isNonInteractiveSession && inputString !== null && !effectiveSkipSlash && !inputString.startsWith("/") && !context.getAppState().ultraplanSessionUrl && !context.getAppState().ultraplanLaunching && hasUltraplanKeyword(preExpansionInput ?? inputString)) {
|
|
3001
|
-
logEvent("tengu_ultraplan_keyword", {});
|
|
3002
|
-
const rewritten = replaceUltraplanKeyword(inputString).trim();
|
|
3003
|
-
const { processSlashCommand } = await import("./chunk-x7t8wrq1.js");
|
|
3004
|
-
const slashResult = await processSlashCommand(`/ultraplan ${rewritten}`, precedingInputBlocks, imageContentBlocks, [], context, setToolJSX, uuid, isAlreadyProcessing, canUseTool, autonomy);
|
|
3005
|
-
return addImageMetadataMessage(slashResult, imageMetadataTexts);
|
|
3006
|
-
}
|
|
3007
|
-
const shouldExtractAttachments = !skipAttachments && inputString !== null && (mode !== "prompt" || effectiveSkipSlash || !inputString.startsWith("/"));
|
|
3008
|
-
queryCheckpoint("query_attachment_loading_start");
|
|
3009
|
-
const attachmentMessages = shouldExtractAttachments ? await toArray(getAttachmentMessages(inputString, context, ideSelection ?? null, [], messages, querySource)) : [];
|
|
3010
|
-
queryCheckpoint("query_attachment_loading_end");
|
|
3011
|
-
if (inputString !== null && mode === "bash") {
|
|
3012
|
-
const { processBashCommand } = await import("./chunk-w6x102n9.js");
|
|
3013
|
-
return addImageMetadataMessage(await processBashCommand(inputString, precedingInputBlocks, attachmentMessages, context, setToolJSX), imageMetadataTexts);
|
|
3014
|
-
}
|
|
3015
|
-
if (inputString !== null && !effectiveSkipSlash && inputString.startsWith("/")) {
|
|
3016
|
-
const { processSlashCommand } = await import("./chunk-x7t8wrq1.js");
|
|
3017
|
-
const slashResult = await processSlashCommand(inputString, precedingInputBlocks, imageContentBlocks, attachmentMessages, context, setToolJSX, uuid, isAlreadyProcessing, canUseTool, autonomy);
|
|
3018
|
-
return addImageMetadataMessage(slashResult, imageMetadataTexts);
|
|
3019
|
-
}
|
|
3020
|
-
if (inputString !== null && mode === "prompt") {
|
|
3021
|
-
const trimmedInput = inputString.trim();
|
|
3022
|
-
const agentMention = attachmentMessages.find((m) => m.attachment.type === "agent_mention");
|
|
3023
|
-
if (agentMention) {
|
|
3024
|
-
const agentMentionString = `@agent-${agentMention.attachment.agentType}`;
|
|
3025
|
-
const isSubagentOnly = trimmedInput === agentMentionString;
|
|
3026
|
-
const isPrefix = trimmedInput.startsWith(agentMentionString) && !isSubagentOnly;
|
|
3027
|
-
logEvent("tengu_subagent_at_mention", {
|
|
3028
|
-
is_subagent_only: isSubagentOnly,
|
|
3029
|
-
is_prefix: isPrefix
|
|
3030
|
-
});
|
|
3031
|
-
}
|
|
3032
|
-
}
|
|
3033
|
-
return addImageMetadataMessage(processTextPrompt(normalizedInput, imageContentBlocks, imagePasteIds, attachmentMessages, uuid, permissionMode, isMeta), imageMetadataTexts);
|
|
3034
|
-
}
|
|
3035
|
-
function addImageMetadataMessage(result, imageMetadataTexts) {
|
|
3036
|
-
if (imageMetadataTexts.length > 0) {
|
|
3037
|
-
result.messages.push(createUserMessage({
|
|
3038
|
-
content: imageMetadataTexts.map((text) => ({ type: "text", text })),
|
|
3039
|
-
isMeta: true
|
|
3040
|
-
}));
|
|
3041
|
-
}
|
|
3042
|
-
return result;
|
|
3043
|
-
}
|
|
3044
|
-
|
|
3045
1681
|
// src/utils/plugins/reconciler.ts
|
|
3046
1682
|
init_isEqual();
|
|
3047
1683
|
init_state();
|
|
@@ -3171,7 +1807,7 @@ function normalizeSource(source, projectRoot) {
|
|
|
3171
1807
|
return source;
|
|
3172
1808
|
}
|
|
3173
1809
|
|
|
3174
|
-
export { claimConsumableQueuedAutonomyCommands, cancelQueuedAutonomyCommands, finalizeAutonomyCommandsForTurn, init_autonomyQueueLifecycle, extractInboundMessageFields,
|
|
1810
|
+
export { claimConsumableQueuedAutonomyCommands, cancelQueuedAutonomyCommands, finalizeAutonomyCommandsForTurn, init_autonomyQueueLifecycle, extractInboundMessageFields, outputSchema, permissionPromptToolResultToPermissionDecision, ndjsonSafeStringify, SANDBOX_NETWORK_ACCESS_TOOL_NAME, StructuredIO, diffMarketplaces, reconcileMarketplaces, getCronJitterConfig, exports_cronJitterConfig, init_cronJitterConfig, createCronScheduler, exports_cronScheduler, init_cronScheduler };
|
|
3175
1811
|
|
|
3176
|
-
//# debugId=
|
|
3177
|
-
//# sourceMappingURL=chunk-
|
|
1812
|
+
//# debugId=8EE8B9C3724B636B64756E2164756E21
|
|
1813
|
+
//# sourceMappingURL=chunk-1gta3pqg.js.map
|