How to Build a Natural Language to SQL Converter using the OpenAI API

Поделиться
HTML-код
  • Опубликовано: 28 мар 2023
  • Taking a break from talking about testing to talk about AI a bit!
    Requirements
    - Python
    - An API key from OpenAI
    UPDATE: the text-davinci models are on their way to being deprecated. Please use the gpt-3.5-turbo model going forward. See Github for updates
    Github code: github.com/Adam-Thometz/Natur...

Комментарии • 5

  • @mitthatpreetkaur4393
    @mitthatpreetkaur4393 4 месяца назад

    Hello, I want to build something similar but is there any way that we do not share our schema as it is as it might contain confidential info. and instead we share some aliases in place of table and column names?

    • @bitsnbotsai
      @bitsnbotsai  2 месяца назад

      I know I'm late but could you give me an example of a schema name you'd want to redact?
      Either way, you'll have to take care of this programmatically. For example, you could redact each column name by giving it a meaningful name (like a variable) and when the AI returns your query, replace the name in the generated query with the actual column name before you run your query.

  • @prasanthv2652
    @prasanthv2652 9 месяцев назад

    can you share the code

    • @bitsnbotsai
      @bitsnbotsai  9 месяцев назад

      Whoops, thought I included it. Apologies. Here ya go: github.com/Adam-Thometz/Natural-Language-to-SQL

    • @prasanthv2652
      @prasanthv2652 9 месяцев назад

      thanks@@bitsnbotsai