0.0.86 • Published 10 months ago

@eloquentops/ask-your-data v0.0.86

Weekly downloads
-
License
ISC
Repository
-
Last release
10 months ago

Ask Your Data

A Custom Component for Retool that adds natural language capability to filter an array. It uses OpenAI GPT API to convert from natural language to SQL string.

npm version

Installation

Drag a Custom Component into your canvas in a Retool app.

Put this code into the IFrame Code area of the Custom Component:

<script src="https://unpkg.com/@eloquentops/retool-plugin-ask-your-data"></script>

Configuration

You can add options in the Model such this example (values are the default).

{
  dataset: {{ query1.data }},
  debug: false, // enable log and console.log for debugging purpose
  openai_token: '<YOUR-OPENAI-API-KEY>',
  groq_token: '<YOUR-GROQ-API-KEY>', // alternative to OpenAI
  question: 'Your question',
  config: [ // optional config for specific columns for manual summarization, they can have specific values or just a generic data type
    {key: 'mycol', value:'only string values'}
  ],
  skip:['name'], // optional, properties you don't want to summarize and send to the llm
  llm: 'gpt-4-turbo-preview' // optional, default is gpt-4-turbo-preview, you can change it. if you use Groq, the llm is llama3-70b-8192
  onError: 'onErrorQuery', // query to trigger on API error, useful to show notifications,
  debugConfig: false // set to true to expose "metaConfig" in model, the summarized dataset for the contextualized prompt. If true, no network request are dispatched
}

How to get the filtered results

Fair question. The component exposes some additional properties in its model:

{
  result: [], // Filtered Array of Object
  isFetching: false, // true durin the OpenAI request
  metaConfig: '' // only with debugConfig:true, a part of the prompt related to dataset summary
}

Licence

This plugin is released under the 3-Clause BSD license.

Copyright © 2024 EloquentOps, https://eloquentops.com

0.0.84

10 months ago

0.0.85

10 months ago

0.0.86

10 months ago

0.0.83

10 months ago

0.0.82

1 year ago

0.0.81

1 year ago

0.0.80

1 year ago

0.0.79

1 year ago

0.0.78

1 year ago

0.0.77

1 year ago

0.0.76

1 year ago

0.0.75

1 year ago

0.0.74

1 year ago

0.0.73

1 year ago

0.0.72

1 year ago

0.0.71

1 year ago

0.0.70

1 year ago

0.0.69

1 year ago

0.0.68

1 year ago

0.0.67

1 year ago

0.0.66

1 year ago

0.0.65

1 year ago

0.0.64

1 year ago

0.0.63

1 year ago

0.0.62

1 year ago

0.0.61

1 year ago

0.0.60

1 year ago

0.0.59

1 year ago

0.0.58

1 year ago

0.0.57

1 year ago

0.0.56

1 year ago

0.0.55

1 year ago

0.0.54

1 year ago

0.0.53

1 year ago

0.0.52

1 year ago

0.0.51

1 year ago

0.0.50

1 year ago

0.0.49

1 year ago

0.0.48

1 year ago

0.0.47

1 year ago

0.0.46

1 year ago

0.0.45

1 year ago

0.0.44

1 year ago

0.0.43

1 year ago

0.0.42

1 year ago

0.0.41

1 year ago

0.0.40

1 year ago

0.0.39

1 year ago

0.0.38

1 year ago

0.0.37

1 year ago

0.0.36

1 year ago

0.0.35

1 year ago

0.0.34

1 year ago

0.0.33

1 year ago

0.0.32

1 year ago

0.0.31

1 year ago

0.0.30

1 year ago

0.0.29

1 year ago

0.0.28

1 year ago

0.0.27

1 year ago

0.0.26

1 year ago

0.0.25

1 year ago

0.0.24

1 year ago

0.0.23

1 year ago

0.0.22

1 year ago

0.0.21

1 year ago

0.0.20

1 year ago

0.0.18

1 year ago

0.0.17

1 year ago

0.0.16

1 year ago

0.0.15

1 year ago