An open source framework for building AI-powered apps with familiar code-centric patterns. Genkit makes it easy to integrate, test, and deploy sophisticated AI features to Firebase or Google Cloud.
Apache License 2.0
644
stars
88
forks
source link
[dotprompt] Always reload .prompt files in dev mode #566
I suggest that when NODE_ENV=development (orGENKIT_ENV=dev) .prompt files should be automatically reloaded from disk before each invocation. This would be beneficial for a few reasons:
We could stop rebooting the entire server when a .prompt file changes, speeding up iteration
There would be less chance of "stale prompts" which seems to happen to me relatively frequently though I'm not sure why
To accomplish this I think we need the proxy ref construct proposed in #513, but once we had that it would be pretty trivial.
Update on this: see #744 which is honestly even more annoying than stale prompts because it actually breaks the flow of the server. Let's solve both of these problems.
I suggest that when
NODE_ENV=development
(orGENKIT_ENV=dev
).prompt
files should be automatically reloaded from disk before each invocation. This would be beneficial for a few reasons:.prompt
file changes, speeding up iterationTo accomplish this I think we need the proxy ref construct proposed in #513, but once we had that it would be pretty trivial.