add help info (#142)
This commit is contained in:
@@ -55,6 +55,7 @@ const AssistantSetting = ({ show }: ISegmentedContentProps) => {
|
||||
label="Language"
|
||||
initialValue={'Chinese'}
|
||||
tooltip="coming soon"
|
||||
style={{display:'none'}}
|
||||
>
|
||||
<Select
|
||||
options={[
|
||||
@@ -66,22 +67,23 @@ const AssistantSetting = ({ show }: ISegmentedContentProps) => {
|
||||
<Form.Item
|
||||
name={['prompt_config', 'empty_response']}
|
||||
label="Empty response"
|
||||
tooltip="coming soon"
|
||||
tooltip="If nothing is retrieved with user's question in the knowledgebase, it will use this as an answer.
|
||||
If you want LLM comes up with its own opinion when nothing is retrieved, leave this blank."
|
||||
>
|
||||
<Input placeholder="" />
|
||||
</Form.Item>
|
||||
<Form.Item
|
||||
name={['prompt_config', 'prologue']}
|
||||
label="Set an opener"
|
||||
tooltip="coming soon"
|
||||
tooltip="How do you want to welcome your clients?"
|
||||
initialValue={"Hi! I'm your assistant, what can I do for you?"}
|
||||
>
|
||||
<Input.TextArea autoSize={{ minRows: 5 }} />
|
||||
</Form.Item>
|
||||
<Form.Item
|
||||
label="Select one context"
|
||||
label="Knowledgebases"
|
||||
name="kb_ids"
|
||||
tooltip="coming soon"
|
||||
tooltip="Select knowledgebases associated."
|
||||
rules={[
|
||||
{
|
||||
required: true,
|
||||
|
||||
@@ -46,16 +46,16 @@ const ModelSetting = ({ show, form }: ISegmentedContentProps) => {
|
||||
<Form.Item
|
||||
label="Model"
|
||||
name="llm_id"
|
||||
tooltip="coming soon"
|
||||
tooltip="Large language chat model"
|
||||
rules={[{ required: true, message: 'Please select!' }]}
|
||||
>
|
||||
<Select options={modelOptions} showSearch />
|
||||
</Form.Item>
|
||||
<Divider></Divider>
|
||||
<Form.Item
|
||||
label="Parameters"
|
||||
label="Freedom"
|
||||
name="parameters"
|
||||
tooltip="coming soon"
|
||||
tooltip="'Precise' means the LLM will be conservative and answer your question cautiously. 'Improvise' means the you want LLM talk much and freely. 'Balance' is between cautiously and freely."
|
||||
initialValue={ModelVariableType.Precise}
|
||||
// rules={[{ required: true, message: 'Please input!' }]}
|
||||
>
|
||||
@@ -64,7 +64,7 @@ const ModelSetting = ({ show, form }: ISegmentedContentProps) => {
|
||||
onChange={handleParametersChange}
|
||||
/>
|
||||
</Form.Item>
|
||||
<Form.Item label="Temperature" tooltip={'xx'}>
|
||||
<Form.Item label="Temperature" tooltip={'This parameter controls the randomness of predictions by the model. A lower temperature makes the model more confident in its responses, while a higher temperature makes it more creative and diverse.'}>
|
||||
<Flex gap={20} align="center">
|
||||
<Form.Item
|
||||
name={'temperatureEnabled'}
|
||||
@@ -96,7 +96,7 @@ const ModelSetting = ({ show, form }: ISegmentedContentProps) => {
|
||||
</Form.Item>
|
||||
</Flex>
|
||||
</Form.Item>
|
||||
<Form.Item label="Top P" tooltip={'xx'}>
|
||||
<Form.Item label="Top P" tooltip={'Also known as “nucleus sampling,” this parameter sets a threshold to select a smaller set of words to sample from. It focuses on the most likely words, cutting off the less probable ones.'}>
|
||||
<Flex gap={20} align="center">
|
||||
<Form.Item name={'topPEnabled'} valuePropName="checked" noStyle>
|
||||
<Switch size="small" />
|
||||
@@ -124,7 +124,7 @@ const ModelSetting = ({ show, form }: ISegmentedContentProps) => {
|
||||
</Form.Item>
|
||||
</Flex>
|
||||
</Form.Item>
|
||||
<Form.Item label="Presence Penalty" tooltip={'xx'}>
|
||||
<Form.Item label="Presence Penalty" tooltip={'This discourages the model from repeating the same information by penalizing words that have already appeared in the conversation.'}>
|
||||
<Flex gap={20} align="center">
|
||||
<Form.Item
|
||||
name={'presencePenaltyEnabled'}
|
||||
@@ -160,7 +160,7 @@ const ModelSetting = ({ show, form }: ISegmentedContentProps) => {
|
||||
</Form.Item>
|
||||
</Flex>
|
||||
</Form.Item>
|
||||
<Form.Item label="Frequency Penalty" tooltip={'xx'}>
|
||||
<Form.Item label="Frequency Penalty" tooltip={'Similar to the presence penalty, this reduces the model’s tendency to repeat the same words frequently.'}>
|
||||
<Flex gap={20} align="center">
|
||||
<Form.Item
|
||||
name={'frequencyPenaltyEnabled'}
|
||||
@@ -196,7 +196,7 @@ const ModelSetting = ({ show, form }: ISegmentedContentProps) => {
|
||||
</Form.Item>
|
||||
</Flex>
|
||||
</Form.Item>
|
||||
<Form.Item label="Max Tokens" tooltip={'xx'}>
|
||||
<Form.Item label="Max Tokens" tooltip={'This sets the maximum length of the model’s output, measured in the number of tokens (words or pieces of words).'}>
|
||||
<Flex gap={20} align="center">
|
||||
<Form.Item name={'maxTokensEnabled'} valuePropName="checked" noStyle>
|
||||
<Switch size="small" />
|
||||
|
||||
@@ -154,7 +154,7 @@ const PromptEngine = (
|
||||
<Form.Item
|
||||
label="System"
|
||||
rules={[{ required: true, message: 'Please input!' }]}
|
||||
tooltip="coming soon"
|
||||
tooltip="Instructions you need LLM to follow when LLM answers questions, like charactor design, answer length and answer language etc."
|
||||
name={['prompt_config', 'system']}
|
||||
initialValue={`你是一个智能助手,请总结知识库的内容来回答问题,请列举知识库中的数据详细回答。当所有知识库内容都与问题无关时,你的回答必须包括“知识库中未找到您要的答案!”这句话。回答需要考虑聊天历史。
|
||||
以下是知识库:
|
||||
@@ -166,10 +166,10 @@ const PromptEngine = (
|
||||
<Divider></Divider>
|
||||
<SimilaritySlider isTooltipShown></SimilaritySlider>
|
||||
<Form.Item<FieldType>
|
||||
label="Top n"
|
||||
label="Top N"
|
||||
name={'top_n'}
|
||||
initialValue={8}
|
||||
tooltip={'xxx'}
|
||||
tooltip={`Not all the chunks whose similarity score is above the 'simialrity threashold' will be feed to LLMs. LLM can only see these 'Top N' chunks.`}
|
||||
>
|
||||
<Slider max={30} />
|
||||
</Form.Item>
|
||||
@@ -178,7 +178,10 @@ const PromptEngine = (
|
||||
<Col span={7} className={styles.variableAlign}>
|
||||
<label className={styles.variableLabel}>
|
||||
Variables
|
||||
<Tooltip title="coming soon">
|
||||
<Tooltip title="If you use dialog APIs, the varialbes might help you chat with your clients with different strategies.
|
||||
The variables are used to fill-in the 'System' part in prompt in order to give LLM a hint.
|
||||
The 'knowledge' is a very special variable which will be filled-in with the retrieved chunks.
|
||||
All the variables in 'System' should be curly bracketed.">
|
||||
<QuestionCircleOutlined className={styles.variableIcon} />
|
||||
</Tooltip>
|
||||
</label>
|
||||
|
||||
Reference in New Issue
Block a user