@@ -3,12 +3,9 @@ import { PropTypes } from 'prop-types';
33import { Dialog , Transition } from '@headlessui/react' ;
44import Button from 'components/atoms/common/Button' ;
55import { BUTTON_INTENT_TYPES , BUTTON_TYPES } from 'constants/Common' ;
6- import TextInput from 'components/atoms/common/TextInput' ;
7- import GenerateFlowTestModal from './GenerateFlowTestModal' ;
8- import { setLocalStorageItem } from 'utils/common' ;
6+ import { addGenAIUsageDisclaimer } from 'service/settings' ;
97
10- const GenAIUsageDisclaimer = ( { closeFn = ( ) => null , open = false , collectionId } ) => {
11- const [ generateFlowTestModalOpen , setGenerateFlowTestModalOpen ] = useState ( false ) ;
8+ const GenAIUsageDisclaimer = ( { closeFn = ( ) => null , open = false , openGenerateFlowTestModal = ( ) => null } ) => {
129 return (
1310 < >
1411 < Transition appear show = { open } as = { Fragment } >
@@ -48,22 +45,17 @@ const GenAIUsageDisclaimer = ({ closeFn = () => null, open = false, collectionId
4845 </ Dialog . Title >
4946 < div className = 'flex flex-col pb-6' >
5047 < p className = 'mt-2 text-xl font-semibold italic 2xl:mt-4' >
51- This tool utilizes OpenAI's and Amazon Bedrock Claude language model to provide information
48+ This tool utilizes OpenAI's and Amazon Bedrock's language models to provide information
5249 and assistance. While we strive to ensure the accuracy and reliability of the information
5350 provided, the responses generated by the model may not always be accurate, complete, or
5451 up-to-date.
5552 </ p >
5653 < ul className = 'font-montserrat' >
5754 < li className = 'py-2' >
5855 < span className = 'font-semibold' > Information Accuracy:</ span > The information and responses
59- provided by the tool are generated based on the data and patterns recognized by OpenAI's
60- language model. Users should independently verify any critical information before relying on it.
61- </ li >
62- < li className = 'py-2' >
63- < span className = 'font-semibold' > No Professional Advice:</ span > The responses generated by the
64- tool do not constitute professional advice, including but not limited to medical, legal,
65- financial, or any other professional service. Always seek the advice of a qualified professional
66- with any questions you may have.
56+ provided by the tool are generated based on the data and patterns recognized by OpenAI's and
57+ Amazon Bedrock's language models. Users should independently verify any critical information
58+ before relying on it.
6759 </ li >
6860 < li className = 'py-2' >
6961 < span className = 'font-semibold' > User Responsibility:</ span > Users are responsible for how they
@@ -72,15 +64,15 @@ const GenAIUsageDisclaimer = ({ closeFn = () => null, open = false, collectionId
7264 </ li >
7365 < li className = 'py-2' >
7466 < span className = 'font-semibold' > Company Policies:</ span > If your company has policies or
75- guidelines related to the use of OpenAI or AI-generated content, please ensure that you adhere
76- to those policies when using this tool. It is your responsibility to comply with your
77- company's regulations and standards.
67+ guidelines related to the use of OpenAI or AWS Bedrock or AI-generated content, please ensure
68+ that you adhere to those policies when using this tool. It is your responsibility to comply with
69+ your company's regulations and standards.
7870 </ li >
7971 < li className = 'py-2' >
80- < span className = 'font-semibold' > Privacy and Data Use:</ span > The tool may collect data input by
81- users to improve the quality of the service . Please review our privacy policy for more
82- information on how we handle your data. By using this tool, you acknowledge that you understand
83- and agree to this disclaimer and our terms of service.
72+ < span className = 'font-semibold' > Privacy and Data Use:</ span > This tool itself DOES NOT collect
73+ any data input by users . Please review the respective LLM's privacy policy for more
74+ information on how they handle your data. By using this tool, you acknowledge that you
75+ understand and agree to this disclaimer and our terms of service.
8476 </ li >
8577 </ ul >
8678 </ div >
@@ -100,10 +92,10 @@ const GenAIUsageDisclaimer = ({ closeFn = () => null, open = false, collectionId
10092 btnType = { BUTTON_TYPES . primary }
10193 isDisabled = { false }
10294 fullWidth = { true }
103- onClickHandle = { ( ) => {
95+ onClickHandle = { async ( ) => {
96+ await addGenAIUsageDisclaimer ( true ) ;
10497 closeFn ( ) ;
105- setGenerateFlowTestModalOpen ( true ) ;
106- setLocalStorageItem ( 'show_gen_ai_disclaimer' , false ) ;
98+ openGenerateFlowTestModal ( ) ;
10799 } }
108100 >
109101 Acknowledge
@@ -115,11 +107,6 @@ const GenAIUsageDisclaimer = ({ closeFn = () => null, open = false, collectionId
115107 </ div >
116108 </ Dialog >
117109 </ Transition >
118- < GenerateFlowTestModal
119- closeFn = { ( ) => setGenerateFlowTestModalOpen ( false ) }
120- open = { generateFlowTestModalOpen }
121- collectionId = { collectionId }
122- />
123110 </ >
124111 ) ;
125112} ;
0 commit comments