@carbon/ai-chat 0.4.0 → 0.5.0
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.
- package/README.md +20 -17
- package/dist/es/aiChatEntry.js +36 -40
- package/dist/es/chat.AppContainer.js +4299 -4973
- package/dist/es/chat.customElement.js +9 -47
- package/dist/es/chat.export.js +1 -1
- package/dist/es/markdownWorker.js +33 -0
- package/dist/es/web-components/cds-aichat-container/index.js +35 -39
- package/dist/es/web-components/cds-aichat-custom-element/index.js +0 -4
- package/dist/types/aiChatEntry.d.ts +475 -702
- package/package.json +7 -7
- package/telemetry.yml +11 -0
- package/dist/es/chat.markdown.js +0 -29
package/README.md
CHANGED
|
@@ -1,20 +1,11 @@
|
|
|
1
1
|
<h1 align="center">
|
|
2
|
-
|
|
2
|
+
@carbon/ai-chat
|
|
3
3
|
</h1>
|
|
4
4
|
|
|
5
|
-
> Carbon AI
|
|
6
|
-
>
|
|
7
|
-
> The Carbon AI chat is a combination of the watsonx Assistant, watsonx Orchestrate and Carbon Labs AI chat projects. As this combination matures and as feedback from other implementing teams is gather, this project will be labeled as "beta" status.
|
|
8
|
-
>
|
|
9
|
-
> Don't let that stop you from using it in production, it is currently being used in production in watsonx Assistant and Orchestrate, just be sure to lock to an exact version as this project won't follow semantic versioning for breaking changes until the `1.0.0` release.
|
|
5
|
+
> Carbon AI Chat is an opinionated but extensible chat application that's available as both React and web components.
|
|
10
6
|
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
This package uses IBM Telemetry to collect de-identified and anonymized metrics data. By installing
|
|
14
|
-
this package as a dependency you are agreeing to telemetry collection. To opt out, see
|
|
15
|
-
[Opting out of IBM Telemetry data collection](https://github.com/ibm-telemetry/telemetry-js/tree/main#opting-out-of-ibm-telemetry-data-collection).
|
|
16
|
-
For more information on the data being collected, please see the
|
|
17
|
-
[IBM Telemetry documentation](https://github.com/ibm-telemetry/telemetry-js/tree/main#ibm-telemetry-collection-basics).
|
|
7
|
+
> [!WARNING]
|
|
8
|
+
> Be sure to lock to an exact version as this project won't follow semantic versioning for breaking changes until the `1.0.0` release.
|
|
18
9
|
|
|
19
10
|
## Getting started
|
|
20
11
|
|
|
@@ -30,8 +21,20 @@ yarn add @carbon/ai-chat
|
|
|
30
21
|
|
|
31
22
|
This will install the package that contains both the web component and React versions of the chat application.
|
|
32
23
|
|
|
33
|
-
## Documentation
|
|
24
|
+
## 📖 Documentation
|
|
25
|
+
|
|
26
|
+
- [Documentation site](https://1.www.s81c.com/common/carbon/ai-chat/tag/latest/docs/documents/Overview.html)
|
|
27
|
+
- [React examples](https://github.com/carbon-design-system/carbon-ai-chat/tree/main/examples/react)
|
|
28
|
+
- [Web component examples](https://github.com/carbon-design-system/carbon-ai-chat/tree/main/examples/web-components)
|
|
29
|
+
|
|
30
|
+
## 📝 License
|
|
34
31
|
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
-
|
|
32
|
+
Licensed under the [Apache 2.0 License](/LICENSE).
|
|
33
|
+
|
|
34
|
+
## <picture><source height="20" width="20" media="(prefers-color-scheme: dark)" srcset="https://raw.githubusercontent.com/ibm-telemetry/telemetry-js/main/docs/images/ibm-telemetry-dark.svg"><source height="20" width="20" media="(prefers-color-scheme: light)" srcset="https://raw.githubusercontent.com/ibm-telemetry/telemetry-js/main/docs/images/ibm-telemetry-light.svg"><img height="20" width="20" alt="IBM Telemetry" src="https://raw.githubusercontent.com/ibm-telemetry/telemetry-js/main/docs/images/ibm-telemetry-light.svg"></picture> IBM Telemetry
|
|
35
|
+
|
|
36
|
+
This package uses IBM Telemetry to collect de-identified and anonymized metrics data. By installing
|
|
37
|
+
this package as a dependency you are agreeing to telemetry collection. To opt out, see
|
|
38
|
+
[Opting out of IBM Telemetry data collection](https://github.com/ibm-telemetry/telemetry-js/tree/main#opting-out-of-ibm-telemetry-data-collection).
|
|
39
|
+
For more information on the data being collected, please see the
|
|
40
|
+
[IBM Telemetry documentation](https://github.com/ibm-telemetry/telemetry-js/tree/main#ibm-telemetry-collection-basics).
|
package/dist/es/aiChatEntry.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { i as isBrowser, A as AppContainerExport } from "./chat.AppContainer.js";
|
|
2
2
|
|
|
3
|
-
export {
|
|
3
|
+
export { B as ButtonItemKind, e as ButtonItemType, C as CSSVariable, b as CarbonTheme, l as ChainOfThoughtStepStatus, a as CornersType, E as ErrorType, F as FileStatusValue, H as HomeScreenBackgroundType, k as HumanAgentMessageType, d as HumanAgentsOnlineStatus, I as IFrameItemDisplayOption, L as LauncherType, m as MessageErrorState, f as MessageInputType, g as MessageResponseTypes, M as MinimizeButtonIconType, c as OnErrorType, h as OptionItemPreference, O as OverlayPanelName, P as PageObjectId, S as ScreenShareState, U as UserType, V as ViewType, j as WidthOptions, W as WriteableElementName, n as makeTestId } from "./chat.AppContainer.js";
|
|
4
4
|
|
|
5
5
|
import { _ as __decorate, c as carbonElement, B as BusEventType } from "./chat.customElement.js";
|
|
6
6
|
|
|
7
|
-
export { F as FeedbackInteractionType, M as MessageSendSource,
|
|
7
|
+
export { F as FeedbackInteractionType, M as MessageSendSource, V as ViewChangeReason } from "./chat.customElement.js";
|
|
8
8
|
|
|
9
9
|
import { createComponent } from "@lit/react";
|
|
10
10
|
|
|
@@ -46,8 +46,6 @@ import "tabbable";
|
|
|
46
46
|
|
|
47
47
|
import "@carbon/icons-react/es/AiLaunch.js";
|
|
48
48
|
|
|
49
|
-
import "@carbon/icons-react/es/ArrowUpLeft.js";
|
|
50
|
-
|
|
51
49
|
import "@carbon/icons-react/es/ChatLaunch.js";
|
|
52
50
|
|
|
53
51
|
import "@carbon/react";
|
|
@@ -64,10 +62,42 @@ import "@carbon/icons-react/es/ScreenOff.js";
|
|
|
64
62
|
|
|
65
63
|
import "@carbon/icons-react/es/UserAvatar.js";
|
|
66
64
|
|
|
65
|
+
import "markdown-it";
|
|
66
|
+
|
|
67
|
+
import "markdown-it-attrs";
|
|
68
|
+
|
|
69
|
+
import "dompurify";
|
|
70
|
+
|
|
67
71
|
import "lit/directives/repeat.js";
|
|
68
72
|
|
|
69
73
|
import "lit/directives/unsafe-html.js";
|
|
70
74
|
|
|
75
|
+
import "@carbon/web-components/es-custom/components/list/index.js";
|
|
76
|
+
|
|
77
|
+
import "@carbon/web-components/es-custom/components/layer/index.js";
|
|
78
|
+
|
|
79
|
+
import "lodash-es/debounce.js";
|
|
80
|
+
|
|
81
|
+
import "@carbon/web-components/es-custom/components/data-table/index.js";
|
|
82
|
+
|
|
83
|
+
import "@carbon/web-components/es-custom/components/checkbox/index.js";
|
|
84
|
+
|
|
85
|
+
import "@carbon/web-components/es-custom/components/button/index.js";
|
|
86
|
+
|
|
87
|
+
import "@carbon/icon-helpers";
|
|
88
|
+
|
|
89
|
+
import "@carbon/icons/es/download/16.js";
|
|
90
|
+
|
|
91
|
+
import "lit/directives/unsafe-svg.js";
|
|
92
|
+
|
|
93
|
+
import "lit-html/directives/repeat.js";
|
|
94
|
+
|
|
95
|
+
import "@carbon/web-components/es-custom/components/pagination/index.js";
|
|
96
|
+
|
|
97
|
+
import "@carbon/web-components/es-custom/components/select/index.js";
|
|
98
|
+
|
|
99
|
+
import "@carbon/web-components/es-custom/components/data-table/table-skeleton.js";
|
|
100
|
+
|
|
71
101
|
import "@carbon/icons-react/es/ChatBot.js";
|
|
72
102
|
|
|
73
103
|
import "@carbon/icons-react/es/CheckmarkFilled.js";
|
|
@@ -82,8 +112,6 @@ import "@carbon/web-components/es-custom/components/textarea/index.js";
|
|
|
82
112
|
|
|
83
113
|
import "@carbon/web-components/es-custom/components/icon-button/index.js";
|
|
84
114
|
|
|
85
|
-
import "@carbon/icon-helpers";
|
|
86
|
-
|
|
87
115
|
import "@carbon/icons/es/thumbs-down/16.js";
|
|
88
116
|
|
|
89
117
|
import "@carbon/icons/es/thumbs-down--filled/16.js";
|
|
@@ -92,18 +120,12 @@ import "@carbon/icons/es/thumbs-up/16.js";
|
|
|
92
120
|
|
|
93
121
|
import "@carbon/icons/es/thumbs-up--filled/16.js";
|
|
94
122
|
|
|
95
|
-
import "lit/directives/unsafe-svg.js";
|
|
96
|
-
|
|
97
123
|
import "@carbon/web-components/es-custom/components/tag/index.js";
|
|
98
124
|
|
|
99
125
|
import "@carbon/web-components/es-custom/components/chat-button/index.js";
|
|
100
126
|
|
|
101
127
|
import "@carbon/web-components/es-custom/components/button/button.js";
|
|
102
128
|
|
|
103
|
-
import "@carbon/web-components/es-custom/components/button/index.js";
|
|
104
|
-
|
|
105
|
-
import "@carbon/web-components/es-custom/components/layer/index.js";
|
|
106
|
-
|
|
107
129
|
import "@carbon/icons-react/es/Checkmark.js";
|
|
108
130
|
|
|
109
131
|
import "@carbon/icons-react/es/HelpDesk.js";
|
|
@@ -124,8 +146,6 @@ import "@carbon/icons-react/es/ChevronLeft.js";
|
|
|
124
146
|
|
|
125
147
|
import "@carbon/icons-react/es/ChevronRight.js";
|
|
126
148
|
|
|
127
|
-
import "lodash-es/debounce.js";
|
|
128
|
-
|
|
129
149
|
import "@carbon/icons-react/es/Link.js";
|
|
130
150
|
|
|
131
151
|
import "@carbon/icons-react/es/Maximize.js";
|
|
@@ -134,24 +154,6 @@ import "@carbon/icons-react/es/ChevronDown.js";
|
|
|
134
154
|
|
|
135
155
|
import "@carbon/icons-react/es/ChevronUp.js";
|
|
136
156
|
|
|
137
|
-
import "csv-stringify/browser/esm/sync";
|
|
138
|
-
|
|
139
|
-
import "@carbon/web-components/es-custom/components/data-table/index.js";
|
|
140
|
-
|
|
141
|
-
import "@carbon/web-components/es-custom/components/checkbox/index.js";
|
|
142
|
-
|
|
143
|
-
import "@carbon/icons/es/download/16.js";
|
|
144
|
-
|
|
145
|
-
import "lit-html/directives/repeat.js";
|
|
146
|
-
|
|
147
|
-
import "@carbon/web-components/es-custom/components/pagination/index.js";
|
|
148
|
-
|
|
149
|
-
import "@carbon/web-components/es-custom/components/select/index.js";
|
|
150
|
-
|
|
151
|
-
import "@carbon/web-components/es-custom/components/data-table/table-skeleton.js";
|
|
152
|
-
|
|
153
|
-
import "@carbon/icons-react/es/Restart.js";
|
|
154
|
-
|
|
155
157
|
import "@carbon/web-components/es-custom/components/inline-loading/index.js";
|
|
156
158
|
|
|
157
159
|
import "@carbon/icons/es/checkmark--filled/16.js";
|
|
@@ -160,6 +162,8 @@ import "@carbon/icons/es/chevron--right/16.js";
|
|
|
160
162
|
|
|
161
163
|
import "@carbon/icons/es/error--filled/16.js";
|
|
162
164
|
|
|
165
|
+
import "@carbon/icons-react/es/Restart.js";
|
|
166
|
+
|
|
163
167
|
import "@carbon/icons-react/es/Home.js";
|
|
164
168
|
|
|
165
169
|
import "@carbon/web-components/es-custom/components/slug/index.js";
|
|
@@ -180,8 +184,6 @@ import "@carbon/web-components/es-custom/components/popover/defs.js";
|
|
|
180
184
|
|
|
181
185
|
import "@carbon/web-components/es-custom/components/skeleton-icon/index.js";
|
|
182
186
|
|
|
183
|
-
import "@carbon/web-components/es-custom/components/overflow-menu/index.js";
|
|
184
|
-
|
|
185
187
|
import "@floating-ui/react";
|
|
186
188
|
|
|
187
189
|
import "@carbon/web-components/es-custom/components/ai-label/ai-label-action-button.js";
|
|
@@ -192,12 +194,6 @@ import "@carbon/icons-react/es/SendFilled.js";
|
|
|
192
194
|
|
|
193
195
|
import "@carbon/icons/es/stop--filled/16.js";
|
|
194
196
|
|
|
195
|
-
import "@carbon/icons-react/es/Subtract.js";
|
|
196
|
-
|
|
197
|
-
import "@carbon/icons-react/es/ArrowLeft.js";
|
|
198
|
-
|
|
199
|
-
import "@carbon/icons-react/es/Chat.js";
|
|
200
|
-
|
|
201
197
|
let ChatContainerReact = class ChatContainerReact extends LitElement {
|
|
202
198
|
firstUpdated(changedProperties) {
|
|
203
199
|
super.firstUpdated(changedProperties);
|