Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
245 commits
Select commit Hold shift + click to select a range
8ac8252
adds flutter guide for threaded messages
swapnil-cometchat Jul 28, 2025
a5c7a30
flutter guide to block/unblock user
swapnil-cometchat Jul 28, 2025
cfff540
Update guide-block-unblock-user.mdx
swapnil-cometchat Jul 28, 2025
119146e
Update guide-threaded-messages.mdx
swapnil-cometchat Jul 28, 2025
225137d
Update guide-threaded-messages.mdx
swapnil-cometchat Jul 28, 2025
feb75fc
Update guide-threaded-messages.mdx
swapnil-cometchat Jul 28, 2025
eaef637
Update guide-block-unblock-user.mdx
swapnil-cometchat Jul 28, 2025
351a78d
adds doc for threaded message
swapnil-cometchat Jul 29, 2025
9aec527
Update guide-threaded-messages.mdx
swapnil-cometchat Jul 29, 2025
81b9e5b
Flutter - New Chat / Create Conversation in Your Flutter Chat App
swapnil-cometchat Jul 29, 2025
da79a8e
Update guide-new-chat.mdx
swapnil-cometchat Jul 29, 2025
ff6e757
flutter message privately
swapnil-cometchat Jul 29, 2025
bc7525f
Update guide-message-privately.mdx
swapnil-cometchat Jul 29, 2025
7fd7baa
flutter - Managing & Viewing Call Logs in Your Flutter Chat App
swapnil-cometchat Jul 29, 2025
714b813
removes table of content
swapnil-cometchat Jul 29, 2025
9b33faf
Update guide-threaded-messages.mdx
swapnil-cometchat Jul 29, 2025
42c28a2
updates guides
swapnil-cometchat Aug 1, 2025
ef74d76
updates link to sample app
swapnil-cometchat Aug 1, 2025
e2b8e74
Update guide-threaded-messages.mdx
swapnil-cometchat Aug 1, 2025
f2fd612
Update guide-threaded-messages.mdx
swapnil-cometchat Aug 1, 2025
5be7735
Update guide-block-unblock-user.mdx
swapnil-cometchat Aug 1, 2025
63cfaa4
Update guide-block-unblock-user.mdx
swapnil-cometchat Aug 1, 2025
8698321
Update guide-block-unblock-user.mdx
swapnil-cometchat Aug 1, 2025
ad06ffb
Update guide-group-chat.mdx
swapnil-cometchat Aug 1, 2025
a5b1c6a
adds guides from sample app
swapnil-cometchat Aug 6, 2025
35d7aec
Update guide-block-unblock-user.mdx
swapnil-cometchat Aug 6, 2025
1bc3393
updates titles
swapnil-cometchat Aug 6, 2025
8d86a0c
Update guide-block-unblock-user.mdx
swapnil-cometchat Aug 6, 2025
f84dc4a
Update guide-new-chat.mdx
swapnil-cometchat Aug 6, 2025
3446168
Update guide-message-privately.mdx
swapnil-cometchat Aug 6, 2025
bdcab1a
Update guide-message-privately.mdx
swapnil-cometchat Aug 6, 2025
f6cc52e
Update guide-message-privately.mdx
swapnil-cometchat Aug 6, 2025
8c84537
Update guide-call-log-details.mdx
swapnil-cometchat Aug 6, 2025
a9cd250
Update guide-group-chat.mdx
swapnil-cometchat Aug 6, 2025
37afce7
Update guide-group-chat.mdx
swapnil-cometchat Aug 6, 2025
4249416
Update guide-group-chat.mdx
swapnil-cometchat Aug 6, 2025
c99221a
Create guide-group-ownership.mdx
swapnil-cometchat Aug 6, 2025
9380380
Update docs.json
swapnil-cometchat Aug 6, 2025
9f4fb50
Merge branch 'main' into feature/guides
swapnil-cometchat Aug 6, 2025
2950b28
Update guide-threaded-messages.mdx
swapnil-cometchat Aug 6, 2025
aa3cd15
Update guide-threaded-messages.mdx
swapnil-cometchat Aug 6, 2025
4ca1aa3
Create guide-block-unblock-user.mdx
swapnil-cometchat Aug 6, 2025
110621d
Create guide-new-chat.mdx
swapnil-cometchat Aug 6, 2025
0937353
Update guide-new-chat.mdx
swapnil-cometchat Aug 6, 2025
737f7d9
adds guides
swapnil-cometchat Aug 6, 2025
872e479
Update guide-message-privately.mdx
swapnil-cometchat Aug 6, 2025
95a902d
Update guide-group-ownership.mdx
swapnil-cometchat Aug 6, 2025
d790e3b
Update guide-group-ownership.mdx
swapnil-cometchat Aug 6, 2025
8fe0e1d
Update guide-group-ownership.mdx
swapnil-cometchat Aug 6, 2025
f878f2b
Update docs.json
swapnil-cometchat Aug 6, 2025
c06d8e0
Update guide-block-unblock-user.mdx
swapnil-cometchat Aug 6, 2025
3b917ca
Update guide-new-chat.mdx
swapnil-cometchat Aug 6, 2025
bcb362a
Update guide-message-privately.mdx
swapnil-cometchat Aug 6, 2025
23de13a
Update guide-call-log-details.mdx
swapnil-cometchat Aug 6, 2025
1a3b9e4
updates android doc
swapnil-cometchat Aug 6, 2025
c328187
Update guide-new-chat.mdx
swapnil-cometchat Aug 6, 2025
e1e3080
Update guide-new-chat.mdx
swapnil-cometchat Aug 7, 2025
286a61b
Update guide-call-log-details.mdx
swapnil-cometchat Aug 7, 2025
3e58a69
Update guide-call-log-details.mdx
swapnil-cometchat Aug 7, 2025
7596ec6
Update guide-call-log-details.mdx
swapnil-cometchat Aug 7, 2025
b47b671
Merge pull request #64 from cometchat/dev
swapnil-cometchat Sep 4, 2025
fbba3f9
Merge branch 'feature/guides' into docs/uikit-guides
swapnil-cometchat Sep 4, 2025
f69d9d0
updates the guide
swapnil-cometchat Sep 5, 2025
a53a114
Update guide-overview.mdx
swapnil-cometchat Sep 5, 2025
463fad9
adds iOS guides
swapnil-cometchat Sep 5, 2025
bf032b2
Update guide-overview.mdx
swapnil-cometchat Sep 5, 2025
8ab6cce
updates guides for flutter
swapnil-cometchat Sep 5, 2025
6f15570
Update guide-overview.mdx
swapnil-cometchat Sep 5, 2025
5ae6934
Merge pull request #65 from cometchat/docs/uikit-guides
swapnil-cometchat Sep 5, 2025
b663c54
adds guide for threaded messages
swapnil-cometchat Sep 8, 2025
e98c00e
Update guide-threaded-messages.mdx
swapnil-cometchat Sep 8, 2025
9a36760
Create guide-block-unblock-user.mdx
swapnil-cometchat Sep 8, 2025
60cb92a
adds guide for block and unblock user
swapnil-cometchat Sep 8, 2025
8a303c4
Update guide-overview.mdx
swapnil-cometchat Sep 8, 2025
01b0e19
Create guide-new-chat.mdx
swapnil-cometchat Sep 8, 2025
530323b
Update docs.json
swapnil-cometchat Sep 8, 2025
5102b2c
adds guides
swapnil-cometchat Sep 8, 2025
125eec0
Create guide-group-chat.mdx
swapnil-cometchat Sep 8, 2025
69ad736
updates overview
swapnil-cometchat Sep 8, 2025
102982e
Update guide-overview.mdx
swapnil-cometchat Sep 8, 2025
e43428d
removes best practices
swapnil-cometchat Sep 8, 2025
ae6bcaa
Update guide-new-chat.mdx
swapnil-cometchat Sep 8, 2025
4f686a5
Update guide-group-chat.mdx
swapnil-cometchat Sep 8, 2025
80424de
Update guide-call-log-details.mdx
swapnil-cometchat Sep 8, 2025
a7dd6ab
Update guide-group-chat.mdx
swapnil-cometchat Sep 8, 2025
7cdb2ff
Update guide-group-chat.mdx
swapnil-cometchat Sep 8, 2025
75d3127
Update guide-search-messages.mdx
swapnil-cometchat Sep 8, 2025
852e81e
Update guide-block-unblock-user.mdx
swapnil-cometchat Sep 8, 2025
9e58e3e
Update guide-call-log-details.mdx
swapnil-cometchat Sep 8, 2025
3351f89
Update guide-threaded-messages.mdx
swapnil-cometchat Sep 8, 2025
23c920d
Update guide-new-chat.mdx
swapnil-cometchat Sep 8, 2025
e26b602
Update guide-message-privately.mdx
swapnil-cometchat Sep 8, 2025
a835048
Merge branch 'main' into docs/uikit-guides
swapnil-cometchat Sep 8, 2025
f16f494
Merge pull request #66 from cometchat/docs/uikit-guides
swapnil-cometchat Sep 8, 2025
cb76401
updates the dependency version for react ui kit
swapnil-cometchat Sep 12, 2025
12d3eae
Added the fix for mentionedUserDetails for import messages
sachinbahukhandi-cometchat Sep 15, 2025
adea6ce
Added OAS for import messages
sachinbahukhandi-cometchat Sep 16, 2025
acf7efe
updates docs
swapnil-cometchat Sep 16, 2025
af466c6
Update mastra-knowlege-agent-pdf.mdx
swapnil-cometchat Sep 16, 2025
462a4e6
Merge pull request #71 from cometchat/docs/ai-agent-tutorials
swapnil-cometchat Sep 16, 2025
4ee9b39
Added the OAS for the import messages
sachinbahukhandi-cometchat Sep 16, 2025
2224ab5
Merged the latest changes for PushNotifications
sachinbahukhandi-cometchat Sep 22, 2025
698f777
Merged the latest changes for PushNotifications
sachinbahukhandi-cometchat Sep 22, 2025
31ef1b4
Added Quoted Message Documentation for JS SDK.
raj-dubey1 Sep 22, 2025
cf1e2d2
fixed typo
raj-dubey1 Sep 22, 2025
4e213f7
Merge pull request #72 from cometchat/feature/js-sdk-quoted-message
swapnil-cometchat Sep 22, 2025
ff4563c
Revert "Added Quoted Message Documentation for JS SDK."
swapnil-cometchat Sep 22, 2025
9e40940
Merge pull request #73 from cometchat/revert-72-feature/js-sdk-quoted…
swapnil-cometchat Sep 22, 2025
5283f26
Added Quoted Message Documentation for JS SDK.
raj-dubey1 Sep 23, 2025
033bd8d
Added the constraints page
sachinbahukhandi-cometchat Sep 23, 2025
c9d254c
Modified content as intended
sachinbahukhandi-cometchat Sep 24, 2025
88eccb0
Merge pull request #75 from cometchat/docs/restapi-chatapi-modify-con…
siva-cometchat Sep 24, 2025
bf89ac9
Added the mentionedUserDetails
sachinbahukhandi-cometchat Sep 24, 2025
f7037c3
Merge pull request #70 from cometchat/docs/restapi-chatapi-import-mes…
siva-cometchat Sep 24, 2025
7491db4
Added docs for swipe to reply feature in react uikit.
raj-dubey1 Sep 24, 2025
2b65d7d
Added new prop onSendButtonClick in CometChatAIAssistantChat component
raj-dubey1 Sep 24, 2025
dbc9887
Merge pull request #77 from cometchat/feature/react-uikit-send-button…
swapnil-cometchat Sep 24, 2025
240c336
ENG-20184: Issue: Incorrect method signature in the documentation for…
william-cometchat Sep 26, 2025
f8af3f0
Added hideModerationView prop in message list
raj-dubey1 Sep 27, 2025
254045c
updates UI Kit version for Chat Builder
swapnil-cometchat Sep 29, 2025
a474a1d
Update navigation.js
swapnil-cometchat Sep 29, 2025
e5e48ca
Merge pull request #74 from cometchat/feature/js-sdk-quoted-message-new
swapnil-cometchat Sep 29, 2025
65bf9b5
Updated Screenshot
raj-dubey1 Sep 29, 2025
d17772e
Bump `react-native-calls-sdk`'s peer deps
honey-cometchat Sep 29, 2025
016546c
Added Swipe to reply in core features docs
raj-dubey1 Sep 29, 2025
d8ceb0b
Merge pull request #79 from cometchat/feature/react-uikit-swipe-to-reply
swapnil-cometchat Sep 29, 2025
fe70384
Renamed swipe to reply -> quoted message
raj-dubey1 Sep 29, 2025
37088d2
renamed to quoted reply
raj-dubey1 Sep 29, 2025
6b281d5
Merge pull request #81 from cometchat/fix/react-uikit-swipe-to-reply-…
swapnil-cometchat Sep 29, 2025
cbaae8b
Merge pull request #80 from cometchat/chore/bump-react-native-calls-s…
swapnil-cometchat Sep 30, 2025
73b8c47
Added templates prop in CometChatAIAssistantChat component
raj-dubey1 Oct 3, 2025
0d1c704
Merge pull request #83 from cometchat/docs/react-uikit-ai-agent-prop-…
swapnil-cometchat Oct 3, 2025
fcdc6fc
Updated CometChatSDK versions in docs
dawinder-cc Oct 6, 2025
d4dd262
Merge pull request #84 from cometchat/release/ios-chat-sdk-v4.0.68
swapnil-cometchat Oct 7, 2025
22b066c
0.77.0
william-cometchat Oct 7, 2025
de8afb9
migration ios uikit
aman-cometchat Oct 8, 2025
468577e
localization react native
swayam-cometchat Oct 8, 2025
4da0d5b
fix
swayam-cometchat Oct 8, 2025
b9fe88e
updated
swayam-cometchat Oct 8, 2025
c080112
message list and chat history component
ashfaqcometchat Oct 8, 2025
b674cf5
message header docs
ashfaqcometchat Oct 9, 2025
02af805
message bubble style docs
ashfaqcometchat Oct 9, 2025
f72fa44
Added docs for ai agents flutter
munikiran-cometchat Oct 9, 2025
84fb946
Merge pull request #78 from cometchat/feature/updated-logoutCall
swapnil-cometchat Oct 9, 2025
fda187b
component styling docs
ashfaqcometchat Oct 9, 2025
ef49d49
refactor
aman-cometchat Oct 9, 2025
e4517fd
Flutter Migration from V4
raj-cometchat Oct 9, 2025
7543877
Added Group Members
raj-cometchat Oct 9, 2025
6b1e583
Added SDK docs
munikiran-cometchat Oct 9, 2025
5c7f5d0
fix
swayam-cometchat Oct 9, 2025
dc95867
fix
swayam-cometchat Oct 9, 2025
4d53c3f
chat sdk docs
ashfaqcometchat Oct 9, 2025
8d24476
Merge pull request #87 from cometchat/react-native-localization
swapnil-cometchat Oct 10, 2025
56e5d7c
Change prop
ashfaqcometchat Oct 10, 2025
9c51da0
Added AI Agents flutter sdk docs
munikiran-cometchat Oct 10, 2025
93bae01
sdk docs
ashfaqcometchat Oct 10, 2025
16cea71
added ai-agents content only version needs to be added
aman-cometchat Oct 10, 2025
6bab610
Added versions ai-agents iOS
aman-cometchat Oct 10, 2025
fc0495e
ai gent guide
ashfaqcometchat Oct 14, 2025
0a69c05
Add listener variable
ashfaqcometchat Oct 14, 2025
40ec2ba
update screenshots and code snippet of themes
ashfaqcometchat Oct 14, 2025
b830429
update message bubble style code
ashfaqcometchat Oct 14, 2025
d4d2e21
Add 'Step' in integration steps in the guide
ashfaqcometchat Oct 14, 2025
758f7d0
adds initial code for versel
swapnil-cometchat Oct 15, 2025
9ac345c
Added conversation and advanced search in core feature.
raj-dubey1 Oct 16, 2025
b7e373f
Update vercel-knowledge-agent.mdx
swapnil-cometchat Oct 16, 2025
d7f0e9f
Update vercel-knowledge-agent.mdx
swapnil-cometchat Oct 16, 2025
846e028
Merge pull request #94 from cometchat/docs/react-ui-kit-core-features…
swapnil-cometchat Oct 16, 2025
a797cb9
Completed AI Agent docs
munikiran-cometchat Oct 16, 2025
cc77b29
Updated version
munikiran-cometchat Oct 16, 2025
fe3fed0
Android v4 to v5 Migration Guide
raj-cometchat Oct 16, 2025
9becbce
Merge pull request #97 from cometchat/docs/android-uikit-migration
swapnil-cometchat Oct 16, 2025
2cc102d
react-native ai agent
swayam-cometchat Oct 16, 2025
f2aca89
Fixed a typo issue in CometChatAIAssistantChatHistoryStyle
munikiran-cometchat Oct 17, 2025
3e951a5
Feature/react native UI Kit/AI Agent
swayam-cometchat Oct 17, 2025
7ce8e4d
adds docs for vercel and ag2
swapnil-cometchat Oct 17, 2025
dd23f75
adds ag2 agent
swapnil-cometchat Oct 17, 2025
87ac597
Update vercel.mdx
swapnil-cometchat Oct 17, 2025
00c07ee
Update ag2-knowledge-agent.mdx
swapnil-cometchat Oct 17, 2025
bb2ee02
Update ag2-knowledge-agent.mdx
swapnil-cometchat Oct 17, 2025
6612626
updates the agent
swapnil-cometchat Oct 17, 2025
a8ce7b6
Merge pull request #93 from cometchat/docs/flutter-uikit-migration
swapnil-cometchat Oct 17, 2025
316a1ec
update v4 version
ashfaqcometchat Oct 17, 2025
2437197
Update vercel-product-hunt-agent.mdx
swapnil-cometchat Oct 17, 2025
e5ec74b
Updated chat uikit version
munikiran-cometchat Oct 17, 2025
6a96c96
Merge pull request #91 from cometchat/feature/android-sdk-ai-agent
swapnil-cometchat Oct 17, 2025
15c0b5b
Merge pull request #92 from cometchat/docs/ios-sdk-AI-Agents
swapnil-cometchat Oct 17, 2025
b853b0a
Merge pull request #90 from cometchat/docs/flutter-sdk-AI-Agents
swapnil-cometchat Oct 17, 2025
d3310ed
Merge pull request #98 from cometchat/feature/react-native-sdk-ai-agents
swapnil-cometchat Oct 17, 2025
c50d947
Merge pull request #96 from cometchat/docs/flutter-uikit-AI-Agents
swapnil-cometchat Oct 17, 2025
ebafa69
Merge pull request #99 from cometchat/feature/react-native-ui-kit-ai-…
swapnil-cometchat Oct 17, 2025
814c1a9
Merge pull request #101 from cometchat/docs/ios-uikit-migration
swapnil-cometchat Oct 17, 2025
74f2444
Merge branch 'main' into feature/android-ui-kit-ai-agent-merge-conflict
ashfaqcometchat Oct 17, 2025
ca486c1
Update ag2-product-hunt-agent.mdx
swapnil-cometchat Oct 20, 2025
6e65dcc
Update vercel.mdx
swapnil-cometchat Oct 21, 2025
d7ba870
updates actions and tools
swapnil-cometchat Oct 21, 2025
b156b54
Merge branch 'docs/vercel-ai-agent'
swapnil-cometchat Oct 21, 2025
54a48ab
Update ai-agents.mdx
swapnil-cometchat Oct 21, 2025
bc72e3d
Merge pull request #95 from cometchat/docs/vercel-ai-agent
swapnil-cometchat Oct 21, 2025
51f0349
Merge pull request #89 from cometchat/feature/android-ui-kit-ai-agent…
swapnil-cometchat Oct 21, 2025
9ab0c39
initial commit
swayam-cometchat Oct 21, 2025
da18266
updated
swayam-cometchat Oct 21, 2025
0bd0fa6
Merge branch 'main' of https://github.com/cometchat/docs
swapnil-cometchat Oct 22, 2025
c68994c
updated property
swayam-cometchat Oct 22, 2025
c8c5b23
updates UI Kit Version to 6.3.2 for Chat Builder
swapnil-cometchat Oct 22, 2025
84a6121
updates ticket - ENG-20984
swapnil-cometchat Oct 22, 2025
c139a16
fix
swayam-cometchat Oct 22, 2025
f32b76b
updates "No Code - Widgets" to "Widget Builder"
swapnil-cometchat Oct 22, 2025
b3eb829
Merge pull request #102 from cometchat/docs/react-native-uikit-migration
swapnil-cometchat Oct 22, 2025
89d6729
AI agents for React Native, Android and Flutter
swapnil-cometchat Oct 24, 2025
992c4aa
Rename Chat Builder
swapnil-cometchat Oct 24, 2025
0243b25
updates
swapnil-cometchat Oct 27, 2025
53d1c56
Merge branch 'main' of https://github.com/cometchat/docs
swapnil-cometchat Oct 27, 2025
9cd9a27
adds ui kit builder docs for flutter
swapnil-cometchat Oct 27, 2025
e230680
Update docs.json
swapnil-cometchat Oct 27, 2025
7b7801e
Update docs.json
swapnil-cometchat Oct 27, 2025
39c05cf
Update ag2.mdx
swapnil-cometchat Oct 27, 2025
8fd078e
Update chat-call.mdx
swapnil-cometchat Oct 27, 2025
302b66a
Merge pull request #105 from cometchat/docs/chat-builder-reference
swapnil-cometchat Oct 28, 2025
ab12e3f
Merge branch 'main' of https://github.com/cometchat/docs
swapnil-cometchat Oct 28, 2025
8da3d45
Merge branch 'main' into feature/flutter-vcb
swapnil-cometchat Oct 28, 2025
282c25c
updates UI Kit references
swapnil-cometchat Oct 28, 2025
f1c1eaa
Merge pull request #106 from cometchat/feature/flutter-vcb
swapnil-cometchat Oct 28, 2025
67a51fa
adds documentation for agno
swapnil-cometchat Oct 30, 2025
667618a
adds docs for AG UI
swapnil-cometchat Oct 31, 2025
33a1a5a
Added new methods in javascript sdk
raj-dubey1 Oct 31, 2025
9529681
Fixed Typo
raj-dubey1 Oct 31, 2025
715b7e3
Merge pull request #113 from cometchat/docs/javascript-sdk-new-methods
swapnil-cometchat Oct 31, 2025
0561692
Added setStorageMode method in angular uikit's UIKitSettingsBuilder
raj-dubey1 Oct 31, 2025
1072b00
Merge pull request #114 from cometchat/docs/uikit-angular-settings-me…
swapnil-cometchat Oct 31, 2025
62ded55
updates docs
swapnil-cometchat Oct 31, 2025
08c853c
Merge pull request #110 from cometchat/docs/agno
swapnil-cometchat Nov 1, 2025
c6d19ef
Added switch camera feature in calls sdk
honey-cometchat Nov 3, 2025
7351c96
Remove unnecessary parameter from switchCamera() method usage in Java…
honey-cometchat Nov 3, 2025
1b87bf6
Merge pull request #115 from cometchat/feature/calls-sdk-javascript-s…
swapnil-cometchat Nov 3, 2025
d6dd57e
updates the docs
swapnil-cometchat Nov 4, 2025
4924959
removes titles
swapnil-cometchat Nov 4, 2025
9ec79f0
Merge branch 'main' into docs/ag-ui
swapnil-cometchat Nov 4, 2025
99707f7
Update cometchat-ag-ui-byoa.mdx
swapnil-cometchat Nov 4, 2025
b6f0e35
Merge pull request #111 from cometchat/docs/ag-ui
swapnil-cometchat Nov 5, 2025
d465caf
Updated Chat UIKit, Calls UIKit and SDK versions
raj-cometchat Nov 6, 2025
8c288ad
versions updated for uikit, chat sdk and calls
dawinder-cc Nov 6, 2025
ae981d5
Merge pull request #117 from cometchat/release/flutter-chat-uikit-v5.2.2
swapnil-cometchat Nov 6, 2025
f258dd1
Merge pull request #118 from cometchat/release/ios-chat-uikit-v5.0.10
swapnil-cometchat Nov 6, 2025
ae495d1
updated calls sdk version to v4.3.1
jitvarpatil Nov 9, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 10 additions & 8 deletions ai-agents.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -58,9 +58,11 @@ With model-agnostic flexibility, CometChat AI Agents let you upgrade your AI sta

