-
-
Notifications
You must be signed in to change notification settings - Fork 44
feat: implement search with ✨jAI #202
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
Conversation
…s for consistency
…nd update search result display
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
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.
Pull Request Overview
This PR introduces a "Search with ✨jAI" feature that enhances the word search experience by providing AI-powered definitions when words are not found in the dictionary, replacing the previous "No Result Found" message.
- Adds jAI search integration with new UI components and keyboard navigation support
- Refactors jAI prompt system to support both general personality and specialized word definition prompts
- Creates new API endpoint and page for handling jAI-powered word searches
Reviewed Changes
Copilot reviewed 9 out of 10 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| src/pages/browse/with-jai/index.astro | New page for displaying jAI-generated word definitions |
| src/pages/api/jai/search.js | New API endpoint for handling jAI search requests |
| src/components/islands/search.jsx | Enhanced search component with jAI integration and improved keyboard navigation |
| src/components/islands/jai-word-search.jsx | New React component for querying jAI and displaying markdown responses |
| src/components/islands/jai-logo.jsx | New React component for the jAI logo |
| src/components/jai-logo.astro | New Astro component for the jAI logo |
| apps/jai/lib/jai-prompt.js | Refactored prompt system to support multiple prompt types |
| src/components/jargonsdev-logo.astro | Code formatting improvements |
| .prettierignore | Removed entry for jargonsdev-logo.astro |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
…dictionry into feat/ask-jai-404-word
…ts to `apps/jai` module
…JAI search functionality
…-powered features and module structure
…ailwind.config.js
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.
Pull Request Overview
Copilot reviewed 14 out of 16 changed files in this pull request and generated 2 comments.
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Description
This pull request introduces a new "Search with ✨jAI" feature to the word search experience; before this, whenever a word was searched and it didn't exist in the dictionary, we'd get a
No Result Foundfeedback, but now we get this options replacing the no found with search for the word with ✨jAI.This feature enable us route to a page where the meaning to that word is generated on the fly using ✨jAI.
Notable Changes
1. AI-powered word definitions and prompt improvements
SEARCH_WORD) injai-prompts.jsfor generating structured, SEO-friendly definitions, and moved the original personality prompt to this file. (apps/jai/lib/jai-prompts.js,apps/jai/lib/jai-prompt.jsremoved,apps/jai/index.js,apps/jai/README.md) [1] [2] [3] [4]apps/jai/README.md) [1] [2]2. New React UI components for ✨jAI integration
logo.jsx, a reusable SVG React component for ✨jAI branding. (apps/jai/components/logo.jsx)word-search.jsx, a React component for generating and displaying AI-powered word definitions, including error handling, loading states, and a trigger component for UI integration. (apps/jai/components/word-search.jsx)JAIWordSearchTriggerinto the main search UI for easy access to AI-powered definitions. (src/components/islands/search.jsx)3. Documentation and architecture updates
README.mdto clarify the module structure, document new components, and explain the updated integration flow, including the new/api/jai/searchendpoint. (apps/jai/README.md) [1] [2] [3]4. Model selection and configuration
gpt-4.1-minifor both local development (.env.example) and documentation, and added detailed notes about model selection strategy for different ✨jAI features. (.env.example,apps/jai/lib/model.js,apps/jai/README.md) [1] [2] [3]5. Minor cleanups
.prettierignoreto reduce noise in formatting tools. (.prettierignore)These changes collectively enhance the user experience, developer clarity, and the overall flexibility of the
apps/jaimodule for future features and scaling.Related Issue
Fixes jargonsdev/roadmap#8
Screenshots/Screencasts
screen-capture.5.webm
Search for word that a not technical term or not related to software, programming ec. fields
Notes to Reviewer