diff --git a/src/web-ui/src/flow_chat/components/modern/ProcessingIndicator.tsx b/src/web-ui/src/flow_chat/components/modern/ProcessingIndicator.tsx index 1384af924..a5715e345 100644 --- a/src/web-ui/src/flow_chat/components/modern/ProcessingIndicator.tsx +++ b/src/web-ui/src/flow_chat/components/modern/ProcessingIndicator.tsx @@ -8,6 +8,7 @@ import React, { useEffect, useRef, useState } from 'react'; import { useTranslation } from 'react-i18next'; import { DotMatrixLoader } from '@/component-library'; +import { processingHintsZh, processingHintsEn } from '../../constants/processingHints'; import './ProcessingIndicator.scss'; interface ProcessingIndicatorProps { @@ -17,8 +18,8 @@ interface ProcessingIndicatorProps { } export const ProcessingIndicator: React.FC = ({ visible, reserveSpace = false }) => { - const { t } = useTranslation('flow-chat'); - const hints = t('processingHints', { returnObjects: true }) as string[]; + const { i18n } = useTranslation(); + const hints = i18n.language.startsWith('zh') ? processingHintsZh : processingHintsEn; const [showHint, setShowHint] = useState(false); const [hintIndex, setHintIndex] = useState(0); diff --git a/src/web-ui/src/flow_chat/constants/processingHints.ts b/src/web-ui/src/flow_chat/constants/processingHints.ts new file mode 100644 index 000000000..b3fd4372e --- /dev/null +++ b/src/web-ui/src/flow_chat/constants/processingHints.ts @@ -0,0 +1,420 @@ +/** + * Fun processing hint messages shown while the AI is working. + * Designed to ease user anxiety with light-hearted copy. + */ + +export const processingHintsZh: string[] = [ + // --- Tech / ML metaphors --- + "思维回路全速运转...", + "Token 们奋力排列中...", + "矩阵乘法进行中...", + "Transformer 全力变形...", + "Embeddings 寻找彼此...", + "最后一次梯度下降...", + "注意力机制已锁定...", + "思维发动机轰鸣启动...", + "思维路线图展开中...", + "激活函数全员上岗...", + "推理链跑起来了...", + "十四亿参数找答案...", + "上下文窗口挤一挤...", + "最合适的词正在出现...", + "正在 Debug 思维链...", + "推导链节节延伸...", + "在语言的岔路口选方向...", + "思路全线开动...", + "向量空间里迷了路...", + "量子态还没塌缩...", + "正在过滤噪音...", + "从千万想法里提炼精华...", + "灵感之流汇聚成河...", + "数百万次思考之后...", + "所有脑力为你服务...", + "思绪整装,即将出发...", + + // --- Personification & humor --- + "给神经网络倒咖啡...", + "模型正在思考人生...", + "神经元群情激昂...", + "反向传播感悟中...", + "正在召开内部评审会...", + "多个思路正在 PK...", + "神经元:已就位...", + "神经网络的午夜加班...", + "正在假装镇定地高速运转...", + "暗中使力中...", + "绞尽脑汁为你服务...", + "正在对话宇宙...", + "向宇宙借创意...", + + // --- Progress --- + "答案在路上了...", + "拼图最后一块到位...", + "思路合流中...", + "逻辑线头找到了...", + "差不多了,收尾中...", + "还差一点点...", + "就差临门一脚...", + "搞定了百分之九十九...", + "最终赢家即将揭晓...", + "答案正在着陆跑道...", + "最后校对一遍...", + "正在打磨最后措辞...", + "正在精简表达...", + "填充最后几块拼图...", + "高质量输出即将发射...", + "系好安全带,即将着陆...", + "即将顿悟...", + "答案就在嘴边...", + + // --- Imagination --- + "翻阅无数可能中...", + "召唤创意,稍候...", + "脑洞已打开...", + "在十万八千条思路里取最优...", + "把你的问题投影到高维空间...", + "好问题!让我选一个薛定谔的答案...", + "在知识图谱里找路...", + "知识正在快速结晶...", + "把抽象想法具体化...", + "思维导图疯狂生长...", + "在概念森林砍出一条路...", + "想法从潜空间投影...", + "将混乱整理成诗...", + "折叠所有可能成一答...", + "举一反三进行中...", + "联想力爆棚中...", + "正在破解难题密码...", + "智慧的光正在聚焦...", + + // --- Light & confident --- + "字斟句酌,只给精华...", + "想想,再想想...", + "已经快了(真的)...", + "快了!(不是在敷衍)", + "这道题,我会!", + "收到!全力处理中...", + "就在这里,别急...", + "全情投入,心无旁骛...", + "私下已想了七八种方案...", + "比想象中更努力...", + "认真的,从没这么认真过...", + "比光速还快(误)...", + "才华正在集中爆发...", + "正在憋大招...", + "超强输出,即将到来...", + "最强答案正在成形...", + + // --- Concrete metaphors --- + "把散落的灵感拼起来...", + "用知识蒸馏一杯好茶...", + "灵感在深处发酵...", + "知识浪潮涌向输出端...", + "脑图正在扩展中...", + "思维潮水汇聚中...", + "思维火焰正旺...", + "知识在快速结晶...", + "脑内灯泡闪烁中...", + "思路打结,解开中...", + "思维信号穿梭神经丛...", + "秒速百公里地思考...", + "知识储备调用中...", + "知识能量正在充能...", + "智慧内核全速转...", + + // --- Care & focus --- + "脑子已经全力转起来了...", + "正在为你量身定制...", + "把最好的留到最后...", + "用心对待每一个字...", + "全神贯注于你的问题...", + "注意力全给你了...", + "这一刻,全给你...", + "正在起草一份诚意回答...", + "灵感正在悄悄聚拢...", + "倾尽所有给你答案...", + "绝不摆烂,全力以赴...", + "努力营业中...", + + // --- Short beats --- + "混沌转逻辑中...", + "思考齿轮咬合中...", + "解码深邃想法中...", + "合并所有子思路...", + "抢救迷失的语义...", + "拆解成千个小问题...", + "千个念头取最好...", + "把想法和文字对齐...", + "整理千头万绪中...", + "确认答案合理性中...", + "检查一遍,再检查...", + "把模糊变清晰中...", + "思维正在对焦...", + "多线程思维全力汇总...", + "把逻辑再拧紧一点...", + "让逻辑自己说话...", + "在语言丛林里寻宝...", + + // --- More fun --- + "全速冲刺,答案在望...", + "思维扩容,装下更多...", + "为回答精心调味...", + "给逻辑链上润滑油...", + "把回答装进包裹打结中...", + "逻辑拼图已完成...", + "有条不紊,稳步推进...", + "万事就绪,答案出发...", + "脑波达到最高频...", + "思路刚打通,马上来...", + "解开语言的最后一层...", + "用推理缝合碎片...", + "召开紧急大脑会议...", + "整理出最佳路径...", + "正在审阅自己的思维...", + "正在进行最后冲刺...", + "努力中,绝不放弃...", + "正在做些不可思议的事...", + "思考容量拉满...", + "我在,我想,我输出...", + "后台小剧场精彩上演...", + "正在奋笔疾书...", + "在参数空间漫步...", + "正在将想法变为现实...", + "知识全力驰援中...", + "删删改改中...", + "像素精灵正在组字...", + "比特们正在排队...", + "比特流已启动...", + "思维启动加速度...", + "正在给回答注入灵魂...", + "准备好了吗?快了...", + "就差最后一步...", + "输出即将解冻...", + "神经丛林探险中...", + "答案雏形已在手...", + "思路正在合流...", + "尽力而为,必有所获...", + "正在快乐工作中...", + "大脑正在全速燃烧...", + "答案即将成形...", + "思维的潮水汇聚中...", + "正在把复杂变简单...", + "脑中千个念头筛选中...", + "正在为你开天辟地...", + "知识海洋里捞最优解...", + "万亿可能取其一...", + "答案正在破壳而出...", + "大脑高速公路全线畅通...", + "最佳路径已锁定...", + "思维齐步走,答案来了...", + "大招正在蓄力中...", + "答案即将横空出世...", +]; + +export const processingHintsEn: string[] = [ + // --- Tech / ML metaphors --- + "Neural circuits running at full speed...", + "Tokens lining up in perfect order...", + "Matrix multiplications in progress...", + "Transformer: transforming at full capacity...", + "Embeddings searching for their soulmates...", + "One final gradient descent to go...", + "Attention heads: activated and locked...", + "Thought engine roaring to life...", + "Mental roadmap unfolding...", + "Activation functions reporting for duty...", + "Reasoning chain is running...", + "Spelunking through fourteen billion parameters...", + "Squeezing into the context window...", + "The perfect word is surfacing...", + "Debugging my own chain of thought...", + "Reasoning links extending one by one...", + "Picking a path through the language labyrinth...", + "All thought lanes open and moving...", + "Got lost in vector space, back soon...", + "Quantum state hasn't collapsed yet...", + "Filtering out the noise...", + "Distilling the best from a million thoughts...", + "Rivers of inspiration converging...", + "After millions of mental iterations...", + "All brainpower dedicated to you...", + "Thoughts packed and ready to go...", + + // --- Personification & humor --- + "Feeding the model its morning coffee...", + "Pondering the meaning of tokens...", + "Neurons firing in passionate debate...", + "Backpropagating through life choices...", + "Holding an internal peer review...", + "Multiple ideas in a heated competition...", + "Neurons: reporting for duty...", + "Neural network pulling an all-nighter...", + "Pretending to be calm while going full speed...", + "Quietly working magic in the background...", + "Wracking every synapse for your sake...", + "Consulting the cosmos...", + "Borrowing creativity from the universe...", + + // --- Progress --- + "Answer is on its way...", + "Last puzzle piece sliding into place...", + "Thoughts merging into one stream...", + "Found the thread of logic...", + "Almost done, wrapping up...", + "Just a tiny bit more...", + "One final push to go...", + "Ninety-nine percent done...", + "The winner is about to be revealed...", + "Answer on final approach for landing...", + "One last proofread...", + "Polishing the last few words...", + "Trimming the fat from the response...", + "Filling in the last few puzzle pieces...", + "High-quality output launching soon...", + "Fasten your seatbelt — landing shortly...", + "Epiphany incoming...", + "Answer is right on the tip of my tongue...", + + // --- Imagination --- + "Rummaging through the multiverse of ideas...", + "Summoning creativity, please hold...", + "Brain hole: open...", + "Picking the best from ten thousand thoughts...", + "Projecting your question into high-dimensional space...", + "Great question! Picking from Schrödinger's answers...", + "Navigating the knowledge graph...", + "Knowledge crystallizing rapidly...", + "Turning abstract ideas into concrete ones...", + "Mind map expanding like wildfire...", + "Hacking a path through the concept forest...", + "Ideas projecting from latent space...", + "Turning chaos into something like poetry...", + "Folding all possible futures into one answer...", + "Analogical reasoning in progress...", + "Associative power: overclocked...", + "Cracking the code of a tough problem...", + "Focusing the beam of intelligence...", + + // --- Light & confident --- + "Hand-picking only the best words...", + "Let me think... still thinking...", + "I'm fast, I promise...", + "Almost there! (Not stalling, really)", + "I know this one!", + "Roger that! Processing at full capacity...", + "Right here, no rush...", + "Fully in the zone right now...", + "Already tried seven different approaches internally...", + "Working harder than you'd expect...", + "Never been this focused in my life...", + "Faster than light (not really)...", + "Talent concentrated and detonating...", + "Charging up the big move...", + "Supercharged output incoming...", + "The best answer is taking shape...", + + // --- Concrete metaphors --- + "Gathering the scattered sparks of inspiration...", + "Distilling knowledge into a fine brew...", + "Ideas fermenting in the neural depths...", + "Tidal waves of knowledge rushing to the output...", + "Mind map expanding at max speed...", + "Waves of thought converging...", + "Thinking flame burning bright...", + "Knowledge solidifying into form...", + "Lightbulb flickering in the back of my mind...", + "Untangling the knots in my reasoning...", + "Thought signals racing through the neural jungle...", + "Thinking at hundreds of miles per second...", + "Pulling from deep knowledge reserves...", + "Knowledge energy charging up...", + "Intelligence core running at max rpm...", + + // --- Care & focus --- + "Brain already spinning at full tilt...", + "Tailoring this response just for you...", + "Saving the best for last...", + "Crafting every word with care...", + "Fully focused on your question...", + "All attention given to you...", + "This moment is entirely for you...", + "Drafting a sincere and thoughtful reply...", + "Inspiration quietly gathering...", + "Giving everything I've got for your answer...", + "Zero slacking, full effort...", + "Diligently serving your request...", + + // --- Short beats --- + "Converting chaos into logic...", + "Gears of thought clicking into place...", + "Decoding your profound question...", + "Merging all sub-ideas...", + "Rescuing lost semantic meaning...", + "Breaking it into a thousand micro-problems...", + "Picking the best of a thousand thoughts...", + "Lining up thoughts with words...", + "Sorting through a tangle of threads...", + "Verifying the answer makes sense...", + "Checking once, then checking again...", + "Turning fuzzy into clear...", + "Thoughts coming into focus...", + "All threads converging at full speed...", + "Tightening the logic just a little more...", + "Letting logic speak for itself...", + "Treasure-hunting through the language forest...", + + // --- More fun --- + "Sprinting to the finish line...", + "Expanding the thought tank...", + "Adding just the right pinch of creativity...", + "Oiling the chain of logic...", + "Tying a bow on your response package...", + "Logic puzzle: assembled...", + "Moving steadily, step by step...", + "Everything ready — answer departing now...", + "Brainwave frequency at all-time high...", + "Thread of thought just clicked — almost there...", + "Unwrapping the final layer of language...", + "Stitching the fragments together with reasoning...", + "Calling an emergency brain session...", + "Plotting the optimal path...", + "Reviewing my own chain of thought...", + "Making the final sprint...", + "Pushing through, won't give up...", + "Doing something kind of amazing right now...", + "Thinking capacity: maxed out...", + "I think, therefore I output...", + "A tiny drama unfolding backstage...", + "Writing at full speed...", + "Wandering the parameter space...", + "Turning ideas into reality...", + "All knowledge rallying to help...", + "Editing and re-editing...", + "Pixel elves composing text...", + "Bits falling into line...", + "Bit stream: engaged...", + "Thought engine accelerating...", + "Infusing the response with soul...", + "Ready for it? Almost there...", + "One last step to go...", + "Output thawing out...", + "Exploring the neural jungle...", + "Answer prototype taking form...", + "Thoughts flowing into one channel...", + "Doing my very best, as always...", + "Happily working away...", + "Brain burning at full speed...", + "Answer taking shape...", + "Waves of thought converging on the answer...", + "Turning complexity into simplicity...", + "Filtering thousands of thoughts right now...", + "Creating something from nothing, just for you...", + "Fishing the best answer from an ocean of knowledge...", + "One in a trillion possibilities, chosen for you...", + "Answer hatching right now...", + "The brain highway is clear and running fast...", + "Optimal path: locked in...", + "Thoughts marching in step — answer incoming...", + "Done in one second (approximately)...", + "Casting a chaos-to-clarity spell...", +]; diff --git a/src/web-ui/src/locales/en-US/flow-chat.json b/src/web-ui/src/locales/en-US/flow-chat.json index dcf2aaef4..2ac0e11a6 100644 --- a/src/web-ui/src/locales/en-US/flow-chat.json +++ b/src/web-ui/src/locales/en-US/flow-chat.json @@ -1,53 +1,4 @@ { - "processingHints": [ - "Rummaging through the multiverse of ideas...", - "Neural gears meshing at full speed...", - "Summoning creativity, please hold...", - "Bits and bytes lining up for you...", - "Got lost in vector space, back in a sec...", - "Quantum state hasn't collapsed yet...", - "Feeding the model its morning coffee...", - "Pondering the meaning of tokens...", - "Arranging thoughts into coherent shapes...", - "Ideas percolating in the neural depths...", - "Inspiration emerging from the void...", - "Running matrix multiplications, hang tight...", - "Trying very hard not to hallucinate...", - "Converting chaos into structured output...", - "Gears of thought clicking into place...", - "Decoding your profound question...", - "Backpropagating through life choices...", - "Neurons firing in passionate debate...", - "Spelunking through fourteen billion parameters...", - "Let me think... still thinking... almost there...", - "Borrowing creativity from the cosmos...", - "Collapsing Schrödinger's answer into one response...", - "Attention heads: activated. Target: locked...", - "Waves of thought converging into a response...", - "Breaking your question into a thousand micro-problems...", - "Turning your question over from every angle...", - "Aligning model outputs with human expectations...", - "Transformer: transforming at full capacity...", - "Thought signals racing through the neural jungle...", - "One final gradient descent to go...", - "Embeddings searching for their soulmates...", - "Trying to say something useful instead of just 'It depends'...", - "Debugging my own chain of thought...", - "Projecting ideas from latent space into reality...", - "Untangling the reasoning knots, one by one...", - "The thinking engine is running hot right now...", - "Fasten your seatbelt — landing soon...", - "High-quality output launching in 3... 2... 1...", - "Bit streams engaged, pixel elves composing text...", - "Folding all possible futures into one answer...", - "Extracting signal from the entropy of the universe...", - "Neural network doing its morning stretches...", - "Tidal waves of knowledge rushing toward the output port...", - "Your answer is being hand-crafted by tiny algorithms...", - "Resisting the urge to just make something up...", - "The inference engine is warmed up and raring to go...", - "Sifting through countless thoughts for the best one..." - ], "emptyState": { "welcomeBack": "Welcome back!", "workingIn": "You are working in {{workspace}}", diff --git a/src/web-ui/src/locales/zh-CN/flow-chat.json b/src/web-ui/src/locales/zh-CN/flow-chat.json index 8f5124d2f..034b9a9d6 100644 --- a/src/web-ui/src/locales/zh-CN/flow-chat.json +++ b/src/web-ui/src/locales/zh-CN/flow-chat.json @@ -1,53 +1,4 @@ { - "processingHints": [ - "正在翻阅无数可能...", - "思维回路全速运转中...", - "召唤创意,请稍候...", - "比特们正在排队就位...", - "向量空间里迷路了一下,马上回来...", - "量子态还没塌缩,稍等片刻...", - "正在给神经网络喝咖啡...", - "模型正在认真思考人生...", - "Token 们正在奋力排列中...", - "灵感正在脑海深处慢慢发酵...", - "在十万八千条思路里找最靠谱的那个...", - "矩阵乘法进行中,坐稳了...", - "AI 正在努力不说废话...", - "正在把混沌转换成逻辑...", - "思考的齿轮咬合中...", - "正在解码你深邃的想法...", - "反向传播人生感悟中...", - "神经元正在群情激昂...", - "在十四亿个参数里找答案...", - "让我想想,再想想,还在想...", - "脑洞已打开,正在向宇宙借创意...", - "正在深呼吸然后开始认真输出...", - "把你的问题转化成高维空间中的一个点...", - "思路打了个小结,正在解开...", - "正在把复杂问题拆成一千个小问题...", - "注意力机制已锁定目标...", - "脑中转了一千个念头,正在取最好的那个...", - "正在对齐价值观与输出期望...", - "Transformer 正在全力变形...", - "思维信号正在神经丛林中全速穿梭...", - "正在做最后一次梯度下降...", - "embeddings 们正在寻找彼此...", - "答案已经在路上了,正在整理仪容...", - "正在 Debug 自己的思维链...", - "拼图的最后一块刚找到,马上完工...", - "正在把想法从潜空间投影到现实...", - "思维的潮水正在汇聚,答案快来了...", - "大脑正在全速燃烧,文字即将涌现...", - "系好安全带,答案即将着陆...", - "注意!高质量输出即将发射...", - "比特流已启动,像素精灵正在组字...", - "正在把所有可能的未来折叠成一个回答...", - "好问题!让我从薛定谔的答案里挑一个...", - "脑子里的想法正在争先恐后地排队...", - "大脑正在假装很镇定地高速运转...", - "知识的浪潮正在涌向输出端口...", - "算法大脑已就绪,文字即将喷涌而出..." - ], "emptyState": { "welcomeBack": "欢迎回来!", "workingIn": "您正在 {{workspace}} 中",