<CardGroup cols={4} className="mt-4">
<Card title="Mastra" icon={<img src="/docs/images/icons/mastra.svg" alt="Mastra" />} href="/ai-agents/mastra" horizontal />
<Card title="LangGraph" icon={<img src="/docs/images/icons/lang-graph.svg" alt="LangGraph" />} horizontal>Coming Soon</Card>
<Card title="Agno" icon={<img src="/docs/images/icons/agno.svg" alt="Agno" />} horizontal>Coming Soon</Card>
<Card title="CrewAI Flows" icon={<img src="/docs/images/icons/crew-ai.svg" alt="CrewAI Flows" />} horizontal>Coming Soon</Card>
{/* <Card title="LangGraph" icon={<img src="/docs/images/icons/lang-graph.svg" alt="LangGraph" />} horizontal>Coming Soon</Card> */}
<Card title="Agno" icon={<img src="/docs/images/icons/agno.svg" alt="Agno" />} href="/ai-agents/agno" horizontal />
{/* <Card title="CrewAI Flows" icon={<img src="/docs/images/icons/crew-ai.svg" alt="CrewAI Flows" />} horizontal>Coming Soon</Card> */}
<Card title="Vercel" icon={<img src="/docs/images/icons/vercel.svg" alt="Vercel" />} href="/ai-agents/vercel" horizontal />
<Card title="AG2" icon={<img src="/docs/images/icons/ag2.svg" alt="AG2" />} href="/ai-agents/ag2" horizontal />
</CardGroup>
<p className="text-gray-500 text-sm mt-3">More providers coming…</p>
</Step>
Expand All @@ -79,17 +81,17 @@ With model-agnostic flexibility, CometChat AI Agents let you upgrade your AI sta
<p className="text-gray-600 dark:text-gray-300">Customize the agent’s appearance and copy the embed code to integrate it into your app.</p>

