mirror of
https://github.com/Azure/cosmos-explorer.git
synced 2025-12-28 21:32:05 +00:00
[Query Copilot] V2 Backend integration (#1584)
* Initial implementetation of backend integration
* Added parameters and interfaces moved
* Initial client implementation
* Additional changes for React FC's
* Updated snapshot of Footer
* Additional Copilot implementation
* Test adjustments and client implementation
* Additional test implementations
* Naming convetion for functions
* Changing {} to any
* Additional changes to the type
* Additional test changes
* Removal of prevention
* adding comment
* Additional changes to tests
* Moving logic based on comments
* client implementation along with corrected tests
---------
Co-authored-by: Predrag Klepic <v-prklepic@microsoft.com>
This commit is contained in:
32
src/Explorer/QueryCopilot/Shared/QueryCopilotInterfaces.ts
Normal file
32
src/Explorer/QueryCopilot/Shared/QueryCopilotInterfaces.ts
Normal file
@@ -0,0 +1,32 @@
|
||||
import Explorer from "Explorer/Explorer";
|
||||
|
||||
export interface GenerateSQLQueryResponse {
|
||||
apiVersion: string;
|
||||
sql: string;
|
||||
explanation: string;
|
||||
generateStart: string;
|
||||
generateEnd: string;
|
||||
}
|
||||
|
||||
enum MessageSource {
|
||||
User,
|
||||
AI,
|
||||
}
|
||||
|
||||
export interface CopilotMessage {
|
||||
source: MessageSource;
|
||||
message: string;
|
||||
explanation?: string;
|
||||
}
|
||||
|
||||
export interface FeedbackParams {
|
||||
likeQuery: boolean;
|
||||
generatedQuery: string;
|
||||
userPrompt: string;
|
||||
description?: string;
|
||||
contact?: string;
|
||||
}
|
||||
|
||||
export interface QueryCopilotProps {
|
||||
explorer: Explorer;
|
||||
}
|
||||
Reference in New Issue
Block a user