| 1 |
- import{y as o}from"./index-bfAIUuub.js";function l(t){return{all:t=t||new Map,on:function(e,i){var n=t.get(e);n?n.push(i):t.set(e,[i])},off:function(e,i){var n=t.get(e);n&&(i?n.splice(n.indexOf(i)>>>0,1):t.set(e,[]))},emit:function(e,i){var n=t.get(e);n&&n.slice().map(function(a){a(i)}),(n=t.get("*"))&&n.slice().map(function(a){a(e,i)})}}}class s{constructor(e){this.event_name=e,this.emitter=l()}on(e){typeof e=="function"&&this.emitter.on(this.event_name,i=>{e(i)})}emit(e){this.emitter.emit(this.event_name,e)}off(){this.emitter.off(this.event_name)}}new s("theme_change");const c=new s("knowledge_search"),E=new s("intelligent_search"),g=new s("intelligent_edit");function m(t,e,i,n="0"){const a=n=="1"?`/api/knowledge/list?current=${t}&pageSize=${e}&keyword=${i}&location=${n}`:`/api/knowledge/list?current=${t}&pageSize=${e}&keyword=${i}`;return o({url:a,method:"get"})}function u(t){return o({url:"/api/knowledge/create",method:"post",data:t})}const f={RAGFLOW:"1",BS:"2",BASIC:"3",DIFY:"4"},p=()=>[{name:"问答助理",description:"EMBEDDING,SPEECH2TEXT,MODERATION",labels:"LLM,TEXT",type:"ragflow"},{name:"工作流助手",description:"EMBEDDING,SPEECH2TEXT,MODERATION",labels:"LLM,TEXT",type:"advanced-chat"},{name:"智能Agent",description:"EMBEDDING,SPEECH2TEXT,MODERATION",labels:"LLM,TEXT",type:"agent-chat"},{name:"工作流应用",description:"EMBEDDING,SPEECH2TEXT,MODERATION",labels:"LLM,TEXT",type:"workflow"}];export{p as a,c as b,u as c,f as d,g as e,E as f,m as g};
|