-
Notifications
You must be signed in to change notification settings - Fork 105
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
Update deploy and auth documentation to use menuSuggestionFlow #112
Conversation
I suggest we split this into 2 PRs. One that ensures that the "deployment" related docs work as intended with |
32fe119
to
e133523
Compare
e133523
to
d98a8be
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Made a few comments.
Please pay particular attention to variable names that need to change along with the flow. I highlighted ones that I spotted, but there are likely more.
@@ -104,7 +104,7 @@ sample flow. | |||
Then, in another window: | |||
|
|||
```posix-terminal | |||
curl -X POST "http://127.0.0.1:3400/jokeFlow?stream=true" -H "Content-Type: application/json" -d '{"data": "banana"}' | |||
curl -X POST "http://127.0.0.1:3400/menuSuggestionFlow?stream=true" -H "Content-Type: application/json" -d '{"data": "banana"}' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this still take "banana" as input?
@@ -81,7 +81,7 @@ sample flow. | |||
```posix-terminal | |||
npm run build | |||
|
|||
genkit flow:run jokeFlow "\"banana\"" -s | |||
genkit flow:run menuSuggestionFlow "\"banana\"" -s |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this still take "banana" as input?
docs/auth.md
Outdated
@@ -140,7 +140,7 @@ above. When running this flow during development, you would pass the user object | |||
in the same way: | |||
|
|||
```posix-terminal | |||
genkit flow:run jokeFlow '"Banana"' --auth '{"admin": true}' | |||
genkit flow:run menuSuggestionFlow '"Banana"' --auth '{"admin": true}' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this still take "banana" as input?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(if we're still going w/ menuSuggestionFlow)
docs/auth.md
Outdated
@@ -121,8 +121,8 @@ You can use Firebase Auth to protect your flows defined with `onFlow()`: | |||
import { firebaseAuth } from '@genkit-ai/firebase/auth'; | |||
import { onFlow } from '@genkit-ai/firebase/functions'; | |||
|
|||
export const jokeFlow = onFlow({ | |||
name: 'jokeFlow', | |||
export const menuSuggestionFlow = onFlow({ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm a little torn on using menuSuggestionFlow
here, since the rest of the doc before and after this point refer to selfSummaryFlow
. I'm wondering if we should use the same (i.e. selfSummaryFlow
) throughout.
@@ -122,7 +122,7 @@ flow. | |||
|
|||
1. In the developer UI (http://localhost:4000/), run the flow: | |||
|
|||
1. Click **jokeFlow**. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are still some references below that need to be updated.
L129-131 - subject matter doesn't work as well w/ menuSuggestionFlow
L162-166 curls jokeFlow w/ banana as input.
docs/auth.md
Outdated
export const jokeFlow = onFlow({ | ||
name: 'jokeFlow', | ||
export const menuSuggestionFlow = onFlow({ | ||
name: 'menuSuggestionFlow', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reference to (joke)
a few more lines below as an input param under authPolicy.
d98a8be
to
9cc4590
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No description provided.