diff --git a/pilot/base_modules/agent/commands/command_mange.py b/pilot/base_modules/agent/commands/command_mange.py index 4fbaa6dc9..ce1679f18 100644 --- a/pilot/base_modules/agent/commands/command_mange.py +++ b/pilot/base_modules/agent/commands/command_mange.py @@ -267,8 +267,12 @@ class ApiCall: all_context = self.__deal_error_md_tags( all_context, api_context ) + # all_context = all_context.replace( + # api_context, api_status.api_result + # ) + all_context = all_context.replace( - api_context, api_status.api_result + api_context, self.to_view_antv_vis(api_status) ) else: if api_status.status == Status.FAILED.value: @@ -335,6 +339,7 @@ class ApiCall: else: api_status.location.append(api_index) + def __to_view_param_str(self, api_status): param = {} if api_status.name: @@ -356,6 +361,27 @@ class ApiCall: result = ET.tostring(api_call_element, encoding="utf-8") return result.decode("utf-8") + def to_view_antv_vis(self, api_status: PluginStatus): + api_call_element = ET.Element("chart-view") + api_call_element.text = self.__to_antv_vis_param(api_status) + result = ET.tostring(api_call_element, encoding="utf-8") + return result.decode("utf-8") + + def __to_antv_vis_param(self, api_status: PluginStatus): + param = {} + if api_status.name: + param["type"] = api_status.name + if api_status.args: + param["sql"] = api_status.args["sql"] + + if api_status.err_msg: + param["err_msg"] = api_status.err_msg + + if api_status.api_result: + param["data"] = api_status.api_result + + return json.dumps(param) + def run(self, llm_text): if self.__is_need_wait_plugin_call(llm_text): # wait api call generate complete @@ -406,3 +432,38 @@ class ApiCall: value.err_msg = str(e) value.end_time = datetime.now().timestamp() * 1000 return self.api_view_context(llm_text, True) + + + def display_sql_llmvis(self, llm_text, sql_run_func): + """ + Render charts using the Antv standard protocol + Args: + llm_text: LLM response text + sql_run_func: sql run function + + Returns: + ChartView protocol text + """ + if self.__is_need_wait_plugin_call(llm_text): + # wait api call generate complete + if self.check_last_plugin_call_ready(llm_text): + self.update_from_context(llm_text) + for key, value in self.plugin_status_map.items(): + if value.status == Status.TODO.value: + value.status = Status.RUNNING.value + logging.info(f"sql展示执行:{value.name},{value.args}") + try: + sql = value.args["sql"] + if sql is not None and len(sql) > 0: + data_df = sql_run_func(sql) + value.api_result = data_df.apply(lambda row: row.to_dict(), axis=1).to_list() + value.status = Status.COMPLETED.value + else: + value.status = Status.FAILED.value + value.err_msg = "No executable sql!" + + except Exception as e: + value.status = Status.FAILED.value + value.err_msg = str(e) + value.end_time = datetime.now().timestamp() * 1000 + return self.api_view_context(llm_text, True) \ No newline at end of file diff --git a/pilot/scene/chat_data/chat_excel/excel_analyze/chat.py b/pilot/scene/chat_data/chat_excel/excel_analyze/chat.py index 9a316cd34..a3dd989d5 100644 --- a/pilot/scene/chat_data/chat_excel/excel_analyze/chat.py +++ b/pilot/scene/chat_data/chat_excel/excel_analyze/chat.py @@ -22,7 +22,7 @@ class ChatExcel(BaseChat): """a Excel analyzer to analyze Excel Data""" chat_scene: str = ChatScene.ChatExcel.value() - chat_retention_rounds = 1 + chat_retention_rounds = 2 def __init__(self, chat_param: Dict): """Chat Excel Module Initialization @@ -88,4 +88,4 @@ class ChatExcel(BaseChat): def stream_plugin_call(self, text): text = text.replace("\n", " ") - return self.api_call.run_display_sql(text, self.excel_reader.get_df_by_sql_ex) + return self.api_call.display_sql_llmvis(text, self.excel_reader.get_df_by_sql_ex) diff --git a/pilot/scene/chat_data/chat_excel/excel_learning/prompt.py b/pilot/scene/chat_data/chat_excel/excel_learning/prompt.py index ee82b51a0..fbc24b28e 100644 --- a/pilot/scene/chat_data/chat_excel/excel_learning/prompt.py +++ b/pilot/scene/chat_data/chat_excel/excel_learning/prompt.py @@ -33,11 +33,18 @@ _DEFAULT_TEMPLATE_ZH = """ {response} """ -RESPONSE_FORMAT_SIMPLE = { +_RESPONSE_FORMAT_SIMPLE_ZH = { "DataAnalysis": "数据内容分析总结", "ColumnAnalysis": [{"column name1": "字段1介绍,专业术语解释(请尽量简单明了)"}], "AnalysisProgram": ["1.分析方案1,图表展示方式1", "2.分析方案2,图表展示方式2"], } +_RESPONSE_FORMAT_SIMPLE_EN = { + "DataAnalysis": "Data content analysis summary", + "ColumnAnalysis": [{"column name1": "Introduction to Column 1 and explanation of professional terms (please try to be as simple and clear as possible)"}], + "AnalysisProgram": ["1. Analysis plan 1, chart display type 1", "2. Analysis plan 2, chart display type 2"], +} + +RESPONSE_FORMAT_SIMPLE =(_RESPONSE_FORMAT_SIMPLE_EN if CFG.LANGUAGE == "en" else _RESPONSE_FORMAT_SIMPLE_ZH) _DEFAULT_TEMPLATE = ( diff --git a/pilot/server/static/404.html b/pilot/server/static/404.html index 1a5fba1f0..a21d62a3d 100644 --- a/pilot/server/static/404.html +++ b/pilot/server/static/404.html @@ -1 +1 @@ -
f&&(f=w),M c&&(d-=2*Math.PI),!s&&c>d&&(c-=2*Math.PI)}var R=c-d;if(Math.abs(R)>m){var L=c,N=a,I=l;E=g(a=p+i*Math.cos(c=d+m*(s&&c>d?1:-1)),l=f+n*Math.sin(c),i,n,r,0,s,N,I,[c,L,p,f])}R=c-d;var w=Math.cos(d),O=Math.cos(c),x=Math.tan(R/4),D=4/3*i*x,M=4/3*n*x,k=[e,t],P=[e+D*Math.sin(d),t-M*w],F=[a+D*Math.sin(c),l-M*O],B=[a,l];if(P[0]=2*k[0]-P[0],P[1]=2*k[1]-P[1],h)return[P,F,B].concat(E);E=[P,F,B].concat(E).join().split(",");for(var U=[],H=0,V=E.length;Hu){C=w;break}N+=M}p[f]=(p[f]||"").slice(0,C)+h}break}if(d=0,p[++f]="",this.isBreakingSpace(x))continue;this.canBreakInLastChar(x)||(p=this.trimToBreakable(p),d=this.sumTextWidthByCache(p[f]||"",v)),this.shouldBreakByKinsokuShorui(x,T)&&(p=this.trimByKinsokuShorui(p),d+=y(b||""))}d+=P,p[f]=(p[f]||"")+x}return p.join("\n")},t.prototype.isBreakingSpace=function(t){return"string"==typeof t&&rA.BreakingSpaces.indexOf(t.charCodeAt(0))>=0},t.prototype.isNewline=function(t){return"string"==typeof t&&rA.Newlines.indexOf(t.charCodeAt(0))>=0},t.prototype.trimToBreakable=function(t){var e=(0,W.ev)([],(0,W.CR)(t),!1),n=e[e.length-2],r=this.findBreakableIndex(n);if(-1===r||!n)return e;var i=n.slice(r,r+1),o=this.isBreakingSpace(i),a=r+1,s=r+(o?0:1);return e[e.length-1]+=n.slice(a,n.length),e[e.length-2]=n.slice(0,s),e},t.prototype.canBreakInLastChar=function(t){return!(t&&rO.test(t))},t.prototype.sumTextWidthByCache=function(t,e){return t.split("").reduce(function(t,n){if(!e[n])throw Error("cannot count the word without cache");return t+e[n]},0)},t.prototype.findBreakableIndex=function(t){for(var e=t.length-1;e>=0;e--)if(!rO.test(t[e]))return e;return -1},t.prototype.getFromCache=function(t,e,n,r){var i=n[t];if("number"!=typeof i){var o=t.length*e;i=r.measureText(t).width+o,n[t]=i}return i},t}(),rG={},r_=(T=new rf,P=new rp,(b={})[M.CIRCLE]=new rl,b[M.ELLIPSE]=new rc,b[M.RECT]=T,b[M.IMAGE]=T,b[M.GROUP]=T,b[M.LINE]=new ru,b[M.TEXT]=new rd(rG),b[M.POLYLINE]=P,b[M.POLYGON]=P,b[M.PATH]=new rh,b[M.HTML]=null,b[M.MESH]=null,b),rF=(N=new nC,C=new nk,(S={})[Y.PERCENTAGE]=null,S[Y.NUMBER]=new nG,S[Y.ANGLE]=new nS,S[Y.DEFINED_PATH]=new nN,S[Y.PAINT]=N,S[Y.COLOR]=N,S[Y.FILTER]=new nw,S[Y.LENGTH]=C,S[Y.LENGTH_PERCENTAGE]=C,S[Y.LENGTH_PERCENTAGE_12]=new nR,S[Y.LENGTH_PERCENTAGE_14]=new nA,S[Y.COORDINATE]=new nI,S[Y.OFFSET_DISTANCE]=new n_,S[Y.OPACITY_VALUE]=new nF,S[Y.PATH]=new nB,S[Y.LIST_OF_POINTS]=new nU,S[Y.SHADOW_BLUR]=new nZ,S[Y.TEXT]=new nV,S[Y.TEXT_TRANSFORM]=new nY,S[Y.TRANSFORM]=new ra,S[Y.TRANSFORM_ORIGIN]=new function(){this.parser=ny},S[Y.Z_INDEX]=new rs,S[Y.MARKER]=new nD,S);rG.CameraContribution=t$,rG.AnimationTimeline=null,rG.EasingFunction=null,rG.offscreenCanvasCreator=new rP,rG.nativeHTMLMap=new WeakMap,rG.sceneGraphSelector=new rC,rG.sceneGraphService=new rR(rG),rG.textService=new rD(rG),rG.geometryUpdaterFactory=r_,rG.CSSPropertySyntaxFactory=rF,rG.styleValueRegistry=new nP(rG),rG.layoutRegistry=null,rG.globalThis="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:void 0!==n.g?n.g:{},rG.enableCSSParsing=!0,rG.enableDataset=!1,rG.enableStyleSyntax=!0;var rB=0,rU=new rw(H.INSERTED,null,"","","",0,"",""),rZ=new rw(H.REMOVED,null,"","","",0,"",""),rV=new rE(H.DESTROY),rY=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.entity=rB++,e.renderable={bounds:void 0,boundsDirty:!0,renderBounds:void 0,renderBoundsDirty:!0,dirtyRenderBounds:void 0,dirty:!1},e.cullable={strategy:Z.Standard,visibilityPlaneMask:-1,visible:!0,enable:!0},e.transformable={dirtyFlag:!1,localDirtyFlag:!1,frozen:!1,localPosition:[0,0,0],localRotation:[0,0,0,1],localScale:[1,1,1],localTransform:[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1],localSkew:[0,0],position:[0,0,0],rotation:[0,0,0,1],scaling:[1,1,1],worldTransform:[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1],origin:[0,0,0]},e.sortable={dirty:!1,sorted:void 0,renderOrder:0,dirtyChildren:[],dirtyReason:void 0},e.geometry={contentBounds:void 0,renderBounds:void 0},e.rBushNode={aabb:void 0},e.namespaceURI="g",e.scrollLeft=0,e.scrollTop=0,e.clientTop=0,e.clientLeft=0,e.destroyed=!1,e.style={},e.computedStyle=rG.enableCSSParsing?{anchor:eu,opacity:eu,fillOpacity:eu,strokeOpacity:eu,fill:eu,stroke:eu,transform:eu,transformOrigin:eu,visibility:eu,pointerEvents:eu,lineWidth:eu,lineCap:eu,lineJoin:eu,increasedLineWidthForHitTesting:eu,fontSize:eu,fontFamily:eu,fontStyle:eu,fontWeight:eu,fontVariant:eu,textAlign:eu,textBaseline:eu,textTransform:eu,zIndex:eu,filter:eu,shadowType:eu}:null,e.parsedStyle={},e.attributes={},e}return(0,W.ZT)(e,t),Object.defineProperty(e.prototype,"className",{get:function(){return this.getAttribute("class")||""},set:function(t){this.setAttribute("class",t)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"classList",{get:function(){return this.className.split(" ").filter(function(t){return""!==t})},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"tagName",{get:function(){return this.nodeName},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"children",{get:function(){return this.childNodes},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"childElementCount",{get:function(){return this.childNodes.length},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"firstElementChild",{get:function(){return this.firstChild},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"lastElementChild",{get:function(){return this.lastChild},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"parentElement",{get:function(){return this.parentNode},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"nextSibling",{get:function(){if(this.parentNode){var t=this.parentNode.childNodes.indexOf(this);return this.parentNode.childNodes[t+1]||null}return null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"previousSibling",{get:function(){if(this.parentNode){var t=this.parentNode.childNodes.indexOf(this);return this.parentNode.childNodes[t-1]||null}return null},enumerable:!1,configurable:!0}),e.prototype.cloneNode=function(t){throw Error(tK)},e.prototype.appendChild=function(t,e){var n;if(t.destroyed)throw Error("Cannot append a destroyed element.");return rG.sceneGraphService.attach(t,this,e),(null===(n=this.ownerDocument)||void 0===n?void 0:n.defaultView)&&this.ownerDocument.defaultView.mountChildren(t),rU.relatedNode=this,t.dispatchEvent(rU),t},e.prototype.insertBefore=function(t,e){if(e){var n=this.childNodes.indexOf(e);this.appendChild(t,n-1)}else this.appendChild(t);return t},e.prototype.replaceChild=function(t,e){var n=this.childNodes.indexOf(e);return this.removeChild(e),this.appendChild(t,n),e},e.prototype.removeChild=function(t){var e;return rZ.relatedNode=this,t.dispatchEvent(rZ),(null===(e=t.ownerDocument)||void 0===e?void 0:e.defaultView)&&t.ownerDocument.defaultView.unmountChildren(t),rG.sceneGraphService.detach(t),t},e.prototype.removeChildren=function(){for(var t=this.childNodes.length-1;t>=0;t--){var e=this.childNodes[t];this.removeChild(e)}},e.prototype.destroyChildren=function(){for(var t=this.childNodes.length-1;t>=0;t--){var e=this.childNodes[t];e.childNodes.length&&e.destroyChildren(),e.destroy()}},e.prototype.matches=function(t){return rG.sceneGraphService.matches(t,this)},e.prototype.getElementById=function(t){return rG.sceneGraphService.querySelector("#".concat(t),this)},e.prototype.getElementsByName=function(t){return rG.sceneGraphService.querySelectorAll('[name="'.concat(t,'"]'),this)},e.prototype.getElementsByClassName=function(t){return rG.sceneGraphService.querySelectorAll(".".concat(t),this)},e.prototype.getElementsByTagName=function(t){return rG.sceneGraphService.querySelectorAll(t,this)},e.prototype.querySelector=function(t){return rG.sceneGraphService.querySelector(t,this)},e.prototype.querySelectorAll=function(t){return rG.sceneGraphService.querySelectorAll(t,this)},e.prototype.closest=function(t){var e=this;do{if(rG.sceneGraphService.matches(t,e))return e;e=e.parentElement}while(null!==e);return null},e.prototype.find=function(t){var e=this,n=null;return this.forEach(function(r){return!!(r!==e&&t(r))&&(n=r,!0)}),n},e.prototype.findAll=function(t){var e=this,n=[];return this.forEach(function(r){r!==e&&t(r)&&n.push(r)}),n},e.prototype.after=function(){for(var t=this,e=[],n=0;n=1?Math.ceil(M):1,C=l||("auto"===(n=nq(a,"width"))?a.offsetWidth:parseFloat(n))||a.width/M,w=c||("auto"===(r=nq(a,"height"))?a.offsetHeight:parseFloat(r))||a.height/M),s&&(rG.offscreenCanvas=s),i.devicePixelRatio=M,i.requestAnimationFrame=null!=v?v:n6.bind(rG.globalThis),i.cancelAnimationFrame=null!=y?y:n7.bind(rG.globalThis),i.supportsTouchEvents=null!=E?E:"ontouchstart"in rG.globalThis,i.supportsPointerEvents=null!=m?m:!!rG.globalThis.PointerEvent,i.isTouchEvent=null!=S?S:function(t){return i.supportsTouchEvents&&t instanceof rG.globalThis.TouchEvent},i.isMouseEvent=null!=N?N:function(t){return!rG.globalThis.MouseEvent||t instanceof rG.globalThis.MouseEvent&&(!i.supportsPointerEvents||!(t instanceof rG.globalThis.PointerEvent))},i.initRenderingContext({container:o,canvas:a,width:C,height:w,renderer:h,offscreenCanvas:s,devicePixelRatio:M,cursor:f||"default",background:p||"transparent",createImage:g,document:d,supportsCSSTransform:x,useNativeClickEvent:T,alwaysTriggerPointerEventOnCanvas:P}),i.initDefaultCamera(C,w,h.clipSpaceNearZ),i.initRenderer(h,!0),i}return(0,W.ZT)(e,t),e.prototype.initRenderingContext=function(t){this.context.config=t,this.context.renderingContext={root:this.document.documentElement,renderListCurrentFrame:[],unculledEntities:[],renderReasons:new Set,force:!1,dirty:!1}},e.prototype.initDefaultCamera=function(t,e,n){var r=this,i=new rG.CameraContribution;i.clipSpaceNearZ=n,i.setType(A.EXPLORING,O.DEFAULT).setPosition(t/2,e/2,500).setFocalPoint(t/2,e/2,0).setOrthographic(-(t/2),t/2,e/2,-(e/2),.1,1e3),i.canvas=this,i.eventEmitter.on(tJ.UPDATED,function(){r.context.renderingContext.renderReasons.add(X.CAMERA_CHANGED)}),this.context.camera=i},e.prototype.getConfig=function(){return this.context.config},e.prototype.getRoot=function(){return this.document.documentElement},e.prototype.getCamera=function(){return this.context.camera},e.prototype.getContextService=function(){return this.context.contextService},e.prototype.getEventService=function(){return this.context.eventService},e.prototype.getRenderingService=function(){return this.context.renderingService},e.prototype.getRenderingContext=function(){return this.context.renderingContext},e.prototype.getStats=function(){return this.getRenderingService().getStats()},Object.defineProperty(e.prototype,"ready",{get:function(){var t=this;return!this.readyPromise&&(this.readyPromise=new Promise(function(e){t.resolveReadyPromise=function(){e(t)}}),this.inited&&this.resolveReadyPromise()),this.readyPromise},enumerable:!1,configurable:!0}),e.prototype.destroy=function(t,e){void 0===t&&(t=!0),void 0===e&&(e=!1),e||this.dispatchEvent(new rE(j.BEFORE_DESTROY)),this.frameId&&(this.getConfig().cancelAnimationFrame||cancelAnimationFrame)(this.frameId);var n=this.getRoot();this.unmountChildren(n),t&&(this.document.destroy(),this.getEventService().destroy()),this.getRenderingService().destroy(),this.getContextService().destroy(),t&&this.context.rBushRoot&&(this.context.rBushRoot.clear(),this.context.rBushRoot=null,this.context.renderingContext.root=null),e||this.dispatchEvent(new rE(j.AFTER_DESTROY))},e.prototype.changeSize=function(t,e){this.resize(t,e)},e.prototype.resize=function(t,e){var n=this.context.config;n.width=t,n.height=e,this.getContextService().resize(t,e);var r=this.context.camera,i=r.getProjectionMode();r.setPosition(t/2,e/2,500).setFocalPoint(t/2,e/2,0),i===L.ORTHOGRAPHIC?r.setOrthographic(-(t/2),t/2,e/2,-(e/2),r.getNear(),r.getFar()):r.setAspect(t/e),this.dispatchEvent(new rE(j.RESIZE,{width:t,height:e}))},e.prototype.appendChild=function(t,e){return this.document.documentElement.appendChild(t,e)},e.prototype.insertBefore=function(t,e){return this.document.documentElement.insertBefore(t,e)},e.prototype.removeChild=function(t){return this.document.documentElement.removeChild(t)},e.prototype.removeChildren=function(){this.document.documentElement.removeChildren()},e.prototype.destroyChildren=function(){this.document.documentElement.destroyChildren()},e.prototype.render=function(){var t=this;this.dispatchEvent(ih),this.getRenderingService().render(this.getConfig(),function(){t.dispatchEvent(ip)}),this.dispatchEvent(id)},e.prototype.run=function(){var t=this,e=function(){t.render(),t.frameId=t.requestAnimationFrame(e)};e()},e.prototype.initRenderer=function(t,e){var n=this;if(void 0===e&&(e=!1),!t)throw Error("Renderer is required.");this.inited=!1,this.readyPromise=void 0,this.context.rBushRoot=new tN,this.context.renderingPlugins=[],this.context.renderingPlugins.push(new io,new il,new ii([new is])),this.loadRendererContainerModule(t),this.context.contextService=new this.context.ContextService((0,W.pi)((0,W.pi)({},rG),this.context)),this.context.renderingService=new rS(rG,this.context),this.context.eventService=new rT(rG,this.context),this.context.eventService.init(),this.context.contextService.init?(this.context.contextService.init(),this.initRenderingService(t,e,!0)):this.context.contextService.initAsync().then(function(){n.initRenderingService(t,e)})},e.prototype.initRenderingService=function(t,e,n){var r=this;void 0===e&&(e=!1),void 0===n&&(n=!1),this.context.renderingService.init(function(){r.inited=!0,e?(n?r.requestAnimationFrame(function(){r.dispatchEvent(new rE(j.READY))}):r.dispatchEvent(new rE(j.READY)),r.readyPromise&&r.resolveReadyPromise()):r.dispatchEvent(new rE(j.RENDERER_CHANGED)),e||r.getRoot().forEach(function(t){var e=t.renderable;e&&(e.renderBoundsDirty=!0,e.boundsDirty=!0,e.dirty=!0)}),r.mountChildren(r.getRoot()),t.getConfig().enableAutoRendering&&r.run()})},e.prototype.loadRendererContainerModule=function(t){var e=this;t.getPlugins().forEach(function(t){t.context=e.context,t.init(rG)})},e.prototype.setRenderer=function(t){var e=this.getConfig();if(e.renderer!==t){var n=e.renderer;e.renderer=t,this.destroy(!1,!0),(0,W.ev)([],(0,W.CR)(null==n?void 0:n.getPlugins()),!1).reverse().forEach(function(t){t.destroy(rG)}),this.initRenderer(t)}},e.prototype.setCursor=function(t){this.getConfig().cursor=t,this.getContextService().applyCursorStyle(t)},e.prototype.unmountChildren=function(t){var e=this;t.childNodes.forEach(function(t){e.unmountChildren(t)}),this.inited&&(t.isMutationObserved?t.dispatchEvent(iu):(iu.target=t,this.dispatchEvent(iu,!0)),t!==this.document.documentElement&&(t.ownerDocument=null),t.isConnected=!1),t.isCustomElement&&t.disconnectedCallback&&t.disconnectedCallback()},e.prototype.mountChildren=function(t){var e=this;this.inited?t.isConnected||(t.ownerDocument=this.document,t.isConnected=!0,t.isMutationObserved?t.dispatchEvent(ic):(ic.target=t,this.dispatchEvent(ic,!0))):console.warn("[g]: You are trying to call `canvas.appendChild` before canvas' initialization finished. You can either await `canvas.ready` or listen to `CanvasEvent.READY` manually.","appended child: ",t.nodeName),t.childNodes.forEach(function(t){e.mountChildren(t)}),t.isCustomElement&&t.connectedCallback&&t.connectedCallback()},e.prototype.client2Viewport=function(t){return this.getEventService().client2Viewport(t)},e.prototype.viewport2Client=function(t){return this.getEventService().viewport2Client(t)},e.prototype.viewport2Canvas=function(t){return this.getEventService().viewport2Canvas(t)},e.prototype.canvas2Viewport=function(t){return this.getEventService().canvas2Viewport(t)},e.prototype.getPointByClient=function(t,e){return this.client2Viewport({x:t,y:e})},e.prototype.getClientByPoint=function(t,e){return this.viewport2Client({x:t,y:e})},e}(rx)}}]);
\ No newline at end of file
diff --git a/pilot/server/static/_next/static/chunks/367-2a6e805cba0c79d3.js b/pilot/server/static/_next/static/chunks/367-2a6e805cba0c79d3.js
new file mode 100644
index 000000000..47c9cf585
--- /dev/null
+++ b/pilot/server/static/_next/static/chunks/367-2a6e805cba0c79d3.js
@@ -0,0 +1,78 @@
+"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[367],{27547:function(e,t,n){var r=n(64836);t.Z=void 0;var l=r(n(64938)),o=n(85893),a=(0,l.default)((0,o.jsx)("path",{d:"M12 12.75c1.63 0 3.07.39 4.24.9 1.08.48 1.76 1.56 1.76 2.73V18H6v-1.61c0-1.18.68-2.26 1.76-2.73 1.17-.52 2.61-.91 4.24-.91zM4 13c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zm1.13 1.1c-.37-.06-.74-.1-1.13-.1-.99 0-1.93.21-2.78.58C.48 14.9 0 15.62 0 16.43V18h4.5v-1.61c0-.83.23-1.61.63-2.29zM20 13c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zm4 3.43c0-.81-.48-1.53-1.22-1.85-.85-.37-1.79-.58-2.78-.58-.39 0-.76.04-1.13.1.4.68.63 1.46.63 2.29V18H24v-1.57zM12 6c1.66 0 3 1.34 3 3s-1.34 3-3 3-3-1.34-3-3 1.34-3 3-3z"}),"Groups");t.Z=a},15398:function(e,t,n){var r=n(64836);t.Z=void 0;var l=r(n(64938)),o=n(85893),a=(0,l.default)((0,o.jsx)("path",{d:"M12 12c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm0 2c-2.67 0-8 1.34-8 4v2h16v-2c0-2.66-5.33-4-8-4z"}),"Person");t.Z=a},57838:function(e,t,n){n.d(t,{Z:function(){return l}});var r=n(67294);function l(){let[,e]=r.useReducer(e=>e+1,0);return e}},84567:function(e,t,n){n.d(t,{Z:function(){return w}});var r=n(94184),l=n.n(r),o=n(50132),a=n(67294),i=n(53124),c=n(98866),s=n(65223);let u=a.createContext(null);var d=n(63185),f=n(45353),p=n(17415),m=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var l=0,r=Object.getOwnPropertySymbols(e);lh&&(h=g)}for(var p=Math.atan(n/(i*Math.tan(r))),f=1/0,m=-1/0,v=[o,s],d=-(2*Math.PI);d<=2*Math.PI;d+=Math.PI){var E=p+d;om&&(m=_)}return{x:l,y:f,width:h-l,height:m-f}},length:function(e,t,i,n,r,o,s){},nearestPoint:function(e,t,i,n,r,o,s,a,l){var h,u=N(a-e,l-t,-r),d=u[0],c=u[1],g=b.nearestPoint(0,0,i,n,d,c),p=(h=g.x,(Math.atan2(g.y*i,h*n)+2*Math.PI)%(2*Math.PI));pi[1].x?(c=i[0],h=i[1],u=i[2],d=i[3],g=(a=a7(r,Math.min(c.x-h.x,h.y-u.y)))[0],m=a[1],f=a[2],p=a[3]):(p=(l=a7(r,Math.min(c.x-h.x,h.y-u.y)))[0],f=l[1],m=l[2],g=l[3])),(v=[]).push(["M",u.x,u.y+g]),0!==g&&v.push(["A",g,g,0,0,1,u.x+g,u.y]),v.push(["L",d.x-p,d.y]),0!==p&&v.push(["A",p,p,0,0,1,d.x,d.y+p]),v.push(["L",c.x,c.y-f]),0!==f&&v.push(["A",f,f,0,0,1,c.x-f,c.y]),v.push(["L",h.x+m,h.y]),0!==m&&v.push(["A",m,m,0,0,1,h.x,h.y-m]),v.push(["L",u.x,u.y+g]),v.push(["z"]),L=v):L=this.parsePath((E=e.points,_=N.lineCap,S=(C=this.coordinate).getWidth(),y=C.getHeight(),T="rect"===C.type,b=[],A=(E[2].x-E[1].x)/2,R=C.isTransposed?A*y/S:A*S/y,"round"===_?(T?(b.push(["M",E[0].x,E[0].y+R]),b.push(["L",E[1].x,E[1].y-R]),b.push(["A",A,A,0,0,1,E[2].x,E[2].y-R]),b.push(["L",E[3].x,E[3].y+R]),b.push(["A",A,A,0,0,1,E[0].x,E[0].y+R])):(b.push(["M",E[0].x,E[0].y]),b.push(["L",E[1].x,E[1].y]),b.push(["A",A,A,0,0,1,E[2].x,E[2].y]),b.push(["L",E[3].x,E[3].y]),b.push(["A",A,A,0,0,1,E[0].x,E[0].y])),b.push(["z"])):b=a9(E),b));var D=I.addShape("path",{attrs:(0,ef.pi)((0,ef.pi)({},N),{path:L}),name:"interval"});return w?I:D},getMarker:function(e){var t=e.color;return e.isInPolar?{symbol:"circle",style:{r:4.5,fill:t}}:{symbol:"square",style:{r:4,fill:t}}}});var li=function(e){function t(t){var i=e.call(this,t)||this;i.type="interval",i.shapeType="interval",i.generatePoints=!0;var n=t.background;return i.background=n,i}return(0,ef.ZT)(t,e),t.prototype.createShapePointsCfg=function(t){var i,n=e.prototype.createShapePointsCfg.call(this,t),r=this.getAttribute("size");return r?i=this.getAttributeValues(r,t)[0]/rt(this.coordinate):(this.defaultSize||(this.defaultSize=lt(this)),i=this.defaultSize),n.size=i,n},t.prototype.adjustScale=function(){e.prototype.adjustScale.call(this);var t,i=this.getYScale();if("theta"===this.coordinate.type)i.change({nice:!1,min:0,max:(t=i.values.filter(function(e){return!(0,em.UM)(e)&&!isNaN(e)}),Math.max.apply(Math,(0,ef.ev)((0,ef.ev)([],t,!1),[(0,em.UM)(i.max)?-1/0:i.max],!1)))});else{var n=this.scaleDefs,r=i.field,o=i.min,s=i.max;"time"!==i.type&&(o>0&&!(0,em.U2)(n,[r,"min"])&&i.change({min:0}),s<=0&&!(0,em.U2)(n,[r,"max"])&&i.change({max:0}))}},t.prototype.getDrawCfg=function(t){var i=e.prototype.getDrawCfg.call(this,t);return i.background=this.background,i},t}(oJ),ln=function(e){function t(t){var i=e.call(this,t)||this;i.type="line";var n=t.sortable;return i.sortable=void 0!==n&&n,i}return(0,ef.ZT)(t,e),t}(a0),lr=["circle","square","bowtie","diamond","hexagon","triangle","triangle-down"];function lo(e,t,i,n,r){var o=aX(t,r,!r,"r"),s=e.parsePoints(t.points),a=s[0];if(t.isStack)a=s[1];else if(s.length>1){for(var l=i.addGroup(),h=0;h