Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add option Embed into webpage #5065

Merged
merged 6 commits into from
Feb 18, 2025
Merged

Conversation

isthaison
Copy link
Contributor

add option Embed into webpage

@@ -38,14 +38,17 @@ def get_prompt(self, conv, language, query):
Role: A helpful assistant
Task: Generate a full user question that would follow the conversation.
Requirements & Restrictions:
- Text generated MUST be in the same language of the original user's question.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's O.K. to metion the language twice in prompt. Otherwise, the default language is empty.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've tried with some smart models it works. but for low-performance local models. It has a low level of return to the user's language


import { useIsDarkTheme } from '@/components/theme-provider';
import { cn } from '@/lib/utils';
import { languageOptions } from '@/locales/config';
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ttempted import error: 'languageOptions' is not exported from '@/locales/config' (imported as 'languageOptions').

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry!! I misstate, please check again

@isthaison isthaison requested a review from cike8899 February 18, 2025 04:02
@KevinHuSh KevinHuSh merged commit d6ba4bd into infiniflow:main Feb 18, 2025
1 check passed
KevinHuSh pushed a commit that referenced this pull request Feb 18, 2025
…5065 (#5072)

### What problem does this PR solve?

Feat: Add LanguageAbbreviation to simplify language resource files.
#5065

### Type of change

- [x] New Feature (non-breaking change which adds functionality)
@isthaison isthaison deleted the option-Embed branch March 4, 2025 04:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants