-
Notifications
You must be signed in to change notification settings - Fork 415
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
chore(wren-ai-service): sql 2 answer streaming #894
Merged
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
cyyeh
added
module/ai-service
ai-service related
ci/ai-service
ai-service related
do-not-merge
labels
Nov 11, 2024
cyyeh
force-pushed
the
chore/ai-service/sql-2-answer-streaming
branch
2 times, most recently
from
November 11, 2024 21:54
af907b5
to
282c5b7
Compare
cyyeh
changed the base branch from
main
to
feat/ai-service/intent-and-chat-pipeline
November 11, 2024 21:54
cyyeh
force-pushed
the
feat/ai-service/intent-and-chat-pipeline
branch
from
November 12, 2024 08:47
a187937
to
78caaa4
Compare
cyyeh
force-pushed
the
chore/ai-service/sql-2-answer-streaming
branch
2 times, most recently
from
November 12, 2024 11:35
aff1072
to
f9acaef
Compare
cyyeh
force-pushed
the
chore/ai-service/sql-2-answer-streaming
branch
from
November 13, 2024 07:14
f9acaef
to
cf8a334
Compare
cyyeh
changed the base branch from
feat/ai-service/intent-and-chat-pipeline
to
main
November 13, 2024 11:31
paopa
reviewed
Nov 29, 2024
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.
overall LGTM. thanks for the hard work. a few comments leave.
paopa
approved these changes
Dec 3, 2024
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.
LGTM
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.
SQL Answers Router
This router handles endpoints related to initiating SQL answer operations and retrieving their results.
Endpoints:
POST /sql-answers
{
"query": "user's question",
"sql": "SELECT * FROM table_name WHERE condition", # Actual SQL statement
"thread_id": "unique-thread-id", # Optional thread identifier for tracking
"user_id": "user-id" # Optional user identifier for tracking
}
{
"query_id": "unique-uuid" # Unique identifier for the initiated SQL operation
}
GET /sql-answers/{query_id}/result
{
"query_id": "unique-uuid", # Unique identifier of the SQL answer operation
"status": "preprocessing" | "succeeded" | "failed",
"num_rows_used_in_llm": int | None,
"error": { # Present only if status is "failed"
"code": "OTHERS",
"message": "Error description"
}
}
GET /sql-answers/{query_id}/streaming-result
query_id
: The unique identifier of the query.Note: The actual SQL processing is performed in the background using FastAPI's BackgroundTasks.