forked from open-webui/open-webui
feat: add {{prompt:start:length}} and {{prompt🔚length}} to title gen
This commit is contained in:
parent
8e30948de9
commit
db817fcf29
3 changed files with 29 additions and 2 deletions
|
@ -1,4 +1,5 @@
|
|||
import { OLLAMA_API_BASE_URL } from '$lib/constants';
|
||||
import { templatePrompt } from '$lib/utils';
|
||||
|
||||
export const getOllamaUrls = async (token: string = '') => {
|
||||
let error = null;
|
||||
|
@ -144,7 +145,7 @@ export const generateTitle = async (
|
|||
) => {
|
||||
let error = null;
|
||||
|
||||
template = template.replace(/{{prompt}}/g, prompt);
|
||||
template = templatePrompt(template, prompt);
|
||||
|
||||
console.log(template);
|
||||
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
import { OPENAI_API_BASE_URL } from '$lib/constants';
|
||||
import { templatePrompt } from '$lib/utils';
|
||||
|
||||
export const getOpenAIUrls = async (token: string = '') => {
|
||||
let error = null;
|
||||
|
@ -273,7 +274,7 @@ export const generateTitle = async (
|
|||
) => {
|
||||
let error = null;
|
||||
|
||||
template = template.replace(/{{prompt}}/g, prompt);
|
||||
template = templatePrompt(template, prompt);
|
||||
|
||||
console.log(template);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue