-
Notifications
You must be signed in to change notification settings - Fork 56
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
feat(qa construct): add optional long context window approach #176
Merged
Conversation
This file contains 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
MichaelWalker-git
requested review from
krokoko,
hvital,
laithalsaadoon and
dineshSajwan
January 5, 2024 05:42
feat: add RAG shortcut
MichaelWalker-git
force-pushed
the
feat/issue_137
branch
from
January 5, 2024 18:45
8820990
to
dd5e82f
Compare
MichaelWalker-git
changed the title
DRAFT: feat: add optional long context window approach
feat(qa construct): add optional long context window approach
Jan 5, 2024
krokoko
reviewed
Jan 5, 2024
resources/gen-ai/aws-rag-appsync-stepfn-opensearch/schema.graphql
Outdated
Show resolved
Hide resolved
krokoko
reviewed
Jan 5, 2024
resources/gen-ai/aws-rag-appsync-stepfn-opensearch/schema.graphql
Outdated
Show resolved
Hide resolved
Test cases discussed:
To know which approach was used, this information will be logged by the Lambda function |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #176 +/- ##
=======================================
Coverage 93.61% 93.61%
=======================================
Files 18 18
Lines 5624 5624
Branches 125 125
=======================================
Hits 5265 5265
Misses 359 359 ☔ View full report in Codecov by Sentry. |
scottschreckengaust
approved these changes
Jan 16, 2024
dineshSajwan
approved these changes
Jan 16, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Problem
Our construct currently defaults to a long context window approach for processing documents when a filename is specified. This method leverages an extensive portion of the document's content as the context for generating AI responses. While effective for comprehensive context provision, it may not always be the most efficient or relevant approach for all use cases.
Proposed Solution
To provide users with greater flexibility and control over the response generation process, we propose introducing a new parameter within our GraphQL schema: responseGenerationMethod. This parameter will allow users to explicitly select their preferred method of context application—either the existing long context window (longContext) or the Retrieval-Augmented Generation (RAG) method.
(QA construct): Update Q/A logic #137
#137
Screenshots:
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of the project license.