cmcts-c-agent-embedding 1.0.27 → 1.0.29-cagent

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 (106) hide show
  1. package/.eslintrc.cjs +1 -0
  2. package/.idea/{Flowise-share-chatbox.iml → flowise-chatbox.iml} +0 -1
  3. package/.idea/modules.xml +1 -2
  4. package/.idea/vcs.xml +5 -6
  5. package/AGENTS.md +166 -0
  6. package/README.md +349 -349
  7. package/dist/BubbleChat.d.ts +9 -12
  8. package/dist/BubbleChat.d.ts.map +1 -1
  9. package/dist/FullPageChat.d.ts +17 -17
  10. package/dist/components/Bot.d.ts +11 -0
  11. package/dist/components/Bot.d.ts.map +1 -1
  12. package/dist/components/FeedbackContentDialog.d.ts.map +1 -1
  13. package/dist/components/Toast.d.ts +10 -0
  14. package/dist/components/Toast.d.ts.map +1 -0
  15. package/dist/components/bubbles/BotBubble.d.ts +7 -0
  16. package/dist/components/bubbles/BotBubble.d.ts.map +1 -1
  17. package/dist/components/bubbles/ChartBubble.d.ts +9 -0
  18. package/dist/components/bubbles/ChartBubble.d.ts.map +1 -0
  19. package/dist/components/bubbles/ChartLoadingPlaceholder.d.ts +8 -0
  20. package/dist/components/bubbles/ChartLoadingPlaceholder.d.ts.map +1 -0
  21. package/dist/components/bubbles/ChartPlaceholder.d.ts +16 -0
  22. package/dist/components/bubbles/ChartPlaceholder.d.ts.map +1 -0
  23. package/dist/components/bubbles/ChartPortalContainer.d.ts +12 -0
  24. package/dist/components/bubbles/ChartPortalContainer.d.ts.map +1 -0
  25. package/dist/components/bubbles/LoadingBubble.d.ts +7 -1
  26. package/dist/components/bubbles/LoadingBubble.d.ts.map +1 -1
  27. package/dist/components/bubbles/SourceBubble.d.ts.map +1 -1
  28. package/dist/components/bubbles/StableChartWrapper.d.ts +16 -0
  29. package/dist/components/bubbles/StableChartWrapper.d.ts.map +1 -0
  30. package/dist/components/bubbles/StarterPromptBubble.d.ts.map +1 -1
  31. package/dist/components/buttons/CopyMessageButton.d.ts +10 -0
  32. package/dist/components/buttons/CopyMessageButton.d.ts.map +1 -0
  33. package/dist/components/buttons/EditMessageButton.d.ts +8 -0
  34. package/dist/components/buttons/EditMessageButton.d.ts.map +1 -0
  35. package/dist/components/buttons/PopupToast.d.ts +7 -0
  36. package/dist/components/buttons/PopupToast.d.ts.map +1 -0
  37. package/dist/components/buttons/SendButton.d.ts +1 -0
  38. package/dist/components/buttons/SendButton.d.ts.map +1 -1
  39. package/dist/components/dialogs/EditMessageDialog.d.ts +9 -0
  40. package/dist/components/dialogs/EditMessageDialog.d.ts.map +1 -0
  41. package/dist/components/icons/AddImageIcon.d.ts.map +1 -1
  42. package/dist/components/icons/CheckIcon.d.ts +3 -0
  43. package/dist/components/icons/CheckIcon.d.ts.map +1 -0
  44. package/dist/components/icons/CopyIcon.d.ts +5 -0
  45. package/dist/components/icons/CopyIcon.d.ts.map +1 -0
  46. package/dist/components/icons/EditIcon.d.ts +5 -0
  47. package/dist/components/icons/EditIcon.d.ts.map +1 -0
  48. package/dist/components/icons/FullScreenIcon.d.ts +3 -0
  49. package/dist/components/icons/FullScreenIcon.d.ts.map +1 -0
  50. package/dist/components/icons/index.d.ts +4 -0
  51. package/dist/components/icons/index.d.ts.map +1 -1
  52. package/dist/components/image/PreviewImage.d.ts +5 -0
  53. package/dist/components/image/PreviewImage.d.ts.map +1 -0
  54. package/dist/components/inputs/textInput/components/ShortTextInput.d.ts +4 -0
  55. package/dist/components/inputs/textInput/components/ShortTextInput.d.ts.map +1 -1
  56. package/dist/components/inputs/textInput/components/TextInput.d.ts +16 -1
  57. package/dist/components/inputs/textInput/components/TextInput.d.ts.map +1 -1
  58. package/dist/constants.d.ts.map +1 -1
  59. package/dist/features/bubble/components/Bubble.d.ts.map +1 -1
  60. package/dist/features/bubble/types.d.ts +1 -0
  61. package/dist/features/bubble/types.d.ts.map +1 -1
  62. package/dist/features/full/components/Full.d.ts.map +1 -1
  63. package/dist/features/popup/components/Popup.d.ts.map +1 -1
  64. package/dist/index.js +1 -1
  65. package/dist/queries/sendMessageQuery.d.ts +26 -0
  66. package/dist/queries/sendMessageQuery.d.ts.map +1 -1
  67. package/dist/types/chart.d.ts +72 -0
  68. package/dist/types/chart.d.ts.map +1 -0
  69. package/dist/utils/chartInstanceManager.d.ts +43 -0
  70. package/dist/utils/chartInstanceManager.d.ts.map +1 -0
  71. package/dist/utils/chartPortalManager.d.ts +76 -0
  72. package/dist/utils/chartPortalManager.d.ts.map +1 -0
  73. package/dist/utils/chartTagParser.d.ts +39 -0
  74. package/dist/utils/chartTagParser.d.ts.map +1 -0
  75. package/dist/utils/index.d.ts +4 -0
  76. package/dist/utils/index.d.ts.map +1 -1
  77. package/dist/utils/textStreamSmoother.d.ts +40 -0
  78. package/dist/utils/textStreamSmoother.d.ts.map +1 -0
  79. package/dist/utils/transcriptApi.d.ts +8 -0
  80. package/dist/utils/transcriptApi.d.ts.map +1 -0
  81. package/dist/utils/ultimateJsonParser.d.ts +2 -0
  82. package/dist/utils/ultimateJsonParser.d.ts.map +1 -0
  83. package/dist/web.d.ts +4 -0
  84. package/dist/web.d.ts.map +1 -1
  85. package/dist/web.js +1 -1
  86. package/dist/window.d.ts +2 -0
  87. package/dist/window.d.ts.map +1 -1
  88. package/docs/chart-rendering-implementation-plan.md +565 -0
  89. package/package.json +9 -5
  90. package/public/index.html +6 -115
  91. package/server.js +401 -401
  92. package/.env +0 -36
  93. package/.husky/pre-commit +0 -18
  94. package/.idea/codeStyles/Project.xml +0 -60
  95. package/.idea/codeStyles/codeStyleConfig.xml +0 -5
  96. package/.idea/inspectionProfiles/Project_Default.xml +0 -16
  97. package/.idea/prettier.xml +0 -6
  98. package/a.json +0 -57
  99. package/bun.lockb +0 -0
  100. package/dist/components/ImageUploadButton.d.ts +0 -11
  101. package/dist/components/ImageUploadButton.d.ts.map +0 -1
  102. package/dist/components/RecordAudioButton.d.ts +0 -11
  103. package/dist/components/RecordAudioButton.d.ts.map +0 -1
  104. package/dist/components/SendButton.d.ts +0 -12
  105. package/dist/components/SendButton.d.ts.map +0 -1
  106. package/test.html +0 -17
