Flowise icon indicating copy to clipboard operation
Flowise copied to clipboard

[FEATURE] Use prompts defined in Langfuse for Flowise Chatflows

Open dkindlund opened this issue 1 year ago • 5 comments

Describe the feature you'd like Langfuse supports the ability to store and manage prompts within that UI. It would be awesome if there was an easy way to fetch those prompts dynamically into a specific chatflow within Flowise.

Additional context Langfuse has a prompts_get API endpoint to support this functionality: https://langfuse.com/docs/api-reference#tag/Prompts

The scope of work would be:

  • Create a new Langfuse-specific node in Flowise that can use the existing Langfuse credentials (from Analytic)
  • Make sure this new node can connect as an input to any Prompt nodes
  • The Prompt nodes can then refer to the Langfuse node through a standard variable

It seems easy enough and I could probably write this as a custom JS node, but:

  1. It would be better if someone from Langfuse supported this and
  2. There's no way for custom JS nodes to easily fetch credential info (and I really don't want to hard code credentials in custom JS nodes anymore)

Hey @HenryHengZJ and @marcklingen, let me know your thoughts on this.

dkindlund avatar Jan 24 '24 16:01 dkindlund

Side note btw, @marcklingen -- it would be great if the prompts_get endpoint supported like an optional param of version=latest so that you didn't have to constantly update those numbers by hand everytime.

dkindlund avatar Jan 24 '24 16:01 dkindlund

Side note btw, @marcklingen -- it would be great if the prompts_get endpoint supported like an optional param of version=latest so that you didn't have to constantly update those numbers by hand everytime

If you do not specify a version, the latest version marked as active in Langfuse is used. No need to update versions every time you make a change.

marcklingen avatar Jan 24 '24 17:01 marcklingen

one way is to specify langfuse credential as variable, and use $vars in the custom function for that

HenryHengZJ avatar Jan 25 '24 19:01 HenryHengZJ

Do you have any updates on this issue? Is any Public PR accepted to have this feature?

petitgen avatar Apr 22 '24 22:04 petitgen

+1

thiagolealassis avatar Jul 24 '24 19:07 thiagolealassis