foliko 1.0.80 → 1.0.82

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.
Files changed (154) hide show
  1. package/.agent/agents/code-assistant.json +14 -0
  2. package/.agent/agents/email-assistant.json +14 -0
  3. package/.agent/agents/file-assistant.json +15 -0
  4. package/.agent/agents/system-assistant.json +15 -0
  5. package/.agent/agents/web-assistant.json +12 -0
  6. package/.agent/data/ambient/goals.json +50 -0
  7. package/.agent/data/ambient/memories.json +7 -0
  8. package/.agent/data/default.json +15 -31894
  9. package/.agent/data/plugins-state.json +146 -181
  10. package/.agent/data/scheduler/tasks.json +1 -0
  11. package/.agent/mcp_config.json +1 -0
  12. package/.agent/package.json +8 -0
  13. package/.agent/plugins/__pycache__/test_plugin.cpython-312.pyc +0 -0
  14. package/.agent/plugins/system-info/index.js +387 -0
  15. package/.agent/plugins/system-info/package.json +4 -0
  16. package/.agent/plugins/system-info/test.js +40 -0
  17. package/.agent/plugins/test_plugin.py +304 -0
  18. package/.agent/plugins.json +14 -5
  19. package/.agent/python-scripts/test_sample.py +24 -0
  20. package/.agent/skills/sysinfo/SKILL.md +38 -0
  21. package/.agent/skills/sysinfo/system-info.sh +130 -0
  22. package/.agent/skills/workflow/SKILL.md +324 -0
  23. package/.agent/workflows/email-digest.json +50 -0
  24. package/.agent/workflows/file-backup.json +21 -0
  25. package/.agent/workflows/get-ip-notify.json +32 -0
  26. package/.agent/workflows/news-aggregator.json +93 -0
  27. package/.agent/workflows/news-dashboard-v2.json +94 -0
  28. package/.agent/workflows/notification-batch.json +32 -0
  29. package/.claude/settings.local.json +171 -171
  30. package/.env.example +56 -56
  31. package/cli/src/ui/chat-ui.js +8 -8
  32. package/package.json +1 -1
  33. package/plugins/feishu-plugin.js +6 -6
  34. package/plugins/file-system-plugin.js +54 -11
  35. package/plugins/telegram-plugin.js +6 -6
  36. package/plugins/weixin-plugin.js +6 -6
  37. package/skills/find-skills/AGENTS.md +162 -162
  38. package/skills/find-skills/SKILL.md +133 -133
  39. package/skills/foliko-dev/SKILL.md +563 -583
  40. package/skills/python-plugin-dev/SKILL.md +238 -238
  41. package/src/core/agent-chat.js +141 -134
  42. package/.agent/.shared/ui-ux-pro-max/data/charts.csv +0 -26
  43. package/.agent/.shared/ui-ux-pro-max/data/colors.csv +0 -97
  44. package/.agent/.shared/ui-ux-pro-max/data/icons.csv +0 -101
  45. package/.agent/.shared/ui-ux-pro-max/data/landing.csv +0 -31
  46. package/.agent/.shared/ui-ux-pro-max/data/products.csv +0 -97
  47. package/.agent/.shared/ui-ux-pro-max/data/prompts.csv +0 -24
  48. package/.agent/.shared/ui-ux-pro-max/data/react-performance.csv +0 -45
  49. package/.agent/.shared/ui-ux-pro-max/data/stacks/flutter.csv +0 -53
  50. package/.agent/.shared/ui-ux-pro-max/data/stacks/html-tailwind.csv +0 -56
  51. package/.agent/.shared/ui-ux-pro-max/data/stacks/jetpack-compose.csv +0 -53
  52. package/.agent/.shared/ui-ux-pro-max/data/stacks/nextjs.csv +0 -53
  53. package/.agent/.shared/ui-ux-pro-max/data/stacks/nuxt-ui.csv +0 -51
  54. package/.agent/.shared/ui-ux-pro-max/data/stacks/nuxtjs.csv +0 -59
  55. package/.agent/.shared/ui-ux-pro-max/data/stacks/react-native.csv +0 -52
  56. package/.agent/.shared/ui-ux-pro-max/data/stacks/react.csv +0 -54
  57. package/.agent/.shared/ui-ux-pro-max/data/stacks/shadcn.csv +0 -61
  58. package/.agent/.shared/ui-ux-pro-max/data/stacks/svelte.csv +0 -54
  59. package/.agent/.shared/ui-ux-pro-max/data/stacks/swiftui.csv +0 -51
  60. package/.agent/.shared/ui-ux-pro-max/data/stacks/vue.csv +0 -50
  61. package/.agent/.shared/ui-ux-pro-max/data/styles.csv +0 -59
  62. package/.agent/.shared/ui-ux-pro-max/data/typography.csv +0 -58
  63. package/.agent/.shared/ui-ux-pro-max/data/ui-reasoning.csv +0 -101
  64. package/.agent/.shared/ui-ux-pro-max/data/ux-guidelines.csv +0 -100
  65. package/.agent/.shared/ui-ux-pro-max/data/web-interface.csv +0 -31
  66. package/.agent/.shared/ui-ux-pro-max/scripts/__pycache__/core.cpython-313.pyc +0 -0
  67. package/.agent/.shared/ui-ux-pro-max/scripts/__pycache__/design_system.cpython-313.pyc +0 -0
  68. package/.agent/.shared/ui-ux-pro-max/scripts/core.py +0 -258
  69. package/.agent/.shared/ui-ux-pro-max/scripts/design_system.py +0 -1067
  70. package/.agent/.shared/ui-ux-pro-max/scripts/search.py +0 -106
  71. package/.agent/ARCHITECTURE.md +0 -288
  72. package/.agent/agents/ambient-agent.md +0 -57
  73. package/.agent/agents/debugger.md +0 -55
  74. package/.agent/agents/email-assistant.md +0 -49
  75. package/.agent/agents/file-manager.md +0 -42
  76. package/.agent/agents/python-developer.md +0 -60
  77. package/.agent/agents/scheduler.md +0 -59
  78. package/.agent/agents/web-developer.md +0 -45
  79. package/.agent/mcp_config_updated.json +0 -12
  80. package/.agent/rules/GEMINI.md +0 -273
  81. package/.agent/rules/allow-rule.md +0 -77
  82. package/.agent/rules/log-rule.md +0 -83
  83. package/.agent/rules/security-rule.md +0 -93
  84. package/.agent/scripts/auto_preview.py +0 -148
  85. package/.agent/scripts/checklist.py +0 -217
  86. package/.agent/scripts/session_manager.py +0 -120
  87. package/.agent/scripts/verify_all.py +0 -327
  88. package/.agent/skills/api-patterns/SKILL.md +0 -81
  89. package/.agent/skills/api-patterns/api-style.md +0 -42
  90. package/.agent/skills/api-patterns/auth.md +0 -24
  91. package/.agent/skills/api-patterns/documentation.md +0 -26
  92. package/.agent/skills/api-patterns/graphql.md +0 -41
  93. package/.agent/skills/api-patterns/rate-limiting.md +0 -31
  94. package/.agent/skills/api-patterns/response.md +0 -37
  95. package/.agent/skills/api-patterns/rest.md +0 -40
  96. package/.agent/skills/api-patterns/scripts/api_validator.py +0 -211
  97. package/.agent/skills/api-patterns/security-testing.md +0 -122
  98. package/.agent/skills/api-patterns/trpc.md +0 -41
  99. package/.agent/skills/api-patterns/versioning.md +0 -22
  100. package/.agent/skills/app-builder/SKILL.md +0 -75
  101. package/.agent/skills/app-builder/agent-coordination.md +0 -71
  102. package/.agent/skills/app-builder/feature-building.md +0 -53
  103. package/.agent/skills/app-builder/project-detection.md +0 -34
  104. package/.agent/skills/app-builder/scaffolding.md +0 -118
  105. package/.agent/skills/app-builder/tech-stack.md +0 -40
  106. package/.agent/skills/app-builder/templates/SKILL.md +0 -39
  107. package/.agent/skills/app-builder/templates/astro-static/TEMPLATE.md +0 -76
  108. package/.agent/skills/app-builder/templates/chrome-extension/TEMPLATE.md +0 -92
  109. package/.agent/skills/app-builder/templates/cli-tool/TEMPLATE.md +0 -88
  110. package/.agent/skills/app-builder/templates/electron-desktop/TEMPLATE.md +0 -88
  111. package/.agent/skills/app-builder/templates/express-api/TEMPLATE.md +0 -83
  112. package/.agent/skills/app-builder/templates/flutter-app/TEMPLATE.md +0 -90
  113. package/.agent/skills/app-builder/templates/monorepo-turborepo/TEMPLATE.md +0 -90
  114. package/.agent/skills/app-builder/templates/nextjs-fullstack/TEMPLATE.md +0 -122
  115. package/.agent/skills/app-builder/templates/nextjs-saas/TEMPLATE.md +0 -122
  116. package/.agent/skills/app-builder/templates/nextjs-static/TEMPLATE.md +0 -169
  117. package/.agent/skills/app-builder/templates/nuxt-app/TEMPLATE.md +0 -134
  118. package/.agent/skills/app-builder/templates/python-fastapi/TEMPLATE.md +0 -83
  119. package/.agent/skills/app-builder/templates/react-native-app/TEMPLATE.md +0 -119
  120. package/.agent/skills/architecture/SKILL.md +0 -55
  121. package/.agent/skills/architecture/context-discovery.md +0 -43
  122. package/.agent/skills/architecture/examples.md +0 -94
  123. package/.agent/skills/architecture/pattern-selection.md +0 -68
  124. package/.agent/skills/architecture/patterns-reference.md +0 -50
  125. package/.agent/skills/architecture/trade-off-analysis.md +0 -77
  126. package/.agent/skills/clean-code/SKILL.md +0 -201
  127. package/.agent/skills/doc.md +0 -177
  128. package/.agent/skills/frontend-design/SKILL.md +0 -418
  129. package/.agent/skills/frontend-design/animation-guide.md +0 -331
  130. package/.agent/skills/frontend-design/color-system.md +0 -311
  131. package/.agent/skills/frontend-design/decision-trees.md +0 -418
  132. package/.agent/skills/frontend-design/motion-graphics.md +0 -306
  133. package/.agent/skills/frontend-design/scripts/accessibility_checker.py +0 -183
  134. package/.agent/skills/frontend-design/scripts/ux_audit.py +0 -722
  135. package/.agent/skills/frontend-design/typography-system.md +0 -345
  136. package/.agent/skills/frontend-design/ux-psychology.md +0 -1116
  137. package/.agent/skills/frontend-design/visual-effects.md +0 -383
  138. package/.agent/skills/i18n-localization/SKILL.md +0 -154
  139. package/.agent/skills/i18n-localization/scripts/i18n_checker.py +0 -241
  140. package/.agent/skills/mcp-builder/SKILL.md +0 -176
  141. package/.agent/skills/web-design-guidelines/SKILL.md +0 -57
  142. package/.agent/workflows/brainstorm.md +0 -113
  143. package/.agent/workflows/create.md +0 -59
  144. package/.agent/workflows/debug.md +0 -103
  145. package/.agent/workflows/deploy.md +0 -176
  146. package/.agent/workflows/enhance.md +0 -63
  147. package/.agent/workflows/orchestrate.md +0 -237
  148. package/.agent/workflows/plan.md +0 -89
  149. package/.agent/workflows/preview.md +0 -81
  150. package/.agent/workflows/simple-test.md +0 -42
  151. package/.agent/workflows/status.md +0 -86
  152. package/.agent/workflows/structured-orchestrate.md +0 -180
  153. package/.agent/workflows/test.md +0 -144
  154. package/.agent/workflows/ui-ux-pro-max.md +0 -296
@@ -5,7 +5,7 @@
5
5
 
6
6
  const { EventEmitter } = require('../utils/event-emitter');
7
7
  const { logger } = require('../utils/logger');
8
- const { generateText, pruneMessages } = require('ai');
8
+ const { generateText, pruneMessages, stepCountIs, convertToModelMessages } = require('ai');
9
9
 
10
10
  // 模型上下文限制表(留 15-20% 余量给 system prompt 和输出)
11
11
  const MODEL_CONTEXT_LIMITS = {
@@ -97,7 +97,7 @@ class AgentChatHandler extends EventEmitter {
97
97
  this._systemPrompt = config.systemPrompt || 'You are a helpful assistant.';
98
98
  this._messages = [];
99
99
  this._tools = new Map();
100
- this._maxSteps = 5; // 降低默认步骤数,减少上下文消耗
100
+ this._maxSteps = 20; // 降低默认步骤数,减少上下文消耗
101
101
 
102
102
  // 上下文压缩配置:根据模型自动设置限制
103
103
  const modelKey = Object.keys(MODEL_CONTEXT_LIMITS).find((k) =>
@@ -163,7 +163,7 @@ class AgentChatHandler extends EventEmitter {
163
163
  const existingCount = existingHistory.length;
164
164
 
165
165
  // 只添加新消息(避免重复添加已加载的历史)
166
- const simpleMessages = messages.filter((m) => m.role === 'user' || m.role === 'assistant');
166
+ const simpleMessages = messages;
167
167
 
168
168
  const newMessages = simpleMessages.slice(existingCount);
169
169
  for (const msg of newMessages) {
@@ -366,13 +366,14 @@ class AgentChatHandler extends EventEmitter {
366
366
  }
367
367
 
368
368
  const summary = {
369
- role: 'system',
369
+ role: 'assistant',
370
370
  content: summaryContent,
371
371
  };
372
372
 
373
- this._messages = [...systemMessages, summary, ...recentMessages];
373
+ this._messages = [...systemMessages, summary, ...recentMessages].filter(
374
+ (item) => item.role !== 'tool'
375
+ );
374
376
  this._compressionCount++;
375
-
376
377
  const totalTokens = this._countMessagesTokens(this._messages);
377
378
  logger.info(
378
379
  `Context compressed (${this._compressionCount} times). Messages: ${this._messages.length}, Est. tokens: ${totalTokens}`
@@ -639,80 +640,77 @@ ${truncatedContent}${truncatedNote}
639
640
  const context = { sessionId, isStream: false };
640
641
  const framework = this.agent.framework;
641
642
  const self = this; // 保存引用用于回调
642
-
643
- // 从 session 加载聊天历史
644
- if (sessionId) {
645
- const savedMessages = this._loadHistoryFromSession(sessionId);
646
- if (savedMessages.length > 0) {
647
- this._messages = savedMessages;
648
- logger.info(`Loaded ${savedMessages.length} messages from session ${sessionId}`);
643
+ try {
644
+ // 从 session 加载聊天历史
645
+ if (sessionId) {
646
+ const savedMessages = this._loadHistoryFromSession(sessionId);
647
+ if (savedMessages.length > 0) {
648
+ this._messages = savedMessages;
649
+ logger.info(`Loaded ${savedMessages.length} messages from session ${sessionId}`);
650
+ }
649
651
  }
650
- }
651
-
652
- // 关键:每次 chat 调用时刷新系统提示词,确保包含最新的工具/技能描述
653
- // 解决上下文过长时 LLM 不调用工具的问题
654
- this._systemPrompt = this.agent._buildSystemPrompt();
655
- // 动态导入 AI SDK
656
- const { tool, ToolLoopAgent } = await this._importAI();
657
-
658
- const userMessage = typeof message === 'string' ? { role: 'user', content: message } : message;
659
-
660
- this._messages.push(userMessage);
661
-
662
- // 检查是否需要压缩上下文(包括工具定义)
663
- const messagesTokens = this._countMessagesTokens(this._messages);
664
- const toolsTokens = this._countToolsTokens();
665
- const systemPromptTokens = this._countTokens(this._systemPrompt);
666
- const totalTokens = messagesTokens + toolsTokens + systemPromptTokens;
667
- const limit = this._maxContextTokens * 0.7; // 降低到 70%,更早压缩
668
-
669
- if (totalTokens > limit) {
670
- logger.info(
671
- `Context large (${totalTokens}/${this._maxContextTokens} tokens = msgs:${messagesTokens} + tools:${toolsTokens} + sys:${systemPromptTokens}), compressing...`
672
- );
673
- // 使用带超时控制的压缩
674
- await this._compressContext();
675
- } else {
676
- logger.info(`Context OK: ${totalTokens}/${this._maxContextTokens} tokens`);
677
- }
678
652
 
679
- const maxSteps = options.maxSteps || this._maxSteps;
680
- const tools = this._getAITools(tool);
653
+ // 关键:每次 chat 调用时刷新系统提示词,确保包含最新的工具/技能描述
654
+ // 解决上下文过长时 LLM 不调用工具的问题
655
+ this._systemPrompt = this.agent._buildSystemPrompt();
656
+ // 动态导入 AI SDK
657
+ const { tool, ToolLoopAgent } = await this._importAI();
658
+
659
+ const userMessage =
660
+ typeof message === 'string' ? { role: 'user', content: message } : message;
661
+ //console.log('System Prompt:', this._systemPrompt);
662
+ this._messages.push(userMessage);
663
+
664
+ // 检查是否需要压缩上下文(包括工具定义)
665
+ const messagesTokens = this._countMessagesTokens(this._messages);
666
+ const toolsTokens = this._countToolsTokens();
667
+ const systemPromptTokens = this._countTokens(this._systemPrompt);
668
+ const totalTokens = messagesTokens + toolsTokens + systemPromptTokens;
669
+ const limit = this._maxContextTokens * 0.7; // 降低到 70%,更早压缩
670
+
671
+ if (totalTokens > limit) {
672
+ logger.info(
673
+ `Context large (${totalTokens}/${this._maxContextTokens} tokens = msgs:${messagesTokens} + tools:${toolsTokens} + sys:${systemPromptTokens}), compressing...`
674
+ );
675
+ // 使用带超时控制的压缩
676
+ await this._compressContext();
677
+ } else {
678
+ logger.info(`Context OK: ${totalTokens}/${this._maxContextTokens} tokens`);
679
+ }
681
680
 
682
- if (!this._aiClient) {
683
- throw new Error('AI client not configured.');
684
- }
681
+ const maxSteps = options.maxSteps || this._maxSteps;
682
+ const tools = this._getAITools(tool);
685
683
 
686
- const agent = new ToolLoopAgent({
687
- model: this._aiClient,
688
- instructions: this._systemPrompt,
689
- tools: tools,
690
- stopWhen: (step) => step.stepCount >= maxSteps,
691
- });
684
+ if (!this._aiClient) {
685
+ throw new Error('AI client not configured.');
686
+ }
687
+ // const prunedMessages = pruneMessages({
688
+ // messages: this._messages,
689
+ // reasoning: 'all', // Remove all reasoning parts
690
+ // toolCalls: 'before-last-6-messages', // Remove tool calls except those in the last message
691
+ // });
692
+ const agent = new ToolLoopAgent({
693
+ model: this._aiClient,
694
+ instructions: this._systemPrompt,
695
+ tools: tools,
696
+ stopWhen: stepCountIs(maxSteps),
697
+ prepareStep: async ({ stepNumber, steps, messages }) => {
698
+ if (messages.length > 20) {
699
+ return {
700
+ messages: messages.slice(-10),
701
+ };
702
+ }
692
703
 
693
- const messages = this._cleanMessages(this._messages);
694
- const prunedMessages = pruneMessages({
695
- messages,
696
- reasoning: 'all', // Remove all reasoning parts
697
- toolCalls: 'before-last-2-messages', // Remove tool calls except those in the last message
698
- });
704
+ return {};
705
+ },
706
+ });
699
707
 
700
- try {
701
708
  // 使用 runWithContext 让工具执行时能获取 sessionId
702
709
  const result = await framework.runWithContext(context, async () => {
703
- return agent.generate({ messages: prunedMessages, ...this.providerOptions });
710
+ return agent.generate({ messages: this._messages, ...this.providerOptions });
704
711
  });
705
712
 
706
- // 处理返回的消息历史:只保留 user 和 assistant 消息,让 SDK 自动处理 tool 消息
707
- if (result.messages && Array.isArray(result.messages)) {
708
- // 只保留 user 和 assistant 消息,SDK 会自动维护 tool 消息
709
- this._messages = result.messages.filter((m) => m.role === 'user' || m.role === 'assistant');
710
- } else if (result.text) {
711
- this._messages.push({
712
- role: 'assistant',
713
- content: result.text,
714
- });
715
- }
713
+ this._messages.push(...result.response.messages);
716
714
 
717
715
  // 生成后检查:如果消息太长,下次需要压缩
718
716
  const afterTokens = this._countMessagesTokens(this._messages);
@@ -746,66 +744,77 @@ ${truncatedContent}${truncatedNote}
746
744
  const sessionId = options.sessionId || null;
747
745
  const context = { sessionId, isStream: true };
748
746
  const framework = this.agent.framework;
749
-
750
- // session 加载聊天历史
751
- if (sessionId) {
752
- const savedMessages = this._loadHistoryFromSession(sessionId);
753
- if (savedMessages.length > 0) {
754
- this._messages = savedMessages;
755
- logger.info(`Loaded ${savedMessages.length} messages from session ${sessionId}`);
747
+ try {
748
+ //从 session 加载聊天历史
749
+ if (sessionId) {
750
+ const savedMessages = this._loadHistoryFromSession(sessionId);
751
+ if (savedMessages.length > 0) {
752
+ this._messages = savedMessages;
753
+ logger.info(`Loaded ${savedMessages.length} messages from session ${sessionId}`);
754
+ }
756
755
  }
757
- }
758
-
759
- // 关键:每次 chat 调用时刷新系统提示词,确保包含最新的工具/技能描述
760
- // 解决上下文过长时 LLM 不调用工具的问题
761
- this._systemPrompt = this.agent._buildSystemPrompt();
762
- // 动态导入 AI SDK
763
- const { tool, ToolLoopAgent } = await this._importAI();
764
-
765
- const userMessage = typeof message === 'string' ? { role: 'user', content: message } : message;
766
- //console.log('System Prompt:', this._systemPrompt);
767
- this._messages.push(userMessage);
768
- // 检查是否需要压缩上下文(包括工具定义)
769
- const messagesTokens = this._countMessagesTokens(this._messages);
770
- const toolsTokens = this._countToolsTokens();
771
- const systemPromptTokens = this._countTokens(this._systemPrompt);
772
- const totalTokens = messagesTokens + toolsTokens + systemPromptTokens;
773
- const limit = this._maxContextTokens * 0.7; // 降低到 70%
774
-
775
- // 对于流式调用,如果上下文太大,先压缩再开始
776
- if (totalTokens > limit) {
777
- logger.info(
778
- `Context large (${totalTokens}/${this._maxContextTokens} tokens), compressing...`
779
- );
780
- // 流式调用时等待压缩完成(使用带超时控制的压缩)
781
- await this._compressContext();
782
- }
783
756
 
784
- const maxSteps = options.maxSteps || this._maxSteps;
785
- const tools = this._getAITools(tool);
786
- const self = this; // 保存引用用于回调
757
+ // 关键:每次 chat 调用时刷新系统提示词,确保包含最新的工具/技能描述
758
+ // 解决上下文过长时 LLM 不调用工具的问题
759
+ this._systemPrompt = this.agent._buildSystemPrompt();
760
+ // 动态导入 AI SDK
761
+ const { tool, ToolLoopAgent } = await this._importAI();
762
+
763
+ const userMessage =
764
+ typeof message === 'string' ? { role: 'user', content: message } : message;
765
+ //console.log('System Prompt:', this._systemPrompt);
766
+ this._messages.push(userMessage);
767
+
768
+ // 检查是否需要压缩上下文(包括工具定义)
769
+ const messagesTokens = this._countMessagesTokens(this._messages);
770
+ const toolsTokens = this._countToolsTokens();
771
+ const systemPromptTokens = this._countTokens(this._systemPrompt);
772
+ const totalTokens = messagesTokens + toolsTokens + systemPromptTokens;
773
+ const limit = this._maxContextTokens * 0.7; // 降低到 70%
774
+ // 对于流式调用,如果上下文太大,先压缩再开始
775
+ if (totalTokens > limit) {
776
+ logger.info(
777
+ `Context large (${totalTokens}/${this._maxContextTokens} tokens), compressing...`
778
+ );
779
+ // 流式调用时等待压缩完成(使用带超时控制的压缩)
780
+ await this._compressContext();
781
+ }
787
782
 
788
- if (!this._aiClient) {
789
- throw new Error('AI client not configured.');
790
- }
783
+ const maxSteps = options.maxSteps || this._maxSteps;
784
+ const tools = this._getAITools(tool);
785
+ const self = this; // 保存引用用于回调
786
+ if (!this._aiClient) {
787
+ throw new Error('AI client not configured.');
788
+ }
789
+ console.log(JSON.stringify(this._messages, null, 2));
790
+ // const prunedMessages = pruneMessages({
791
+ // messages: this._messages,
792
+ // reasoning: 'all', // Remove all reasoning parts
793
+ // toolCalls: 'before-last-6-messages', // Remove tool calls except those in the last message
794
+ // });
795
+
796
+ const agent = new ToolLoopAgent({
797
+ model: this._aiClient,
798
+ instructions: this._systemPrompt,
799
+ tools: tools,
800
+ stopWhen: stepCountIs(maxSteps),
801
+ prepareStep: async ({ stepNumber, steps, messages }) => {
802
+ if (messages.length > 20) {
803
+ return {
804
+ messages: messages.slice(-10),
805
+ };
806
+ }
791
807
 
792
- const agent = new ToolLoopAgent({
793
- model: this._aiClient,
794
- instructions: this._systemPrompt,
795
- tools: tools,
796
- stopWhen: (step) => step.stepCount >= maxSteps,
797
- });
808
+ return {};
809
+ },
810
+ });
798
811
 
799
- const messages = this._cleanMessages(this._messages);
800
- const prunedMessages = pruneMessages({
801
- messages,
802
- reasoning: 'all', // Remove all reasoning parts
803
- toolCalls: 'before-last-2-messages', // Remove tool calls except those in the last message
804
- });
805
- try {
806
812
  // 使用 runWithContext 让工具执行时能获取 sessionId(支持并行)
807
813
  const result = await framework.runWithContext(context, async () => {
808
- return agent.stream({ messages: prunedMessages, ...this.providerOptions });
814
+ return agent.stream({
815
+ messages: this._messages,
816
+ ...this.providerOptions,
817
+ });
809
818
  });
810
819
 
811
820
  const stream = result.fullStream;
@@ -813,7 +822,6 @@ ${truncatedContent}${truncatedNote}
813
822
 
814
823
  // 流式迭代器
815
824
  const iterator = stream[Symbol.asyncIterator] ? stream : stream.fullStream;
816
- const finalMessages = [];
817
825
 
818
826
  for await (const part of iterator || stream) {
819
827
  if (part.type === 'text-delta') {
@@ -821,25 +829,24 @@ ${truncatedContent}${truncatedNote}
821
829
  fullText += text;
822
830
  yield { type: 'text', text };
823
831
  } else if (part.type === 'reasoning') {
824
- finalMessages.push(part);
825
832
  this.emit('thinking', { content: part.text });
826
833
  } else if (part.type === 'tool-call') {
827
- finalMessages.push(part);
828
- yield { type: 'tool-call', toolName: part.toolName, args: part.input };
834
+ yield { type: 'tool-call', toolName: part.toolName, input: part.input };
829
835
  } else if (part.type === 'tool-result') {
830
- // AI SDK 6.x 要求 tool 消息格式为:
831
- // { role: 'tool', content: [{ type: 'tool-result', toolCallId, toolName, output }] }
832
- finalMessages.push(part); // 先保存到 finalMessages,等生成结束后统一添加到历史
833
836
  yield { type: 'tool-result', toolName: part.toolName, result: part.output };
834
837
  } else if (part.type === 'error') {
835
838
  yield { type: 'error', error: part.error };
836
839
  }
837
840
  }
838
841
 
839
- this._messages.push({ role: 'tool', content: finalMessages });
840
- // 添加 assistant 消息
841
- const assistantMsg = { role: 'assistant', content: fullText };
842
- this._messages.push(assistantMsg);
842
+ const finish_messages = (await result.response).messages;
843
+ this._messages.push(...finish_messages);
844
+ // console.log(JSON.stringify(this._messages, null, 2));
845
+ // 生成后检查:如果消息太长,下次需要压缩
846
+ const afterTokens = this._countMessagesTokens(this._messages);
847
+ if (afterTokens > this._maxContextTokens * 0.8) {
848
+ logger.info(`After generation: ${afterTokens} tokens, will compress on next turn`);
849
+ }
843
850
 
844
851
  // 保存聊天历史到 session
845
852
  if (sessionId) {
@@ -1,26 +0,0 @@
1
- No,Data Type,Keywords,Best Chart Type,Secondary Options,Color Guidance,Performance Impact,Accessibility Notes,Library Recommendation,Interactive Level
2
- 1,Trend Over Time,"trend, time-series, line, growth, timeline, progress",Line Chart,"Area Chart, Smooth Area",Primary: #0080FF. Multiple series: use distinct colors. Fill: 20% opacity,⚡ Excellent (optimized),✓ Clear line patterns for colorblind users. Add pattern overlays.,"Chart.js, Recharts, ApexCharts",Hover + Zoom
3
- 2,Compare Categories,"compare, categories, bar, comparison, ranking",Bar Chart (Horizontal or Vertical),"Column Chart, Grouped Bar",Each bar: distinct color. Category: grouped same color. Sorted: descending order,⚡ Excellent,✓ Easy to compare. Add value labels on bars for clarity.,"Chart.js, Recharts, D3.js",Hover + Sort
4
- 3,Part-to-Whole,"part-to-whole, pie, donut, percentage, proportion, share",Pie Chart or Donut,"Stacked Bar, Treemap",Colors: 5-6 max. Contrasting palette. Large slices first. Use labels.,⚡ Good (limit 6 slices),⚠ Hard for accessibility. Better: Stacked bar with legend. Avoid pie if >5 items.,"Chart.js, Recharts, D3.js",Hover + Drill
5
- 4,Correlation/Distribution,"correlation, distribution, scatter, relationship, pattern",Scatter Plot or Bubble Chart,"Heat Map, Matrix",Color axis: gradient (blue-red). Size: relative. Opacity: 0.6-0.8 to show density,⚠ Moderate (many points),⚠ Provide data table alternative. Use pattern + color distinction.,"D3.js, Plotly, Recharts",Hover + Brush
6
- 5,Heatmap/Intensity,"heatmap, heat-map, intensity, density, matrix",Heat Map or Choropleth,"Grid Heat Map, Bubble Heat",Gradient: Cool (blue) to Hot (red). Scale: clear legend. Divergent for ±data,⚡ Excellent (color CSS),⚠ Colorblind: Use pattern overlay. Provide numerical legend.,"D3.js, Plotly, ApexCharts",Hover + Zoom
7
- 6,Geographic Data,"geographic, map, location, region, geo, spatial","Choropleth Map, Bubble Map",Geographic Heat Map,Regional: single color gradient or categorized colors. Legend: clear scale,⚠ Moderate (rendering),⚠ Include text labels for regions. Provide data table alternative.,"D3.js, Mapbox, Leaflet",Pan + Zoom + Drill
8
- 7,Funnel/Flow,funnel/flow,"Funnel Chart, Sankey",Waterfall (for flows),Stages: gradient (starting color → ending color). Show conversion %,⚡ Good,✓ Clear stage labels + percentages. Good for accessibility if labeled.,"D3.js, Recharts, Custom SVG",Hover + Drill
9
- 8,Performance vs Target,performance-vs-target,Gauge Chart or Bullet Chart,"Dial, Thermometer",Performance: Red→Yellow→Green gradient. Target: marker line. Threshold colors,⚡ Good,✓ Add numerical value + percentage label beside gauge.,"D3.js, ApexCharts, Custom SVG",Hover
10
- 9,Time-Series Forecast,time-series-forecast,Line with Confidence Band,Ribbon Chart,Actual: solid line #0080FF. Forecast: dashed #FF9500. Band: light shading,⚡ Good,✓ Clearly distinguish actual vs forecast. Add legend.,"Chart.js, ApexCharts, Plotly",Hover + Toggle
11
- 10,Anomaly Detection,anomaly-detection,Line Chart with Highlights,Scatter with Alert,Normal: blue #0080FF. Anomaly: red #FF0000 circle/square marker + alert,⚡ Good,✓ Circle/marker for anomalies. Add text alert annotation.,"D3.js, Plotly, ApexCharts",Hover + Alert
12
- 11,Hierarchical/Nested Data,hierarchical/nested-data,Treemap,"Sunburst, Nested Donut, Icicle",Parent: distinct hues. Children: lighter shades. White borders 2-3px.,⚠ Moderate,⚠ Poor - provide table alternative. Label large areas.,"D3.js, Recharts, ApexCharts",Hover + Drilldown
13
- 12,Flow/Process Data,flow/process-data,Sankey Diagram,"Alluvial, Chord Diagram",Gradient from source to target. Opacity 0.4-0.6 for flows.,⚠ Moderate,⚠ Poor - provide flow table alternative.,"D3.js (d3-sankey), Plotly",Hover + Drilldown
14
- 13,Cumulative Changes,cumulative-changes,Waterfall Chart,"Stacked Bar, Cascade",Increases: #4CAF50. Decreases: #F44336. Start: #2196F3. End: #0D47A1.,⚡ Good,✓ Good - clear directional colors with labels.,"ApexCharts, Highcharts, Plotly",Hover
15
- 14,Multi-Variable Comparison,multi-variable-comparison,Radar/Spider Chart,"Parallel Coordinates, Grouped Bar",Single: #0080FF 20% fill. Multiple: distinct colors per dataset.,⚡ Good,⚠ Moderate - limit 5-8 axes. Add data table.,"Chart.js, Recharts, ApexCharts",Hover + Toggle
16
- 15,Stock/Trading OHLC,stock/trading-ohlc,Candlestick Chart,"OHLC Bar, Heikin-Ashi",Bullish: #26A69A. Bearish: #EF5350. Volume: 40% opacity below.,⚡ Good,⚠ Moderate - provide OHLC data table.,"Lightweight Charts (TradingView), ApexCharts",Real-time + Hover + Zoom
17
- 16,Relationship/Connection Data,relationship/connection-data,Network Graph,"Hierarchical Tree, Adjacency Matrix",Node types: categorical colors. Edges: #90A4AE 60% opacity.,❌ Poor (500+ nodes struggles),❌ Very Poor - provide adjacency list alternative.,"D3.js (d3-force), Vis.js, Cytoscape.js",Drilldown + Hover + Drag
18
- 17,Distribution/Statistical,distribution/statistical,Box Plot,"Violin Plot, Beeswarm",Box: #BBDEFB. Border: #1976D2. Median: #D32F2F. Outliers: #F44336.,⚡ Excellent,"✓ Good - include stats table (min, Q1, median, Q3, max).","Plotly, D3.js, Chart.js (plugin)",Hover
19
- 18,Performance vs Target (Compact),performance-vs-target-(compact),Bullet Chart,"Gauge, Progress Bar","Ranges: #FFCDD2, #FFF9C4, #C8E6C9. Performance: #1976D2. Target: black 3px.",⚡ Excellent,✓ Excellent - compact with clear values.,"D3.js, Plotly, Custom SVG",Hover
20
- 19,Proportional/Percentage,proportional/percentage,Waffle Chart,"Pictogram, Stacked Bar 100%",10x10 grid. 3-5 categories max. 2-3px spacing between squares.,⚡ Good,✓ Good - better than pie for accessibility.,"D3.js, React-Waffle, Custom CSS Grid",Hover
21
- 20,Hierarchical Proportional,hierarchical-proportional,Sunburst Chart,"Treemap, Icicle, Circle Packing",Center to outer: darker to lighter. 15-20% lighter per level.,⚠ Moderate,⚠ Poor - provide hierarchy table alternative.,"D3.js (d3-hierarchy), Recharts, ApexCharts",Drilldown + Hover
22
- 21,Root Cause Analysis,"root cause, decomposition, tree, hierarchy, drill-down, ai-split",Decomposition Tree,"Decision Tree, Flow Chart",Nodes: #2563EB (Primary) vs #EF4444 (Negative impact). Connectors: Neutral grey.,⚠ Moderate (calculation heavy),✓ clear hierarchy. Allow keyboard navigation for nodes.,"Power BI (native), React-Flow, Custom D3.js",Drill + Expand
23
- 22,3D Spatial Data,"3d, spatial, immersive, terrain, molecular, volumetric",3D Scatter/Surface Plot,"Volumetric Rendering, Point Cloud",Depth cues: lighting/shading. Z-axis: color gradient (cool to warm).,❌ Heavy (WebGL required),❌ Poor - requires alternative 2D view or data table.,"Three.js, Deck.gl, Plotly 3D",Rotate + Zoom + VR
24
- 23,Real-Time Streaming,"streaming, real-time, ticker, live, velocity, pulse",Streaming Area Chart,"Ticker Tape, Moving Gauge",Current: Bright Pulse (#00FF00). History: Fading opacity. Grid: Dark.,⚡ Optimized (canvas/webgl),⚠ Flashing elements - provide pause button. High contrast.,Smoothed D3.js, CanvasJS, SciChart,Real-time + Pause
25
- 24,Sentiment/Emotion,"sentiment, emotion, nlp, opinion, feeling",Word Cloud with Sentiment,"Sentiment Arc, Radar Chart",Positive: #22C55E. Negative: #EF4444. Neutral: #94A3B8. Size = Frequency.,⚡ Good,⚠ Word clouds poor for screen readers. Use list view.,"D3-cloud, Highcharts, Nivo",Hover + Filter
26
- 25,Process Mining,"process, mining, variants, path, bottleneck, log",Process Map / Graph,"Directed Acyclic Graph (DAG), Petri Net",Happy path: #10B981 (Thick). Deviations: #F59E0B (Thin). Bottlenecks: #EF4444.,⚠ Moderate to Heavy,⚠ Complex graphs hard to navigate. Provide path summary.,"React-Flow, Cytoscape.js, Recharts",Drag + Node-Click
@@ -1,97 +0,0 @@
1
- No,Product Type,Keywords,Primary (Hex),Secondary (Hex),CTA (Hex),Background (Hex),Text (Hex),Border (Hex),Notes
2
- 1,SaaS (General),"saas, general",#2563EB,#3B82F6,#F97316,#F8FAFC,#1E293B,#E2E8F0,Trust blue + accent contrast
3
- 2,Micro SaaS,"micro, saas",#2563EB,#3B82F6,#F97316,#F8FAFC,#1E293B,#E2E8F0,Vibrant primary + white space
4
- 3,E-commerce,commerce,#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Brand primary + success green
5
- 4,E-commerce Luxury,"commerce, luxury",#1C1917,#44403C,#CA8A04,#FAFAF9,#0C0A09,#D6D3D1,Premium colors + minimal accent
6
- 5,Service Landing Page,"service, landing, page",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Brand primary + trust colors
7
- 6,B2B Service,"b2b, service",#0F172A,#334155,#0369A1,#F8FAFC,#020617,#E2E8F0,Professional blue + neutral grey
8
- 7,Financial Dashboard,"financial, dashboard",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Dark bg + red/green alerts + trust blue
9
- 8,Analytics Dashboard,"analytics, dashboard",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Cool→Hot gradients + neutral grey
10
- 9,Healthcare App,"healthcare, app",#0891B2,#22D3EE,#059669,#ECFEFF,#164E63,#A5F3FC,Calm blue + health green + trust
11
- 10,Educational App,"educational, app",#4F46E5,#818CF8,#F97316,#EEF2FF,#1E1B4B,#C7D2FE,Playful colors + clear hierarchy
12
- 11,Creative Agency,"creative, agency",#EC4899,#F472B6,#06B6D4,#FDF2F8,#831843,#FBCFE8,Bold primaries + artistic freedom
13
- 12,Portfolio/Personal,"portfolio, personal",#18181B,#3F3F46,#2563EB,#FAFAFA,#09090B,#E4E4E7,Brand primary + artistic interpretation
14
- 13,Gaming,gaming,#7C3AED,#A78BFA,#F43F5E,#0F0F23,#E2E8F0,#4C1D95,Vibrant + neon + immersive colors
15
- 14,Government/Public Service,"government, public, service",#0F172A,#334155,#0369A1,#F8FAFC,#020617,#E2E8F0,Professional blue + high contrast
16
- 15,Fintech/Crypto,"fintech, crypto",#F59E0B,#FBBF24,#8B5CF6,#0F172A,#F8FAFC,#334155,Dark tech colors + trust + vibrant accents
17
- 16,Social Media App,"social, media, app",#2563EB,#60A5FA,#F43F5E,#F8FAFC,#1E293B,#DBEAFE,Vibrant + engagement colors
18
- 17,Productivity Tool,"productivity, tool",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Clear hierarchy + functional colors
19
- 18,Design System/Component Library,"design, system, component, library",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Clear hierarchy + code-like structure
20
- 19,AI/Chatbot Platform,"chatbot, platform",#7C3AED,#A78BFA,#06B6D4,#FAF5FF,#1E1B4B,#DDD6FE,Neutral + AI Purple (#6366F1)
21
- 20,NFT/Web3 Platform,"nft, web3, platform",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Dark + Neon + Gold (#FFD700)
22
- 21,Creator Economy Platform,"creator, economy, platform",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Vibrant + Brand colors
23
- 22,Sustainability/ESG Platform,"sustainability, esg, platform",#7C3AED,#A78BFA,#06B6D4,#FAF5FF,#1E1B4B,#DDD6FE,Green (#228B22) + Earth tones
24
- 23,Remote Work/Collaboration Tool,"remote, work, collaboration, tool",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Calm Blue + Neutral grey
25
- 24,Mental Health App,"mental, health, app",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Calm Pastels + Trust colors
26
- 25,Pet Tech App,"pet, tech, app",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Playful + Warm colors
27
- 26,Smart Home/IoT Dashboard,"smart, home, iot, dashboard",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Dark + Status indicator colors
28
- 27,EV/Charging Ecosystem,"charging, ecosystem",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Electric Blue (#009CD1) + Green
29
- 28,Subscription Box Service,"subscription, box, service",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Brand + Excitement colors
30
- 29,Podcast Platform,"podcast, platform",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Dark + Audio waveform accents
31
- 30,Dating App,"dating, app",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Warm + Romantic (Pink/Red gradients)
32
- 31,Micro-Credentials/Badges Platform,"micro, credentials, badges, platform",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Trust Blue + Gold (#FFD700)
33
- 32,Knowledge Base/Documentation,"knowledge, base, documentation",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Clean hierarchy + minimal color
34
- 33,Hyperlocal Services,"hyperlocal, services",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Location markers + Trust colors
35
- 34,Beauty/Spa/Wellness Service,"beauty, spa, wellness, service",#10B981,#34D399,#8B5CF6,#ECFDF5,#064E3B,#A7F3D0,Soft pastels (Pink #FFB6C1 Sage #90EE90) + Cream + Gold accents
36
- 35,Luxury/Premium Brand,"luxury, premium, brand",#1C1917,#44403C,#CA8A04,#FAFAF9,#0C0A09,#D6D3D1,Black + Gold (#FFD700) + White + Minimal accent
37
- 36,Restaurant/Food Service,"restaurant, food, service",#DC2626,#F87171,#CA8A04,#FEF2F2,#450A0A,#FECACA,Warm colors (Orange Red Brown) + appetizing imagery
38
- 37,Fitness/Gym App,"fitness, gym, app",#DC2626,#F87171,#16A34A,#FEF2F2,#1F2937,#FECACA,Energetic (Orange #FF6B35 Electric Blue) + Dark bg
39
- 38,Real Estate/Property,"real, estate, property",#0F766E,#14B8A6,#0369A1,#F0FDFA,#134E4A,#99F6E4,Trust Blue (#0077B6) + Gold accents + White
40
- 39,Travel/Tourism Agency,"travel, tourism, agency",#EC4899,#F472B6,#06B6D4,#FDF2F8,#831843,#FBCFE8,Vibrant destination colors + Sky Blue + Warm accents
41
- 40,Hotel/Hospitality,"hotel, hospitality",#1E3A8A,#3B82F6,#CA8A04,#F8FAFC,#1E40AF,#BFDBFE,Warm neutrals + Gold (#D4AF37) + Brand accent
42
- 41,Wedding/Event Planning,"wedding, event, planning",#7C3AED,#A78BFA,#F97316,#FAF5FF,#4C1D95,#DDD6FE,Soft Pink (#FFD6E0) + Gold + Cream + Sage
43
- 42,Legal Services,"legal, services",#1E3A8A,#1E40AF,#B45309,#F8FAFC,#0F172A,#CBD5E1,Navy Blue (#1E3A5F) + Gold + White
44
- 43,Insurance Platform,"insurance, platform",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Trust Blue (#0066CC) + Green (security) + Neutral
45
- 44,Banking/Traditional Finance,"banking, traditional, finance",#0F766E,#14B8A6,#0369A1,#F0FDFA,#134E4A,#99F6E4,Navy (#0A1628) + Trust Blue + Gold accents
46
- 45,Online Course/E-learning,"online, course, learning",#0D9488,#2DD4BF,#EA580C,#F0FDFA,#134E4A,#5EEAD4,Vibrant learning colors + Progress green
47
- 46,Non-profit/Charity,"non, profit, charity",#0891B2,#22D3EE,#F97316,#ECFEFF,#164E63,#A5F3FC,Cause-related colors + Trust + Warm
48
- 47,Music Streaming,"music, streaming",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Dark (#121212) + Vibrant accents + Album art colors
49
- 48,Video Streaming/OTT,"video, streaming, ott",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Dark bg + Content poster colors + Brand accent
50
- 49,Job Board/Recruitment,"job, board, recruitment",#0F172A,#334155,#0369A1,#F8FAFC,#020617,#E2E8F0,Professional Blue + Success Green + Neutral
51
- 50,Marketplace (P2P),"marketplace, p2p",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Trust colors + Category colors + Success green
52
- 51,Logistics/Delivery,"logistics, delivery",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Blue (#2563EB) + Orange (tracking) + Green (delivered)
53
- 52,Agriculture/Farm Tech,"agriculture, farm, tech",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Earth Green (#4A7C23) + Brown + Sky Blue
54
- 53,Construction/Architecture,"construction, architecture",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Grey (#4A4A4A) + Orange (safety) + Blueprint Blue
55
- 54,Automotive/Car Dealership,"automotive, car, dealership",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Brand colors + Metallic accents + Dark/Light
56
- 55,Photography Studio,"photography, studio",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Black + White + Minimal accent
57
- 56,Coworking Space,"coworking, space",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Energetic colors + Wood tones + Brand accent
58
- 57,Cleaning Service,"cleaning, service",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Fresh Blue (#00B4D8) + Clean White + Green
59
- 58,Home Services (Plumber/Electrician),"home, services, plumber, electrician",#0F172A,#334155,#0369A1,#F8FAFC,#020617,#E2E8F0,Trust Blue + Safety Orange + Professional grey
60
- 59,Childcare/Daycare,"childcare, daycare",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Playful pastels + Safe colors + Warm accents
61
- 60,Senior Care/Elderly,"senior, care, elderly",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Calm Blue + Warm neutrals + Large text
62
- 61,Medical Clinic,"medical, clinic",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Medical Blue (#0077B6) + Trust White + Calm Green
63
- 62,Pharmacy/Drug Store,"pharmacy, drug, store",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Pharmacy Green + Trust Blue + Clean White
64
- 63,Dental Practice,"dental, practice",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Fresh Blue + White + Smile Yellow accent
65
- 64,Veterinary Clinic,"veterinary, clinic",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Caring Blue + Pet-friendly colors + Warm accents
66
- 65,Florist/Plant Shop,"florist, plant, shop",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Natural Green + Floral pinks/purples + Earth tones
67
- 66,Bakery/Cafe,"bakery, cafe",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Warm Brown + Cream + Appetizing accents
68
- 67,Coffee Shop,"coffee, shop",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Coffee Brown (#6F4E37) + Cream + Warm accents
69
- 68,Brewery/Winery,"brewery, winery",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Deep amber/burgundy + Gold + Craft aesthetic
70
- 69,Airline,airline,#7C3AED,#A78BFA,#06B6D4,#FAF5FF,#1E1B4B,#DDD6FE,Sky Blue + Brand colors + Trust accents
71
- 70,News/Media Platform,"news, media, platform",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Brand colors + High contrast + Category colors
72
- 71,Magazine/Blog,"magazine, blog",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Editorial colors + Brand primary + Clean white
73
- 72,Freelancer Platform,"freelancer, platform",#0F172A,#334155,#0369A1,#F8FAFC,#020617,#E2E8F0,Professional Blue + Success Green + Neutral
74
- 73,Consulting Firm,"consulting, firm",#0F172A,#334155,#0369A1,#F8FAFC,#020617,#E2E8F0,Navy + Gold + Professional grey
75
- 74,Marketing Agency,"marketing, agency",#EC4899,#F472B6,#06B6D4,#FDF2F8,#831843,#FBCFE8,Bold brand colors + Creative freedom
76
- 75,Event Management,"event, management",#7C3AED,#A78BFA,#F97316,#FAF5FF,#4C1D95,#DDD6FE,Event theme colors + Excitement accents
77
- 76,Conference/Webinar Platform,"conference, webinar, platform",#0F172A,#334155,#0369A1,#F8FAFC,#020617,#E2E8F0,Professional Blue + Video accent + Brand
78
- 77,Membership/Community,"membership, community",#7C3AED,#A78BFA,#F97316,#FAF5FF,#4C1D95,#DDD6FE,Community brand colors + Engagement accents
79
- 78,Newsletter Platform,"newsletter, platform",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Brand primary + Clean white + CTA accent
80
- 79,Digital Products/Downloads,"digital, products, downloads",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Product category colors + Brand + Success green
81
- 80,Church/Religious Organization,"church, religious, organization",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Warm Gold + Deep Purple/Blue + White
82
- 81,Sports Team/Club,"sports, team, club",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Team colors + Energetic accents
83
- 82,Museum/Gallery,"museum, gallery",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Art-appropriate neutrals + Exhibition accents
84
- 83,Theater/Cinema,"theater, cinema",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Dark + Spotlight accents + Gold
85
- 84,Language Learning App,"language, learning, app",#0D9488,#2DD4BF,#EA580C,#F0FDFA,#134E4A,#5EEAD4,Playful colors + Progress indicators + Country flags
86
- 85,Coding Bootcamp,"coding, bootcamp",#3B82F6,#60A5FA,#F97316,#F8FAFC,#1E293B,#E2E8F0,Code editor colors + Brand + Success green
87
- 86,Cybersecurity Platform,"cybersecurity, security, cyber, hacker",#00FF41,#0D0D0D,#00FF41,#000000,#E0E0E0,#1F1F1F,Matrix Green + Deep Black + Terminal feel
88
- 87,Developer Tool / IDE,"developer, tool, ide, code, dev",#3B82F6,#1E293B,#2563EB,#0F172A,#F1F5F9,#334155,Dark syntax theme colors + Blue focus
89
- 88,Biotech / Life Sciences,"biotech, science, biology, medical",#0EA5E9,#0284C7,#10B981,#F8FAFC,#0F172A,#E2E8F0,Sterile White + DNA Blue + Life Green
90
- 89,Space Tech / Aerospace,"space, aerospace, tech, futuristic",#FFFFFF,#94A3B8,#3B82F6,#0B0B10,#F8FAFC,#1E293B,Deep Space Black + Star White + Metallic
91
- 90,Architecture / Interior,"architecture, interior, design, luxury",#171717,#404040,#D4AF37,#FFFFFF,#171717,#E5E5E5,Monochrome + Gold Accent + High Imagery
92
- 91,Quantum Computing,"quantum, qubit, tech",#00FFFF,#7B61FF,#FF00FF,#050510,#E0E0FF,#333344,Interference patterns + Neon + Deep Dark
93
- 92,Biohacking / Longevity,"bio, health, science",#FF4D4D,#4D94FF,#00E676,#F5F5F7,#1C1C1E,#E5E5EA,Biological red/blue + Clinical white
94
- 93,Autonomous Systems,"drone, robot, fleet",#00FF41,#008F11,#FF3333,#0D1117,#E6EDF3,#30363D,Terminal Green + Tactical Dark
95
- 94,Generative AI Art,"art, gen-ai, creative",#111111,#333333,#FFFFFF,#FAFAFA,#000000,#E5E5E5,Canvas Neutral + High Contrast
96
- 95,Spatial / Vision OS,"spatial, glass, vision",#FFFFFF,#E5E5E5,#007AFF,#888888,#000000,#FFFFFF,Glass opacity 20% + System Blue
97
- 96,Climate Tech,"climate, green, energy",#2E8B57,#87CEEB,#FFD700,#F0FFF4,#1A3320,#C6E6C6,Nature Green + Solar Yellow + Air Blue
@@ -1,101 +0,0 @@
1
- STT,Category,Icon Name,Keywords,Library,Import Code,Usage,Best For,Style
2
- 1,Navigation,menu,hamburger menu navigation toggle bars,Lucide,import { Menu } from 'lucide-react',<Menu />,Mobile navigation drawer toggle sidebar,Outline
3
- 2,Navigation,arrow-left,back previous return navigate,Lucide,import { ArrowLeft } from 'lucide-react',<ArrowLeft />,Back button breadcrumb navigation,Outline
4
- 3,Navigation,arrow-right,next forward continue navigate,Lucide,import { ArrowRight } from 'lucide-react',<ArrowRight />,Forward button next step CTA,Outline
5
- 4,Navigation,chevron-down,dropdown expand accordion select,Lucide,import { ChevronDown } from 'lucide-react',<ChevronDown />,Dropdown toggle accordion header,Outline
6
- 5,Navigation,chevron-up,collapse close accordion minimize,Lucide,import { ChevronUp } from 'lucide-react',<ChevronUp />,Accordion collapse minimize,Outline
7
- 6,Navigation,home,homepage main dashboard start,Lucide,import { Home } from 'lucide-react',<Home />,Home navigation main page,Outline
8
- 7,Navigation,x,close cancel dismiss remove exit,Lucide,import { X } from 'lucide-react',<X />,Modal close dismiss button,Outline
9
- 8,Navigation,external-link,open new tab external link,Lucide,import { ExternalLink } from 'lucide-react',<ExternalLink />,External link indicator,Outline
10
- 9,Action,plus,add create new insert,Lucide,import { Plus } from 'lucide-react',<Plus />,Add button create new item,Outline
11
- 10,Action,minus,remove subtract decrease delete,Lucide,import { Minus } from 'lucide-react',<Minus />,Remove item quantity decrease,Outline
12
- 11,Action,trash-2,delete remove discard bin,Lucide,import { Trash2 } from 'lucide-react',<Trash2 />,Delete action destructive,Outline
13
- 12,Action,edit,pencil modify change update,Lucide,import { Edit } from 'lucide-react',<Edit />,Edit button modify content,Outline
14
- 13,Action,save,disk store persist save,Lucide,import { Save } from 'lucide-react',<Save />,Save button persist changes,Outline
15
- 14,Action,download,export save file download,Lucide,import { Download } from 'lucide-react',<Download />,Download file export,Outline
16
- 15,Action,upload,import file attach upload,Lucide,import { Upload } from 'lucide-react',<Upload />,Upload file import,Outline
17
- 16,Action,copy,duplicate clipboard paste,Lucide,import { Copy } from 'lucide-react',<Copy />,Copy to clipboard,Outline
18
- 17,Action,share,social distribute send,Lucide,import { Share } from 'lucide-react',<Share />,Share button social,Outline
19
- 18,Action,search,find lookup filter query,Lucide,import { Search } from 'lucide-react',<Search />,Search input bar,Outline
20
- 19,Action,filter,sort refine narrow options,Lucide,import { Filter } from 'lucide-react',<Filter />,Filter dropdown sort,Outline
21
- 20,Action,settings,gear cog preferences config,Lucide,import { Settings } from 'lucide-react',<Settings />,Settings page configuration,Outline
22
- 21,Status,check,success done complete verified,Lucide,import { Check } from 'lucide-react',<Check />,Success state checkmark,Outline
23
- 22,Status,check-circle,success verified approved complete,Lucide,import { CheckCircle } from 'lucide-react',<CheckCircle />,Success badge verified,Outline
24
- 23,Status,x-circle,error failed cancel rejected,Lucide,import { XCircle } from 'lucide-react',<XCircle />,Error state failed,Outline
25
- 24,Status,alert-triangle,warning caution attention danger,Lucide,import { AlertTriangle } from 'lucide-react',<AlertTriangle />,Warning message caution,Outline
26
- 25,Status,alert-circle,info notice information help,Lucide,import { AlertCircle } from 'lucide-react',<AlertCircle />,Info notice alert,Outline
27
- 26,Status,info,information help tooltip details,Lucide,import { Info } from 'lucide-react',<Info />,Information tooltip help,Outline
28
- 27,Status,loader,loading spinner processing wait,Lucide,import { Loader } from 'lucide-react',<Loader className="animate-spin" />,Loading state spinner,Outline
29
- 28,Status,clock,time schedule pending wait,Lucide,import { Clock } from 'lucide-react',<Clock />,Pending time schedule,Outline
30
- 29,Communication,mail,email message inbox letter,Lucide,import { Mail } from 'lucide-react',<Mail />,Email contact inbox,Outline
31
- 30,Communication,message-circle,chat comment bubble conversation,Lucide,import { MessageCircle } from 'lucide-react',<MessageCircle />,Chat comment message,Outline
32
- 31,Communication,phone,call mobile telephone contact,Lucide,import { Phone } from 'lucide-react',<Phone />,Phone contact call,Outline
33
- 32,Communication,send,submit dispatch message airplane,Lucide,import { Send } from 'lucide-react',<Send />,Send message submit,Outline
34
- 33,Communication,bell,notification alert ring reminder,Lucide,import { Bell } from 'lucide-react',<Bell />,Notification bell alert,Outline
35
- 34,User,user,profile account person avatar,Lucide,import { User } from 'lucide-react',<User />,User profile account,Outline
36
- 35,User,users,team group people members,Lucide,import { Users } from 'lucide-react',<Users />,Team group members,Outline
37
- 36,User,user-plus,add invite new member,Lucide,import { UserPlus } from 'lucide-react',<UserPlus />,Add user invite,Outline
38
- 37,User,log-in,signin authenticate enter,Lucide,import { LogIn } from 'lucide-react',<LogIn />,Login signin,Outline
39
- 38,User,log-out,signout exit leave logout,Lucide,import { LogOut } from 'lucide-react',<LogOut />,Logout signout,Outline
40
- 39,Media,image,photo picture gallery thumbnail,Lucide,import { Image } from 'lucide-react',<Image />,Image photo gallery,Outline
41
- 40,Media,video,movie film play record,Lucide,import { Video } from 'lucide-react',<Video />,Video player media,Outline
42
- 41,Media,play,start video audio media,Lucide,import { Play } from 'lucide-react',<Play />,Play button video audio,Outline
43
- 42,Media,pause,stop halt video audio,Lucide,import { Pause } from 'lucide-react',<Pause />,Pause button media,Outline
44
- 43,Media,volume-2,sound audio speaker music,Lucide,import { Volume2 } from 'lucide-react',<Volume2 />,Volume audio sound,Outline
45
- 44,Media,mic,microphone record voice audio,Lucide,import { Mic } from 'lucide-react',<Mic />,Microphone voice record,Outline
46
- 45,Media,camera,photo capture snapshot picture,Lucide,import { Camera } from 'lucide-react',<Camera />,Camera photo capture,Outline
47
- 46,Commerce,shopping-cart,cart checkout basket buy,Lucide,import { ShoppingCart } from 'lucide-react',<ShoppingCart />,Shopping cart e-commerce,Outline
48
- 47,Commerce,shopping-bag,purchase buy store bag,Lucide,import { ShoppingBag } from 'lucide-react',<ShoppingBag />,Shopping bag purchase,Outline
49
- 48,Commerce,credit-card,payment card checkout stripe,Lucide,import { CreditCard } from 'lucide-react',<CreditCard />,Payment credit card,Outline
50
- 49,Commerce,dollar-sign,money price currency cost,Lucide,import { DollarSign } from 'lucide-react',<DollarSign />,Price money currency,Outline
51
- 50,Commerce,tag,label price discount sale,Lucide,import { Tag } from 'lucide-react',<Tag />,Price tag label,Outline
52
- 51,Commerce,gift,present reward bonus offer,Lucide,import { Gift } from 'lucide-react',<Gift />,Gift reward offer,Outline
53
- 52,Commerce,percent,discount sale offer promo,Lucide,import { Percent } from 'lucide-react',<Percent />,Discount percentage sale,Outline
54
- 53,Data,bar-chart,analytics statistics graph metrics,Lucide,import { BarChart } from 'lucide-react',<BarChart />,Bar chart analytics,Outline
55
- 54,Data,pie-chart,statistics distribution breakdown,Lucide,import { PieChart } from 'lucide-react',<PieChart />,Pie chart distribution,Outline
56
- 55,Data,trending-up,growth increase positive trend,Lucide,import { TrendingUp } from 'lucide-react',<TrendingUp />,Growth trend positive,Outline
57
- 56,Data,trending-down,decline decrease negative trend,Lucide,import { TrendingDown } from 'lucide-react',<TrendingDown />,Decline trend negative,Outline
58
- 57,Data,activity,pulse heartbeat monitor live,Lucide,import { Activity } from 'lucide-react',<Activity />,Activity monitor pulse,Outline
59
- 58,Data,database,storage server data backend,Lucide,import { Database } from 'lucide-react',<Database />,Database storage,Outline
60
- 59,Files,file,document page paper doc,Lucide,import { File } from 'lucide-react',<File />,File document,Outline
61
- 60,Files,file-text,document text page article,Lucide,import { FileText } from 'lucide-react',<FileText />,Text document article,Outline
62
- 61,Files,folder,directory organize group files,Lucide,import { Folder } from 'lucide-react',<Folder />,Folder directory,Outline
63
- 62,Files,folder-open,expanded browse files view,Lucide,import { FolderOpen } from 'lucide-react',<FolderOpen />,Open folder browse,Outline
64
- 63,Files,paperclip,attachment attach file link,Lucide,import { Paperclip } from 'lucide-react',<Paperclip />,Attachment paperclip,Outline
65
- 64,Files,link,url hyperlink chain connect,Lucide,import { Link } from 'lucide-react',<Link />,Link URL hyperlink,Outline
66
- 65,Files,clipboard,paste copy buffer notes,Lucide,import { Clipboard } from 'lucide-react',<Clipboard />,Clipboard paste,Outline
67
- 66,Layout,grid,tiles gallery layout dashboard,Lucide,import { Grid } from 'lucide-react',<Grid />,Grid layout gallery,Outline
68
- 67,Layout,list,rows table lines items,Lucide,import { List } from 'lucide-react',<List />,List view rows,Outline
69
- 68,Layout,columns,layout split dual sidebar,Lucide,import { Columns } from 'lucide-react',<Columns />,Column layout split,Outline
70
- 69,Layout,maximize,fullscreen expand enlarge zoom,Lucide,import { Maximize } from 'lucide-react',<Maximize />,Fullscreen maximize,Outline
71
- 70,Layout,minimize,reduce shrink collapse exit,Lucide,import { Minimize } from 'lucide-react',<Minimize />,Minimize reduce,Outline
72
- 71,Layout,sidebar,panel drawer navigation menu,Lucide,import { Sidebar } from 'lucide-react',<Sidebar />,Sidebar panel,Outline
73
- 72,Social,heart,like love favorite wishlist,Lucide,import { Heart } from 'lucide-react',<Heart />,Like favorite love,Outline
74
- 73,Social,star,rating review favorite bookmark,Lucide,import { Star } from 'lucide-react',<Star />,Star rating favorite,Outline
75
- 74,Social,thumbs-up,like approve agree positive,Lucide,import { ThumbsUp } from 'lucide-react',<ThumbsUp />,Like approve thumb,Outline
76
- 75,Social,thumbs-down,dislike disapprove disagree negative,Lucide,import { ThumbsDown } from 'lucide-react',<ThumbsDown />,Dislike disapprove,Outline
77
- 76,Social,bookmark,save later favorite mark,Lucide,import { Bookmark } from 'lucide-react',<Bookmark />,Bookmark save,Outline
78
- 77,Social,flag,report mark important highlight,Lucide,import { Flag } from 'lucide-react',<Flag />,Flag report,Outline
79
- 78,Device,smartphone,mobile phone device touch,Lucide,import { Smartphone } from 'lucide-react',<Smartphone />,Mobile smartphone,Outline
80
- 79,Device,tablet,ipad device touch screen,Lucide,import { Tablet } from 'lucide-react',<Tablet />,Tablet device,Outline
81
- 80,Device,monitor,desktop screen computer display,Lucide,import { Monitor } from 'lucide-react',<Monitor />,Desktop monitor,Outline
82
- 81,Device,laptop,notebook computer portable device,Lucide,import { Laptop } from 'lucide-react',<Laptop />,Laptop computer,Outline
83
- 82,Device,printer,print document output paper,Lucide,import { Printer } from 'lucide-react',<Printer />,Printer print,Outline
84
- 83,Security,lock,secure password protected private,Lucide,import { Lock } from 'lucide-react',<Lock />,Lock secure,Outline
85
- 84,Security,unlock,open access unsecure public,Lucide,import { Unlock } from 'lucide-react',<Unlock />,Unlock open,Outline
86
- 85,Security,shield,protection security safe guard,Lucide,import { Shield } from 'lucide-react',<Shield />,Shield protection,Outline
87
- 86,Security,key,password access unlock login,Lucide,import { Key } from 'lucide-react',<Key />,Key password,Outline
88
- 87,Security,eye,view show visible password,Lucide,import { Eye } from 'lucide-react',<Eye />,Show password view,Outline
89
- 88,Security,eye-off,hide invisible password hidden,Lucide,import { EyeOff } from 'lucide-react',<EyeOff />,Hide password,Outline
90
- 89,Location,map-pin,location marker place address,Lucide,import { MapPin } from 'lucide-react',<MapPin />,Location pin marker,Outline
91
- 90,Location,map,directions navigate geography location,Lucide,import { Map } from 'lucide-react',<Map />,Map directions,Outline
92
- 91,Location,navigation,compass direction pointer arrow,Lucide,import { Navigation } from 'lucide-react',<Navigation />,Navigation compass,Outline
93
- 92,Location,globe,world international global web,Lucide,import { Globe } from 'lucide-react',<Globe />,Globe world,Outline
94
- 93,Time,calendar,date schedule event appointment,Lucide,import { Calendar } from 'lucide-react',<Calendar />,Calendar date,Outline
95
- 94,Time,refresh-cw,reload sync update refresh,Lucide,import { RefreshCw } from 'lucide-react',<RefreshCw />,Refresh reload,Outline
96
- 95,Time,rotate-ccw,undo back revert history,Lucide,import { RotateCcw } from 'lucide-react',<RotateCcw />,Undo revert,Outline
97
- 96,Time,rotate-cw,redo forward repeat history,Lucide,import { RotateCw } from 'lucide-react',<RotateCw />,Redo forward,Outline
98
- 97,Development,code,develop programming syntax html,Lucide,import { Code } from 'lucide-react',<Code />,Code development,Outline
99
- 98,Development,terminal,console cli command shell,Lucide,import { Terminal } from 'lucide-react',<Terminal />,Terminal console,Outline
100
- 99,Development,git-branch,version control branch merge,Lucide,import { GitBranch } from 'lucide-react',<GitBranch />,Git branch,Outline
101
- 100,Development,github,repository code open source,Lucide,import { Github } from 'lucide-react',<Github />,GitHub repository,Outline