{"repo":"Predictable-Dialogs/agent-embed","free":true,"listed":false,"github":"https://github.com/Predictable-Dialogs/agent-embed","clone":"git clone https://github.com/Predictable-Dialogs/agent-embed.git","description":"OpenAI embed for the web with https://predictabledialogs.com","language":"TypeScript","stars":16,"topics":["agent","ai","embed","nextjs","react","web","widget","ai-sdk"],"license":"AGPL-3.0","category":"ai-agents","readme_excerpt":"Add an OpenAI Chatbot to your website using this library. Pre-requisite Create an agent on https://predictabledialogs.com The agent-embed repository provides components which can be embedded on a website and communicates with the predictable dialogs backend which in turn talks to the openAI LLM models. It currently provides components for chat. The chat components it provides are Bubbles, Standard, Popup. Example with all props: Introduction The embed code can be added to HTML or JS, here is an example to add the embed code to HTML In the above we are adding a Standard widget - Agent.initStandard , similarly the Bubble - Agent.initBubble and Popup - Agent.initPopup are initialized. initialPrompts accepts 1-8 prompt objects shaped like { text, icon?, iconUrl? } and renders them as clickable cards above the input; clicking one sends it as the first user message. Use the optional welcome: { title, subtitle } prop to show a heading above those prompts. The legacy initialPrompt prop is still accepted for backward compatibility and will be treated as a single-entry initialPrompts array. The filterResponse prop accepts a function that processes the AI's response. This function takes the response as an argument and allows for custom handling, such as filtering out annotations. The function should return the modified response, which will then be displayed in the widget. The apiHost prop points to the Predictable Dialogs backend, but it can also be configured to use your own backend. T","default_branch":null,"files":null,"tree":[],"storefront":"/r/Predictable-Dialogs","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/Predictable-Dialogs/agent-embed/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}