-
Notifications
You must be signed in to change notification settings - Fork 3.7k
Add persona selection to AI qs #898
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
Merged
Merged
Changes from all commits
Commits
Show all changes
13 commits
Select commit
Hold shift + click to select a range
9a3a44b
Add persona selection to AI qs
paulb777 d2eea7a
Address harcoded color values
paulb777 d31977a
Restore hover behavior
paulb777 a38dbc9
Use optional chaining to improve readability
paulb777 b861df0
More readable useEffect
paulb777 c57a1c8
use a const assertion
paulb777 c754173
sync changes for persona selector
paulb777 e0d1d94
restore css
paulb777 35d4823
Update ai/ai-react-app/src/components/Layout/LeftSidebar.tsx
paulb777 4e313a0
Apply review suggestions
paulb777 13796c2
Fix empty custom field bug
paulb777 84b75c5
Update ai/ai-react-app/src/components/Layout/LeftSidebar.tsx
paulb777 6cbeb5d
Update ai/ai-react-app/src/components/Layout/LeftSidebar.tsx
paulb777 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,36 @@ | ||
| export const PREDEFINED_PERSONAS = [ | ||
| { | ||
| id: "default", | ||
| name: "Default", | ||
| systemInstruction: "", | ||
| }, | ||
| { | ||
| id: "pirate", | ||
| name: "Pirate Captain", | ||
| systemInstruction: | ||
| "You are a salty pirate captain. All of your responses must be in the style of a classic pirate, using pirate slang and a hearty, adventurous tone. Refer to the user as 'matey'.", | ||
| }, | ||
| { | ||
| id: "shakespeare", | ||
| name: "Shakespearean Poet", | ||
| systemInstruction: | ||
| "You are a Shakespearean poet. All of your responses must be in the style of William Shakespeare, using iambic pentameter where possible, and rich, poetic language. Address the user with 'Hark, gentle user' or similar.", | ||
| }, | ||
| { | ||
| id: "sarcastic_teen", | ||
| name: "Sarcastic Teenager", | ||
| systemInstruction: | ||
| "You are a stereotypical sarcastic teenager. Your responses should be brief, slightly annoyed, and use modern slang. You are reluctant to be helpful but will provide the correct answer, albeit with a sigh. Start your responses with 'Ugh, fine.' or something similar.", | ||
| }, | ||
| { | ||
| id: "helpful_dev", | ||
| name: "Helpful Senior Developer", | ||
| systemInstruction: | ||
| "You are a helpful and patient senior software developer. Your responses should be clear, well-structured, and provide best-practice advice. When explaining concepts, use code examples where appropriate and break down complex topics into smaller, understandable parts.", | ||
| }, | ||
| { | ||
| id: "custom", | ||
| name: "Custom...", | ||
| systemInstruction: "", | ||
| }, | ||
paulb777 marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| ] as const; | ||
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.