Rolex
Rolex
LLangfuse
Created by Rolex on 9/2/2024 in #self-host-discussion
Langfuse organization/project API
Hey @Clemo Looks like v2.78.0 has this feature. I will try it out. Thanks You guys are super fast.🫡
3 replies
LLangfuse
Created by Rolex on 6/17/2024 in #get-support
Hey
In langchain the text prompt should be
You are an expert in generating JSON for the given input

Example:
user: `I have 2 employees named Marc and Max who are the founders of Langfuse`
assistant: {{"company": "Langfuse", "founders": ["Marc", "Max"]}}

user: {userInput}
You are an expert in generating JSON for the given input

Example:
user: `I have 2 employees named Marc and Max who are the founders of Langfuse`
assistant: {{"company": "Langfuse", "founders": ["Marc", "Max"]}}

user: {userInput}
Where a double mustache is used as escaping character
5 replies
LLangfuse
Created by Rolex on 6/17/2024 in #get-support
Hey
Yeah, the issue was when the prompt contained JSON. ex prompt in langfuse:
You are an expert in generating JSON for the given input

Example:
user: `I have 2 employees named Marc and Max who are the founders of Langfuse`
assistant: {"company": "Langfuse", "founders": ["Marc", "Max"]}

user: {{userInput}}
You are an expert in generating JSON for the given input

Example:
user: `I have 2 employees named Marc and Max who are the founders of Langfuse`
assistant: {"company": "Langfuse", "founders": ["Marc", "Max"]}

user: {{userInput}}
When I use .get_langchain_prompt() the variable is converted to langchain format. i,e {userInput} but the JSON remains as is. So the langchain considers "company" as a variable too. This is only when we use the new feature .get_langchain_prompt(). we can use old way, template format jinja2
5 replies