package/.eslintrc.cjs CHANGED
@@ -1,3 +1,4 @@
1
+ // eslint-disable-next-line no-undef
1
2
  module.exports = {
2
3
  root: true,
3
4
  extends: ['eslint:recommended', 'plugin:@typescript-eslint/recommended', 'prettier', 'plugin:solid/typescript'],
@@ -8,6 +8,5 @@
8
8
  </content>
9
9
  <orderEntry type="inheritedJdk" />
10
10
  <orderEntry type="sourceFolder" forTests="false" />
11
- <orderEntry type="module" module-name="Flowise-share-chatbox-main" />
12
11
  </component>
13
12
  </module>
package/.idea/modules.xml CHANGED
@@ -2,8 +2,7 @@
2
2
  <project version="4">
3
3
  <component name="ProjectModuleManager">
4
4
  <modules>
5
- <module fileurl="file://$PROJECT_DIR$/.idea/Flowise-share-chatbox.iml" filepath="$PROJECT_DIR$/.idea/Flowise-share-chatbox.iml" />
6
- <module fileurl="file://$PROJECT_DIR$/../Flowise-share-chatbox-main/.idea/Flowise-share-chatbox-main.iml" filepath="$PROJECT_DIR$/../Flowise-share-chatbox-main/.idea/Flowise-share-chatbox-main.iml" />
5
+ <module fileurl="file://$PROJECT_DIR$/.idea/flowise-chatbox.iml" filepath="$PROJECT_DIR$/.idea/flowise-chatbox.iml" />
7
6
  </modules>
8
7
  </component>
9
8
  </project>
package/.idea/vcs.xml CHANGED
@@ -1,7 +1,6 @@
1
- <?xml version="1.0" encoding="UTF-8"?>
2
- <project version="4">
3
- <component name="VcsDirectoryMappings">
4
- <mapping directory="" vcs="Git" />
5
- <mapping directory="$PROJECT_DIR$/../Flowise-share-chatbox-main" vcs="Git" />
6
- </component>
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <project version="4">
3
+ <component name="VcsDirectoryMappings">
4
+ <mapping directory="" vcs="Git" />
5
+ </component>
7
6
  </project>
package/AGENTS.md ADDED
@@ -0,0 +1,166 @@
1
+ # AGENTS.md - Coding Guidelines
2
+
3
+ > **Purpose:** Guidelines for code quality, development process, and decision-making
4
+ > **Target Audience:** AI coding assistants and developers
5
+ > **Version:** 1.0
6
+
7
+ ---
8
+
9
+ ## Code Quality Standards
10
+
11
+ ### Core Principles
12
+
13
+ #### No Unused Code
14
+ - **Rule:** Don't write unused code
15
+ - **Requirement:** Ensure everything written is utilized in the project
16
+ - **Priority:** Critical
17
+
18
+ #### Readability First
19
+ - **Rule:** Prioritize readability for human understanding over execution efficiency
20
+ - **Priority:** Critical
21
+
22
+ #### Maintainability
23
+ - **Rule:** Maintain long-term maintainability over short-term optimization
24
+ - **Priority:** High
25
+
26
+ #### Simplicity
27
+ - **Rule:** Avoid unnecessary complexity
28
+ - **Approach:** Implement simple solutions unless complexity is truly required
29
+ - **Priority:** High
30
+
31
+ #### Clean Code Philosophy
32
+ - **Rule:** Follow Linus Torvalds' clean code principles
33
+ - **Priority:** High
34
+ - **Guidelines:**
35
+ 1. Keep it simple
36
+ 2. Make code readable like prose
37
+ 3. Avoid premature optimization
38
+ 4. Express intent clearly
39
+ 5. Minimize abstraction layers
40
+
41
+ ---
42
+
43
+ ### Documentation Standards
44
+
45
+ #### Comment Purpose
46
+ - **Rule:** Comments must explain "what" (business logic/purpose) and "why" (reasoning/decisions), not "how"
47
+ - **Priority:** High
48
+
49
+ #### Avoid Over-Commenting
50
+ - **Rule:** Avoid over-commenting
51
+ - **Rationale:** Excessive comments indicate poor code quality
52
+ - **Priority:** Medium
53
+
54
+ #### Function Comments
55
+ - **Rule:** Function comments must explain purpose and reasoning
56
+ - **Placement:** Placed at function beginnings
57
+ - **Priority:** Medium
58
+
59
+ #### Self-Explanatory Code
60
+ - **Rule:** Well-written code should be self-explanatory
61
+ - **Method:** Through meaningful names and clear structure
62
+ - **Priority:** High
63
+
64
+ ---
65
+
66
+ ## Development Process
67
+
68
+ > **Description:** Follow these steps in order for effective development
69
+ > **Priority:** Critical
70
+
71
+ | Step | Name | Action/Rationale | Importance |
72
+ |------|------|------------------|------------|
73
+ | 1 | Understand First | Use available tools to understand data structures before implementation | Critical |
74
+ | 2 | Design Data Structures | Good data structures lead to good code | Critical |
75
+ | 3 | Define Interfaces | Specify all input/output structures before writing logic | High |
76
+ | 4 | Define Functions | Create all function signatures before implementation | High |
77
+ | 5 | Implement Logic | Write implementation only after structures and definitions are complete | High |
78
+ | 6 | Validate Code Quality | Always run lint and typecheck after writing code. Fix all linting errors and type errors before considering the task complete. Zero tolerance for lint and typecheck errors | Critical |
79
+
80
+ ---
81
+
82
+ ## Quality Guidelines
83
+
84
+ #### Avoid Over-Engineering
85
+ - **Rule:** Avoid over-engineering
86
+ - **Focus:** Focus on minimal viable solutions meeting acceptance criteria
87
+ - **Priority:** High
88
+
89
+ #### Testing Approach
90
+ - **Rule:** Only create automated tests if explicitly required
91
+ - **Priority:** Medium
92
+
93
+ #### Feature Scope
94
+ - **Rule:** Never add functionality "just in case"
95
+ - **Requirement:** Implement only what's needed now
96
+ - **Priority:** High
97
+
98
+ #### Code Validation
99
+ - **Rule:** Always run lint and typecheck after code changes
100
+ - **Requirement:** Must fix all linting and type checking errors before completion
101
+ - **Process:** Run lint command, then typecheck command. Address all errors and warnings
102
+ - **Tolerance:** Zero tolerance for lint or typecheck errors
103
+ - **Priority:** Critical
104
+
105
+ ---
106
+
107
+ ## Decision Making Framework
108
+
109
+ > **Description:** Apply these principles systematically for all decisions
110
+ > **Priority:** High
111
+
112
+ | Step | Principle | Importance |
113
+ |------|-----------|------------|
114
+ | 1 | Gather Complete Information | Critical |
115
+ | 2 | Multi-Perspective Analysis | High |
116
+ | 3 | Consider All Stakeholders | High |
117
+ | 4 | Evaluate Alternatives | High |
118
+ | 5 | Assess Impact & Consequences | High |
119
+ | 6 | Apply Ethical Framework | Medium |
120
+ | 7 | Take Responsibility | High |
121
+ | 8 | Learn & Adapt | High |
122
+
123
+ ---
124
+
125
+ ## Code Validation Workflow
126
+
127
+ > **Description:** Mandatory validation process after writing or modifying code
128
+ > **Priority:** Critical
129
+
130
+ #### Validation Commands
131
+ - **Lint Fix Command:** `yarn run lint-fix`
132
+ - **Type Check Command:** `yarn run type-check`
133
+ - **Combined Command:** `yarn run lint-fix && yarn run type-check`
134
+
135
+ #### Required Workflow
136
+ | Step | Action | Description |
137
+ |------|--------|-------------|
138
+ | 1 | Write/Edit Code | Make your code changes |
139
+ | 2 | Run Validation | Execute `yarn run lint-fix && yarn run type-check` |
140
+ | 3 | Review Results | Check for any remaining errors |
141
+ | 4 | Fix Errors | Address all lint and type errors |
142
+ | 5 | Repeat | Run validation again until all errors are resolved |
143
+
144
+ #### Rules
145
+ - **Rule:** Always run validation commands after every code change
146
+ - **Requirement:** Must run both lint-fix and type-check before considering task complete
147
+ - **Tolerance:** Zero errors allowed - all lint and type errors must be fixed
148
+ - **Priority:** Critical
149
+
150
+ ---
151
+
152
+ ## Package Manager
153
+
154
+ #### Required Package Manager
155
+ - **Rule:** Use `yarn` as the package manager for this project
156
+ - **Requirement:** All package installations and script executions must use `yarn`
157
+ - **Prohibited:** Do NOT use `npm`, `pnpm`, or `bun`
158
+ - **Priority:** Critical
159
+
160
+ #### Examples
161
+ | Action | Correct | Incorrect |
162
+ |--------|---------|-----------|
163
+ | Install dependencies | `yarn install` | `npm install`, `pnpm install` |
164
+ | Add package | `yarn add <package>` | `npm install <package>` |
165
+ | Run script | `yarn run <script>` | `npm run <script>` |
166
+ | Remove package | `yarn remove <package>` | `npm uninstall <package>` |