CONVERTING NATURAL LANGUAGE QUERIES TO SQL QUERIES USING ONTOLOGICAL CODES AND PLACEHOLDERS

    公开(公告)号:US20250013636A1

    公开(公告)日:2025-01-09

    申请号:US18892144

    申请日:2024-09-20

    Abstract: An NLQ-SQLQ tool or service of a provider network may receive a natural language query (NLQ) from a client and convert the NLQ to an SQL query using ontological codes and placeholders. For one or more portions of the NLQ, the tool/service determines that the portion is associated with one or more codes of an ontology. The tool/service then assigns, based on criteria, a particular code to the portion. The tool/service replaces portions of the NLQ with different argument placeholders to generate a modified NLQ. A trained model converts the modified NLQ into an initial SQL query that has argument placeholders and subquery placeholders. The tool/service generates a final SQL query based on the initial SQL query, predefined SQL subquery templates associated with the subquery placeholders, and codes associated with the argument placeholders. The tool/service executes the final SQL query and sends results to the client.

Patent Agency Ranking