<CardGroup cols={3} className="mt-4">
<Card title="No Code - Widget" icon={<img src="/docs/images/icons/ai-agents.svg" alt="Widget" />} description="No‑code" href="/ai-agents/chat-widget" horizontal />
<Card title="Widget Builder" icon={<img src="/docs/images/icons/ai-agents.svg" alt="Widget" />} description="No‑code" href="/ai-agents/chat-widget" horizontal />
<Card title="React UI Kit" icon={<img src="/docs/images/icons/react.svg" alt="React" />} href="https://www.cometchat.com/docs/ui-kit/react/ai-assistant-chat" horizontal>Pre Built UI Components</Card>
<Card title="JavaScript SDK" icon={<img src="/docs/images/icons/js.svg" alt="JavaScript SDK" />} horizontal>Coming Soon</Card>
<Card title="JavaScript SDK" icon={<img src="/docs/images/icons/js.svg" alt="JavaScript SDK" />} href="https://www.cometchat.com/docs/sdk/javascript/ai-agents" horizontal>Ready to use SDK Methods</Card>
</CardGroup>
<CardGroup cols={3} className="mt-4">
<Card title="React Native" icon={<img src="/docs/images/icons/react.svg" alt="React Native" />} horizontal>Coming Soon</Card>
<Card title="Android" icon={<img src="/docs/images/icons/android.svg" alt="Android" />} horizontal>Coming Soon</Card>
<Card title="React Native" icon={<img src="/docs/images/icons/react.svg" alt="React Native" />} href="https://www.cometchat.com/docs/ui-kit/react-native/guide-ai-agent" horizontal>Pre Built UI Components</Card>
<Card title="Android" icon={<img src="/docs/images/icons/android.svg" alt="Android" />} href="https://www.cometchat.com/docs/ui-kit/android/guide-ai-agent" horizontal>Pre Built UI Components</Card>
<Card title="iOS Swift" icon={<img src="/docs/images/icons/swift.svg" alt="iOS Swift" />} horizontal>Coming Soon</Card>
</CardGroup>
<CardGroup cols={3} className="mt-4">
<Card title="Flutter" icon={<img src="/docs/images/icons/flutter.svg" alt="Flutter" />} horizontal>Coming Soon</Card>
<Card title="Flutter" icon={<img src="/docs/images/icons/flutter.svg" alt="Flutter" />} href="https://www.cometchat.com/docs/ui-kit/flutter/guide-message-agentic-flow" horizontal>Pre Built UI Components</Card>
</CardGroup>
</Step>

