Method and related device for generating database query statement

The embodiment of the invention discloses a method for generating a database query statement and a related device, which are applied to artificial intelligence, and the method comprises the following steps: inputting a to-be-processed natural language statement and a database mode of a to-be-queried...

Ausführliche Beschreibung

Gespeichert in:
Bibliographische Detailangaben
Hauptverfasser: CAO YUNBO, XIANG YANZHENG, ZHOU DEYU, ZHANG XU, ZHANG QIANWEN
Format: Patent
Sprache:chi ; eng
Schlagworte:
Online-Zugang:Volltext bestellen
Tags: Tag hinzufügen
Keine Tags, Fügen Sie den ersten Tag hinzu!
Beschreibung
Zusammenfassung:The embodiment of the invention discloses a method for generating a database query statement and a related device, which are applied to artificial intelligence, and the method comprises the following steps: inputting a to-be-processed natural language statement and a database mode of a to-be-queried database into an encoder for generating a model, and outputting a first encoding vector of the to-be-processed natural language statement and the database mode; after the first coding vector is input into the generation model to generate t-1 actions, a first syntax tree-action bigraph of the t-1 actions is constructed, and t is a positive integer and is larger than or equal to 2; inputting the first coding vector and the first syntax tree-action bipartite graph into a bipartite graph-based decoder for generating a model, and outputting the tth action until a complete candidate action sequence is generated; and converting the candidate action sequence into a to-be-processed database query statement corresponding to