API Reference Overview
API reference for the DataAnalyzr class in the lyzr library
The DataAnalyzr
class provides a high-level interface for performing data analysis using the Large Language Models (LLM) for generating insights, recommendations, and tasks based on user input.
It supports SQL and machine learning (ML) analysis types. Please refer to the full user guide for details on usage.
In addition to the methods described below, the DataAnalyzr
class includes several internal flows for handling data, analysis, and response generation.
In this reference guide, we will cover the public methods of the DataAnalyzr
class, including their parameters and return values.
You will find detailed explanations of each method, its purpose, and how to use it in your data analysis workflow.
You will also find examples of the parameters of each method and how to use them in practice.
Constructor
- DataAnalyzr - class object for performing conversational data analysis.
Primary Methods
- DataAnalyzr.get_data - Connect your DataAnalyzr instance to a database and vector store.
- DataAnalyzr.ask - Get responses to queries in the form of plots, insights, recommendations, and tasks.
Attributes
- Basic Attributes
- Instance configuration attributes
analysis_type
,params
,generator_llm
,analysis_llm
,context
,logger
.
- Data Related Attributes
- Input dataset and vector store connections
df_dict
,database_connector
,vector_store
.
- Analysis Related Attributes
- Values generated during analysis
analysis_code
,analysis_guide
,analysis_output
,plot_code
.
- Output Attributes
- Output values of various steps in query response generation
plot_output
,insights_output
,recommendations_output
,tasks_output
,ai_queries_output
.
Additional Methods
- analysis - Perform data analysis using the LLM.
- visualisation - Generate visualizations based on the analysis output.
- insights - Generate insights based on the analysis output.
- recommendations - Generate recommendations based on the analysis output.
- tasks - Generate tasks based on the analysis output.