Expand Down
281 changes: 281 additions & 0 deletions ai-agents/ag2-knowledge-agent.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,281 @@
---
title: "Build Your Knowledge Agent with AG2"
sidebarTitle: "Knowledge Agent"
description: "Create an AG2 Knowledge Agent that answers documentation questions, then connect it to CometChat."
---

Imagine an assistant that reads your product docs, returns cited answers when mentioned in chat, and streams context back to the UI in real time. That’s what the AG2 Knowledge Agent delivers.

***

## What You’ll Build

* An **AG2 (AutoGen 2)** agent that behaves like a documentation expert.
* Triggered only when invoked (e.g., `@knowledge`).
* Retrieves & cites snippets from an on-disk knowledge store.
* Integrated into **CometChat** conversations with streaming responses.

***

## Prerequisites

* Python 3.10+ and `pip`.
* `OPENAI_API_KEY` in a `.env` file (used for embeddings + chat completions).
* Optional overrides:
* `KNOWLEDGE_AGENT_MODEL` (default `gpt-4o-mini`)
* `KNOWLEDGE_AGENT_EMBEDDING_MODEL` (default `text-embedding-3-small`)
* `KNOWLEDGE_AGENT_TOP_K`, `KNOWLEDGE_AGENT_TEMPERATURE`, etc.
* CometChat app credentials (App ID, Region, Auth Key).

