workflow.ts 16 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476
  1. const translation = {
  2. common: {
  3. undo: 'Undo',
  4. redo: 'Redo',
  5. editing: 'Editing',
  6. autoSaved: 'Auto-Saved',
  7. unpublished: 'Unpublished',
  8. published: 'Published',
  9. publish: 'Publish',
  10. update: 'Update',
  11. run: 'Run',
  12. running: 'Running',
  13. inRunMode: 'In Run Mode',
  14. inPreview: 'In Preview',
  15. inPreviewMode: 'In Preview Mode',
  16. preview: 'Preview',
  17. viewRunHistory: 'View run history',
  18. runHistory: 'Run History',
  19. goBackToEdit: 'Go back to editor',
  20. conversationLog: 'Conversation Log',
  21. features: 'Features',
  22. debugAndPreview: 'Debug and Preview',
  23. restart: 'Restart',
  24. currentDraft: 'Current Draft',
  25. currentDraftUnpublished: 'Current Draft Unpublished',
  26. latestPublished: 'Latest Published',
  27. publishedAt: 'Published',
  28. restore: 'Restore',
  29. runApp: 'Run App',
  30. batchRunApp: 'Batch Run App',
  31. accessAPIReference: 'Access API Reference',
  32. embedIntoSite: 'Embed Into Site',
  33. addTitle: 'Add title...',
  34. addDescription: 'Add description...',
  35. noVar: 'No variable',
  36. searchVar: 'Search variable',
  37. variableNamePlaceholder: 'Variable name',
  38. setVarValuePlaceholder: 'Set variable',
  39. needConnecttip: 'This step is not connected to anything',
  40. maxTreeDepth: 'Maximum limit of {{depth}} nodes per branch',
  41. needEndNode: 'The End block must be added',
  42. needAnswerNode: 'The Answer block must be added',
  43. workflowProcess: 'Workflow Process',
  44. notRunning: 'Not running yet',
  45. previewPlaceholder: 'Enter content in the box below to start debugging the Chatbot',
  46. effectVarConfirm: {
  47. title: 'Remove Variable',
  48. content: 'The variable is used in other nodes. Do you still want to remove it?',
  49. },
  50. insertVarTip: 'Press the \'/\' key to insert quickly',
  51. processData: 'Process Data',
  52. input: 'Input',
  53. output: 'Output',
  54. jinjaEditorPlaceholder: 'Type \'/\' or \'{\' to insert variable',
  55. viewOnly: 'View Only',
  56. showRunHistory: 'Show Run History',
  57. enableJinja: 'Enable Jinja template support',
  58. learnMore: 'Learn More',
  59. copy: 'Copy',
  60. duplicate: 'Duplicate',
  61. addBlock: 'Add Block',
  62. pasteHere: 'Paste Here',
  63. pointerMode: 'Pointer Mode',
  64. handMode: 'Hand Mode',
  65. model: 'Model',
  66. workflowAsTool: 'Workflow as Tool',
  67. configureRequired: 'Configure Required',
  68. configure: 'Configure',
  69. manageInTools: 'Manage in Tools',
  70. workflowAsToolTip: 'Tool reconfiguration is required after the workflow update.',
  71. viewDetailInTracingPanel: 'View details',
  72. syncingData: 'Syncing data, just a few seconds.',
  73. importDSL: 'Import DSL',
  74. importDSLTip: 'Current draft will be overwritten. Export workflow as backup before importing.',
  75. backupCurrentDraft: 'Backup Current Draft',
  76. chooseDSL: 'Choose DSL(yml) file',
  77. overwriteAndImport: 'Overwrite and Import',
  78. importFailure: 'Import failure',
  79. importSuccess: 'Import success',
  80. },
  81. changeHistory: {
  82. title: 'Change History',
  83. placeholder: 'You haven\'t changed anything yet',
  84. clearHistory: 'Clear History',
  85. hint: 'Hint',
  86. hintText: 'Your editing actions are tracked in a change history, which is stored on your device for the duration of this session. This history will be cleared when you leave the editor.',
  87. stepBackward_one: '{{count}} step backward',
  88. stepBackward_other: '{{count}} steps backward',
  89. stepForward_one: '{{count}} step forward',
  90. stepForward_other: '{{count}} steps forward',
  91. sessionStart: 'Session Start',
  92. currentState: 'Current State',
  93. nodeTitleChange: 'Block title changed',
  94. nodeDescriptionChange: 'Block description changed',
  95. nodeDragStop: 'Block moved',
  96. nodeChange: 'Block changed',
  97. nodeConnect: 'Block connected',
  98. nodePaste: 'Block pasted',
  99. nodeDelete: 'Block deleted',
  100. nodeAdd: 'Block added',
  101. nodeResize: 'Block resized',
  102. noteAdd: 'Note added',
  103. noteChange: 'Note changed',
  104. noteDelete: 'Note deleted',
  105. edgeDelete: 'Block disconnected',
  106. },
  107. errorMsg: {
  108. fieldRequired: '{{field}} is required',
  109. authRequired: 'Authorization is required',
  110. invalidJson: '{{field}} is invalid JSON',
  111. fields: {
  112. variable: 'Variable Name',
  113. variableValue: 'Variable Value',
  114. code: 'Code',
  115. model: 'Model',
  116. rerankModel: 'Rerank Model',
  117. },
  118. invalidVariable: 'Invalid variable',
  119. },
  120. singleRun: {
  121. testRun: 'Test Run ',
  122. startRun: 'Start Run',
  123. running: 'Running',
  124. testRunIteration: 'Test Run Iteration',
  125. back: 'Back',
  126. iteration: 'Iteration',
  127. },
  128. tabs: {
  129. 'searchBlock': 'Search block',
  130. 'blocks': 'Blocks',
  131. 'tools': 'Tools',
  132. 'allTool': 'All',
  133. 'builtInTool': 'Built-in',
  134. 'customTool': 'Custom',
  135. 'workflowTool': 'Workflow',
  136. 'question-understand': 'Question Understand',
  137. 'logic': 'Logic',
  138. 'transform': 'Transform',
  139. 'utilities': 'Utilities',
  140. 'noResult': 'No match found',
  141. },
  142. blocks: {
  143. 'start': 'Start',
  144. 'end': 'End',
  145. 'answer': 'Answer',
  146. 'llm': 'LLM',
  147. 'knowledge-retrieval': 'Knowledge Retrieval',
  148. 'question-classifier': 'Question Classifier',
  149. 'if-else': 'IF/ELSE',
  150. 'code': 'Code',
  151. 'template-transform': 'Template',
  152. 'http-request': 'HTTP Request',
  153. 'variable-assigner': 'Variable Aggregator',
  154. 'variable-aggregator': 'Variable Aggregator',
  155. 'iteration-start': 'Iteration Start',
  156. 'iteration': 'Iteration',
  157. 'parameter-extractor': 'Parameter Extractor',
  158. },
  159. blocksAbout: {
  160. 'start': 'Define the initial parameters for launching a workflow',
  161. 'end': 'Define the end and result type of a workflow',
  162. 'answer': 'Define the reply content of a chat conversation',
  163. 'llm': 'Invoking large language models to answer questions or process natural language',
  164. 'knowledge-retrieval': 'Allows you to query text content related to user questions from the Knowledge',
  165. 'question-classifier': 'Define the classification conditions of user questions, LLM can define how the conversation progresses based on the classification description',
  166. 'if-else': 'Allows you to split the workflow into two branches based on if/else conditions',
  167. 'code': 'Execute a piece of Python or NodeJS code to implement custom logic',
  168. 'template-transform': 'Convert data to string using Jinja template syntax',
  169. 'http-request': 'Allow server requests to be sent over the HTTP protocol',
  170. 'variable-assigner': 'Aggregate multi-branch variables into a single variable for unified configuration of downstream nodes.',
  171. 'variable-aggregator': 'Aggregate multi-branch variables into a single variable for unified configuration of downstream nodes.',
  172. 'iteration': 'Perform multiple steps on a list object until all results are outputted.',
  173. 'parameter-extractor': 'Use LLM to extract structured parameters from natural language for tool invocations or HTTP requests.',
  174. },
  175. operator: {
  176. zoomIn: 'Zoom In',
  177. zoomOut: 'Zoom Out',
  178. zoomTo50: 'Zoom to 50%',
  179. zoomTo100: 'Zoom to 100%',
  180. zoomToFit: 'Zoom to Fit',
  181. },
  182. panel: {
  183. userInputField: 'User Input Field',
  184. changeBlock: 'Change Block',
  185. helpLink: 'Help Link',
  186. about: 'About',
  187. createdBy: 'Created By ',
  188. nextStep: 'Next Step',
  189. addNextStep: 'Add the next block in this workflow',
  190. selectNextStep: 'Select Next Block',
  191. runThisStep: 'Run this step',
  192. checklist: 'Checklist',
  193. checklistTip: 'Make sure all issues are resolved before publishing',
  194. checklistResolved: 'All issues are resolved',
  195. organizeBlocks: 'Organize blocks',
  196. change: 'Change',
  197. },
  198. nodes: {
  199. common: {
  200. outputVars: 'Output Variables',
  201. insertVarTip: 'Insert Variable',
  202. memory: {
  203. memory: 'Memory',
  204. memoryTip: 'Chat memory settings',
  205. windowSize: 'Window Size',
  206. conversationRoleName: 'Conversation Role Name',
  207. user: 'User prefix',
  208. assistant: 'Assistant prefix',
  209. },
  210. memories: {
  211. title: 'Memories',
  212. tip: 'Chat memory',
  213. builtIn: 'Built-in',
  214. },
  215. },
  216. start: {
  217. required: 'required',
  218. inputField: 'Input Field',
  219. builtInVar: 'Built-in Variables',
  220. outputVars: {
  221. query: 'User input',
  222. memories: {
  223. des: 'Conversation history',
  224. type: 'message type',
  225. content: 'message content',
  226. },
  227. files: 'File list',
  228. },
  229. noVarTip: 'Set inputs that can be used in the Workflow',
  230. },
  231. end: {
  232. outputs: 'Outputs',
  233. output: {
  234. type: 'output type',
  235. variable: 'output variable',
  236. },
  237. type: {
  238. 'none': 'None',
  239. 'plain-text': 'Plain Text',
  240. 'structured': 'Structured',
  241. },
  242. },
  243. answer: {
  244. answer: 'Answer',
  245. outputVars: 'Output Variables',
  246. },
  247. llm: {
  248. model: 'model',
  249. variables: 'variables',
  250. context: 'context',
  251. contextTooltip: 'You can import Knowledge as context',
  252. notSetContextInPromptTip: 'To enable the context feature, please fill in the context variable in PROMPT.',
  253. prompt: 'prompt',
  254. roleDescription: {
  255. system: 'Give high level instructions for the conversation',
  256. user: 'Provide instructions, queries, or any text-based input to the model',
  257. assistant: 'The model’s responses based on the user messages',
  258. },
  259. addMessage: 'Add Message',
  260. vision: 'vision',
  261. files: 'Files',
  262. resolution: {
  263. name: 'Resolution',
  264. high: 'High',
  265. low: 'Low',
  266. },
  267. outputVars: {
  268. output: 'Generate content',
  269. usage: 'Model Usage Information',
  270. },
  271. singleRun: {
  272. variable: 'Variable',
  273. },
  274. sysQueryInUser: 'sys.query in user message is required',
  275. },
  276. knowledgeRetrieval: {
  277. queryVariable: 'Query Variable',
  278. knowledge: 'Knowledge',
  279. outputVars: {
  280. output: 'Retrieval segmented data',
  281. content: 'Segmented content',
  282. title: 'Segmented title',
  283. icon: 'Segmented icon',
  284. url: 'Segmented URL',
  285. metadata: 'Other metadata',
  286. },
  287. },
  288. http: {
  289. inputVars: 'Input Variables',
  290. api: 'API',
  291. apiPlaceholder: 'Enter URL, type ‘/’ insert variable',
  292. notStartWithHttp: 'API should start with http:// or https://',
  293. key: 'Key',
  294. value: 'Value',
  295. bulkEdit: 'Bulk Edit',
  296. keyValueEdit: 'Key-Value Edit',
  297. headers: 'Headers',
  298. params: 'Params',
  299. body: 'Body',
  300. outputVars: {
  301. body: 'Response Content',
  302. statusCode: 'Response Status Code',
  303. headers: 'Response Header List JSON',
  304. files: 'Files List',
  305. },
  306. authorization: {
  307. 'authorization': 'Authorization',
  308. 'authorizationType': 'Authorization Type',
  309. 'no-auth': 'None',
  310. 'api-key': 'API-Key',
  311. 'auth-type': 'Auth Type',
  312. 'basic': 'Basic',
  313. 'bearer': 'Bearer',
  314. 'custom': 'Custom',
  315. 'api-key-title': 'API Key',
  316. 'header': 'Header',
  317. },
  318. insertVarPlaceholder: 'type \'/\' to insert variable',
  319. timeout: {
  320. title: 'Timeout',
  321. connectLabel: 'Connection Timeout',
  322. connectPlaceholder: 'Enter connection timeout in seconds',
  323. readLabel: 'Read Timeout',
  324. readPlaceholder: 'Enter read timeout in seconds',
  325. writeLabel: 'Write Timeout',
  326. writePlaceholder: 'Enter write timeout in seconds',
  327. },
  328. },
  329. code: {
  330. inputVars: 'Input Variables',
  331. outputVars: 'Output Variables',
  332. advancedDependencies: 'Advanced Dependencies',
  333. advancedDependenciesTip: 'Add some preloaded dependencies that take more time to consume or are not default built-in here',
  334. searchDependencies: 'Search Dependencies',
  335. },
  336. templateTransform: {
  337. inputVars: 'Input Variables',
  338. code: 'Code',
  339. codeSupportTip: 'Only supports Jinja2',
  340. outputVars: {
  341. output: 'Transformed content',
  342. },
  343. },
  344. ifElse: {
  345. if: 'If',
  346. else: 'Else',
  347. elseDescription: 'Used to define the logic that should be executed when the if condition is not met.',
  348. and: 'and',
  349. or: 'or',
  350. operator: 'Operator',
  351. notSetVariable: 'Please set variable first',
  352. comparisonOperator: {
  353. 'contains': 'contains',
  354. 'not contains': 'not contains',
  355. 'start with': 'start with',
  356. 'end with': 'end with',
  357. 'is': 'is',
  358. 'is not': 'is not',
  359. 'empty': 'is empty',
  360. 'not empty': 'is not empty',
  361. 'null': 'is null',
  362. 'not null': 'is not null',
  363. },
  364. enterValue: 'Enter value',
  365. addCondition: 'Add Condition',
  366. conditionNotSetup: 'Condition NOT setup',
  367. },
  368. variableAssigner: {
  369. title: 'Assign variables',
  370. outputType: 'Output Type',
  371. varNotSet: 'Variable not set',
  372. noVarTip: 'Add the variables to be assigned',
  373. type: {
  374. string: 'String',
  375. number: 'Number',
  376. object: 'Object',
  377. array: 'Array',
  378. },
  379. aggregationGroup: 'Aggregation Group',
  380. aggregationGroupTip: 'Enabling this feature allows the variable aggregator to aggregate multiple sets of variables.',
  381. addGroup: 'Add Group',
  382. outputVars: {
  383. varDescribe: '{{groupName}} output',
  384. },
  385. setAssignVariable: 'Set assign variable',
  386. },
  387. tool: {
  388. toAuthorize: 'To authorize',
  389. inputVars: 'Input Variables',
  390. outputVars: {
  391. text: 'tool generated content',
  392. files: {
  393. title: 'tool generated files',
  394. type: 'Support type. Now only support image',
  395. transfer_method: 'Transfer method.Value is remote_url or local_file',
  396. url: 'Image url',
  397. upload_file_id: 'Upload file id',
  398. },
  399. },
  400. },
  401. questionClassifiers: {
  402. model: 'model',
  403. inputVars: 'Input Variables',
  404. outputVars: {
  405. className: 'Class Name',
  406. },
  407. class: 'Class',
  408. classNamePlaceholder: 'Write your class name',
  409. advancedSetting: 'Advanced Setting',
  410. topicName: 'Topic Name',
  411. topicPlaceholder: 'Write your topic name',
  412. addClass: 'Add Class',
  413. instruction: 'Instruction',
  414. instructionTip: 'Input additional instructions to help the question classifier better understand how to categorize questions.',
  415. instructionPlaceholder: 'Write your instruction',
  416. },
  417. parameterExtractor: {
  418. inputVar: 'Input Variable',
  419. extractParameters: 'Extract Parameters',
  420. importFromTool: 'Import from tools',
  421. addExtractParameter: 'Add Extract Parameter',
  422. addExtractParameterContent: {
  423. name: 'Name',
  424. namePlaceholder: 'Extract Parameter Name',
  425. type: 'Type',
  426. typePlaceholder: 'Extract Parameter Type',
  427. description: 'Description',
  428. descriptionPlaceholder: 'Extract Parameter Description',
  429. required: 'Required',
  430. requiredContent: 'Required is only used as a reference for model inference, and not for mandatory validation of parameter output.',
  431. },
  432. extractParametersNotSet: 'Extract Parameters not setup',
  433. instruction: 'Instruction',
  434. instructionTip: 'Input additional instructions to help the parameter extractor understand how to extract parameters.',
  435. advancedSetting: 'Advanced Setting',
  436. reasoningMode: 'Reasoning Mode',
  437. reasoningModeTip: 'You can choose the appropriate reasoning mode based on the model\'s ability to respond to instructions for function calling or prompts.',
  438. isSuccess: 'Is Success.On success the value is 1, on failure the value is 0.',
  439. errorReason: 'Error Reason',
  440. },
  441. iteration: {
  442. deleteTitle: 'Delete Iteration Node?',
  443. deleteDesc: 'Deleting the iteration node will delete all child nodes',
  444. input: 'Input',
  445. output: 'Output Variables',
  446. iteration_one: '{{count}} Iteration',
  447. iteration_other: '{{count}} Iterations',
  448. currentIteration: 'Current Iteration',
  449. },
  450. note: {
  451. addNote: 'Add Note',
  452. editor: {
  453. placeholder: 'Write your note...',
  454. small: 'Small',
  455. medium: 'Medium',
  456. large: 'Large',
  457. bold: 'Bold',
  458. italic: 'Italic',
  459. strikethrough: 'Strikethrough',
  460. link: 'Link',
  461. openLink: 'Open',
  462. unlink: 'Unlink',
  463. enterUrl: 'Enter URL...',
  464. invalidUrl: 'Invalid URL',
  465. bulletList: 'Bullet List',
  466. showAuthor: 'Show Author',
  467. },
  468. },
  469. },
  470. tracing: {
  471. stopBy: 'Stop by {{user}}',
  472. },
  473. }
  474. export default translation