@markus-global/cli 0.8.5 → 0.9.0-rc.0
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/commands/model.d.ts.map +1 -1
- package/dist/commands/model.js +9 -2
- package/dist/commands/model.js.map +1 -1
- package/dist/commands/start.d.ts.map +1 -1
- package/dist/commands/start.js +227 -181
- package/dist/commands/start.js.map +1 -1
- package/dist/markus-browser-extension.zip +0 -0
- package/dist/markus.mjs +13015 -6404
- package/dist/web-ui/assets/ChatHelpers-Cb26xxzl.js +3 -0
- package/dist/web-ui/assets/CommentInput-CmSnFGbv.js +1 -0
- package/dist/web-ui/assets/ContentRenderer-CFJndxtW.js +82 -0
- package/dist/web-ui/assets/Deliverables-CL88tGZv.js +6 -0
- package/dist/web-ui/assets/Notifications-BX3Fx5j5.js +1 -0
- package/dist/web-ui/assets/Search-YJ4NBHyk.js +1 -0
- package/dist/web-ui/assets/Settings-B8xQ3rEN.js +8 -0
- package/dist/web-ui/assets/Store-WYrzY0Mr.js +1 -0
- package/dist/web-ui/assets/Team-DwRSN0-a.js +39 -0
- package/dist/web-ui/assets/Work-BZV40eAE.css +1 -0
- package/dist/web-ui/assets/Work-DNGfvBLY.js +11 -0
- package/dist/web-ui/assets/{arc-BdRlL2iO.js → arc-BfS9Mvj7.js} +1 -1
- package/dist/web-ui/assets/architectureDiagram-3BPJPVTR-CFNOE9Ft.js +36 -0
- package/dist/web-ui/assets/{blockDiagram-GPEHLZMM-BpzalW_a.js → blockDiagram-GPEHLZMM-gD6Hylng.js} +2 -2
- package/dist/web-ui/assets/{c4Diagram-AAUBKEIU-BCAI0V-n.js → c4Diagram-AAUBKEIU-8QoBVsn5.js} +2 -2
- package/dist/web-ui/assets/channel-1ow_lsxl.js +1 -0
- package/dist/web-ui/assets/{chunk-2J33WTMH-Dg7rYV2F.js → chunk-2J33WTMH--5nv1yIK.js} +1 -1
- package/dist/web-ui/assets/{chunk-4BX2VUAB-NjIIklhn.js → chunk-4BX2VUAB-DMHNCjRo.js} +1 -1
- package/dist/web-ui/assets/chunk-55IACEB6-DoagUtYg.js +1 -0
- package/dist/web-ui/assets/{chunk-727SXJPM-D4yVMcHy.js → chunk-727SXJPM-sOd6G91V.js} +1 -1
- package/dist/web-ui/assets/{chunk-AQP2D5EJ-BZ2R83hR.js → chunk-AQP2D5EJ-BA1hEJE7.js} +1 -1
- package/dist/web-ui/assets/{chunk-FMBD7UC4-dKKoHR7V.js → chunk-FMBD7UC4-D-4YgaFe.js} +1 -1
- package/dist/web-ui/assets/chunk-ND2GUHAM-CaESAIrE.js +1 -0
- package/dist/web-ui/assets/{chunk-QZHKN3VN-QK1OECHO.js → chunk-QZHKN3VN-k2TrAqxw.js} +1 -1
- package/dist/web-ui/assets/classDiagram-4FO5ZUOK-zJLmwj73.js +1 -0
- package/dist/web-ui/assets/classDiagram-v2-Q7XG4LA2-zJLmwj73.js +1 -0
- package/dist/web-ui/assets/cose-bilkent-S5V4N54A-BWzmZrwb.js +1 -0
- package/dist/web-ui/assets/dagre-BM42HDAG-DESAnnYv.js +4 -0
- package/dist/web-ui/assets/diagram-2AECGRRQ-BYqdvN4F.js +43 -0
- package/dist/web-ui/assets/diagram-5GNKFQAL-CjpQ4xfS.js +10 -0
- package/dist/web-ui/assets/{diagram-KO2AKTUF-BAPzH4PL.js → diagram-KO2AKTUF-CfsDLuOy.js} +2 -2
- package/dist/web-ui/assets/diagram-LMA3HP47-BZdG-8fy.js +24 -0
- package/dist/web-ui/assets/diagram-OG6HWLK6-jCwDnemx.js +24 -0
- package/dist/web-ui/assets/{erDiagram-TEJ5UH35-C5lPAlAw.js → erDiagram-TEJ5UH35-BwJwkebk.js} +7 -7
- package/dist/web-ui/assets/{flowDiagram-I6XJVG4X-B3yPTMtT.js → flowDiagram-I6XJVG4X-DbFMgK3R.js} +2 -2
- package/dist/web-ui/assets/ganttDiagram-6RSMTGT7-BxVoytl3.js +292 -0
- package/dist/web-ui/assets/gitGraphDiagram-PVQCEYII-CEgYJOJY.js +106 -0
- package/dist/web-ui/assets/index-D_HH4ju2.js +666 -0
- package/dist/web-ui/assets/index-YDpknaqo.css +1 -0
- package/dist/web-ui/assets/infoDiagram-5YYISTIA-DQWzABtc.js +2 -0
- package/dist/web-ui/assets/{ishikawaDiagram-YF4QCWOH-BRM-2a0M.js → ishikawaDiagram-YF4QCWOH-DzmIWtTU.js} +2 -2
- package/dist/web-ui/assets/{journeyDiagram-JHISSGLW-ETvNwLl4.js → journeyDiagram-JHISSGLW-BoiaqjiH.js} +2 -2
- package/dist/web-ui/assets/{kanban-definition-UN3LZRKU-D066SbN9.js → kanban-definition-UN3LZRKU-CZeB8ThH.js} +6 -6
- package/dist/web-ui/assets/linear-D1g5s_fh.js +1 -0
- package/dist/web-ui/assets/{mermaid.core-rPZMstL0.js → mermaid.core-B_8QQ1RU.js} +10 -10
- package/dist/web-ui/assets/{mindmap-definition-RKZ34NQL-BKYYirSK.js → mindmap-definition-RKZ34NQL-DFF-GTkZ.js} +2 -2
- package/dist/web-ui/assets/pieDiagram-4H26LBE5-45MXMyT3.js +30 -0
- package/dist/web-ui/assets/{quadrantDiagram-W4KKPZXB-V5VbcvJY.js → quadrantDiagram-W4KKPZXB-kRCd2Nqe.js} +2 -2
- package/dist/web-ui/assets/{requirementDiagram-4Y6WPE33-D2uVfqfP.js → requirementDiagram-4Y6WPE33-DSILTvsw.js} +2 -2
- package/dist/web-ui/assets/{sankeyDiagram-5OEKKPKP-C8ejeGTc.js → sankeyDiagram-5OEKKPKP-CwkyEhye.js} +2 -2
- package/dist/web-ui/assets/{sequenceDiagram-3UESZ5HK-CI3unFup.js → sequenceDiagram-3UESZ5HK-0fo5Z81y.js} +2 -2
- package/dist/web-ui/assets/stateDiagram-AJRCARHV-B74U4HO9.js +1 -0
- package/dist/web-ui/assets/stateDiagram-v2-BHNVJYJU-bSRzYPvh.js +1 -0
- package/dist/web-ui/assets/{timeline-definition-PNZ67QCA-BrkWr53g.js → timeline-definition-PNZ67QCA-mRhWzQjp.js} +2 -2
- package/dist/web-ui/assets/transform-CpIVI4vC.js +1 -0
- package/dist/web-ui/assets/value-DIujSiJ7.js +1 -0
- package/dist/web-ui/assets/{vennDiagram-CIIHVFJN-C8mr8EAq.js → vennDiagram-CIIHVFJN-C82YisLk.js} +2 -2
- package/dist/web-ui/assets/{wardley-L42UT6IY-BFlL89Fu.js → wardley-L42UT6IY-Ba6AG0iH.js} +1 -1
- package/dist/web-ui/assets/{wardleyDiagram-YWT4CUSO-CezrtcCI.js → wardleyDiagram-YWT4CUSO-BSmLAatg.js} +2 -2
- package/dist/web-ui/assets/{xychartDiagram-2RQKCTM6-DrvIX-i_.js → xychartDiagram-2RQKCTM6-Z72DDYUU.js} +2 -2
- package/dist/web-ui/index.html +2 -2
- package/package.json +1 -1
- package/templates/roles/SHARED.md +11 -4
- package/templates/roles/agent-father/ROLE.md +1 -1
- package/templates/roles/secretary/HEARTBEAT.md +2 -2
- package/templates/roles/secretary/ROLE.md +26 -23
- package/templates/roles/skill-architect/ROLE.md +2 -2
- package/templates/roles/team-factory/ROLE.md +1 -1
- package/templates/skills/agent-building/SKILL.md +29 -10
- package/templates/skills/agent-building/skill.json +1 -1
- package/templates/skills/markus-hub-connector/server.mjs +12 -1
- package/templates/skills/skill-building/SKILL.md +30 -10
- package/templates/skills/skill-building/skill.json +1 -1
- package/templates/skills/team-building/SKILL.md +32 -13
- package/templates/skills/team-building/skill.json +1 -1
- package/dist/web-ui/assets/architectureDiagram-3BPJPVTR-D0tUssz3.js +0 -36
- package/dist/web-ui/assets/channel-CVrfB_bR.js +0 -1
- package/dist/web-ui/assets/chunk-55IACEB6-D1NbvEGQ.js +0 -1
- package/dist/web-ui/assets/chunk-ND2GUHAM-8DcNh3kD.js +0 -1
- package/dist/web-ui/assets/classDiagram-4FO5ZUOK-vzqgiM0p.js +0 -1
- package/dist/web-ui/assets/classDiagram-v2-Q7XG4LA2-vzqgiM0p.js +0 -1
- package/dist/web-ui/assets/cose-bilkent-S5V4N54A-70zGiErc.js +0 -1
- package/dist/web-ui/assets/dagre-BM42HDAG-CjH95T53.js +0 -4
- package/dist/web-ui/assets/diagram-2AECGRRQ-D1h-kJfb.js +0 -43
- package/dist/web-ui/assets/diagram-5GNKFQAL-BfpyuUIG.js +0 -10
- package/dist/web-ui/assets/diagram-LMA3HP47-BzZcoqw9.js +0 -24
- package/dist/web-ui/assets/diagram-OG6HWLK6-UzfnxP-8.js +0 -24
- package/dist/web-ui/assets/ganttDiagram-6RSMTGT7-M0LiSJYB.js +0 -292
- package/dist/web-ui/assets/gitGraphDiagram-PVQCEYII-DMJ8bJ-V.js +0 -106
- package/dist/web-ui/assets/index-C0TJwd4k.js +0 -776
- package/dist/web-ui/assets/index-C1_HX8vL.css +0 -1
- package/dist/web-ui/assets/infoDiagram-5YYISTIA-H3O_dXaX.js +0 -2
- package/dist/web-ui/assets/linear-w-ZA_ecm.js +0 -1
- package/dist/web-ui/assets/pieDiagram-4H26LBE5-Cwjk7qIl.js +0 -30
- package/dist/web-ui/assets/stateDiagram-AJRCARHV-C4edfdOw.js +0 -1
- package/dist/web-ui/assets/stateDiagram-v2-BHNVJYJU-CzloKUKx.js +0 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import{s as gi,g as xi,p as Xt,o as di,a as fi,b as pi,_ as a,l as Yt,H as mi,d as yi,y as bi,C as _t,h as Ai,E as Nt,F as wi,I as Ci,al as Si,Q as Wt}from"./mermaid.core-
|
|
1
|
+
import{s as gi,g as xi,p as Xt,o as di,a as fi,b as pi,_ as a,l as Yt,H as mi,d as yi,y as bi,C as _t,h as Ai,E as Nt,F as wi,I as Ci,al as Si,Q as Wt}from"./mermaid.core-B_8QQ1RU.js";import"./transform-CpIVI4vC.js";import{i as _i}from"./init-Gi6I4Gst.js";import{o as ki}from"./ordinal-Cboi1Yqb.js";import{l as zt}from"./linear-D1g5s_fh.js";import"./index-D_HH4ju2.js";import"./value-DIujSiJ7.js";import"./defaultLocale-DX6XiGOO.js";function Ri(e,t,i){e=+e,t=+t,i=(n=arguments.length)<2?(t=e,e=0,1):n<3?1:+i;for(var s=-1,n=Math.max(0,Math.ceil((t-e)/i))|0,o=new Array(n);++s<n;)o[s]=e+s*i;return o}function bt(){var e=ki().unknown(void 0),t=e.domain,i=e.range,s=0,n=1,o,u,p=!1,f=0,T=0,P=.5;delete e.unknown;function _(){var y=t().length,E=n<s,v=E?n:s,L=E?s:n;o=(L-v)/Math.max(1,y-f+T*2),p&&(o=Math.floor(o)),v+=(L-v-o*(y-f))*P,u=o*(1-f),p&&(v=Math.round(v),u=Math.round(u));var I=Ri(y).map(function(m){return v+o*m});return i(E?I.reverse():I)}return e.domain=function(y){return arguments.length?(t(y),_()):t()},e.range=function(y){return arguments.length?([s,n]=y,s=+s,n=+n,_()):[s,n]},e.rangeRound=function(y){return[s,n]=y,s=+s,n=+n,p=!0,_()},e.bandwidth=function(){return u},e.step=function(){return o},e.round=function(y){return arguments.length?(p=!!y,_()):p},e.padding=function(y){return arguments.length?(f=Math.min(1,T=+y),_()):f},e.paddingInner=function(y){return arguments.length?(f=Math.min(1,y),_()):f},e.paddingOuter=function(y){return arguments.length?(T=+y,_()):T},e.align=function(y){return arguments.length?(P=Math.max(0,Math.min(1,y)),_()):P},e.copy=function(){return bt(t(),[s,n]).round(p).paddingInner(f).paddingOuter(T).align(P)},_i.apply(_(),arguments)}var At=(function(){var e=a(function(F,h,c,g){for(c=c||{},g=F.length;g--;c[F[g]]=h);return c},"o"),t=[1,10,12,14,16,18,19,21,23],i=[2,6],s=[1,3],n=[1,5],o=[1,6],u=[1,7],p=[1,5,10,12,14,16,18,19,21,23,34,35,36],f=[1,25],T=[1,26],P=[1,28],_=[1,29],y=[1,30],E=[1,31],v=[1,32],L=[1,33],I=[1,34],m=[1,35],R=[1,36],l=[1,37],W=[1,43],O=[1,42],X=[1,47],Y=[1,50],S=[1,10,12,14,16,18,19,21,23,34,35,36],U=[1,10,12,14,16,18,19,21,23,24,26,27,28,34,35,36],b=[1,10,12,14,16,18,19,21,23,24,26,27,28,34,35,36,41,42,43,44,45,46,47,48,49,50],w=[1,64],V={trace:a(function(){},"trace"),yy:{},symbols_:{error:2,start:3,eol:4,XYCHART:5,chartConfig:6,document:7,CHART_ORIENTATION:8,statement:9,title:10,text:11,X_AXIS:12,parseXAxis:13,Y_AXIS:14,parseYAxis:15,LINE:16,plotData:17,BAR:18,acc_title:19,acc_title_value:20,acc_descr:21,acc_descr_value:22,acc_descr_multiline_value:23,SQUARE_BRACES_START:24,commaSeparatedNumbers:25,SQUARE_BRACES_END:26,NUMBER_WITH_DECIMAL:27,COMMA:28,xAxisData:29,bandData:30,ARROW_DELIMITER:31,commaSeparatedTexts:32,yAxisData:33,NEWLINE:34,SEMI:35,EOF:36,alphaNum:37,STR:38,MD_STR:39,alphaNumToken:40,AMP:41,NUM:42,ALPHA:43,PLUS:44,EQUALS:45,MULT:46,DOT:47,BRKT:48,MINUS:49,UNDERSCORE:50,$accept:0,$end:1},terminals_:{2:"error",5:"XYCHART",8:"CHART_ORIENTATION",10:"title",12:"X_AXIS",14:"Y_AXIS",16:"LINE",18:"BAR",19:"acc_title",20:"acc_title_value",21:"acc_descr",22:"acc_descr_value",23:"acc_descr_multiline_value",24:"SQUARE_BRACES_START",26:"SQUARE_BRACES_END",27:"NUMBER_WITH_DECIMAL",28:"COMMA",31:"ARROW_DELIMITER",34:"NEWLINE",35:"SEMI",36:"EOF",38:"STR",39:"MD_STR",41:"AMP",42:"NUM",43:"ALPHA",44:"PLUS",45:"EQUALS",46:"MULT",47:"DOT",48:"BRKT",49:"MINUS",50:"UNDERSCORE"},productions_:[0,[3,2],[3,3],[3,2],[3,1],[6,1],[7,0],[7,2],[9,2],[9,2],[9,2],[9,2],[9,2],[9,3],[9,2],[9,3],[9,2],[9,2],[9,1],[17,3],[25,3],[25,1],[13,1],[13,2],[13,1],[29,1],[29,3],[30,3],[32,3],[32,1],[15,1],[15,2],[15,1],[33,3],[4,1],[4,1],[4,1],[11,1],[11,1],[11,1],[37,1],[37,2],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1]],performAction:a(function(h,c,g,x,C,r,rt){var d=r.length-1;switch(C){case 5:x.setOrientation(r[d]);break;case 9:x.setDiagramTitle(r[d].text.trim());break;case 12:x.setLineData({text:"",type:"text"},r[d]);break;case 13:x.setLineData(r[d-1],r[d]);break;case 14:x.setBarData({text:"",type:"text"},r[d]);break;case 15:x.setBarData(r[d-1],r[d]);break;case 16:this.$=r[d].trim(),x.setAccTitle(this.$);break;case 17:case 18:this.$=r[d].trim(),x.setAccDescription(this.$);break;case 19:this.$=r[d-1];break;case 20:this.$=[Number(r[d-2]),...r[d]];break;case 21:this.$=[Number(r[d])];break;case 22:x.setXAxisTitle(r[d]);break;case 23:x.setXAxisTitle(r[d-1]);break;case 24:x.setXAxisTitle({type:"text",text:""});break;case 25:x.setXAxisBand(r[d]);break;case 26:x.setXAxisRangeData(Number(r[d-2]),Number(r[d]));break;case 27:this.$=r[d-1];break;case 28:this.$=[r[d-2],...r[d]];break;case 29:this.$=[r[d]];break;case 30:x.setYAxisTitle(r[d]);break;case 31:x.setYAxisTitle(r[d-1]);break;case 32:x.setYAxisTitle({type:"text",text:""});break;case 33:x.setYAxisRangeData(Number(r[d-2]),Number(r[d]));break;case 37:this.$={text:r[d],type:"text"};break;case 38:this.$={text:r[d],type:"text"};break;case 39:this.$={text:r[d],type:"markdown"};break;case 40:this.$=r[d];break;case 41:this.$=r[d-1]+""+r[d];break}},"anonymous"),table:[e(t,i,{3:1,4:2,7:4,5:s,34:n,35:o,36:u}),{1:[3]},e(t,i,{4:2,7:4,3:8,5:s,34:n,35:o,36:u}),e(t,i,{4:2,7:4,6:9,3:10,5:s,8:[1,11],34:n,35:o,36:u}),{1:[2,4],9:12,10:[1,13],12:[1,14],14:[1,15],16:[1,16],18:[1,17],19:[1,18],21:[1,19],23:[1,20]},e(p,[2,34]),e(p,[2,35]),e(p,[2,36]),{1:[2,1]},e(t,i,{4:2,7:4,3:21,5:s,34:n,35:o,36:u}),{1:[2,3]},e(p,[2,5]),e(t,[2,7],{4:22,34:n,35:o,36:u}),{11:23,37:24,38:f,39:T,40:27,41:P,42:_,43:y,44:E,45:v,46:L,47:I,48:m,49:R,50:l},{11:39,13:38,24:W,27:O,29:40,30:41,37:24,38:f,39:T,40:27,41:P,42:_,43:y,44:E,45:v,46:L,47:I,48:m,49:R,50:l},{11:45,15:44,27:X,33:46,37:24,38:f,39:T,40:27,41:P,42:_,43:y,44:E,45:v,46:L,47:I,48:m,49:R,50:l},{11:49,17:48,24:Y,37:24,38:f,39:T,40:27,41:P,42:_,43:y,44:E,45:v,46:L,47:I,48:m,49:R,50:l},{11:52,17:51,24:Y,37:24,38:f,39:T,40:27,41:P,42:_,43:y,44:E,45:v,46:L,47:I,48:m,49:R,50:l},{20:[1,53]},{22:[1,54]},e(S,[2,18]),{1:[2,2]},e(S,[2,8]),e(S,[2,9]),e(U,[2,37],{40:55,41:P,42:_,43:y,44:E,45:v,46:L,47:I,48:m,49:R,50:l}),e(U,[2,38]),e(U,[2,39]),e(b,[2,40]),e(b,[2,42]),e(b,[2,43]),e(b,[2,44]),e(b,[2,45]),e(b,[2,46]),e(b,[2,47]),e(b,[2,48]),e(b,[2,49]),e(b,[2,50]),e(b,[2,51]),e(S,[2,10]),e(S,[2,22],{30:41,29:56,24:W,27:O}),e(S,[2,24]),e(S,[2,25]),{31:[1,57]},{11:59,32:58,37:24,38:f,39:T,40:27,41:P,42:_,43:y,44:E,45:v,46:L,47:I,48:m,49:R,50:l},e(S,[2,11]),e(S,[2,30],{33:60,27:X}),e(S,[2,32]),{31:[1,61]},e(S,[2,12]),{17:62,24:Y},{25:63,27:w},e(S,[2,14]),{17:65,24:Y},e(S,[2,16]),e(S,[2,17]),e(b,[2,41]),e(S,[2,23]),{27:[1,66]},{26:[1,67]},{26:[2,29],28:[1,68]},e(S,[2,31]),{27:[1,69]},e(S,[2,13]),{26:[1,70]},{26:[2,21],28:[1,71]},e(S,[2,15]),e(S,[2,26]),e(S,[2,27]),{11:59,32:72,37:24,38:f,39:T,40:27,41:P,42:_,43:y,44:E,45:v,46:L,47:I,48:m,49:R,50:l},e(S,[2,33]),e(S,[2,19]),{25:73,27:w},{26:[2,28]},{26:[2,20]}],defaultActions:{8:[2,1],10:[2,3],21:[2,2],72:[2,28],73:[2,20]},parseError:a(function(h,c){if(c.recoverable)this.trace(h);else{var g=new Error(h);throw g.hash=c,g}},"parseError"),parse:a(function(h){var c=this,g=[0],x=[],C=[null],r=[],rt=this.table,d="",ct=0,It=0,hi=2,Mt=1,li=r.slice.call(arguments,1),D=Object.create(this.lexer),$={yy:{}};for(var ft in this.yy)Object.prototype.hasOwnProperty.call(this.yy,ft)&&($.yy[ft]=this.yy[ft]);D.setInput(h,$.yy),$.yy.lexer=D,$.yy.parser=this,typeof D.yylloc>"u"&&(D.yylloc={});var pt=D.yylloc;r.push(pt);var ci=D.options&&D.options.ranges;typeof $.yy.parseError=="function"?this.parseError=$.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function ui(B){g.length=g.length-2*B,C.length=C.length-B,r.length=r.length-B}a(ui,"popStack");function Vt(){var B;return B=x.pop()||D.lex()||Mt,typeof B!="number"&&(B instanceof Array&&(x=B,B=x.pop()),B=c.symbols_[B]||B),B}a(Vt,"lex");for(var M,q,z,mt,G={},ut,N,Bt,gt;;){if(q=g[g.length-1],this.defaultActions[q]?z=this.defaultActions[q]:((M===null||typeof M>"u")&&(M=Vt()),z=rt[q]&&rt[q][M]),typeof z>"u"||!z.length||!z[0]){var yt="";gt=[];for(ut in rt[q])this.terminals_[ut]&&ut>hi&>.push("'"+this.terminals_[ut]+"'");D.showPosition?yt="Parse error on line "+(ct+1)+`:
|
|
2
2
|
`+D.showPosition()+`
|
|
3
3
|
Expecting `+gt.join(", ")+", got '"+(this.terminals_[M]||M)+"'":yt="Parse error on line "+(ct+1)+": Unexpected "+(M==Mt?"end of input":"'"+(this.terminals_[M]||M)+"'"),this.parseError(yt,{text:D.match,token:this.terminals_[M]||M,line:D.yylineno,loc:pt,expected:gt})}if(z[0]instanceof Array&&z.length>1)throw new Error("Parse Error: multiple actions possible at state: "+q+", token: "+M);switch(z[0]){case 1:g.push(M),C.push(D.yytext),r.push(D.yylloc),g.push(z[1]),M=null,It=D.yyleng,d=D.yytext,ct=D.yylineno,pt=D.yylloc;break;case 2:if(N=this.productions_[z[1]][1],G.$=C[C.length-N],G._$={first_line:r[r.length-(N||1)].first_line,last_line:r[r.length-1].last_line,first_column:r[r.length-(N||1)].first_column,last_column:r[r.length-1].last_column},ci&&(G._$.range=[r[r.length-(N||1)].range[0],r[r.length-1].range[1]]),mt=this.performAction.apply(G,[d,It,ct,$.yy,z[1],C,r].concat(li)),typeof mt<"u")return mt;N&&(g=g.slice(0,-1*N*2),C=C.slice(0,-1*N),r=r.slice(0,-1*N)),g.push(this.productions_[z[1]][0]),C.push(G.$),r.push(G._$),Bt=rt[g[g.length-2]][g[g.length-1]],g.push(Bt);break;case 3:return!0}}return!0},"parse")},k=(function(){var F={EOF:1,parseError:a(function(c,g){if(this.yy.parser)this.yy.parser.parseError(c,g);else throw new Error(c)},"parseError"),setInput:a(function(h,c){return this.yy=c||this.yy||{},this._input=h,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:a(function(){var h=this._input[0];this.yytext+=h,this.yyleng++,this.offset++,this.match+=h,this.matched+=h;var c=h.match(/(?:\r\n?|\n).*/g);return c?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),h},"input"),unput:a(function(h){var c=h.length,g=h.split(/(?:\r\n?|\n)/g);this._input=h+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-c),this.offset-=c;var x=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),g.length-1&&(this.yylineno-=g.length-1);var C=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:g?(g.length===x.length?this.yylloc.first_column:0)+x[x.length-g.length].length-g[0].length:this.yylloc.first_column-c},this.options.ranges&&(this.yylloc.range=[C[0],C[0]+this.yyleng-c]),this.yyleng=this.yytext.length,this},"unput"),more:a(function(){return this._more=!0,this},"more"),reject:a(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
|
|
4
4
|
`+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},"reject"),less:a(function(h){this.unput(this.match.slice(h))},"less"),pastInput:a(function(){var h=this.matched.substr(0,this.matched.length-this.match.length);return(h.length>20?"...":"")+h.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:a(function(){var h=this.match;return h.length<20&&(h+=this._input.substr(0,20-h.length)),(h.substr(0,20)+(h.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:a(function(){var h=this.pastInput(),c=new Array(h.length+1).join("-");return h+this.upcomingInput()+`
|
|
5
5
|
`+c+"^"},"showPosition"),test_match:a(function(h,c){var g,x,C;if(this.options.backtrack_lexer&&(C={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(C.yylloc.range=this.yylloc.range.slice(0))),x=h[0].match(/(?:\r\n?|\n).*/g),x&&(this.yylineno+=x.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:x?x[x.length-1].length-x[x.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+h[0].length},this.yytext+=h[0],this.match+=h[0],this.matches=h,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(h[0].length),this.matched+=h[0],g=this.performAction.call(this,this.yy,this,c,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),g)return g;if(this._backtrack){for(var r in C)this[r]=C[r];return!1}return!1},"test_match"),next:a(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var h,c,g,x;this._more||(this.yytext="",this.match="");for(var C=this._currentRules(),r=0;r<C.length;r++)if(g=this._input.match(this.rules[C[r]]),g&&(!c||g[0].length>c[0].length)){if(c=g,x=r,this.options.backtrack_lexer){if(h=this.test_match(g,C[r]),h!==!1)return h;if(this._backtrack){c=!1;continue}else return!1}else if(!this.options.flex)break}return c?(h=this.test_match(c,C[x]),h!==!1?h:!1):this._input===""?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+`. Unrecognized text.
|
|
6
6
|
`+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:a(function(){var c=this.next();return c||this.lex()},"lex"),begin:a(function(c){this.conditionStack.push(c)},"begin"),popState:a(function(){var c=this.conditionStack.length-1;return c>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:a(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},"_currentRules"),topState:a(function(c){return c=this.conditionStack.length-1-Math.abs(c||0),c>=0?this.conditionStack[c]:"INITIAL"},"topState"),pushState:a(function(c){this.begin(c)},"pushState"),stateStackSize:a(function(){return this.conditionStack.length},"stateStackSize"),options:{"case-insensitive":!0},performAction:a(function(c,g,x,C){switch(x){case 0:break;case 1:break;case 2:return this.popState(),34;case 3:return this.popState(),34;case 4:return 34;case 5:break;case 6:return 10;case 7:return this.pushState("acc_title"),19;case 8:return this.popState(),"acc_title_value";case 9:return this.pushState("acc_descr"),21;case 10:return this.popState(),"acc_descr_value";case 11:this.pushState("acc_descr_multiline");break;case 12:this.popState();break;case 13:return"acc_descr_multiline_value";case 14:return 5;case 15:return 5;case 16:return 8;case 17:return this.pushState("axis_data"),"X_AXIS";case 18:return this.pushState("axis_data"),"Y_AXIS";case 19:return this.pushState("axis_band_data"),24;case 20:return 31;case 21:return this.pushState("data"),16;case 22:return this.pushState("data"),18;case 23:return this.pushState("data_inner"),24;case 24:return 27;case 25:return this.popState(),26;case 26:this.popState();break;case 27:this.pushState("string");break;case 28:this.popState();break;case 29:return"STR";case 30:return 24;case 31:return 26;case 32:return 43;case 33:return"COLON";case 34:return 44;case 35:return 28;case 36:return 45;case 37:return 46;case 38:return 48;case 39:return 50;case 40:return 47;case 41:return 41;case 42:return 49;case 43:return 42;case 44:break;case 45:return 35;case 46:return 36}},"anonymous"),rules:[/^(?:%%(?!\{)[^\n]*)/i,/^(?:[^\}]%%[^\n]*)/i,/^(?:(\r?\n))/i,/^(?:(\r?\n))/i,/^(?:[\n\r]+)/i,/^(?:%%[^\n]*)/i,/^(?:title\b)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:\})/i,/^(?:[^\}]*)/i,/^(?:xychart-beta\b)/i,/^(?:xychart\b)/i,/^(?:(?:vertical|horizontal))/i,/^(?:x-axis\b)/i,/^(?:y-axis\b)/i,/^(?:\[)/i,/^(?:-->)/i,/^(?:line\b)/i,/^(?:bar\b)/i,/^(?:\[)/i,/^(?:[+-]?(?:\d+(?:\.\d+)?|\.\d+))/i,/^(?:\])/i,/^(?:(?:`\) \{ this\.pushState\(md_string\); \}\n<md_string>\(\?:\(\?!`"\)\.\)\+ \{ return MD_STR; \}\n<md_string>\(\?:`))/i,/^(?:["])/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:\[)/i,/^(?:\])/i,/^(?:[A-Za-z]+)/i,/^(?::)/i,/^(?:\+)/i,/^(?:,)/i,/^(?:=)/i,/^(?:\*)/i,/^(?:#)/i,/^(?:[\_])/i,/^(?:\.)/i,/^(?:&)/i,/^(?:-)/i,/^(?:[0-9]+)/i,/^(?:\s+)/i,/^(?:;)/i,/^(?:$)/i],conditions:{data_inner:{rules:[0,1,4,5,6,7,9,11,14,15,16,17,18,21,22,24,25,26,27,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46],inclusive:!0},data:{rules:[0,1,3,4,5,6,7,9,11,14,15,16,17,18,21,22,23,26,27,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46],inclusive:!0},axis_band_data:{rules:[0,1,4,5,6,7,9,11,14,15,16,17,18,21,22,25,26,27,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46],inclusive:!0},axis_data:{rules:[0,1,2,4,5,6,7,9,11,14,15,16,17,18,19,20,21,22,24,26,27,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46],inclusive:!0},acc_descr_multiline:{rules:[12,13],inclusive:!1},acc_descr:{rules:[10],inclusive:!1},acc_title:{rules:[8],inclusive:!1},title:{rules:[],inclusive:!1},md_string:{rules:[],inclusive:!1},string:{rules:[28,29],inclusive:!1},INITIAL:{rules:[0,1,4,5,6,7,9,11,14,15,16,17,18,21,22,26,27,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46],inclusive:!0}}};return F})();V.lexer=k;function H(){this.yy={}}return a(H,"Parser"),H.prototype=V,V.Parser=H,new H})();At.parser=At;var Ti=At;function wt(e){return e.type==="bar"}a(wt,"isBarPlot");function kt(e){return e.type==="band"}a(kt,"isBandAxisData");function j(e){return e.type==="linear"}a(j,"isLinearAxisData");var Q,Ht=(Q=class{constructor(t){this.parentGroup=t}getMaxDimension(t,i){if(!this.parentGroup)return{width:t.reduce((o,u)=>Math.max(u.length,o),0)*i,height:i};const s={width:0,height:0},n=this.parentGroup.append("g").attr("visibility","hidden").attr("font-size",i);for(const o of t){const u=Si(n,1,o),p=u?u.width:o.length*i,f=u?u.height:i;s.width=Math.max(s.width,p),s.height=Math.max(s.height,f)}return n.remove(),s}},a(Q,"TextDimensionCalculatorWithFont"),Q),Ot=.7,Ft=.2,K,Ut=(K=class{constructor(t,i,s,n){this.axisConfig=t,this.title=i,this.textDimensionCalculator=s,this.axisThemeConfig=n,this.boundingRect={x:0,y:0,width:0,height:0},this.axisPosition="left",this.showTitle=!1,this.showLabel=!1,this.showTick=!1,this.showAxisLine=!1,this.outerPadding=0,this.titleTextHeight=0,this.labelTextHeight=0,this.range=[0,10],this.boundingRect={x:0,y:0,width:0,height:0},this.axisPosition="left"}setRange(t){this.range=t,this.axisPosition==="left"||this.axisPosition==="right"?this.boundingRect.height=t[1]-t[0]:this.boundingRect.width=t[1]-t[0],this.recalculateScale()}getRange(){return[this.range[0]+this.outerPadding,this.range[1]-this.outerPadding]}setAxisPosition(t){this.axisPosition=t,this.setRange(this.range)}getTickDistance(){const t=this.getRange();return Math.abs(t[0]-t[1])/this.getTickValues().length}getAxisOuterPadding(){return this.outerPadding}getLabelDimension(){return this.textDimensionCalculator.getMaxDimension(this.getTickValues().map(t=>t.toString()),this.axisConfig.labelFontSize)}recalculateOuterPaddingToDrawBar(){Ot*this.getTickDistance()>this.outerPadding*2&&(this.outerPadding=Math.floor(Ot*this.getTickDistance()/2)),this.recalculateScale()}calculateSpaceIfDrawnHorizontally(t){let i=t.height;if(this.axisConfig.showAxisLine&&i>this.axisConfig.axisLineWidth&&(i-=this.axisConfig.axisLineWidth,this.showAxisLine=!0),this.axisConfig.showLabel){const s=this.getLabelDimension(),n=Ft*t.width;this.outerPadding=Math.min(s.width/2,n);const o=s.height+this.axisConfig.labelPadding*2;this.labelTextHeight=s.height,o<=i&&(i-=o,this.showLabel=!0)}if(this.axisConfig.showTick&&i>=this.axisConfig.tickLength&&(this.showTick=!0,i-=this.axisConfig.tickLength),this.axisConfig.showTitle&&this.title){const s=this.textDimensionCalculator.getMaxDimension([this.title],this.axisConfig.titleFontSize),n=s.height+this.axisConfig.titlePadding*2;this.titleTextHeight=s.height,n<=i&&(i-=n,this.showTitle=!0)}this.boundingRect.width=t.width,this.boundingRect.height=t.height-i}calculateSpaceIfDrawnVertical(t){let i=t.width;if(this.axisConfig.showAxisLine&&i>this.axisConfig.axisLineWidth&&(i-=this.axisConfig.axisLineWidth,this.showAxisLine=!0),this.axisConfig.showLabel){const s=this.getLabelDimension(),n=Ft*t.height;this.outerPadding=Math.min(s.height/2,n);const o=s.width+this.axisConfig.labelPadding*2;o<=i&&(i-=o,this.showLabel=!0)}if(this.axisConfig.showTick&&i>=this.axisConfig.tickLength&&(this.showTick=!0,i-=this.axisConfig.tickLength),this.axisConfig.showTitle&&this.title){const s=this.textDimensionCalculator.getMaxDimension([this.title],this.axisConfig.titleFontSize),n=s.height+this.axisConfig.titlePadding*2;this.titleTextHeight=s.height,n<=i&&(i-=n,this.showTitle=!0)}this.boundingRect.width=t.width-i,this.boundingRect.height=t.height}calculateSpace(t){return this.axisPosition==="left"||this.axisPosition==="right"?this.calculateSpaceIfDrawnVertical(t):this.calculateSpaceIfDrawnHorizontally(t),this.recalculateScale(),{width:this.boundingRect.width,height:this.boundingRect.height}}setBoundingBoxXY(t){this.boundingRect.x=t.x,this.boundingRect.y=t.y}getDrawableElementsForLeftAxis(){const t=[];if(this.showAxisLine){const i=this.boundingRect.x+this.boundingRect.width-this.axisConfig.axisLineWidth/2;t.push({type:"path",groupTexts:["left-axis","axisl-line"],data:[{path:`M ${i},${this.boundingRect.y} L ${i},${this.boundingRect.y+this.boundingRect.height} `,strokeFill:this.axisThemeConfig.axisLineColor,strokeWidth:this.axisConfig.axisLineWidth}]})}if(this.showLabel&&t.push({type:"text",groupTexts:["left-axis","label"],data:this.getTickValues().map(i=>({text:i.toString(),x:this.boundingRect.x+this.boundingRect.width-(this.showLabel?this.axisConfig.labelPadding:0)-(this.showTick?this.axisConfig.tickLength:0)-(this.showAxisLine?this.axisConfig.axisLineWidth:0),y:this.getScaleValue(i),fill:this.axisThemeConfig.labelColor,fontSize:this.axisConfig.labelFontSize,rotation:0,verticalPos:"middle",horizontalPos:"right"}))}),this.showTick){const i=this.boundingRect.x+this.boundingRect.width-(this.showAxisLine?this.axisConfig.axisLineWidth:0);t.push({type:"path",groupTexts:["left-axis","ticks"],data:this.getTickValues().map(s=>({path:`M ${i},${this.getScaleValue(s)} L ${i-this.axisConfig.tickLength},${this.getScaleValue(s)}`,strokeFill:this.axisThemeConfig.tickColor,strokeWidth:this.axisConfig.tickWidth}))})}return this.showTitle&&t.push({type:"text",groupTexts:["left-axis","title"],data:[{text:this.title,x:this.boundingRect.x+this.axisConfig.titlePadding,y:this.boundingRect.y+this.boundingRect.height/2,fill:this.axisThemeConfig.titleColor,fontSize:this.axisConfig.titleFontSize,rotation:270,verticalPos:"top",horizontalPos:"center"}]}),t}getDrawableElementsForBottomAxis(){const t=[];if(this.showAxisLine){const i=this.boundingRect.y+this.axisConfig.axisLineWidth/2;t.push({type:"path",groupTexts:["bottom-axis","axis-line"],data:[{path:`M ${this.boundingRect.x},${i} L ${this.boundingRect.x+this.boundingRect.width},${i}`,strokeFill:this.axisThemeConfig.axisLineColor,strokeWidth:this.axisConfig.axisLineWidth}]})}if(this.showLabel&&t.push({type:"text",groupTexts:["bottom-axis","label"],data:this.getTickValues().map(i=>({text:i.toString(),x:this.getScaleValue(i),y:this.boundingRect.y+this.axisConfig.labelPadding+(this.showTick?this.axisConfig.tickLength:0)+(this.showAxisLine?this.axisConfig.axisLineWidth:0),fill:this.axisThemeConfig.labelColor,fontSize:this.axisConfig.labelFontSize,rotation:0,verticalPos:"top",horizontalPos:"center"}))}),this.showTick){const i=this.boundingRect.y+(this.showAxisLine?this.axisConfig.axisLineWidth:0);t.push({type:"path",groupTexts:["bottom-axis","ticks"],data:this.getTickValues().map(s=>({path:`M ${this.getScaleValue(s)},${i} L ${this.getScaleValue(s)},${i+this.axisConfig.tickLength}`,strokeFill:this.axisThemeConfig.tickColor,strokeWidth:this.axisConfig.tickWidth}))})}return this.showTitle&&t.push({type:"text",groupTexts:["bottom-axis","title"],data:[{text:this.title,x:this.range[0]+(this.range[1]-this.range[0])/2,y:this.boundingRect.y+this.boundingRect.height-this.axisConfig.titlePadding-this.titleTextHeight,fill:this.axisThemeConfig.titleColor,fontSize:this.axisConfig.titleFontSize,rotation:0,verticalPos:"top",horizontalPos:"center"}]}),t}getDrawableElementsForTopAxis(){const t=[];if(this.showAxisLine){const i=this.boundingRect.y+this.boundingRect.height-this.axisConfig.axisLineWidth/2;t.push({type:"path",groupTexts:["top-axis","axis-line"],data:[{path:`M ${this.boundingRect.x},${i} L ${this.boundingRect.x+this.boundingRect.width},${i}`,strokeFill:this.axisThemeConfig.axisLineColor,strokeWidth:this.axisConfig.axisLineWidth}]})}if(this.showLabel&&t.push({type:"text",groupTexts:["top-axis","label"],data:this.getTickValues().map(i=>({text:i.toString(),x:this.getScaleValue(i),y:this.boundingRect.y+(this.showTitle?this.titleTextHeight+this.axisConfig.titlePadding*2:0)+this.axisConfig.labelPadding,fill:this.axisThemeConfig.labelColor,fontSize:this.axisConfig.labelFontSize,rotation:0,verticalPos:"top",horizontalPos:"center"}))}),this.showTick){const i=this.boundingRect.y;t.push({type:"path",groupTexts:["top-axis","ticks"],data:this.getTickValues().map(s=>({path:`M ${this.getScaleValue(s)},${i+this.boundingRect.height-(this.showAxisLine?this.axisConfig.axisLineWidth:0)} L ${this.getScaleValue(s)},${i+this.boundingRect.height-this.axisConfig.tickLength-(this.showAxisLine?this.axisConfig.axisLineWidth:0)}`,strokeFill:this.axisThemeConfig.tickColor,strokeWidth:this.axisConfig.tickWidth}))})}return this.showTitle&&t.push({type:"text",groupTexts:["top-axis","title"],data:[{text:this.title,x:this.boundingRect.x+this.boundingRect.width/2,y:this.boundingRect.y+this.axisConfig.titlePadding,fill:this.axisThemeConfig.titleColor,fontSize:this.axisConfig.titleFontSize,rotation:0,verticalPos:"top",horizontalPos:"center"}]}),t}getDrawableElements(){if(this.axisPosition==="left")return this.getDrawableElementsForLeftAxis();if(this.axisPosition==="right")throw Error("Drawing of right axis is not implemented");return this.axisPosition==="bottom"?this.getDrawableElementsForBottomAxis():this.axisPosition==="top"?this.getDrawableElementsForTopAxis():[]}},a(K,"BaseAxis"),K),Z,Di=(Z=class extends Ut{constructor(t,i,s,n,o){super(t,n,o,i),this.categories=s,this.scale=bt().domain(this.categories).range(this.getRange())}setRange(t){super.setRange(t)}recalculateScale(){this.scale=bt().domain(this.categories).range(this.getRange()).paddingInner(1).paddingOuter(0).align(.5),Yt.trace("BandAxis axis final categories, range: ",this.categories,this.getRange())}getTickValues(){return this.categories}getScaleValue(t){return this.scale(t)??this.getRange()[0]}},a(Z,"BandAxis"),Z),J,vi=(J=class extends Ut{constructor(t,i,s,n,o){super(t,n,o,i),this.domain=s,this.scale=zt().domain(this.domain).range(this.getRange())}getTickValues(){return this.scale.ticks()}recalculateScale(){const t=[...this.domain];this.axisPosition==="left"&&t.reverse(),this.scale=zt().domain(t).range(this.getRange())}getScaleValue(t){return this.scale(t)}},a(J,"LinearAxis"),J);function Ct(e,t,i,s){const n=new Ht(s);return kt(e)?new Di(t,i,e.categories,e.title,n):new vi(t,i,[e.min,e.max],e.title,n)}a(Ct,"getAxis");var tt,Pi=(tt=class{constructor(t,i,s,n){this.textDimensionCalculator=t,this.chartConfig=i,this.chartData=s,this.chartThemeConfig=n,this.boundingRect={x:0,y:0,width:0,height:0},this.showChartTitle=!1}setBoundingBoxXY(t){this.boundingRect.x=t.x,this.boundingRect.y=t.y}calculateSpace(t){const i=this.textDimensionCalculator.getMaxDimension([this.chartData.title],this.chartConfig.titleFontSize),s=Math.max(i.width,t.width),n=i.height+2*this.chartConfig.titlePadding;return i.width<=s&&i.height<=n&&this.chartConfig.showTitle&&this.chartData.title&&(this.boundingRect.width=s,this.boundingRect.height=n,this.showChartTitle=!0),{width:this.boundingRect.width,height:this.boundingRect.height}}getDrawableElements(){const t=[];return this.showChartTitle&&t.push({groupTexts:["chart-title"],type:"text",data:[{fontSize:this.chartConfig.titleFontSize,text:this.chartData.title,verticalPos:"middle",horizontalPos:"center",x:this.boundingRect.x+this.boundingRect.width/2,y:this.boundingRect.y+this.boundingRect.height/2,fill:this.chartThemeConfig.titleColor,rotation:0}]}),t}},a(tt,"ChartTitle"),tt);function $t(e,t,i,s){const n=new Ht(s);return new Pi(n,e,t,i)}a($t,"getChartTitleComponent");var it,Li=(it=class{constructor(t,i,s,n,o){this.plotData=t,this.xAxis=i,this.yAxis=s,this.orientation=n,this.plotIndex=o}getDrawableElement(){const t=this.plotData.data.map(s=>[this.xAxis.getScaleValue(s[0]),this.yAxis.getScaleValue(s[1])]);let i;return this.orientation==="horizontal"?i=Wt().y(s=>s[0]).x(s=>s[1])(t):i=Wt().x(s=>s[0]).y(s=>s[1])(t),i?[{groupTexts:["plot",`line-plot-${this.plotIndex}`],type:"path",data:[{path:i,strokeFill:this.plotData.strokeFill,strokeWidth:this.plotData.strokeWidth}]}]:[]}},a(it,"LinePlot"),it),et,Ei=(et=class{constructor(t,i,s,n,o,u){this.barData=t,this.boundingRect=i,this.xAxis=s,this.yAxis=n,this.orientation=o,this.plotIndex=u}getDrawableElement(){const t=this.barData.data.map(o=>[this.xAxis.getScaleValue(o[0]),this.yAxis.getScaleValue(o[1])]),s=Math.min(this.xAxis.getAxisOuterPadding()*2,this.xAxis.getTickDistance())*(1-.05),n=s/2;return this.orientation==="horizontal"?[{groupTexts:["plot",`bar-plot-${this.plotIndex}`],type:"rect",data:t.map(o=>({x:this.boundingRect.x,y:o[0]-n,height:s,width:o[1]-this.boundingRect.x,fill:this.barData.fill,strokeWidth:0,strokeFill:this.barData.fill}))}]:[{groupTexts:["plot",`bar-plot-${this.plotIndex}`],type:"rect",data:t.map(o=>({x:o[0]-n,y:o[1],width:s,height:this.boundingRect.y+this.boundingRect.height-o[1],fill:this.barData.fill,strokeWidth:0,strokeFill:this.barData.fill}))}]}},a(et,"BarPlot"),et),st,Ii=(st=class{constructor(t,i,s){this.chartConfig=t,this.chartData=i,this.chartThemeConfig=s,this.boundingRect={x:0,y:0,width:0,height:0}}setAxes(t,i){this.xAxis=t,this.yAxis=i}setBoundingBoxXY(t){this.boundingRect.x=t.x,this.boundingRect.y=t.y}calculateSpace(t){return this.boundingRect.width=t.width,this.boundingRect.height=t.height,{width:this.boundingRect.width,height:this.boundingRect.height}}getDrawableElements(){if(!(this.xAxis&&this.yAxis))throw Error("Axes must be passed to render Plots");const t=[];for(const[i,s]of this.chartData.plots.entries())switch(s.type){case"line":{const n=new Li(s,this.xAxis,this.yAxis,this.chartConfig.chartOrientation,i);t.push(...n.getDrawableElement())}break;case"bar":{const n=new Ei(s,this.boundingRect,this.xAxis,this.yAxis,this.chartConfig.chartOrientation,i);t.push(...n.getDrawableElement())}break}return t}},a(st,"BasePlot"),st);function qt(e,t,i){return new Ii(e,t,i)}a(qt,"getPlotComponent");var nt,Mi=(nt=class{constructor(t,i,s,n){this.chartConfig=t,this.chartData=i,this.componentStore={title:$t(t,i,s,n),plot:qt(t,i,s),xAxis:Ct(i.xAxis,t.xAxis,{titleColor:s.xAxisTitleColor,labelColor:s.xAxisLabelColor,tickColor:s.xAxisTickColor,axisLineColor:s.xAxisLineColor},n),yAxis:Ct(i.yAxis,t.yAxis,{titleColor:s.yAxisTitleColor,labelColor:s.yAxisLabelColor,tickColor:s.yAxisTickColor,axisLineColor:s.yAxisLineColor},n)}}calculateVerticalSpace(){let t=this.chartConfig.width,i=this.chartConfig.height,s=0,n=0,o=Math.floor(t*this.chartConfig.plotReservedSpacePercent/100),u=Math.floor(i*this.chartConfig.plotReservedSpacePercent/100),p=this.componentStore.plot.calculateSpace({width:o,height:u});t-=p.width,i-=p.height,p=this.componentStore.title.calculateSpace({width:this.chartConfig.width,height:i}),n=p.height,i-=p.height,this.componentStore.xAxis.setAxisPosition("bottom"),p=this.componentStore.xAxis.calculateSpace({width:t,height:i}),i-=p.height,this.componentStore.yAxis.setAxisPosition("left"),p=this.componentStore.yAxis.calculateSpace({width:t,height:i}),s=p.width,t-=p.width,t>0&&(o+=t,t=0),i>0&&(u+=i,i=0),this.componentStore.plot.calculateSpace({width:o,height:u}),this.componentStore.plot.setBoundingBoxXY({x:s,y:n}),this.componentStore.xAxis.setRange([s,s+o]),this.componentStore.xAxis.setBoundingBoxXY({x:s,y:n+u}),this.componentStore.yAxis.setRange([n,n+u]),this.componentStore.yAxis.setBoundingBoxXY({x:0,y:n}),this.chartData.plots.some(f=>wt(f))&&this.componentStore.xAxis.recalculateOuterPaddingToDrawBar()}calculateHorizontalSpace(){let t=this.chartConfig.width,i=this.chartConfig.height,s=0,n=0,o=0,u=Math.floor(t*this.chartConfig.plotReservedSpacePercent/100),p=Math.floor(i*this.chartConfig.plotReservedSpacePercent/100),f=this.componentStore.plot.calculateSpace({width:u,height:p});t-=f.width,i-=f.height,f=this.componentStore.title.calculateSpace({width:this.chartConfig.width,height:i}),s=f.height,i-=f.height,this.componentStore.xAxis.setAxisPosition("left"),f=this.componentStore.xAxis.calculateSpace({width:t,height:i}),t-=f.width,n=f.width,this.componentStore.yAxis.setAxisPosition("top"),f=this.componentStore.yAxis.calculateSpace({width:t,height:i}),i-=f.height,o=s+f.height,t>0&&(u+=t,t=0),i>0&&(p+=i,i=0),this.componentStore.plot.calculateSpace({width:u,height:p}),this.componentStore.plot.setBoundingBoxXY({x:n,y:o}),this.componentStore.yAxis.setRange([n,n+u]),this.componentStore.yAxis.setBoundingBoxXY({x:n,y:s}),this.componentStore.xAxis.setRange([o,o+p]),this.componentStore.xAxis.setBoundingBoxXY({x:0,y:o}),this.chartData.plots.some(T=>wt(T))&&this.componentStore.xAxis.recalculateOuterPaddingToDrawBar()}calculateSpace(){this.chartConfig.chartOrientation==="horizontal"?this.calculateHorizontalSpace():this.calculateVerticalSpace()}getDrawableElement(){this.calculateSpace();const t=[];this.componentStore.plot.setAxes(this.componentStore.xAxis,this.componentStore.yAxis);for(const i of Object.values(this.componentStore))t.push(...i.getDrawableElements());return t}},a(nt,"Orchestrator"),nt),at,Vi=(at=class{static build(t,i,s,n){return new Mi(t,i,s,n).getDrawableElement()}},a(at,"XYChartBuilder"),at),ot=0,Gt,ht=Dt(),lt=Tt(),A=vt(),St=lt.plotColorPalette.split(",").map(e=>e.trim()),xt=!1,Rt=!1;function Tt(){const e=Ci(),t=_t();return Nt(e.xyChart,t.themeVariables.xyChart)}a(Tt,"getChartDefaultThemeConfig");function Dt(){const e=_t();return Nt(wi.xyChart,e.xyChart)}a(Dt,"getChartDefaultConfig");function vt(){return{yAxis:{type:"linear",title:"",min:1/0,max:-1/0},xAxis:{type:"band",title:"",categories:[]},title:"",plots:[]}}a(vt,"getChartDefaultData");function dt(e){const t=_t();return Ai(e.trim(),t)}a(dt,"textSanitizer");function jt(e){Gt=e}a(jt,"setTmpSVGG");function Qt(e){e==="horizontal"?ht.chartOrientation="horizontal":ht.chartOrientation="vertical"}a(Qt,"setOrientation");function Kt(e){A.xAxis.title=dt(e.text)}a(Kt,"setXAxisTitle");function Pt(e,t){A.xAxis={type:"linear",title:A.xAxis.title,min:e,max:t},xt=!0}a(Pt,"setXAxisRangeData");function Zt(e){A.xAxis={type:"band",title:A.xAxis.title,categories:e.map(t=>dt(t.text))},xt=!0}a(Zt,"setXAxisBand");function Jt(e){A.yAxis.title=dt(e.text)}a(Jt,"setYAxisTitle");function ti(e,t){A.yAxis={type:"linear",title:A.yAxis.title,min:e,max:t},Rt=!0}a(ti,"setYAxisRangeData");function ii(e){const t=Math.min(...e),i=Math.max(...e),s=j(A.yAxis)?A.yAxis.min:1/0,n=j(A.yAxis)?A.yAxis.max:-1/0;A.yAxis={type:"linear",title:A.yAxis.title,min:Math.min(s,t),max:Math.max(n,i)}}a(ii,"setYAxisRangeFromPlotData");function Lt(e){let t=[];if(e.length===0)return t;if(!xt){const i=j(A.xAxis)?A.xAxis.min:1/0,s=j(A.xAxis)?A.xAxis.max:-1/0;Pt(Math.min(i,1),Math.max(s,e.length))}if(Rt||ii(e),kt(A.xAxis)&&(t=A.xAxis.categories.map((i,s)=>[i,e[s]])),j(A.xAxis)){const i=A.xAxis.min,s=A.xAxis.max,n=(s-i)/(e.length-1),o=[];for(let u=i;u<=s;u+=n)o.push(`${u}`);t=o.map((u,p)=>[u,e[p]])}return t}a(Lt,"transformDataWithoutCategory");function Et(e){return St[e===0?0:e%St.length]}a(Et,"getPlotColorFromPalette");function ei(e,t){const i=Lt(t);A.plots.push({type:"line",strokeFill:Et(ot),strokeWidth:2,data:i}),ot++}a(ei,"setLineData");function si(e,t){const i=Lt(t);A.plots.push({type:"bar",fill:Et(ot),data:i}),ot++}a(si,"setBarData");function ni(){if(A.plots.length===0)throw Error("No Plot to render, please provide a plot with some data");return A.title=Xt(),Vi.build(ht,A,lt,Gt)}a(ni,"getDrawableElem");function ai(){return lt}a(ai,"getChartThemeConfig");function ri(){return ht}a(ri,"getChartConfig");function oi(){return A}a(oi,"getXYChartData");var Bi=a(function(){bi(),ot=0,ht=Dt(),A=vt(),lt=Tt(),St=lt.plotColorPalette.split(",").map(e=>e.trim()),xt=!1,Rt=!1},"clear"),Wi={getDrawableElem:ni,clear:Bi,setAccTitle:pi,getAccTitle:fi,setDiagramTitle:di,getDiagramTitle:Xt,getAccDescription:xi,setAccDescription:gi,setOrientation:Qt,setXAxisTitle:Kt,setXAxisRangeData:Pt,setXAxisBand:Zt,setYAxisTitle:Jt,setYAxisRangeData:ti,setLineData:ei,setBarData:si,setTmpSVGG:jt,getChartThemeConfig:ai,getChartConfig:ri,getXYChartData:oi},zi=a((e,t,i,s)=>{const n=s.db,o=n.getChartThemeConfig(),u=n.getChartConfig(),p=n.getXYChartData().plots[0].data.map(m=>m[1]);function f(m){return m==="top"?"text-before-edge":"middle"}a(f,"getDominantBaseLine");function T(m){return m==="left"?"start":m==="right"?"end":"middle"}a(T,"getTextAnchor");function P(m){return`translate(${m.x}, ${m.y}) rotate(${m.rotation||0})`}a(P,"getTextTransformation"),Yt.debug(`Rendering xychart chart
|
|
7
|
-
`+e);const _=mi(t),y=_.append("g").attr("class","main"),E=y.append("rect").attr("width",u.width).attr("height",u.height).attr("class","background");yi(_,u.height,u.width,!0),_.attr("viewBox",`0 0 ${u.width} ${u.height}`),E.attr("fill",o.backgroundColor),n.setTmpSVGG(_.append("g").attr("class","mermaid-tmp-group"));const v=n.getDrawableElem(),L={};function I(m){let R=y,l="";for(const[W]of m.entries()){let O=y;W>0&&L[l]&&(O=L[l]),l+=m[W],R=L[l],R||(R=L[l]=O.append("g").attr("class",m[W]))}return R}a(I,"getGroup");for(const m of v){if(m.data.length===0)continue;const R=I(m.groupTexts);switch(m.type){case"rect":if(R.selectAll("rect").data(m.data).enter().append("rect").attr("x",l=>l.x).attr("y",l=>l.y).attr("width",l=>l.width).attr("height",l=>l.height).attr("fill",l=>l.fill).attr("stroke",l=>l.strokeFill).attr("stroke-width",l=>l.strokeWidth),u.showDataLabel){const l=u.showDataLabelOutsideBar;if(u.chartOrientation==="horizontal"){let W=function(w,V){const{data:k,label:H}=w;return V*H.length*O<=k.width-X};a(W,"fitsHorizontally");const O=.7,X=10,Y=m.data.map((w,V)=>({data:w,label:p[V].toString()})).filter(w=>w.data.width>0&&w.data.height>0),S=Y.map(w=>{const{data:V}=w;let k=V.height*.7;for(;!W(w,k)&&k>0;)k-=1;return k}),U=Math.floor(Math.min(...S)),b=a(w=>l?w.data.x+w.data.width+X:w.data.x+w.data.width-X,"determineLabelXPosition");R.selectAll("text").data(Y).enter().append("text").attr("x",b).attr("y",w=>w.data.y+w.data.height/2).attr("text-anchor",l?"start":"end").attr("dominant-baseline","middle").attr("fill",o.dataLabelColor).attr("font-size",`${U}px`).text(w=>w.label)}else{let W=function(b,w,V){const{data:k,label:H}=b,h=w*H.length*.7,c=k.x+k.width/2,g=c-h/2,x=c+h/2,C=g>=k.x&&x<=k.x+k.width,r=k.y+V+w<=k.y+k.height;return C&&r};a(W,"fitsInBar");const O=10,X=m.data.map((b,w)=>({data:b,label:p[w].toString()})).filter(b=>b.data.width>0&&b.data.height>0),Y=X.map(b=>{const{data:w,label:V}=b;let k=w.width/(V.length*.7);for(;!W(b,k,O)&&k>0;)k-=1;return k}),S=Math.floor(Math.min(...Y)),U=a(b=>l?b.data.y-O:b.data.y+O,"determineLabelYPosition");R.selectAll("text").data(X).enter().append("text").attr("x",b=>b.data.x+b.data.width/2).attr("y",U).attr("text-anchor","middle").attr("dominant-baseline",l?"auto":"hanging").attr("fill",o.dataLabelColor).attr("font-size",`${S}px`).text(b=>b.label)}}break;case"text":R.selectAll("text").data(m.data).enter().append("text").attr("x",0).attr("y",0).attr("fill",l=>l.fill).attr("font-size",l=>l.fontSize).attr("dominant-baseline",l=>f(l.verticalPos)).attr("text-anchor",l=>T(l.horizontalPos)).attr("transform",l=>P(l)).text(l=>l.text);break;case"path":R.selectAll("path").data(m.data).enter().append("path").attr("d",l=>l.path).attr("fill",l=>l.fill?l.fill:"none").attr("stroke",l=>l.strokeFill).attr("stroke-width",l=>l.strokeWidth);break}}},"draw"),Oi={draw:zi}
|
|
7
|
+
`+e);const _=mi(t),y=_.append("g").attr("class","main"),E=y.append("rect").attr("width",u.width).attr("height",u.height).attr("class","background");yi(_,u.height,u.width,!0),_.attr("viewBox",`0 0 ${u.width} ${u.height}`),E.attr("fill",o.backgroundColor),n.setTmpSVGG(_.append("g").attr("class","mermaid-tmp-group"));const v=n.getDrawableElem(),L={};function I(m){let R=y,l="";for(const[W]of m.entries()){let O=y;W>0&&L[l]&&(O=L[l]),l+=m[W],R=L[l],R||(R=L[l]=O.append("g").attr("class",m[W]))}return R}a(I,"getGroup");for(const m of v){if(m.data.length===0)continue;const R=I(m.groupTexts);switch(m.type){case"rect":if(R.selectAll("rect").data(m.data).enter().append("rect").attr("x",l=>l.x).attr("y",l=>l.y).attr("width",l=>l.width).attr("height",l=>l.height).attr("fill",l=>l.fill).attr("stroke",l=>l.strokeFill).attr("stroke-width",l=>l.strokeWidth),u.showDataLabel){const l=u.showDataLabelOutsideBar;if(u.chartOrientation==="horizontal"){let W=function(w,V){const{data:k,label:H}=w;return V*H.length*O<=k.width-X};a(W,"fitsHorizontally");const O=.7,X=10,Y=m.data.map((w,V)=>({data:w,label:p[V].toString()})).filter(w=>w.data.width>0&&w.data.height>0),S=Y.map(w=>{const{data:V}=w;let k=V.height*.7;for(;!W(w,k)&&k>0;)k-=1;return k}),U=Math.floor(Math.min(...S)),b=a(w=>l?w.data.x+w.data.width+X:w.data.x+w.data.width-X,"determineLabelXPosition");R.selectAll("text").data(Y).enter().append("text").attr("x",b).attr("y",w=>w.data.y+w.data.height/2).attr("text-anchor",l?"start":"end").attr("dominant-baseline","middle").attr("fill",o.dataLabelColor).attr("font-size",`${U}px`).text(w=>w.label)}else{let W=function(b,w,V){const{data:k,label:H}=b,h=w*H.length*.7,c=k.x+k.width/2,g=c-h/2,x=c+h/2,C=g>=k.x&&x<=k.x+k.width,r=k.y+V+w<=k.y+k.height;return C&&r};a(W,"fitsInBar");const O=10,X=m.data.map((b,w)=>({data:b,label:p[w].toString()})).filter(b=>b.data.width>0&&b.data.height>0),Y=X.map(b=>{const{data:w,label:V}=b;let k=w.width/(V.length*.7);for(;!W(b,k,O)&&k>0;)k-=1;return k}),S=Math.floor(Math.min(...Y)),U=a(b=>l?b.data.y-O:b.data.y+O,"determineLabelYPosition");R.selectAll("text").data(X).enter().append("text").attr("x",b=>b.data.x+b.data.width/2).attr("y",U).attr("text-anchor","middle").attr("dominant-baseline",l?"auto":"hanging").attr("fill",o.dataLabelColor).attr("font-size",`${S}px`).text(b=>b.label)}}break;case"text":R.selectAll("text").data(m.data).enter().append("text").attr("x",0).attr("y",0).attr("fill",l=>l.fill).attr("font-size",l=>l.fontSize).attr("dominant-baseline",l=>f(l.verticalPos)).attr("text-anchor",l=>T(l.horizontalPos)).attr("transform",l=>P(l)).text(l=>l.text);break;case"path":R.selectAll("path").data(m.data).enter().append("path").attr("d",l=>l.path).attr("fill",l=>l.fill?l.fill:"none").attr("stroke",l=>l.strokeFill).attr("stroke-width",l=>l.strokeWidth);break}}},"draw"),Oi={draw:zi},Gi={parser:Ti,db:Wi,renderer:Oi};export{Gi as diagram};
|
package/dist/web-ui/index.html
CHANGED
|
@@ -11,8 +11,8 @@
|
|
|
11
11
|
<script>
|
|
12
12
|
(function(){var t=localStorage.getItem('markus-theme');if(t==='midnight'){t='dark';try{localStorage.setItem('markus-theme','dark')}catch(e){}}if(t&&t!=='system')document.documentElement.classList.add(t)})();
|
|
13
13
|
</script>
|
|
14
|
-
<script type="module" crossorigin src="/assets/index-
|
|
15
|
-
<link rel="stylesheet" crossorigin href="/assets/index-
|
|
14
|
+
<script type="module" crossorigin src="/assets/index-D_HH4ju2.js"></script>
|
|
15
|
+
<link rel="stylesheet" crossorigin href="/assets/index-YDpknaqo.css">
|
|
16
16
|
</head>
|
|
17
17
|
<body>
|
|
18
18
|
<div id="root"></div>
|
package/package.json
CHANGED
|
@@ -174,6 +174,7 @@ When debugging failures — especially in multi-step workflows or agent-produced
|
|
|
174
174
|
You consume computational resources with every action. Be intentional about resource usage:
|
|
175
175
|
|
|
176
176
|
- **Token efficiency**: Write concise, structured outputs. Avoid restating the question or padding responses with unnecessary context. Use tables and lists over prose when they convey the same information more compactly.
|
|
177
|
+
- **End cleanly in chat**: When the user's request is done, state the outcome and stop. Do not add a closing check-in ("anything else?", "还需要我做什么吗?"). Do not announce a next tool step without calling that tool in the same turn.
|
|
177
178
|
- **Targeted searches**: Use specific search queries over broad exploration. `grep_search("className AuthService")` is better than reading every file in `src/`.
|
|
178
179
|
- **Context management**: Use `spawn_subagent` for heavy reads (large files, deep codebase exploration) to keep your main context lean. Your context window is finite — treat it as a scarce resource.
|
|
179
180
|
- **Tool call efficiency**: Batch independent operations. Check if information is already available in your context before making additional tool calls.
|
|
@@ -274,12 +275,13 @@ You operate within a project-based system. Key concepts:
|
|
|
274
275
|
- **Agents can propose requirement drafts** — use `requirement_propose` to suggest work that should be done. These drafts must be reviewed and **approved by a human user** before any work begins.
|
|
275
276
|
- **No requirement = no task creation.** You may NOT create top-level tasks without an approved `requirement_id`. If you identify work that needs to be done, propose a requirement — do NOT create a task directly.
|
|
276
277
|
- Subtasks are embedded within tasks and inherit the task's requirement automatically.
|
|
278
|
+
- **Built-in approval UI**: After you `requirement_propose` or `task_create`, Markus already shows Approve/Reject on the card and notifies the human. **Do NOT** call `request_user_input` / `request_user_approval` to ask them to approve — that duplicates the system buttons. **Do NOT** send an extra `notify_user` just to remind them at creation time. Wait; they will decide. If something has been stuck pending for a very long time, a single non-blocking `notify_user` nudge is enough — never a blocking questionnaire.
|
|
277
279
|
|
|
278
280
|
### What to do when you see untracked work
|
|
279
281
|
If you notice work that should be done but no requirement exists for it:
|
|
280
282
|
1. Use `requirement_list` to check if a relevant requirement already exists.
|
|
281
283
|
2. If not, use `requirement_propose` with a clear title, description, and priority.
|
|
282
|
-
3. **Wait for the user to approve**
|
|
284
|
+
3. **Wait for the user to approve** via the built-in Approve button on the requirement card. Do NOT proceed until approval is granted. Do NOT re-ask via `request_user_input`.
|
|
283
285
|
4. If you receive no approval response, do NOT create tasks and do NOT attempt the work. Simply wait.
|
|
284
286
|
|
|
285
287
|
### When to start working on a task
|
|
@@ -291,7 +293,7 @@ If you notice work that should be done but no requirement exists for it:
|
|
|
291
293
|
### Task creation rules
|
|
292
294
|
- Every `task_create` call **MUST** include `requirement_id` (the approved requirement this task fulfills), `project_id` (the project it belongs to), `assigned_agent_id` (who executes the work), and `reviewer_agent_id` (who approves after review). **Tasks without these fields are invalid and will be rejected.**
|
|
293
295
|
- Every `task_create` call for related tasks **MUST** include `blocked_by` — this field is mandatory whenever the task depends on the output or completion of another task. Omitting `blocked_by` when dependencies exist is a protocol violation. A task with `blocked_by` will start in `blocked` status and automatically transition to `in_progress` when all blockers complete.
|
|
294
|
-
- When you call `task_create`, the system may place it in `pending` status. You MUST wait for explicit human or manager approval — do NOT treat the task as yours to execute just because you created it
|
|
296
|
+
- When you call `task_create`, the system may place it in `pending` status. You MUST wait for explicit human or manager approval via the **built-in Approve button** on the task card — do NOT treat the task as yours to execute just because you created it, and do NOT ask for approval again with `request_user_input`.
|
|
295
297
|
- **Before creating a task**, call `task_list` with the same `requirement_id` to check for existing tasks. Do NOT create tasks that duplicate existing ones.
|
|
296
298
|
- Respect the task cap — if you have reached your concurrent task limit, finish existing tasks before creating new ones.
|
|
297
299
|
|
|
@@ -314,10 +316,15 @@ When a user assigns work that is too large or complex to complete in a single co
|
|
|
314
316
|
|
|
315
317
|
## Workspace
|
|
316
318
|
|
|
317
|
-
Each agent has a dedicated
|
|
319
|
+
Each agent has a dedicated **working directory** (for project work) and an **agent home** (for identity/memory files). Both absolute paths are listed in the system context under "Your Workspace & Files".
|
|
320
|
+
|
|
321
|
+
- Persona and heartbeat files are only under `agent-home/role/` (`ROLE.md`, `HEARTBEAT.md`).
|
|
322
|
+
- Long-term memory / notebook live at agent-home root (`MEMORY.md`, `NOTEBOOK.md`).
|
|
323
|
+
- Do not create `ROLE.md` or `HEARTBEAT.md` in the working directory — those copies are ignored.
|
|
324
|
+
- You can read and write elsewhere, but **you cannot write to other agents' directories**.
|
|
318
325
|
|
|
319
326
|
### Best Practices
|
|
320
|
-
- For project code work, prefer creating worktrees inside your
|
|
327
|
+
- For project code work, prefer creating worktrees inside your working directory via `git worktree add` (`shell_execute`). You decide the layout and branching strategy.
|
|
321
328
|
- When referencing files for other agents, always provide the **absolute path** so they can read the file directly.
|
|
322
329
|
|
|
323
330
|
### Coordination
|
|
@@ -51,6 +51,6 @@ Don't write generic platitudes — write actionable workflow instructions specif
|
|
|
51
51
|
- **DO NOT** invent role names or skill IDs. Only use values from the dynamic context.
|
|
52
52
|
- **DO NOT** put file content in the JSON. Always use `file_write` for files.
|
|
53
53
|
- **DO NOT** default skills to `[]` when relevant skills are available. Check the skills list!
|
|
54
|
-
- **The `name` field MUST be English kebab-case
|
|
54
|
+
- **The `name` field MUST be a valid English kebab-case slug** (e.g. `code-reviewer`). Chinese goes in `displayName` only — invalid `name` is rejected on write/save/share. Follow the `agent-building` skill Package Slug rules.
|
|
55
55
|
- The `ROLE.md` is what makes the agent unique — write at least 5 substantive paragraphs. A generic one-liner is useless.
|
|
56
56
|
- Always explain your design choices to the user.
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
- Use `requirement_list` to check requirements you created:
|
|
14
14
|
- **`in_progress`**: Are all linked tasks progressing? Are any stalled or blocked?
|
|
15
15
|
- **`in_progress` with all tasks done**: Evaluate whether the requirement is fully met. If yes, update status to `completed`. If not, create additional tasks.
|
|
16
|
-
- **`pending`**:
|
|
16
|
+
- **`pending`**: Leave it alone at first — creation already notified the user and the card has Approve/Reject. Only if still pending >24h, optionally send ONE non-blocking `notify_user` nudge. Never use `request_user_input` to re-ask for approval.
|
|
17
17
|
- **`rejected`**: Review the rejection reason. Either resubmit with updates via `requirement_resubmit`, or abandon it.
|
|
18
18
|
|
|
19
19
|
## New-Hire & Artifact Monitoring
|
|
@@ -57,7 +57,7 @@ Check `task_list` for tasks recently completed by you or your team members. For
|
|
|
57
57
|
For identified best practices:
|
|
58
58
|
- Save via `memory_save` with `tags: ["insight", "secretary"]` and `[INSIGHT]` format.
|
|
59
59
|
- If it is a multi-step workflow (e.g., "new agent onboarding procedure", "org knowledge audit process"), promote it to MEMORY.md via `memory_update_longterm({ section: "procedures", ... })`.
|
|
60
|
-
- When 3+ related insights accumulate, update
|
|
60
|
+
- When 3+ related insights accumulate, update `role/ROLE.md` under your agent home (absolute path in system context; read first via `file_read`, append only, log with `tags: ["insight", "role-evolution"]`). Do not write ROLE.md in the working directory.
|
|
61
61
|
|
|
62
62
|
## Self-Evolution Reflection
|
|
63
63
|
|
|
@@ -24,6 +24,7 @@ You are a **protected system agent** — you cannot be deleted. You persist acro
|
|
|
24
24
|
- Track progress and escalate blockers to the task creator or team lead immediately
|
|
25
25
|
- Prioritize tasks by urgency and impact
|
|
26
26
|
- Use messages (`agent_send_message`) only for status notifications and quick coordination; use tasks for any substantial work delegation
|
|
27
|
+
- When you ask another agent something on behalf of the owner: once you have their answer, **`notify_user` the owner** (or report it in the owner chat). Do **not** paste “XXX 回复说:…” back into that agent’s DM — that re-triggers them and creates endless “收到/保持待命” loops
|
|
27
28
|
|
|
28
29
|
### 4. Information & Communication
|
|
29
30
|
- Summarize complex situations clearly and briefly
|
|
@@ -35,45 +36,46 @@ You are a **protected system agent** — you cannot be deleted. You persist acro
|
|
|
35
36
|
|
|
36
37
|
You are the primary builder and talent manager. You have building skills (agent-building, team-building, skill-building) and access to hiring/installation tools. **Hiring is a process, not a command** — creating the agent is step 1; onboarding is what makes them productive.
|
|
37
38
|
|
|
38
|
-
#### Team
|
|
39
|
+
#### Team & Hire — keep it simple
|
|
39
40
|
|
|
40
|
-
|
|
41
|
+
**Mental model:** design = write a package directory under `~/.markus/builder-artifacts/`; deploy = `package_install`. There is **no** separate `team_create` tool.
|
|
41
42
|
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
43
|
+
| User asks for… | What you do |
|
|
44
|
+
|---|---|
|
|
45
|
+
| **A whole custom team** (roles, norms, several members) | `team-building` skill → `file_write` everything under `~/.markus/builder-artifacts/teams/{kebab-name}/` → `package_list(type:"team")` → `package_install(type:"team", name)` — **one install creates the team + all members** |
|
|
46
|
+
| **One agent on a new/named team** | `package_list` → `package_install(type:"agent", name, agent_name, team_name:"…")` — find-or-creates that team and places the agent |
|
|
47
|
+
| **One agent on an existing team** | `list_teams` → `package_install(type:"agent", …, team_id)` |
|
|
48
|
+
| **Builtin full team template** (e.g. research-lab) | `package_list(type:"team")` → `package_install(type:"team", name)` — no artifact writing |
|
|
45
49
|
|
|
46
|
-
|
|
50
|
+
**Wrong:**
|
|
51
|
+
- Looking for `team_create` or creating teams via shell / sqlite / curl
|
|
52
|
+
- Writing packages under `workspace/` (install only sees `builder-artifacts`)
|
|
53
|
+
- Assuming chat JSON is auto-saved — always `file_write`
|
|
54
|
+
- Hiring many agents with neither `team_id` nor `team_name` when the user wanted a dedicated team
|
|
47
55
|
|
|
48
56
|
#### Hiring Workflow (the complete process)
|
|
49
57
|
|
|
50
|
-
1. **Assess need**:
|
|
51
|
-
2. **
|
|
52
|
-
3. **Source
|
|
53
|
-
4. **
|
|
54
|
-
5. **Onboard
|
|
55
|
-
|
|
56
|
-
- Share relevant project info: active repositories, current requirements, coding standards
|
|
57
|
-
- Point them to team norms and announcements
|
|
58
|
-
- If the team has existing patterns or past decisions, share context from `memory_search`
|
|
59
|
-
6. **Assign initial work**: Create tasks (`task_create`) immediately so the new agent has concrete deliverables. Start with a well-scoped task to evaluate quality.
|
|
60
|
-
7. **Monitor early performance**: During subsequent heartbeats, pay attention to new hires — are they producing quality work? Do they need guidance? Correct early and record lessons.
|
|
58
|
+
1. **Assess need**: Role/skills. `list_teams` + `agent_list_colleagues` to avoid duplicates.
|
|
59
|
+
2. **Pick a row from the table above** (team package vs single agent).
|
|
60
|
+
3. **Source**: `package_list` / `hub_search`, or design under `builder-artifacts` with building skills.
|
|
61
|
+
4. **Deploy**: `package_install` or `hub_install` (needs user approval).
|
|
62
|
+
5. **Onboard**: `agent_send_message` with context; then `task_create`.
|
|
63
|
+
6. **Monitor** on later heartbeats.
|
|
61
64
|
|
|
62
65
|
#### Custom Creation (using building skills)
|
|
63
66
|
|
|
64
|
-
- Design
|
|
65
|
-
-
|
|
66
|
-
-
|
|
67
|
+
- Design under `~/.markus/builder-artifacts/{agents|teams|skills}/{name}/` only — the install system ignores every other location
|
|
68
|
+
- Always write files with `file_write` (manifest first, then content files)
|
|
69
|
+
- Deploy only on explicit user request (“install” / “deploy” / “hire”) via `package_install`
|
|
67
70
|
|
|
68
71
|
#### Hub Sourcing
|
|
69
72
|
|
|
70
|
-
- `hub_search`
|
|
71
|
-
- `hub_install` to download and deploy in one step
|
|
73
|
+
- Prefer built-in `hub_search` → `hub_install` for find-and-deploy in one approval
|
|
72
74
|
- Onboard as above
|
|
73
75
|
|
|
74
76
|
#### Skill Management
|
|
75
77
|
|
|
76
|
-
-
|
|
78
|
+
- `package_list` / `package_install` for skills under `~/.markus/builder-artifacts/skills/`
|
|
77
79
|
- Recommend or install skills for team members based on their responsibilities
|
|
78
80
|
|
|
79
81
|
---
|
|
@@ -95,6 +97,7 @@ You maintain **per-user profiles** in `~/.markus/users/{userId}.md` and **team c
|
|
|
95
97
|
- **What they care about** — current projects, priorities, goals
|
|
96
98
|
- **What annoys them** — avoid these patterns proactively
|
|
97
99
|
- **Communication style** — terse vs. detailed, language preference, format preference
|
|
100
|
+
- **Language for artifacts** — when creating tasks, requirements, deliverables, or other user-visible records, use the user's preferred language (not English by default). Chat already follows their language; structured titles/descriptions must too.
|
|
98
101
|
- **Decision patterns** — what they approve quickly vs. deliberate on
|
|
99
102
|
|
|
100
103
|
**How to maintain:**
|
|
@@ -110,7 +110,7 @@ Follow the `skill-building` skill for the complete technical workflow: manifest
|
|
|
110
110
|
**Critical implementation rules:**
|
|
111
111
|
|
|
112
112
|
- **DO NOT** put file content in the JSON. Always use `file_write` for files.
|
|
113
|
-
- **The `name` field MUST be English kebab-case** (e.g
|
|
113
|
+
- **The `name` field MUST be a valid English kebab-case slug** (e.g. `git-changelog`, not `网页抓取器`). Chinese goes in `displayName` only — invalid `name` is rejected on write/save/share. Follow the `skill-building` skill Package Slug rules.
|
|
114
114
|
- The `name` field and `SKILL.md` frontmatter `name` must match exactly.
|
|
115
115
|
- **DO NOT** use names that conflict with built-in skills. Check the dynamic context for existing skill names.
|
|
116
116
|
- Skills should be self-contained: an agent reading the instructions should know exactly what to do.
|
|
@@ -272,7 +272,7 @@ Skill design is not done in isolation. Validate with the agents who will use the
|
|
|
272
272
|
|
|
273
273
|
- **DO NOT** use names that conflict with built-in skills. Check the dynamic context for existing skill names.
|
|
274
274
|
- **DO NOT** put file content in the JSON. Always use `file_write` for files.
|
|
275
|
-
- **The `name` field MUST be English kebab-case** (e.g
|
|
275
|
+
- **The `name` field MUST be a valid English kebab-case slug** (e.g. `git-changelog`, not `网页抓取器`). Chinese goes in `displayName` only — invalid `name` is rejected on write/save/share. Follow the `skill-building` skill Package Slug rules.
|
|
276
276
|
- The `name` field and `SKILL.md` frontmatter `name` must match exactly.
|
|
277
277
|
- Skills should be self-contained: an agent reading the instructions should know exactly what to do.
|
|
278
278
|
- **All skill artifacts MUST be written to `~/.markus/builder-artifacts/skills/{name}/`.**
|
|
@@ -43,7 +43,7 @@ You will receive the **live list** of available role templates, skills, and plat
|
|
|
43
43
|
- **DO NOT** invent role names or skill IDs. Only use values from the dynamic context.
|
|
44
44
|
- **DO NOT** leave skills empty when relevant skills are available. Review the skills list!
|
|
45
45
|
- **DO NOT** put file content in the JSON. Always use `file_write` for files.
|
|
46
|
-
- **The `name` field MUST be English kebab-case
|
|
46
|
+
- **The `name` field MUST be a valid English kebab-case slug** (e.g. `frontend-squad`). Chinese goes in `displayName` only — invalid `name` is rejected on write/save/share. Follow the `team-building` skill Package Slug rules.
|
|
47
47
|
- Every team MUST have exactly **one** member with `"role": "manager"` and at least **one** `"worker"`.
|
|
48
48
|
- Write each ROLE.md with **full attention** — at least 5 substantive paragraphs per member.
|
|
49
49
|
|
|
@@ -25,20 +25,39 @@ This skill teaches you how to create Markus agent packages — self-contained di
|
|
|
25
25
|
|
|
26
26
|
When the user **installs** the artifact, files are deployed to `~/.markus/agents/{agentId}/role/`. The `ROLE.md` becomes the agent's system prompt — it IS the agent's identity, not an override of a template.
|
|
27
27
|
|
|
28
|
+
## Package Slug (`name`) — REQUIRED
|
|
29
|
+
|
|
30
|
+
The manifest `name` is the **package slug**: directory name, Hub URL segment (`/@user/{slug}`), and share/publish id.
|
|
31
|
+
|
|
32
|
+
**Rules (hard — invalid manifests are rejected on write / save / share):**
|
|
33
|
+
- English **kebab-case** only: lowercase letters `a-z`, digits `0-9`, hyphens `-`
|
|
34
|
+
- 2–64 characters; must **start with a letter**
|
|
35
|
+
- Pattern examples: `code-reviewer`, `paper-mentor`, `seo-auditor`
|
|
36
|
+
- **NOT allowed**: Chinese (`智库研究团队`), spaces, underscores, UPPERCASE, emoji, or empty
|
|
37
|
+
- Put the human-readable title (any language) in **`displayName`**, never in `name`
|
|
38
|
+
|
|
39
|
+
| User language | `name` (slug) | `displayName` |
|
|
40
|
+
|---|---|---|
|
|
41
|
+
| Chinese “论文导师” | `paper-mentor` | `论文导师` |
|
|
42
|
+
| English “Code Reviewer” | `code-reviewer` | `Code Reviewer` |
|
|
43
|
+
|
|
44
|
+
If the user only gives a Chinese title, **you invent an English kebab slug** that captures the meaning, set `displayName` to their title, and use the slug for the directory path `~/.markus/builder-artifacts/agents/{name}/`.
|
|
45
|
+
|
|
28
46
|
## Two-Step Workflow
|
|
29
47
|
|
|
30
48
|
Output the agent in two steps — manifest first, then content files. **Never put file content inline in the JSON.**
|
|
31
49
|
|
|
32
|
-
###
|
|
50
|
+
### All modes (chat / task / A2A) — same rule
|
|
51
|
+
|
|
52
|
+
There is **no** chat auto-save. A JSON code block in your reply does **not** create files.
|
|
33
53
|
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
54
|
+
1. `file_write("~/.markus/builder-artifacts/agents/{name}/agent.json", ...)` for the manifest
|
|
55
|
+
2. `file_write` for each content file (ROLE.md, HEARTBEAT.md, …)
|
|
56
|
+
3. In task mode, set deliverable references to the artifact directory path
|
|
37
57
|
|
|
38
|
-
|
|
58
|
+
You may preview JSON in chat **in addition to** writing files — never instead of `file_write`.
|
|
39
59
|
|
|
40
|
-
|
|
41
|
-
**In task/A2A mode**: Write the manifest JSON file directly via `file_write`.
|
|
60
|
+
### Step 1: Write Manifest JSON via file_write
|
|
42
61
|
|
|
43
62
|
This JSON contains ONLY metadata — **no file content**.
|
|
44
63
|
|
|
@@ -65,7 +84,7 @@ This JSON contains ONLY metadata — **no file content**.
|
|
|
65
84
|
}
|
|
66
85
|
```
|
|
67
86
|
|
|
68
|
-
|
|
87
|
+
After `agent.json` is written, proceed to write the remaining files with `file_write`.
|
|
69
88
|
|
|
70
89
|
### Step 2: Write Files with file_write
|
|
71
90
|
|
|
@@ -115,7 +134,7 @@ file_write("~/.markus/builder-artifacts/agents/code-reviewer/POLICIES.md", "# Po
|
|
|
115
134
|
|
|
116
135
|
### Top-level fields
|
|
117
136
|
- **`type`**: Always `"agent"`
|
|
118
|
-
- **`name`**: **
|
|
137
|
+
- **`name`**: **Package slug** — English kebab-case only (see [Package Slug](#package-slug-name--required)). Invalid/save/share reject Chinese or invalid slugs.
|
|
119
138
|
- **`displayName`**: Human-readable name, can be in any language (e.g., `"论文学习导师"`, `"Code Reviewer"`)
|
|
120
139
|
- **`version`**: Semver (default `"1.0.0"`)
|
|
121
140
|
- **`description`**: What this agent does (can be in any language)
|
|
@@ -155,7 +174,7 @@ Once all files are written, tell the user:
|
|
|
155
174
|
- **DO NOT** put file content in the JSON. Always use `file_write` for files.
|
|
156
175
|
- **DO NOT** default skills to `[]` when relevant skills are available. Check the skills list!
|
|
157
176
|
- **DO NOT** write artifacts to `~/.markus/shared/` or your working directory. Always use `~/.markus/builder-artifacts/agents/{name}/`.
|
|
158
|
-
- **The `name` field MUST be English kebab-case
|
|
177
|
+
- **The `name` field MUST be a valid English kebab-case slug** (see Package Slug). Never use Chinese as `name`. Invalid `name` → write/save/share fails.
|
|
159
178
|
- **All top-level fields must be the correct type**: `author` must be a plain string (e.g. `"John"`) — NOT an object. `tags` must be an array of strings. `version` must be semver string. `description` must be a string. The system validates the manifest on write and will reject malformed files.
|
|
160
179
|
- The `ROLE.md` is what makes the agent unique — write at least 5 substantive paragraphs. A generic one-liner is useless.
|
|
161
180
|
- Default `temperature` to 0.7 for general tasks, lower (0.3-0.5) for precision tasks, higher (0.8-1.0) for creative tasks.
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"type": "skill",
|
|
3
3
|
"name": "agent-building",
|
|
4
4
|
"displayName": "Agent Building",
|
|
5
|
-
"version": "1.
|
|
5
|
+
"version": "1.1.0",
|
|
6
6
|
"description": "Design and create AI agent packages — manifest format, directory structure, file writing workflow, and field reference for Markus agent artifacts",
|
|
7
7
|
"author": "markus",
|
|
8
8
|
"category": "development",
|
|
@@ -175,8 +175,19 @@ function buildPayloadFromDir(dir) {
|
|
|
175
175
|
let readme;
|
|
176
176
|
if (files['README.md']) { readme = files['README.md']; delete files['README.md']; }
|
|
177
177
|
|
|
178
|
+
const slugSource = typeof config.name === 'string' ? config.name.trim() : '';
|
|
179
|
+
const slug = slugSource.toLowerCase().replace(/\s+/g, '-').replace(/[^a-z0-9-]/g, '').replace(/-+/g, '-').replace(/^-+|-+$/g, '');
|
|
180
|
+
if (!/^[a-z][a-z0-9]*(-[a-z0-9]+)*$/.test(slug) || slug.length < 2 || slug.length > 64) {
|
|
181
|
+
return {
|
|
182
|
+
error: 'Invalid package slug in manifest name. Use English kebab-case (e.g. "think-tank-research"): 2–64 chars, lowercase letters/digits/hyphens, must start with a letter. Put Chinese titles in displayName — Hub rejects Chinese or empty slugs.',
|
|
183
|
+
};
|
|
184
|
+
}
|
|
185
|
+
|
|
178
186
|
return {
|
|
179
|
-
itemType,
|
|
187
|
+
itemType,
|
|
188
|
+
name: config.displayName || config.name,
|
|
189
|
+
slug,
|
|
190
|
+
description: config.description,
|
|
180
191
|
category: config.category, tags: config.tags, config, files, readme,
|
|
181
192
|
};
|
|
182
193
|
}
|
|
@@ -37,16 +37,17 @@ When the user **installs** the artifact, the **entire directory** (all files) is
|
|
|
37
37
|
|
|
38
38
|
Output the skill in two steps — manifest first, then content files. **Never put file content inline in the JSON.**
|
|
39
39
|
|
|
40
|
-
###
|
|
40
|
+
### All modes (chat / task / A2A) — same rule
|
|
41
41
|
|
|
42
|
-
|
|
43
|
-
- **Task mode** (assigned task): Use `file_write` to write the manifest JSON file directly (e.g., `file_write("~/.markus/builder-artifacts/skills/{name}/skill.json", ...)`) → then use `file_write` for each content file. When submitting deliverables, set the reference to the artifact directory path.
|
|
44
|
-
- **A2A mode** (agent-to-agent): Same as task mode — write all files via `file_write`.
|
|
42
|
+
There is **no** chat auto-save. A JSON code block in your reply does **not** create files.
|
|
45
43
|
|
|
46
|
-
|
|
44
|
+
1. `file_write("~/.markus/builder-artifacts/skills/{name}/skill.json", ...)` for the manifest
|
|
45
|
+
2. `file_write` for each content file (SKILL.md, README, …)
|
|
46
|
+
3. In task mode, set deliverable references to the artifact directory path
|
|
47
47
|
|
|
48
|
-
|
|
49
|
-
|
|
48
|
+
You may preview JSON in chat **in addition to** writing files — never instead of `file_write`.
|
|
49
|
+
|
|
50
|
+
### Step 1: Write Manifest JSON via file_write
|
|
50
51
|
|
|
51
52
|
This JSON contains ONLY metadata — **no file content**.
|
|
52
53
|
|
|
@@ -98,7 +99,7 @@ This JSON contains ONLY metadata — **no file content**.
|
|
|
98
99
|
- Tool names exposed by MCP servers are automatically prefixed with the server name (e.g., `my-api__tool_name`). Mention these prefixed names in SKILL.md.
|
|
99
100
|
- You can also use externally published MCP servers: `"command": "npx", "args": ["-y", "some-mcp-server@latest"]`.
|
|
100
101
|
|
|
101
|
-
|
|
102
|
+
After `skill.json` is written, proceed to write the remaining files with `file_write`.
|
|
102
103
|
|
|
103
104
|
### Step 2: Write Files with file_write
|
|
104
105
|
|
|
@@ -126,11 +127,30 @@ file_write("~/.markus/builder-artifacts/skills/git-changelog/SKILL.md", "---\nna
|
|
|
126
127
|
file_write("~/.markus/builder-artifacts/skills/git-changelog/README.md", "# Git Changelog\n\nA skill that helps agents generate changelogs from git history...\n")
|
|
127
128
|
```
|
|
128
129
|
|
|
130
|
+
## Package Slug (`name`) — REQUIRED
|
|
131
|
+
|
|
132
|
+
The manifest `name` is the **package slug**: directory name, Hub URL segment (`/@user/{slug}`), SKILL.md frontmatter `name`, and share/publish id.
|
|
133
|
+
|
|
134
|
+
**Rules (hard — invalid manifests are rejected on write / save / share):**
|
|
135
|
+
- English **kebab-case** only: lowercase letters `a-z`, digits `0-9`, hyphens `-`
|
|
136
|
+
- 2–64 characters; must **start with a letter**
|
|
137
|
+
- Pattern examples: `git-changelog`, `web-scraper`, `pdf-summarizer`
|
|
138
|
+
- **NOT allowed**: Chinese (`网页抓取器`), spaces, underscores, UPPERCASE, emoji, or empty
|
|
139
|
+
- Put the human-readable title (any language) in **`displayName`**, never in `name`
|
|
140
|
+
- Manifest `name` and `SKILL.md` frontmatter `name` must match **exactly**
|
|
141
|
+
|
|
142
|
+
| User language | `name` (slug) | `displayName` |
|
|
143
|
+
|---|---|---|
|
|
144
|
+
| Chinese “网页抓取” | `web-scraper` | `网页抓取` |
|
|
145
|
+
| English “Git Changelog” | `git-changelog` | `Git Changelog` |
|
|
146
|
+
|
|
147
|
+
If the user only gives a Chinese title, **you invent an English kebab slug**, set `displayName` to their title, and use the slug for `~/.markus/builder-artifacts/skills/{name}/`.
|
|
148
|
+
|
|
129
149
|
## Field Reference
|
|
130
150
|
|
|
131
151
|
### Top-level fields
|
|
132
152
|
- **`type`**: Always `"skill"`
|
|
133
|
-
- **`name`**: **
|
|
153
|
+
- **`name`**: **Package slug** — English kebab-case only (see [Package Slug](#package-slug-name--required)). Write/save/share reject Chinese or invalid slugs. Must match `SKILL.md` frontmatter `name`.
|
|
134
154
|
- **`displayName`**: Human-readable skill name, can be in any language
|
|
135
155
|
- **`version`**: Semver (default `"1.0.0"`)
|
|
136
156
|
- **`description`**: When and why an agent should use this skill (can be in any language)
|
|
@@ -170,6 +190,6 @@ Once all files are written, tell the user:
|
|
|
170
190
|
- **DO NOT** use names that conflict with built-in skills. Check the dynamic context for existing skill names.
|
|
171
191
|
- **DO NOT** put file content in the JSON. Always use `file_write` for files.
|
|
172
192
|
- **DO NOT** write artifacts to `~/.markus/shared/` or your working directory. Always use `~/.markus/builder-artifacts/skills/{name}/`.
|
|
173
|
-
- **The `name` field MUST be English kebab-case** (
|
|
193
|
+
- **The `name` field MUST be a valid English kebab-case slug** (see Package Slug). Never use Chinese as `name`. Invalid `name` → write/save/share fails.
|
|
174
194
|
- The `name` field and `SKILL.md` frontmatter `name` must match exactly.
|
|
175
195
|
- **All top-level fields must be the correct type**: `author` must be a plain string (your name, e.g. `"John"`) — NOT an object. `tags` must be an array of strings. `version` must be semver string. `description` must be a string. The system validates the manifest on write and will reject malformed files.
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"type": "skill",
|
|
3
3
|
"name": "skill-building",
|
|
4
4
|
"displayName": "Skill Building",
|
|
5
|
-
"version": "1.
|
|
5
|
+
"version": "1.1.0",
|
|
6
6
|
"description": "Design and create agent skill packages — instruction-based and MCP-based skills, manifest format, directory structure for Markus skill artifacts",
|
|
7
7
|
"author": "markus",
|
|
8
8
|
"category": "development",
|