***

## Quick links

- Repo (examples): [ai-agent-ag2-examples/ag2-knowledge-agent](https://github.com/cometchat/ai-agent-ag2-examples/tree/main/ag2-knowledge-agent)
- Agent source: [agent.py](https://github.com/cometchat/ai-agent-ag2-examples/blob/main/ag2-knowledge-agent/agent.py)
- FastAPI server: [server.py](https://github.com/cometchat/ai-agent-ag2-examples/blob/main/ag2-knowledge-agent/server.py)
- Sample web embed: [web/index.html](https://github.com/cometchat/ai-agent-ag2-examples/blob/main/ag2-knowledge-agent/web/index.html)

***

## How it works

This project packages a retrieval-augmented AG2 agent that:

- **Ingests sources** into namespaces using the `KnowledgeStore`. POST payloads to `/tools/ingest` with URLs, local files, or raw text. Files (`.pdf`, `.md`, `.txt`) are parsed and chunked before embeddings are stored under `knowledge/<namespace>/index.json`.
- **Searches namespaces** via `/tools/search`, ranking chunks with cosine similarity on OpenAI embeddings (defaults to top 4 results).
- **Streams answers** from `/agent`. The server wraps AG2’s `ConversableAgent`, emits SSE events for tool calls (`tool_call_start`, `tool_call_result`) and text chunks, and always terminates with `[DONE]`.
- **Cites sources**. The agent compiles the retrieved snippets, instructs the LLM to cite them with bracketed numbers, and appends a `Sources:` line.
- **Hardens operations**: namespaces are sanitized, ingestion is thread-safe, and errors are surfaced as SSE `error` events so the client can render fallbacks.

Key modules:

- `agent.py` — KnowledgeAgent, store helpers, embedding + retrieval logic.
- `server.py` — FastAPI app hosting `/agent`, `/tools/ingest`, `/tools/search`, `/health`.
- `knowledge/` — default storage root (persisted chunks + index).
- `web/index.html` — CometChat Chat Embed sample that points to your deployed agent.

***

## Setup

<Steps>
<Step title="Clone & install">
<code>git clone https://github.com/cometchat/ai-agent-ag2-examples.git</code> then <code>cd ai-agent-ag2-examples/ag2-knowledge-agent</code>. Create a virtualenv and run <code>pip install -r requirements.txt</code>.
</Step>
<Step title="Configure environment">
Create a <code>.env</code> file, set <code>OPENAI_API_KEY</code>, and override other knobs as needed (model, temperature, namespace).
</Step>
<Step title="Prime knowledge">
Run <code>python server.py</code> once (or <code>uvicorn server:app</code>) to initialize folders. Use the ingest endpoint or the provided knowledge samples as a starting point.
</Step>
<Step title="Run locally">
Start FastAPI: <code>uvicorn server:app --reload --host 0.0.0.0 --port 8000</code>. Verify <code>GET /health</code> returns <code>`{"status": "healthy"}`</code>.
</Step>
<Step title="Create a tunnel">
Expose <code>/agent</code> publicly with ngrok, Cloudflare Tunnel, or Render so CometChat can reach it.
</Step>
</Steps>

***

## Project structure

- Dependencies: [requirements.txt](https://github.com/cometchat/ai-agent-ag2-examples/blob/main/ag2-knowledge-agent/requirements.txt)
- Agent logic: [agent.py](https://github.com/cometchat/ai-agent-ag2-examples/blob/main/ag2-knowledge-agent/agent.py)
- Knowledge store: [knowledge/](https://github.com/cometchat/ai-agent-ag2-examples/tree/main/ag2-knowledge-agent/knowledge)
- API server: [server.py](https://github.com/cometchat/ai-agent-ag2-examples/blob/main/ag2-knowledge-agent/server.py)
- Web sample: [web/index.html](https://github.com/cometchat/ai-agent-ag2-examples/blob/main/ag2-knowledge-agent/web/index.html)

***

## Core configuration

<AccordionGroup>
<Accordion title="Environment variables">

```bash
OPENAI_API_KEY=sk-your-key
KNOWLEDGE_AGENT_MODEL=gpt-4o
KNOWLEDGE_AGENT_TEMPERATURE=0.2
KNOWLEDGE_AGENT_TOP_K=4
KNOWLEDGE_AGENT_EMBEDDING_MODEL=text-embedding-3-small
KNOWLEDGE_AGENT_DEFAULT_NAMESPACE=docs
KNOWLEDGE_AGENT_STORAGE_PATH=knowledge
```

</Accordion>
<Accordion title="Knowledge ingestion schema">

```json
POST /tools/ingest
{
"namespace": "docs",
"sources": [
{
"type": "url",
"value": "https://example.com/handbook",
"title": "Handbook"
},
{
"type": "file",
"path": "/absolute/path/to/policies.pdf"
},
{
"type": "text",
"title": "Inline FAQ",
"value": "Q: How do refunds work?\nA: ..."
}
]
}
```

</Accordion>
<Accordion title="Streaming response shape">

```text
data: {"type":"tool_call_start","tool_call_id":"call_123","tool_name":"search_docs","args":{"namespace":"docs","query":"@agent refund policy"}}

data: {"type":"tool_call_result","tool_call_id":"call_123","result":{"matches":[{"chunk_id":"...","score":0.82,"source":"knowledge/docs/...","title":"Refund Policy","preview":"..."}]},"is_frontend_tool":false}

data: {"type":"text_message","delta":"Refunds are processed within 5 business days "}
data: {"type":"text_message","delta":"once the request is approved.[1] Sources: [1] Refund Policy"}
data: [DONE]
```

</Accordion>
</AccordionGroup>

***

## Step 1 - Ingest documentation

<Steps>
<Step title="Pick a namespace">
Stick with <code>docs</code> or choose a sanitized string (alphanumeric, <code>-</code>, <code>_</code>).
</Step>
<Step title="POST to /tools/ingest">
Supply a mix of URLs, file paths, and inline text. The server fetches, parses (PDF/Markdown/Text), chunks, embeds, and persists everything.
</Step>
<Step title="Inspect storage">
Confirm <code>knowledge/&lt;namespace&gt;</code> contains generated <code>.md</code> copies and an updated <code>index.json</code>.
</Step>
</Steps>

***

## Step 2 - Ask the knowledge agent

<Steps>
<Step title="Make a request">

```bash
curl -N -X POST http://localhost:8000/agent \
-H "Content-Type: application/json" \
-d '{
"thread_id": "demo-thread",
"run_id": "demo-run",
"messages": [
{ "role": "user", "content": "@knowledge What does our refund policy cover?" }
],
"tool_params": { "namespace": "docs" }
}'
```

</Step>
<Step title="Handle SSE">
Streamed events include tool telemetry and text deltas. Buffer them until you receive <code>[DONE]</code>.
</Step>
<Step title="Observe citations">
Replies contain bracketed numbers matching the <code>matches</code> payload returned by the retrieval tool.
</Step>
</Steps>

***

## Step 3 - Deploy the API

- Host the FastAPI app (Render, Fly.io, ECS, etc.) or wrap it in a serverless function.
- Expose <code>/agent</code>, <code>/tools/ingest</code>, and <code>/tools/search</code> over HTTPS.
- Keep <code>KNOWLEDGE_AGENT_STORAGE_PATH</code> on a persistent volume so ingested docs survive restarts.
- Harden CORS, rate limiting, and authentication before opening the endpoints to the public internet.

***

## Step 4 - Configure CometChat

<Steps>
<Step title="Open Dashboard">Go to <a href="https://app.cometchat.com/" target="_blank" rel="noreferrer">app.cometchat.com</a>.</Step>
<Step title="Add agent">Navigation: <b>AI Agents → Add Agent</b>.</Step>
<Step title="Provider & IDs">Set <b>Provider</b>=AG2 (AutoGen), <b>Agent ID</b>=<code>knowledge</code>, <b>Deployment URL</b>=public <code>/agent</code> endpoint.</Step>
<Step title="Optional metadata">Add greeting, intro, or suggested prompts such as “@knowledge Summarize the onboarding guide.”</Step>
<Step title="Enable">Save then confirm the toggle shows <b>Enabled</b>.</Step>
</Steps>

> For more on CometChat AI Agents, see: [Overview](/ai-agents/overview) · [Instructions](/ai-agents/instructions) · [Custom agents](/ai-agents/custom-agents)

***

## Step 5 - Customize in UI Kit Builder

<Steps>
<Step title="Open variant">From the Dashboard variant card, click <b>Customize and Deploy</b>.</Step>
<Step title="Update UX">Themes, layouts, attachment rules, and action bindings—all reflect in exports.</Step>
<Step title="Preview">Run conversations and confirm the knowledge agent responds only when invoked.</Step>
</Steps>

<Frame>
<img src="/images/ai-agent-chat-builder-preview.png" />
</Frame>

***

## Step 6 - Integrate

Once configured, embed the agent in your product using the exported configuration.

<CardGroup>
<Card title="Widget Builder" icon={<img src="/docs/images/products/ai-agents.svg" alt="Widget" />} description="Embed / script" href="/widget/ai-agents" horizontal />
<Card title="React UI Kit" icon={<img src="/docs/images/icons/react.svg" alt="React" />} href="https://www.cometchat.com/docs/ui-kit/react/ai-assistant-chat" horizontal>Pre Built UI Components</Card>
</CardGroup>

> The AG2 Knowledge agent you connected is bundled automatically. End-users will see it immediately after deployment.

***

## Step 7 - Test end-to-end

<Steps>
<Step title="API generates response">POST to <code>/agent</code> returns cited answers.</Step>
<Step title="Search utility works">POST to <code>/tools/search</code> returns ranked snippets.</Step>
<Step title="Dashboard check">In CometChat, ensure the agent appears as a selectable bot.</Step>
<Step title="Widget/UI verification">Preview in <b>UI Kit Builder</b> or your app and confirm streaming + citations behave as expected.</Step>
</Steps>

***

## Security & production checklist

- Protect ingestion routes with auth (API key/JWT) and restrict who can write to each namespace.
- Validate URLs and file paths before fetching to avoid SSRF or untrusted uploads.
- Rate limit the `/agent` and `/tools/*` endpoints to prevent abuse.
- Keep OpenAI keys server-side; never ship them in browser code or UI Kit Builder exports.
- Log tool calls (namespace, duration) for debugging and monitoring.

***

## Troubleshooting

* **Agent replies without citations**: confirm the retrieval step returns matches; check embeddings or namespace.
* **Empty or slow results**: ensure documents were ingested successfully and the top-k limit isn’t set to 0.
* **`503 Agent not initialized`**: verify server logs—`KnowledgeAgent` requires `OPENAI_API_KEY` during startup.
* **SSE errors in widget**: make sure your reverse proxy supports streaming and disables response buffering.

***

## Next steps

* Add new tools (e.g., `summarize`, `link_to_source`) by extending the AG2 agent before responding.
* Swap in enterprise vector stores by replacing `KnowledgeStore` with Pinecone, Qdrant, or Postgres.
* Schedule re-ingestion jobs when docs change, or watch folders for automatic refreshes.
* Layer analytics: log `tool_call_result.matches` for insight into content coverage.
Loading