SYMBOL INDEX (1496 symbols across 157 files) FILE: extensions/connectors/sql/pandasai_sql/__init__.py function load_from_mysql (line 9) | def load_from_mysql( function load_from_postgres (line 28) | def load_from_postgres( function load_from_cockroachdb (line 47) | def load_from_cockroachdb( function load_from_sqlserver (line 66) | def load_from_sqlserver( FILE: extensions/connectors/sql/tests/test_sql.py class TestDatabaseLoader (line 17) | class TestDatabaseLoader(unittest.TestCase): method test_load_from_mysql (line 20) | def test_load_from_mysql(self, mock_read_sql, mock_pymysql_connect): method test_load_from_postgres (line 59) | def test_load_from_postgres(self, mock_read_sql, mock_psycopg2_connect): method test_load_from_cockroachdb (line 97) | def test_load_from_cockroachdb(self, mock_read_sql, mock_postgresql_co... method test_load_from_mysql_with_params (line 135) | def test_load_from_mysql_with_params(self, mock_read_sql, mock_pymysql... method test_load_from_postgres_with_params (line 170) | def test_load_from_postgres_with_params(self, mock_read_sql, mock_psyc... method test_load_from_cockroachdb_with_params (line 205) | def test_load_from_cockroachdb_with_params( method test_load_from_sqlserver (line 242) | def test_load_from_sqlserver(self, mock_read_sql, mock_pymssql_connect): method test_load_from_sqlserver_with_params (line 280) | def test_load_from_sqlserver_with_params(self, mock_read_sql, mock_pym... FILE: extensions/connectors/yfinance/pandasai_yfinance/__init__.py function load_from_yahoo_finance (line 1) | def load_from_yahoo_finance(connection_info, query): FILE: extensions/connectors/yfinance/tests/test_yahoo_finance.py class TestYahooFinanceLoader (line 10) | class TestYahooFinanceLoader(unittest.TestCase): method test_load_from_yahoo_finance (line 12) | def test_load_from_yahoo_finance(self, MockTicker): FILE: extensions/ee/connectors/bigquery/pandasai_bigquery/__init__.py function load_from_bigquery (line 5) | def load_from_bigquery(connection_info, query): FILE: extensions/ee/connectors/bigquery/tests/test_bigquery.py function mock_connection_info (line 9) | def mock_connection_info(): function mock_query_result (line 17) | def mock_query_result(): function test_load_from_bigquery_success (line 25) | def test_load_from_bigquery_success(mock_connection_info, mock_query_res... function test_load_from_bigquery_failure (line 51) | def test_load_from_bigquery_failure(mock_connection_info): FILE: extensions/ee/connectors/databricks/pandasai_databricks/__init__.py function load_from_databricks (line 5) | def load_from_databricks(config): FILE: extensions/ee/connectors/databricks/tests/test_databricks.py class TestDatabricksLoader (line 9) | class TestDatabricksLoader(unittest.TestCase): method test_load_from_databricks_with_query (line 11) | def test_load_from_databricks_with_query(self, MockConnect): method test_load_from_databricks_with_table (line 50) | def test_load_from_databricks_with_table(self, MockConnect): method test_load_from_databricks_no_query_or_table (line 86) | def test_load_from_databricks_no_query_or_table(self, MockConnect): method test_load_from_databricks_empty_result (line 105) | def test_load_from_databricks_empty_result(self, MockConnect): FILE: extensions/ee/connectors/oracle/pandasai_oracle/__init__.py function load_from_oracle (line 5) | def load_from_oracle(connection_info, query): FILE: extensions/ee/connectors/oracle/tests/test_oracle.py class TestOracleLoader (line 8) | class TestOracleLoader(unittest.TestCase): method test_load_from_oracle_success (line 12) | def test_load_from_oracle_success(self, mock_makedsn, mock_read_sql, m... method test_load_from_oracle_with_sid (line 53) | def test_load_from_oracle_with_sid(self, mock_makedsn, mock_read_sql, ... method test_load_from_oracle_empty_result (line 93) | def test_load_from_oracle_empty_result(self, mock_read_sql, mock_conne... method test_load_from_oracle_missing_params (line 118) | def test_load_from_oracle_missing_params(self, mock_connect): method test_load_from_oracle_invalid_query (line 133) | def test_load_from_oracle_invalid_query(self, mock_read_sql, mock_conn... FILE: extensions/ee/connectors/snowflake/pandasai_snowflake/__init__.py function load_from_snowflake (line 5) | def load_from_snowflake(connection_info, query): FILE: extensions/ee/connectors/snowflake/tests/test_snowflake.py class TestSnowflakeLoader (line 8) | class TestSnowflakeLoader(unittest.TestCase): method test_load_from_snowflake_success (line 11) | def test_load_from_snowflake_success(self, mock_read_sql, mock_connect): method test_load_from_snowflake_with_optional_role (line 55) | def test_load_from_snowflake_with_optional_role(self, mock_read_sql, m... method test_load_from_snowflake_empty_result (line 100) | def test_load_from_snowflake_empty_result(self, mock_read_sql, mock_co... method test_load_from_snowflake_missing_params (line 126) | def test_load_from_snowflake_missing_params(self, mock_connect): method test_load_from_snowflake_invalid_query (line 141) | def test_load_from_snowflake_invalid_query(self, mock_read_sql, mock_c... FILE: extensions/ee/vectorstores/chromadb/pandasai_chromadb/chroma.py class ChromaDB (line 16) | class ChromaDB(VectorStore): method __init__ (line 19) | def __init__( method add_question_answer (line 69) | def add_question_answer( method add_docs (line 91) | def add_docs( method update_question_answer (line 105) | def update_question_answer( method update_docs (line 124) | def update_docs( method delete_question_and_answers (line 136) | def delete_question_and_answers( method delete_docs (line 142) | def delete_docs(self, ids: Optional[List[str]] = None) -> Optional[bool]: method get_relevant_question_answers (line 146) | def get_relevant_question_answers( method get_relevant_docs (line 161) | def get_relevant_docs(self, question: str, k: int = None) -> List[dict]: method get_relevant_question_answers_by_id (line 174) | def get_relevant_question_answers_by_id(self, ids: Iterable[str]) -> L... method get_relevant_docs_by_id (line 182) | def get_relevant_docs_by_id(self, ids: Iterable[str]) -> List[dict]: method get_relevant_qa_documents (line 190) | def get_relevant_qa_documents(self, question: str, k: int = None) -> L... method get_relevant_docs_documents (line 193) | def get_relevant_docs_documents(self, question: str, k: int = None) ->... method _filter_docs_based_on_distance (line 196) | def _filter_docs_based_on_distance( FILE: extensions/ee/vectorstores/chromadb/tests/test_chromadb.py class TestChromaDB (line 7) | class TestChromaDB(unittest.TestCase): method test_add_question_answer (line 9) | def test_add_question_answer(self, mock_client): method test_add_question_answer_with_ids (line 21) | def test_add_question_answer_with_ids(self, mock_client): method test_add_question_answer_different_dimensions (line 41) | def test_add_question_answer_different_dimensions(self, mock_client): method test_update_question_answer (line 53) | def test_update_question_answer(self, mock_client): method test_update_question_answer_different_dimensions (line 66) | def test_update_question_answer_different_dimensions(self, mock_client): method test_add_docs (line 79) | def test_add_docs(self, mock_client): method test_add_docs_with_ids (line 87) | def test_add_docs_with_ids(self, mock_client): method test_delete_question_and_answers (line 99) | def test_delete_question_and_answers(self, mock_client): method test_delete_docs (line 108) | def test_delete_docs(self, mock_client): method test_get_relevant_question_answers (line 117) | def test_get_relevant_question_answers(self, mock_client): method test_get_relevant_question_answers_by_ids (line 140) | def test_get_relevant_question_answers_by_ids(self, mock_client): method test_get_relevant_docs (line 163) | def test_get_relevant_docs(self, mock_client): method test_get_relevant_docs_by_id (line 186) | def test_get_relevant_docs_by_id(self, mock_client): method test_get_relevant_question_answers_documents (line 207) | def test_get_relevant_question_answers_documents(self, mock_client): method test_get_relevant_docs_documents (line 222) | def test_get_relevant_docs_documents(self, mock_client): FILE: extensions/ee/vectorstores/lancedb/pandasai_lancedb/lancedb.py class EmbeddingFunction (line 17) | class EmbeddingFunction(TextEmbeddingFunction): method __init__ (line 18) | def __init__(self, model, **kwargs): method generate_embeddings (line 23) | def generate_embeddings(self, texts): method ndims (line 26) | def ndims(self): class Schema (line 32) | class Schema: method __init__ (line 33) | def __init__(self, custom_embedding_function, model=None): method _create_schema (line 47) | def _create_schema(self): class LanceDB (line 63) | class LanceDB(VectorStore): method __init__ (line 66) | def __init__( method add_question_answer (line 104) | def add_question_answer( method add_docs (line 141) | def add_docs( method get_embeddings (line 171) | def get_embeddings(self, text): method update_question_answer (line 179) | def update_question_answer( method update_docs (line 206) | def update_docs( method delete_question_and_answers (line 225) | def delete_question_and_answers( method delete_docs (line 232) | def delete_docs(self, ids: Optional[List[str]] = None) -> Optional[bool]: method get_relevant_question_answers (line 237) | def get_relevant_question_answers( method get_relevant_docs (line 254) | def get_relevant_docs(self, question: str, k: int = None) -> List[dict]: method get_relevant_question_answers_by_id (line 269) | def get_relevant_question_answers_by_id(self, ids: Iterable[str]) -> L... method get_relevant_docs_by_id (line 282) | def get_relevant_docs_by_id(self, ids: Iterable[str]) -> List[dict]: method get_relevant_qa_documents (line 295) | def get_relevant_qa_documents(self, question: str, k: int = None) -> L... method get_relevant_docs_documents (line 298) | def get_relevant_docs_documents(self, question: str, k: int = None) ->... method _filter_docs_based_on_distance (line 301) | def _filter_docs_based_on_distance( FILE: extensions/ee/vectorstores/lancedb/tests/test_lancedb.py class TestLanceDB (line 10) | class TestLanceDB(unittest.TestCase): method setUp (line 11) | def setUp(self): method tearDown (line 18) | def tearDown(self) -> None: method test_constructor_default_parameters (line 23) | def test_constructor_default_parameters(self): method test_constructor_with_custom_logger (line 30) | def test_constructor_with_custom_logger(self): method test_constructor_creates_table_if_not_exists (line 35) | def test_constructor_creates_table_if_not_exists(self): method test_add_question_answer (line 40) | def test_add_question_answer(self): method test_add_question_answer_with_ids (line 47) | def test_add_question_answer_with_ids(self): method test_add_question_answer_different_dimensions (line 55) | def test_add_question_answer_different_dimensions(self): method test_update_question_answer (line 62) | def test_update_question_answer(self): method test_update_question_answer_different_dimensions (line 70) | def test_update_question_answer_different_dimensions(self): method test_add_docs (line 78) | def test_add_docs(self): method test_add_docs_with_ids (line 82) | def test_add_docs_with_ids(self): method test_delete_question_and_answers (line 88) | def test_delete_question_and_answers(self): method test_delete_docs (line 92) | def test_delete_docs(self): method test_get_relevant_question_answers (line 96) | def test_get_relevant_question_answers(self): method test_get_relevant_question_answers_by_ids (line 119) | def test_get_relevant_question_answers_by_ids(self): method test_get_relevant_docs (line 139) | def test_get_relevant_docs(self): method test_get_relevant_docs_by_ids (line 153) | def test_get_relevant_docs_by_ids(self): FILE: extensions/ee/vectorstores/milvus/pandasai_milvus/milvus.py class Milvus (line 19) | class Milvus(VectorStore): method __init__ (line 30) | def __init__( method add_question_answer (line 49) | def add_question_answer( method add_docs (line 93) | def add_docs( method get_relevant_question_answers (line 129) | def get_relevant_question_answers(self, question: str, k: int = 1) -> ... method get_relevant_docs (line 150) | def get_relevant_docs(self, question: str, k: int = 1) -> List[Dict]: method _convert_search_response (line 169) | def _convert_search_response(self, response): method _initiate_qa_collection (line 191) | def _initiate_qa_collection(self): method _initiate_docs_collection (line 222) | def _initiate_docs_collection(self): method get_relevant_docs_documents (line 253) | def get_relevant_docs_documents(self, question: str, k: int = 1) -> Li... method get_relevant_qa_documents (line 258) | def get_relevant_qa_documents(self, question: str, k: int = 1) -> List... method get_relevant_question_answers_by_id (line 262) | def get_relevant_question_answers_by_id(self, ids: Iterable[str]) -> L... method delete_docs (line 272) | def delete_docs(self, ids: List[str] = None) -> bool: method delete_question_and_answers (line 282) | def delete_question_and_answers(self, ids: List[str] = None) -> bool: method update_question_answer (line 293) | def update_question_answer( method update_docs (line 326) | def update_docs( method _validate_update_ids (line 349) | def _validate_update_ids(self, collection_name: str, ids: List[str]) -... method delete_collection (line 361) | def delete_collection(self, collection_name: str) -> Optional[bool]: method _convert_ids (line 367) | def _convert_ids(self, ids: Iterable[str]) -> List[str]: method _is_valid_uuid (line 376) | def _is_valid_uuid(self, id: str): method generate_random_uuids (line 384) | def generate_random_uuids(self, n): FILE: extensions/ee/vectorstores/milvus/tests/test_milvus.py class TestMilvus (line 7) | class TestMilvus(unittest.TestCase): method test_add_question_answer (line 12) | def test_add_question_answer(self, mock_client): method test_add_question_answer_with_ids (line 24) | def test_add_question_answer_with_ids(self, mock_client): method test_add_question_answer_different_dimensions (line 57) | def test_add_question_answer_different_dimensions(self, mock_client): method test_update_question_answer (line 69) | def test_update_question_answer(self, mock_client): method test_update_question_answer_different_dimensions (line 82) | def test_update_question_answer_different_dimensions(self, mock_client): method test_add_docs (line 95) | def test_add_docs(self, mock_client): method test_add_docs_with_ids (line 104) | def test_add_docs_with_ids(self, mock_client): method test_delete_question_and_answers (line 119) | def test_delete_question_and_answers(self, mock_client): method test_delete_docs (line 133) | def test_delete_docs(self, mock_client): method test_get_relevant_question_answers (line 147) | def test_get_relevant_question_answers(self, mock_client): method test_get_relevant_docs (line 166) | def test_get_relevant_docs(self, mock_client): FILE: extensions/ee/vectorstores/pinecone/pandasai_pinecone/pinecone.py class Pinecone (line 10) | class Pinecone(VectorStore): method __init__ (line 17) | def __init__( method cleanup (line 68) | def cleanup(self): method __del__ (line 75) | def __del__(self): method add_question_answer (line 79) | def add_question_answer( method add_docs (line 110) | def add_docs( method update_question_answer (line 138) | def update_question_answer( method update_docs (line 162) | def update_docs( method delete_question_and_answers (line 183) | def delete_question_and_answers( method delete_docs (line 189) | def delete_docs(self, ids: Optional[List[str]] = None) -> Optional[bool]: method get_relevant_question_answers (line 193) | def get_relevant_question_answers( method get_relevant_docs (line 210) | def get_relevant_docs(self, question: str, k: int = None) -> List[dict]: method get_relevant_question_answers_by_id (line 225) | def get_relevant_question_answers_by_id(self, ids: Iterable[str]) -> L... method get_relevant_docs_by_id (line 228) | def get_relevant_docs_by_id(self, ids: Iterable[str]) -> List[dict]: method get_relevant_qa_documents (line 231) | def get_relevant_qa_documents(self, question: str, k: int = None) -> L... method get_relevant_docs_documents (line 234) | def get_relevant_docs_documents(self, question: str, k: int = None) ->... method _filter_docs_based_on_distance (line 237) | def _filter_docs_based_on_distance(self, documents, threshold: int) ->... method _format_qa (line 254) | def _format_qa(self, query: str, code: str) -> str: FILE: extensions/ee/vectorstores/pinecone/tests/test_pinecone.py class TestPinecone (line 7) | class TestPinecone(unittest.TestCase): method setUp (line 8) | def setUp(self): method tearDown (line 14) | def tearDown(self): method test_constructor_with_custom_logger (line 21) | def test_constructor_with_custom_logger(self, mock_pinecone): method test_constructor_creates_index_if_not_exists (line 34) | def test_constructor_creates_index_if_not_exists(self, mock_pinecone): method test_constructor_with_optional_parameters (line 50) | def test_constructor_with_optional_parameters(self, mock_pinecone): method test_add_question_answer (line 62) | def test_add_question_answer(self, mock_pinecone): method test_add_question_answer_with_ids (line 77) | def test_add_question_answer_with_ids(self, mock_pinecone): method test_add_question_answer_different_dimensions (line 109) | def test_add_question_answer_different_dimensions(self, mock_pinecone): method test_update_question_answer (line 123) | def test_update_question_answer(self, mock_pinecone): method test_update_question_answer_different_dimensions (line 139) | def test_update_question_answer_different_dimensions(self, mock_pineco... method test_add_docs (line 154) | def test_add_docs(self, mock_pinecone): method test_add_docs_with_ids (line 165) | def test_add_docs_with_ids(self, mock_pinecone): method test_delete_question_and_answers (line 192) | def test_delete_question_and_answers(self, mock_pinecone): method test_delete_docs (line 206) | def test_delete_docs(self, mock_pinecone): method test_get_relevant_question_answers (line 220) | def test_get_relevant_question_answers(self, mock_pinecone): method test_get_relevant_question_answers_by_ids (line 255) | def test_get_relevant_question_answers_by_ids(self, mock_pinecone): method test_get_relevant_docs (line 280) | def test_get_relevant_docs(self, mock_pinecone): method test_get_relevant_docs_by_id (line 315) | def test_get_relevant_docs_by_id(self, mock_pinecone): FILE: extensions/ee/vectorstores/qdrant/pandasai_qdrant/qdrant.py class Qdrant (line 17) | class Qdrant(VectorStore): method __init__ (line 18) | def __init__( method add_question_answer (line 58) | def add_question_answer( method add_docs (line 91) | def add_docs( method update_question_answer (line 120) | def update_question_answer( method update_docs (line 152) | def update_docs( method delete_question_and_answers (line 180) | def delete_question_and_answers(self, ids: Optional[List[str]] = None): method delete_docs (line 191) | def delete_docs(self, ids: Optional[List[str]] = None): method delete_collection (line 202) | def delete_collection(self, collection_name: str): method get_relevant_question_answers (line 208) | def get_relevant_question_answers(self, question: str, k: int = 1): method get_relevant_docs (line 217) | def get_relevant_docs(self, question: str, k: int = 1): method get_relevant_question_answers_by_id (line 226) | def get_relevant_question_answers_by_id(self, ids: Iterable[str]): method get_relevant_docs_by_id (line 233) | def get_relevant_docs_by_id(self, ids: List[str]) -> Dict[str, List[An... method get_relevant_qa_documents (line 264) | def get_relevant_qa_documents(self, question: str, k: int = 1): method get_relevant_docs_documents (line 273) | def get_relevant_docs_documents(self, question: str, k: int = 1): method _validate_update_ids (line 282) | def _validate_update_ids(self, collection_name: str, ids: List[str]) -... method _convert_ids (line 311) | def _convert_ids(self, ids: Iterable[str]): method _convert_query_response (line 321) | def _convert_query_response(self, results: List[models.ScoredPoint]) -... method _convert_retrieve_response (line 337) | def _convert_retrieve_response(self, response: List[models.Record]) ->... method _is_valid_uuid (line 351) | def _is_valid_uuid(self, id: str): FILE: extensions/ee/vectorstores/qdrant/tests/test_qdrant.py class TestQdrant (line 13) | class TestQdrant(unittest.TestCase): method setUp (line 14) | def setUp(self): method test_add_question_answer (line 22) | def test_add_question_answer(self, mock_client): method test_add_question_answer_with_ids (line 35) | def test_add_question_answer_with_ids(self, mock_client): method test_update_question_answer (line 50) | def test_update_question_answer(self, mock_client): method test_add_docs (line 68) | def test_add_docs(self, mock_client): method test_add_docs_with_ids (line 78) | def test_add_docs_with_ids(self, mock_client): method test_delete_question_and_answers (line 89) | def test_delete_question_and_answers(self, mock_client): method test_delete_docs (line 100) | def test_delete_docs(self, mock_client): method test_get_relevant_question_answers (line 111) | def test_get_relevant_question_answers(self, mock_client): method test_get_relevant_question_answers_by_ids (line 131) | def test_get_relevant_question_answers_by_ids(self, mock_client): method test_get_relevant_docs (line 148) | def test_get_relevant_docs(self, mock_client): method test_get_relevant_docs_by_id (line 168) | def test_get_relevant_docs_by_id(self, mock_client): FILE: extensions/llms/litellm/pandasai_litellm/litellm.py class LiteLLM (line 9) | class LiteLLM(LLM): method __init__ (line 27) | def __init__(self, model: str, **kwargs): method type (line 41) | def type(self) -> str: method call (line 51) | def call(self, instruction: BasePrompt, context: AgentState = None) ->... FILE: extensions/llms/litellm/tests/test_litellm.py class TestPrompt (line 12) | class TestPrompt(BasePrompt): function prompt (line 33) | def prompt(): function llm (line 47) | def llm(): function test_missing_api_key (line 60) | def test_missing_api_key(llm, prompt): function test_invalid_api_key (line 80) | def test_invalid_api_key(llm, prompt): function test_successful_completion (line 97) | def test_successful_completion(llm, prompt): function test_completion_with_extra_params (line 149) | def test_completion_with_extra_params(prompt): FILE: extensions/llms/openai/pandasai_openai/azure_openai.py class AzureOpenAI (line 14) | class AzureOpenAI(BaseOpenAI): method __init__ (line 37) | def __init__( method _default_params (line 121) | def _default_params(self) -> Dict[str, Any]: method _client_params (line 135) | def _client_params(self) -> Dict[str, any]: method type (line 148) | def type(self) -> str: FILE: extensions/llms/openai/pandasai_openai/base.py class BaseOpenAI (line 13) | class BaseOpenAI(LLM): method _set_params (line 43) | def _set_params(self, **kwargs): method _default_params (line 71) | def _default_params(self) -> Dict[str, Any]: method _invocation_params (line 94) | def _invocation_params(self) -> Dict[str, Any]: method _client_params (line 101) | def _client_params(self) -> Dict[str, any]: method completion (line 112) | def completion(self, prompt: str, memory: Memory) -> str: method chat_completion (line 137) | def chat_completion(self, value: str, memory: Memory) -> str: method call (line 171) | def call(self, instruction: BasePrompt, context: AgentState = None): FILE: extensions/llms/openai/pandasai_openai/openai.py class OpenAI (line 14) | class OpenAI(BaseOpenAI): method __init__ (line 55) | def __init__( method _default_params (line 93) | def _default_params(self) -> Dict[str, Any]: method type (line 101) | def type(self) -> str: FILE: extensions/llms/openai/tests/test_azure_openai.py class OpenAIObject (line 10) | class OpenAIObject: method __init__ (line 11) | def __init__(self, dictionary): class TestAzureOpenAILLM (line 15) | class TestAzureOpenAILLM: method test_type_without_token (line 18) | def test_type_without_token(self): method test_type_without_endpoint (line 22) | def test_type_without_endpoint(self): method test_type_without_api_version (line 26) | def test_type_without_api_version(self): method test_type_without_deployment (line 30) | def test_type_without_deployment(self): method test_type_with_token (line 34) | def test_type_with_token(self): method test_type_with_http_client (line 45) | def test_type_with_http_client(self): method test_proxy (line 57) | def test_proxy(self): method test_params_setting (line 70) | def test_params_setting(self): method test_completion (line 94) | def test_completion(self, mocker): method test_chat_completion (line 120) | def test_chat_completion(self, mocker): FILE: extensions/llms/openai/tests/test_openai.py class OpenAIObject (line 14) | class OpenAIObject: method __init__ (line 15) | def __init__(self, dictionary): class TestOpenAILLM (line 19) | class TestOpenAILLM: method prompt (line 23) | def prompt(self): method test_type_without_token (line 29) | def test_type_without_token(self): method test_type_with_token (line 34) | def test_type_with_token(self): method test_proxy (line 37) | def test_proxy(self): method test_params_setting (line 44) | def test_params_setting(self): method test_completion (line 64) | def test_completion(self, mocker): method test_chat_completion (line 85) | def test_chat_completion(self, mocker): method test_call_with_unsupported_model (line 108) | def test_call_with_unsupported_model(self, prompt): method test_call_supported_completion_model (line 119) | def test_call_supported_completion_model(self, mocker, prompt): method test_call_supported_chat_model (line 126) | def test_call_supported_chat_model(self, mocker, prompt): method test_call_with_system_prompt (line 133) | def test_call_with_system_prompt(self, mocker, prompt): FILE: extensions/sandbox/docker/pandasai_docker/docker_sandbox.py class DockerSandbox (line 19) | class DockerSandbox(Sandbox): method __init__ (line 20) | def __init__(self, image_name="pandasai-sandbox", dockerfile_path=None): method _image_exists (line 37) | def _image_exists(self) -> bool: method _build_image (line 44) | def _build_image(self) -> None: method start (line 69) | def start(self): method stop (line 86) | def stop(self) -> None: method _read_start_code (line 94) | def _read_start_code(self, file_path: str) -> str: method _exec_code (line 106) | def _exec_code(self, code: str, environment: dict) -> dict: method transfer_file (line 186) | def transfer_file(self, csv_data, filename="file.csv") -> None: method __del__ (line 208) | def __del__(self) -> None: FILE: extensions/sandbox/docker/pandasai_docker/serializer.py class ResponseSerializer (line 12) | class ResponseSerializer: method serialize_dataframe (line 14) | def serialize_dataframe(df: pd.DataFrame) -> dict: method serialize (line 20) | def serialize(result: dict) -> str: method deserialize (line 34) | def deserialize(response: str, chart_path: str = None) -> dict: class CustomEncoder (line 56) | class CustomEncoder(JSONEncoder): method default (line 57) | def default(self, obj): FILE: extensions/sandbox/docker/tests/test_sandbox.py class TestDockerSandbox (line 10) | class TestDockerSandbox(unittest.TestCase): method setUp (line 11) | def setUp(self): method test_destructor (line 16) | def test_destructor(self, mock_docker): method test_image_exists (line 27) | def test_image_exists(self, mock_docker): method test_build_image (line 39) | def test_build_image(self, mock_subprocess, mock_docker, mock_open): method test_start_and_stop_container (line 62) | def test_start_and_stop_container(self, mock_docker): method test_extract_sql_queries_from_code (line 80) | def test_extract_sql_queries_from_code(self): method test_transfer_file (line 90) | def test_transfer_file(self, mock_docker): method test_exec_code (line 102) | def test_exec_code(self, mock_docker): method test_exec_code_with_sql_queries (line 121) | def test_exec_code_with_sql_queries(self, mock_transfer_file, mock_doc... method test_exec_code_with_sql_queries_raise_no_env (line 149) | def test_exec_code_with_sql_queries_raise_no_env( method test_exec_code_with_sql_queries_with_plot (line 176) | def test_exec_code_with_sql_queries_with_plot( method test_exec_code_with_sql_queries_with_dataframe (line 222) | def test_exec_code_with_sql_queries_with_dataframe( method test_extract_sql_queries_from_code_with_bool_constant (line 261) | def test_extract_sql_queries_from_code_with_bool_constant(self): method test_extract_sql_queries_from_code_with_cte (line 271) | def test_extract_sql_queries_from_code_with_cte(self): method test_extract_sql_queries_from_code_with_malicious_query (line 283) | def test_extract_sql_queries_from_code_with_malicious_query(self): FILE: extensions/sandbox/docker/tests/test_serializer.py class TestResponseSerializer (line 13) | class TestResponseSerializer(unittest.TestCase): method test_serialize_dataframe_empty (line 14) | def test_serialize_dataframe_empty(self): method test_serialize_dataframe_non_empty (line 19) | def test_serialize_dataframe_non_empty(self): method test_serialize_plot (line 27) | def test_serialize_plot(self, mock_b64encode, mock_open_file): method test_serialize_dataframe_type (line 35) | def test_serialize_dataframe_type(self): method test_deserialize_dataframe (line 45) | def test_deserialize_dataframe(self): method test_deserialize_plot (line 57) | def test_deserialize_plot(self, mock_b64decode, mock_open_file): class TestCustomEncoder (line 68) | class TestCustomEncoder(unittest.TestCase): method test_encode_numpy (line 69) | def test_encode_numpy(self): method test_encode_datetime (line 74) | def test_encode_datetime(self): method test_encode_dataframe (line 80) | def test_encode_dataframe(self): FILE: pandasai/__init__.py function create (line 46) | def create( function chat (line 219) | def chat(query: str, *dataframes: DataFrame, sandbox: Optional[Sandbox] ... function follow_up (line 239) | def follow_up(query: str): function load (line 259) | def load(dataset_path: str) -> DataFrame: function read_csv (line 294) | def read_csv(filepath: Union[str, BytesIO]) -> DataFrame: function read_excel (line 300) | def read_excel( FILE: pandasai/agent/base.py class Agent (line 34) | class Agent: method __init__ (line 39) | def __init__( method is_pd_dataframe (line 89) | def is_pd_dataframe(self, df: Union[DataFrame, VirtualDataFrame]) -> b... method chat (line 92) | def chat(self, query: str, output_type: Optional[str] = None): method follow_up (line 105) | def follow_up(self, query: str, output_type: Optional[str] = None): method generate_code (line 111) | def generate_code(self, query: Union[UserQuery, str]) -> str: method execute_code (line 123) | def execute_code(self, code: str) -> dict: method _execute_sql_query (line 137) | def _execute_sql_query(self, query: str) -> pd.DataFrame: method generate_code_with_retries (line 171) | def generate_code_with_retries(self, query: str) -> Any: method execute_with_retries (line 197) | def execute_with_retries(self, code: str) -> Any: method train (line 218) | def train( method clear_memory (line 251) | def clear_memory(self): method add_message (line 257) | def add_message(self, message, is_user=False): method start_new_conversation (line 265) | def start_new_conversation(self): method _process_query (line 271) | def _process_query(self, query: str, output_type: Optional[str] = None): method _regenerate_code_after_error (line 296) | def _regenerate_code_after_error(self, code: str, error: Exception) ->... method _handle_exception (line 310) | def _handle_exception(self, code: str) -> ErrorResponse: method last_generated_code (line 318) | def last_generated_code(self): method last_code_executed (line 322) | def last_code_executed(self): method last_prompt_used (line 326) | def last_prompt_used(self): FILE: pandasai/agent/state.py class AgentState (line 24) | class AgentState: method __post_init__ (line 41) | def __post_init__(self): method initialize (line 45) | def initialize( method _configure (line 68) | def _configure(self): method _get_config (line 73) | def _get_config(self, config: Union[Config, dict, None]) -> Config: method _get_llm (line 83) | def _get_llm(self, llm: Optional[LLM] = None) -> LLM: method assign_prompt_id (line 87) | def assign_prompt_id(self): method reset_intermediate_values (line 94) | def reset_intermediate_values(self): method add (line 98) | def add(self, key: str, value: Any): method add_many (line 102) | def add_many(self, values: Dict[str, Any]): method get (line 106) | def get(self, key: str, default: Any = "") -> Any: method config (line 111) | def config(self): method config (line 123) | def config(self, value: Union[Config, dict, None]): FILE: pandasai/cli/main.py function validate_api_key (line 15) | def validate_api_key(api_key: str) -> bool: function cli (line 22) | def cli(): function dataset (line 28) | def dataset(): function create (line 34) | def create(): function login (line 104) | def login(api_key: str): FILE: pandasai/config.py class Config (line 10) | class Config(BaseModel): method from_dict (line 19) | def from_dict(cls, config: Dict[str, Any]) -> "Config": class ConfigManager (line 23) | class ConfigManager: method set (line 29) | def set(cls, config_dict: Dict[str, Any]) -> None: method get (line 34) | def get(cls) -> Config: method update (line 42) | def update(cls, config_dict: Dict[str, Any]) -> None: class APIKeyManager (line 49) | class APIKeyManager: method set (line 53) | def set(cls, api_key: str): method get (line 58) | def get(cls) -> Optional[str]: FILE: pandasai/core/code_execution/code_executor.py class CodeExecutor (line 8) | class CodeExecutor: method __init__ (line 15) | def __init__(self, config: Config) -> None: method add_to_env (line 18) | def add_to_env(self, key: str, value: Any) -> None: method execute (line 27) | def execute(self, code: str) -> dict: method execute_and_return_result (line 34) | def execute_and_return_result(self, code: str) -> Any: method environment (line 49) | def environment(self) -> dict: FILE: pandasai/core/code_execution/environment.py function get_version (line 12) | def get_version(module: types.ModuleType) -> str: function get_environment (line 22) | def get_environment() -> dict: function import_dependency (line 37) | def import_dependency( FILE: pandasai/core/code_generation/base.py class CodeGenerator (line 10) | class CodeGenerator: method __init__ (line 11) | def __init__(self, context: AgentState): method generate_code (line 16) | def generate_code(self, prompt: BasePrompt) -> str: method validate_and_clean_code (line 54) | def validate_and_clean_code(self, code: str) -> str: FILE: pandasai/core/code_generation/code_cleaning.py class CodeCleaner (line 17) | class CodeCleaner: method __init__ (line 18) | def __init__(self, context: AgentState): method _check_direct_sql_func_def_exists (line 27) | def _check_direct_sql_func_def_exists(self, node: ast.AST) -> bool: method _check_if_skill_func_def_exists (line 33) | def _check_if_skill_func_def_exists(self, node: ast.AST) -> bool: method _replace_table_names (line 42) | def _replace_table_names( method _clean_sql_query (line 62) | def _clean_sql_query(self, sql_query: str) -> str: method _validate_and_make_table_name_case_sensitive (line 75) | def _validate_and_make_table_name_case_sensitive(self, node: ast.AST) ... method get_target_names (line 112) | def get_target_names(self, targets): method check_is_df_declaration (line 127) | def check_is_df_declaration(self, node: ast.AST): method clean_code (line 138) | def clean_code(self, code: str) -> str: method _replace_output_filenames_with_temp_chart (line 171) | def _replace_output_filenames_with_temp_chart(self, code: str) -> str: FILE: pandasai/core/code_generation/code_validation.py class CodeRequirementValidator (line 7) | class CodeRequirementValidator: class _FunctionCallVisitor (line 12) | class _FunctionCallVisitor(ast.NodeVisitor): method __init__ (line 17) | def __init__(self): method visit_Call (line 20) | def visit_Call(self, node: ast.Call): method __init__ (line 32) | def __init__(self, context: AgentState): method validate (line 41) | def validate(self, code: str) -> bool: FILE: pandasai/core/prompts/__init__.py function get_chat_prompt_for_sql (line 19) | def get_chat_prompt_for_sql(context: AgentState) -> BasePrompt: function get_correct_error_prompt_for_sql (line 27) | def get_correct_error_prompt_for_sql( function get_correct_output_type_error_prompt (line 35) | def get_correct_output_type_error_prompt( FILE: pandasai/core/prompts/base.py class BasePrompt (line 14) | class BasePrompt: method __init__ (line 23) | def __init__(self, **kwargs): method render (line 39) | def render(self): method to_string (line 48) | def to_string(self): method __str__ (line 55) | def __str__(self): method validate (line 58) | def validate(self, output: str) -> bool: method to_json (line 61) | def to_json(self): class AbstractPrompt (line 79) | class AbstractPrompt(ABC): method get_prompt (line 81) | def get_prompt(self): FILE: pandasai/core/prompts/correct_execute_sql_query_usage_error_prompt.py class CorrectExecuteSQLQueryUsageErrorPrompt (line 4) | class CorrectExecuteSQLQueryUsageErrorPrompt(BasePrompt): method to_json (line 9) | def to_json(self): FILE: pandasai/core/prompts/correct_output_type_error_prompt.py class CorrectOutputTypeErrorPrompt (line 4) | class CorrectOutputTypeErrorPrompt(BasePrompt): method to_json (line 9) | def to_json(self): FILE: pandasai/core/prompts/generate_python_code_with_sql.py class GeneratePythonCodeWithSQLPrompt (line 4) | class GeneratePythonCodeWithSQLPrompt(BasePrompt): method to_json (line 9) | def to_json(self): FILE: pandasai/core/prompts/generate_system_message.py class GenerateSystemMessagePrompt (line 4) | class GenerateSystemMessagePrompt(BasePrompt): FILE: pandasai/core/response/base.py class BaseResponse (line 7) | class BaseResponse: method __init__ (line 12) | def __init__( method __str__ (line 36) | def __str__(self) -> str: method __repr__ (line 40) | def __repr__(self) -> str: method to_dict (line 44) | def to_dict(self) -> dict: method to_json (line 48) | def to_json(self) -> str: method __format__ (line 52) | def __format__(self, fmt): FILE: pandasai/core/response/chart.py class ChartResponse (line 10) | class ChartResponse(BaseResponse): method __init__ (line 11) | def __init__(self, value: Any, last_code_executed: str): method _get_image (line 14) | def _get_image(self) -> Image.Image: method save (line 22) | def save(self, path: str): method show (line 26) | def show(self): method __str__ (line 30) | def __str__(self) -> str: method get_base64_image (line 34) | def get_base64_image(self) -> str: FILE: pandasai/core/response/dataframe.py class DataFrameResponse (line 8) | class DataFrameResponse(BaseResponse): method __init__ (line 9) | def __init__(self, value: Any = None, last_code_executed: str = None): method format_value (line 13) | def format_value(self, value): FILE: pandasai/core/response/error.py class ErrorResponse (line 4) | class ErrorResponse(BaseResponse): method __init__ (line 9) | def __init__( FILE: pandasai/core/response/number.py class NumberResponse (line 6) | class NumberResponse(BaseResponse): method __init__ (line 11) | def __init__(self, value: Any = None, last_code_executed: str = None): FILE: pandasai/core/response/parser.py class ResponseParser (line 15) | class ResponseParser: method parse (line 16) | def parse(self, result: dict, last_code_executed: str = None) -> BaseR... method _generate_response (line 20) | def _generate_response(self, result: dict, last_code_executed: str = N... method _validate_response (line 32) | def _validate_response(self, result: dict): FILE: pandasai/core/response/string.py class StringResponse (line 6) | class StringResponse(BaseResponse): method __init__ (line 11) | def __init__(self, value: Any = None, last_code_executed: str = None): FILE: pandasai/core/user_query.py class UserQuery (line 1) | class UserQuery: method __init__ (line 2) | def __init__(self, user_query: str): method __str__ (line 5) | def __str__(self): method __repr__ (line 8) | def __repr__(self): method __dict__ (line 11) | def __dict__(self): method to_json (line 14) | def to_json(self): FILE: pandasai/data_loader/duck_db_connection_manager.py class DuckDBConnectionManager (line 8) | class DuckDBConnectionManager: method __init__ (line 9) | def __init__(self): method __del__ (line 14) | def __del__(self): method register (line 18) | def register(self, name: str, df): method unregister (line 23) | def unregister(self, name: str): method sql (line 29) | def sql(self, query: str, params: Optional[list] = None): method close (line 34) | def close(self): FILE: pandasai/data_loader/loader.py class DatasetLoader (line 22) | class DatasetLoader(ABC): method __init__ (line 23) | def __init__(self, schema: SemanticLayerSchema, dataset_path: str): method query_builder (line 30) | def query_builder(self) -> BaseQueryBuilder: method execute_query (line 35) | def execute_query(self, query: str, params: Optional[list] = None): method create_loader_from_schema (line 39) | def create_loader_from_schema( method create_loader_from_path (line 63) | def create_loader_from_path(cls, dataset_path: str) -> "DatasetLoader": method _read_schema_file (line 72) | def _read_schema_file(dataset_path: str) -> SemanticLayerSchema: method load (line 84) | def load(self) -> DataFrame: FILE: pandasai/data_loader/local_loader.py class LocalDatasetLoader (line 17) | class LocalDatasetLoader(DatasetLoader): method __init__ (line 22) | def __init__(self, schema: SemanticLayerSchema, dataset_path: str): method query_builder (line 27) | def query_builder(self) -> LocalQueryBuilder: method register_table (line 30) | def register_table(self): method load (line 35) | def load(self) -> DataFrame: method _replace_readparquet_block_with_table (line 43) | def _replace_readparquet_block_with_table( method execute_query (line 53) | def execute_query(self, query: str, params: Optional[list] = None) -> ... FILE: pandasai/data_loader/semantic_layer_schema.py class SQLConnectionConfig (line 25) | class SQLConnectionConfig(BaseModel): method __eq__ (line 36) | def __eq__(self, other): class Column (line 46) | class Column(BaseModel): method is_column_type_supported (line 57) | def is_column_type_supported(cls, type: str) -> str: method is_expression_valid (line 66) | def is_expression_valid(cls, expr: str) -> Optional[str]: class Relation (line 76) | class Relation(BaseModel): class TransformationParams (line 87) | class TransformationParams(BaseModel): method validate_required_params (line 163) | def validate_required_params(cls, values: dict) -> dict: class Transformation (line 175) | class Transformation(BaseModel): method is_transformation_type_supported (line 183) | def is_transformation_type_supported(cls, type: str) -> str: method set_transform_type (line 190) | def set_transform_type(cls, values: dict) -> dict: class Source (line 198) | class Source(BaseModel): method is_compatible_source (line 206) | def is_compatible_source(self, source2: "Source"): method validate_type_and_fields (line 230) | def validate_type_and_fields(cls, values): class Destination (line 257) | class Destination(BaseModel): method is_format_supported (line 264) | def is_format_supported(cls, format: str) -> str: class SemanticLayerSchema (line 270) | class SemanticLayerSchema(BaseModel): method validate_schema (line 304) | def validate_schema(self) -> "SemanticLayerSchema": method _validate_name (line 310) | def _validate_name(self) -> None: method _validate_group_by_columns (line 316) | def _validate_group_by_columns(self) -> None: method _validate_columns_relations (line 333) | def _validate_columns_relations(self): method to_dict (line 396) | def to_dict(self) -> Dict[str, Any]: method to_yaml (line 399) | def to_yaml(self) -> str: function is_schema_source_same (line 403) | def is_schema_source_same( FILE: pandasai/data_loader/sql_loader.py class SQLDatasetLoader (line 19) | class SQLDatasetLoader(DatasetLoader): method __init__ (line 24) | def __init__(self, schema: SemanticLayerSchema, dataset_path: str): method query_builder (line 29) | def query_builder(self) -> SqlQueryBuilder: method load (line 32) | def load(self) -> VirtualDataFrame: method execute_query (line 39) | def execute_query(self, query: str, params: Optional[list] = None) -> ... method _get_loader_function (line 66) | def _get_loader_function(source_type: str): method load_head (line 78) | def load_head(self) -> pd.DataFrame: method get_row_count (line 82) | def get_row_count(self) -> int: FILE: pandasai/data_loader/view_loader.py class ViewDatasetLoader (line 21) | class ViewDatasetLoader(SQLDatasetLoader): method __init__ (line 26) | def __init__(self, schema: SemanticLayerSchema, dataset_path: str): method query_builder (line 40) | def query_builder(self) -> ViewQueryBuilder: method _get_dependencies_datasets (line 43) | def _get_dependencies_datasets(self) -> set[str]: method _get_dependencies_schemas (line 50) | def _get_dependencies_schemas(self) -> dict[str, DatasetLoader]: method load (line 73) | def load(self) -> VirtualDataFrame: method execute_local_query (line 80) | def execute_local_query( method execute_query (line 89) | def execute_query(self, query: str, params: Optional[list] = None) -> ... FILE: pandasai/dataframe/base.py class DataFrame (line 31) | class DataFrame(pd.DataFrame): method __init__ (line 51) | def __init__( method __repr__ (line 76) | def __repr__(self) -> str: method _calculate_column_hash (line 88) | def _calculate_column_hash(self): method column_hash (line 93) | def column_hash(self): method type (line 97) | def type(self) -> str: method chat (line 100) | def chat(self, prompt: str, sandbox: Optional[Sandbox] = None) -> Base... method follow_up (line 120) | def follow_up(self, query: str, output_type: Optional[str] = None): method rows_count (line 128) | def rows_count(self) -> int: method columns_count (line 132) | def columns_count(self) -> int: method get_dialect (line 135) | def get_dialect(self): method serialize_dataframe (line 144) | def serialize_dataframe(self) -> str: method get_head (line 154) | def get_head(self): method get_column_type (line 158) | def get_column_type(column_dtype) -> Optional[str]: method get_default_schema (line 176) | def get_default_schema(cls, dataframe: DataFrame) -> SemanticLayerSchema: FILE: pandasai/dataframe/virtual_dataframe.py class VirtualDataFrame (line 14) | class VirtualDataFrame(DataFrame): method __init__ (line 26) | def __init__(self, *args, **kwargs): method head (line 37) | def head(self): method rows_count (line 43) | def rows_count(self) -> int: method query_builder (line 47) | def query_builder(self): method execute_sql_query (line 50) | def execute_sql_query(self, query: str) -> pd.DataFrame: FILE: pandasai/ee/skills/__init__.py class SkillType (line 7) | class SkillType(BaseModel): method __init__ (line 15) | def __init__( method __call__ (line 49) | def __call__(self, *args, **kwargs) -> Any: method from_function (line 54) | def from_function(cls, func: Callable, **kwargs: Any) -> "SkillType": method stringify (line 67) | def stringify(self): method __str__ (line 70) | def __str__(self): function skill (line 76) | def skill(*args: Union[str, Callable]) -> Callable: FILE: pandasai/ee/skills/manager.py class SkillsManager (line 6) | class SkillsManager: method add_skills (line 14) | def add_skills(cls, *skills: SkillType): method skill_exists (line 29) | def skill_exists(cls, name: str): method has_skills (line 42) | def has_skills(cls): method get_skill_by_func_name (line 52) | def get_skill_by_func_name(cls, name: str): method get_skills (line 65) | def get_skills(cls) -> List[SkillType]: method clear_skills (line 75) | def clear_skills(cls): method __str__ (line 82) | def __str__(cls) -> str: FILE: pandasai/exceptions.py class InvalidRequestError (line 10) | class InvalidRequestError(Exception): class APIKeyNotFoundError (line 19) | class APIKeyNotFoundError(Exception): class LLMNotFoundError (line 28) | class LLMNotFoundError(Exception): class NoCodeFoundError (line 37) | class NoCodeFoundError(Exception): class NoResultFoundError (line 46) | class NoResultFoundError(Exception): class MethodNotImplementedError (line 55) | class MethodNotImplementedError(Exception): class UnsupportedModelError (line 64) | class UnsupportedModelError(Exception): method __init__ (line 73) | def __init__(self, model_name): class MissingModelError (line 81) | class MissingModelError(Exception): class BadImportError (line 90) | class BadImportError(Exception): method __init__ (line 98) | def __init__(self, library_name): class TemplateFileNotFoundError (line 112) | class TemplateFileNotFoundError(FileNotFoundError): method __init__ (line 117) | def __init__(self, template_path, prompt_name="Unknown"): class UnSupportedLogicUnit (line 132) | class UnSupportedLogicUnit(Exception): class InvalidWorkspacePathError (line 140) | class InvalidWorkspacePathError(Exception): class InvalidConfigError (line 149) | class InvalidConfigError(Exception): class MaliciousQueryError (line 157) | class MaliciousQueryError(Exception): class InvalidLLMOutputType (line 165) | class InvalidLLMOutputType(Exception): class InvalidOutputValueMismatch (line 173) | class InvalidOutputValueMismatch(Exception): class ExecuteSQLQueryNotUsed (line 181) | class ExecuteSQLQueryNotUsed(Exception): class PipelineConcatenationError (line 189) | class PipelineConcatenationError(Exception): class MissingVectorStoreError (line 197) | class MissingVectorStoreError(Exception): class PandasAIApiKeyError (line 205) | class PandasAIApiKeyError(Exception): method __init__ (line 210) | def __init__(self, message=None): class PandasAIApiCallError (line 215) | class PandasAIApiCallError(Exception): class PandasConnectorTableNotFound (line 223) | class PandasConnectorTableNotFound(Exception): class InvalidTrainJson (line 231) | class InvalidTrainJson(Exception): class InvalidSchemaJson (line 239) | class InvalidSchemaJson(Exception): class LazyLoadError (line 247) | class LazyLoadError(Exception): class InvalidDataSourceType (line 253) | class InvalidDataSourceType(Exception): class MaliciousCodeGenerated (line 259) | class MaliciousCodeGenerated(Exception): class DatasetNotFound (line 267) | class DatasetNotFound(Exception): class CodeExecutionError (line 275) | class CodeExecutionError(Exception): class VirtualizationError (line 283) | class VirtualizationError(Exception): class UnsupportedTransformation (line 289) | class UnsupportedTransformation(Exception): FILE: pandasai/helpers/dataframe_serializer.py class DataframeSerializer (line 8) | class DataframeSerializer: method serialize (line 12) | def serialize(cls, df: "DataFrame", dialect: str = "postgres") -> str: method _truncate_dataframe (line 49) | def _truncate_dataframe(cls, df: "DataFrame") -> "DataFrame": FILE: pandasai/helpers/env.py function load_dotenv (line 6) | def load_dotenv(): FILE: pandasai/helpers/filemanager.py class FileManager (line 7) | class FileManager(ABC): method load (line 11) | def load(self, file_path: str) -> str: method load_binary (line 16) | def load_binary(self, file_path: str) -> bytes: method write (line 21) | def write(self, file_path: str, content: str) -> None: method write_binary (line 26) | def write_binary(self, file_path: str, content: bytes) -> None: method exists (line 31) | def exists(self, file_path: str) -> bool: method mkdir (line 36) | def mkdir(self, dir_path: str) -> None: method abs_path (line 41) | def abs_path(self, file_path: str) -> str: class DefaultFileManager (line 46) | class DefaultFileManager(FileManager): method __init__ (line 49) | def __init__(self): method load (line 52) | def load(self, file_path: str) -> str: method load_binary (line 56) | def load_binary(self, file_path: str) -> bytes: method write (line 60) | def write(self, file_path: str, content: str) -> None: method write_binary (line 64) | def write_binary(self, file_path: str, content: bytes) -> None: method exists (line 68) | def exists(self, file_path: str) -> bool: method mkdir (line 71) | def mkdir(self, dir_path: str) -> None: method abs_path (line 74) | def abs_path(self, file_path: str) -> str: FILE: pandasai/helpers/folder.py class FolderConfig (line 10) | class FolderConfig(BaseModel): class Folder (line 15) | class Folder: method create (line 17) | def create(path, config: FolderConfig = FolderConfig()): FILE: pandasai/helpers/json_encoder.py function convert_numpy_types (line 8) | def convert_numpy_types(obj): class CustomJsonEncoder (line 37) | class CustomJsonEncoder(JSONEncoder): method default (line 38) | def default(self, obj): FILE: pandasai/helpers/logger.py class Log (line 32) | class Log(BaseModel): class Logger (line 39) | class Logger: method __init__ (line 47) | def __init__(self, save_logs: bool = True, verbose: bool = False): method log (line 73) | def log(self, message: str, level: int = logging.INFO): method _invoked_from (line 94) | def _invoked_from(self, level: int = 5) -> str: method _calculate_time_diff (line 108) | def _calculate_time_diff(self): method logs (line 115) | def logs(self) -> List[str]: method verbose (line 120) | def verbose(self) -> bool: method verbose (line 125) | def verbose(self, verbose: bool): method save_logs (line 138) | def save_logs(self) -> bool: method save_logs (line 143) | def save_logs(self, save_logs: bool): FILE: pandasai/helpers/memory.py class Memory (line 5) | class Memory: method __init__ (line 12) | def __init__( method add (line 19) | def add(self, message: str, is_user: bool): method count (line 22) | def count(self) -> int: method all (line 25) | def all(self) -> list: method last (line 28) | def last(self) -> dict: method _truncate (line 31) | def _truncate(self, message: Union[str, int], max_length: int = 100) -... method get_messages (line 39) | def get_messages(self, limit: int = None) -> list: method get_conversation (line 51) | def get_conversation(self, limit: int = None) -> str: method get_previous_conversation (line 58) | def get_previous_conversation(self) -> str: method get_last_message (line 65) | def get_last_message(self) -> str: method to_json (line 72) | def to_json(self): method to_openai_messages (line 81) | def to_openai_messages(self): method clear (line 100) | def clear(self): method size (line 104) | def size(self): FILE: pandasai/helpers/path.py function find_project_root (line 9) | def find_project_root(filename=None): function find_closest (line 45) | def find_closest(filename): function validate_name_format (line 49) | def validate_name_format(value): function validate_underscore_name_format (line 56) | def validate_underscore_name_format(value): function transform_dash_to_underscore (line 63) | def transform_dash_to_underscore(value: str) -> str: function transform_underscore_to_dash (line 67) | def transform_underscore_to_dash(value: str) -> str: function get_validated_dataset_path (line 71) | def get_validated_dataset_path(path: str): function get_table_name_from_path (line 96) | def get_table_name_from_path(filepath: Union[str, BytesIO]) -> str: FILE: pandasai/helpers/session.py class Session (line 19) | class Session: method __init__ (line 24) | def __init__( method get (line 43) | def get(self, path=None, **kwargs): method post (line 46) | def post(self, path=None, **kwargs): method patch (line 49) | def patch(self, path=None, **kwargs): method put (line 52) | def put(self, path=None, **kwargs): method delete (line 55) | def delete(self, path=None, **kwargs): method make_request (line 58) | def make_request( function get_PandasAI_session (line 107) | def get_PandasAI_session() -> Session: FILE: pandasai/helpers/sql_sanitizer.py function sanitize_view_column_name (line 9) | def sanitize_view_column_name(relation_name: str) -> str: function sanitize_sql_table_name (line 19) | def sanitize_sql_table_name(table_name: str) -> str: function sanitize_sql_table_name_lowercase (line 30) | def sanitize_sql_table_name_lowercase(table_name: str) -> str: function sanitize_file_name (line 34) | def sanitize_file_name(filepath: str) -> str: function is_sql_query_safe (line 40) | def is_sql_query_safe(query: str, dialect: str = "postgres") -> bool: function is_sql_query (line 114) | def is_sql_query(query: str) -> bool: FILE: pandasai/helpers/telemetry.py function scarf_analytics (line 9) | def scarf_analytics(): FILE: pandasai/llm/base.py class LLM (line 22) | class LLM: method __init__ (line 27) | def __init__(self, api_key: Optional[str] = None, **kwargs: Any) -> None: method is_pandasai_llm (line 36) | def is_pandasai_llm(self) -> bool: method type (line 47) | def type(self) -> str: method _polish_code (line 60) | def _polish_code(self, code: str) -> str: method _is_python_code (line 79) | def _is_python_code(self, string): method _extract_code (line 94) | def _extract_code(self, response: str, separator: str = "```") -> str: method prepend_system_prompt (line 122) | def prepend_system_prompt(self, prompt: str, memory: Memory) -> str | ... method get_system_prompt (line 131) | def get_system_prompt(self, memory: Memory) -> Any: method get_messages (line 138) | def get_messages(self, memory: Memory) -> Any: method call (line 147) | def call(self, instruction: BasePrompt, context: AgentState = None) ->... method generate_code (line 161) | def generate_code(self, instruction: BasePrompt, context: AgentState) ... FILE: pandasai/llm/fake.py class FakeLLM (line 11) | class FakeLLM(LLM): method __init__ (line 17) | def __init__(self, output: Optional[str] = None, type: str = "fake"): method call (line 26) | def call(self, instruction: BasePrompt, context: AgentState = None) ->... method type (line 32) | def type(self) -> str: FILE: pandasai/query_builders/base_query_builder.py class BaseQueryBuilder (line 12) | class BaseQueryBuilder: method __init__ (line 13) | def __init__(self, schema: SemanticLayerSchema): method validate_query_builder (line 17) | def validate_query_builder(self): method build_query (line 25) | def build_query(self) -> str: method get_head_query (line 44) | def get_head_query(self, n=5): method get_row_count (line 61) | def get_row_count(self): method _get_columns (line 64) | def _get_columns(self) -> list[str]: method _get_table_expression (line 90) | def _get_table_expression(self) -> str: method _check_distinct (line 93) | def _check_distinct(self) -> bool: method check_compatible_sources (line 106) | def check_compatible_sources(sources: List[Source]) -> bool: FILE: pandasai/query_builders/local_query_builder.py class LocalQueryBuilder (line 8) | class LocalQueryBuilder(BaseQueryBuilder): method __init__ (line 9) | def __init__(self, schema: SemanticLayerSchema, dataset_path: str): method _get_table_expression (line 13) | def _get_table_expression(self) -> str: FILE: pandasai/query_builders/paginator.py class PaginationParams (line 12) | class PaginationParams(BaseModel): method not_sql (line 30) | def not_sql(cls, field): class DatasetPaginator (line 38) | class DatasetPaginator: method is_float (line 40) | def is_float(value: str) -> bool: method is_valid_boolean (line 50) | def is_valid_boolean(value): method is_valid_uuid (line 59) | def is_valid_uuid(value): method is_valid_datetime (line 67) | def is_valid_datetime(value: str) -> bool: method apply_pagination (line 75) | def apply_pagination( FILE: pandasai/query_builders/sql_parser.py class SQLParser (line 10) | class SQLParser: method replace_table_and_column_names (line 12) | def replace_table_and_column_names(query, table_mapping): method transpile_sql_dialect (line 60) | def transpile_sql_dialect( method extract_table_names (line 76) | def extract_table_names(sql_query: str, dialect: str = "postgres") -> ... FILE: pandasai/query_builders/sql_query_builder.py class SqlQueryBuilder (line 6) | class SqlQueryBuilder(BaseQueryBuilder): method _get_table_expression (line 7) | def _get_table_expression(self) -> str: FILE: pandasai/query_builders/sql_transformation_manager.py class SQLTransformationManager (line 9) | class SQLTransformationManager: method _quote_str (line 13) | def _quote_str(value: str) -> str: method _validate_numeric (line 22) | def _validate_numeric( method apply_transformations (line 36) | def apply_transformations(expr: str, transformations: List[Transformat... method _anonymize (line 52) | def _anonymize(expr: str, params: TransformationParams) -> str: method _fill_na (line 57) | def _fill_na(expr: str, params: TransformationParams) -> str: method _map_values (line 67) | def _map_values(expr: str, params: TransformationParams) -> str: method _to_lowercase (line 83) | def _to_lowercase(expr: str, params: TransformationParams) -> str: method _to_uppercase (line 87) | def _to_uppercase(expr: str, params: TransformationParams) -> str: method _round_numbers (line 91) | def _round_numbers(expr: str, params: TransformationParams) -> str: method _format_date (line 98) | def _format_date(expr: str, params: TransformationParams) -> str: method _truncate (line 105) | def _truncate(expr: str, params: TransformationParams) -> str: method _scale (line 112) | def _scale(expr: str, params: TransformationParams) -> str: method _normalize (line 119) | def _normalize(expr: str, params: TransformationParams) -> str: method _standardize (line 123) | def _standardize(expr: str, params: TransformationParams) -> str: method _convert_timezone (line 127) | def _convert_timezone(expr: str, params: TransformationParams) -> str: method _strip (line 133) | def _strip(expr: str, params: TransformationParams) -> str: method _to_numeric (line 137) | def _to_numeric(expr: str, params: TransformationParams) -> str: method _to_datetime (line 141) | def _to_datetime(expr: str, params: TransformationParams) -> str: method _replace (line 147) | def _replace(expr: str, params: TransformationParams) -> str: method _extract (line 153) | def _extract(expr: str, params: TransformationParams) -> str: method _pad (line 158) | def _pad(expr: str, params: TransformationParams) -> str: method _clip (line 168) | def _clip(expr: str, params: TransformationParams) -> str: method _bin (line 174) | def _bin(expr: str, params: TransformationParams) -> str: method _validate_email (line 196) | def _validate_email(expr: str, params: TransformationParams) -> str: method _validate_date_range (line 202) | def _validate_date_range(expr: str, params: TransformationParams) -> str: method _normalize_phone (line 208) | def _normalize_phone(expr: str, params: TransformationParams) -> str: method _remove_duplicates (line 213) | def _remove_duplicates(expr: str, params: TransformationParams) -> str: method _validate_foreign_key (line 217) | def _validate_foreign_key(expr: str, params: TransformationParams) -> ... method _ensure_positive (line 223) | def _ensure_positive(expr: str, params: TransformationParams) -> str: method _standardize_categories (line 227) | def _standardize_categories(expr: str, params: TransformationParams) -... method _rename (line 243) | def _rename(expr: str, params: TransformationParams) -> str: method get_column_transformations (line 249) | def get_column_transformations( method apply_column_transformations (line 272) | def apply_column_transformations( FILE: pandasai/query_builders/view_query_builder.py class ViewQueryBuilder (line 16) | class ViewQueryBuilder(BaseQueryBuilder): method __init__ (line 17) | def __init__( method normalize_view_column_name (line 26) | def normalize_view_column_name(name: str) -> str: method normalize_view_column_alias (line 30) | def normalize_view_column_alias(name: str) -> str: method _get_group_by_columns (line 34) | def _get_group_by_columns(self) -> list[str]: method _get_aliases (line 41) | def _get_aliases(self) -> list[str]: method _get_columns (line 47) | def _get_columns(self) -> list[str]: method build_query (line 73) | def build_query(self) -> str: method get_head_query (line 86) | def get_head_query(self, n=5): method _get_sub_query_from_loader (line 96) | def _get_sub_query_from_loader(self, loader: DatasetLoader) -> Subquery: method _get_table_expression (line 100) | def _get_table_expression(self) -> str: FILE: pandasai/sandbox/sandbox.py class Sandbox (line 4) | class Sandbox: method __init__ (line 5) | def __init__(self): method start (line 8) | def start(self): method stop (line 11) | def stop(self): method execute (line 14) | def execute(self, code: str, environment: dict) -> dict: method _exec_code (line 21) | def _exec_code(self, code: str, environment: dict) -> dict: method transfer_file (line 24) | def transfer_file(self, csv_data, filename="file.csv"): method _extract_sql_queries_from_code (line 29) | def _extract_sql_queries_from_code(self, code) -> list[str]: method _compile_code (line 74) | def _compile_code(self, code: str) -> str: FILE: pandasai/smart_dataframe/__init__.py class SmartDataframe (line 16) | class SmartDataframe: method __init__ (line 27) | def __init__( method load_df (line 65) | def load_df(self, df, name: str, description: str, custom_head: pd.Dat... method chat (line 76) | def chat(self, query: str, output_type: Optional[str] = None): method head_df (line 98) | def head_df(self): method head_csv (line 107) | def head_csv(self): method last_prompt (line 117) | def last_prompt(self): method last_prompt_id (line 121) | def last_prompt_id(self) -> uuid.UUID: method last_code_generated (line 125) | def last_code_generated(self): method last_code_executed (line 129) | def last_code_executed(self): method original_import (line 132) | def original_import(self): method logger (line 136) | def logger(self): method logger (line 140) | def logger(self, logger: Logger): method logs (line 144) | def logs(self): method verbose (line 148) | def verbose(self): method verbose (line 152) | def verbose(self, verbose: bool): method save_logs (line 156) | def save_logs(self): method save_logs (line 160) | def save_logs(self, save_logs: bool): method save_charts (line 164) | def save_charts(self): method save_charts (line 168) | def save_charts(self, save_charts: bool): method save_charts_path (line 172) | def save_charts_path(self): method save_charts_path (line 176) | def save_charts_path(self, save_charts_path: str): method table_name (line 180) | def table_name(self): method table_description (line 184) | def table_description(self): method custom_head (line 188) | def custom_head(self): method __len__ (line 192) | def __len__(self): method __eq__ (line 195) | def __eq__(self, other): method __getattr__ (line 198) | def __getattr__(self, name): method __getitem__ (line 204) | def __getitem__(self, key): method __setitem__ (line 207) | def __setitem__(self, key, value): function load_smartdataframes (line 211) | def load_smartdataframes( FILE: pandasai/smart_datalake/__init__.py class SmartDatalake (line 13) | class SmartDatalake: method __init__ (line 14) | def __init__( method load_dfs (line 33) | def load_dfs(self, dfs: List[pd.DataFrame]): method chat (line 48) | def chat(self, query: str, output_type: Optional[str] = None): method clear_memory (line 71) | def clear_memory(self): method last_prompt (line 78) | def last_prompt(self): method last_prompt_id (line 82) | def last_prompt_id(self) -> uuid.UUID: method logs (line 89) | def logs(self): method logger (line 93) | def logger(self): method logger (line 97) | def logger(self, logger): method config (line 101) | def config(self): method verbose (line 105) | def verbose(self): method verbose (line 109) | def verbose(self, verbose: bool): method save_logs (line 114) | def save_logs(self): method save_logs (line 118) | def save_logs(self, save_logs: bool): method custom_prompts (line 123) | def custom_prompts(self): method custom_prompts (line 127) | def custom_prompts(self, custom_prompts: dict): method save_charts (line 131) | def save_charts(self): method save_charts (line 135) | def save_charts(self, save_charts: bool): method save_charts_path (line 139) | def save_charts_path(self): method save_charts_path (line 143) | def save_charts_path(self, save_charts_path: str): method last_code_generated (line 147) | def last_code_generated(self): method last_code_executed (line 151) | def last_code_executed(self): method last_result (line 155) | def last_result(self): method last_error (line 159) | def last_error(self): method dfs (line 163) | def dfs(self): method memory (line 167) | def memory(self): FILE: pandasai/vectorstores/vectorstore.py class VectorStore (line 5) | class VectorStore(ABC): method add_question_answer (line 9) | def add_question_answer( method add_docs (line 32) | def add_docs( method update_question_answer (line 51) | def update_question_answer( method update_docs (line 71) | def update_docs( method delete_question_and_answers (line 90) | def delete_question_and_answers( method delete_docs (line 106) | def delete_docs(self, ids: Optional[List[str]] = None) -> Optional[bool]: method delete_collection (line 118) | def delete_collection(self, collection_name: str) -> Optional[bool]: method get_relevant_question_answers (line 128) | def get_relevant_question_answers(self, question: str, k: int = 1) -> ... method get_relevant_docs (line 136) | def get_relevant_docs(self, question: str, k: int = 1) -> List[dict]: method get_relevant_question_answers_by_id (line 144) | def get_relevant_question_answers_by_id(self, ids: Iterable[str]) -> L... method get_relevant_docs_by_id (line 150) | def get_relevant_docs_by_id(self, ids: Iterable[str]) -> List[dict]: method get_relevant_qa_documents (line 157) | def get_relevant_qa_documents(self, question: str, k: int = 1) -> List... method get_relevant_docs_documents (line 168) | def get_relevant_docs_documents(self, question: str, k: int = 1) -> Li... method _format_qa (line 178) | def _format_qa(self, query: str, code: str) -> str: FILE: tests/integration_tests/conftest.py function mock_pandasai_push (line 21) | def mock_pandasai_push(): function mock_dataset_pull (line 33) | def mock_dataset_pull(): function root_path (line 67) | def root_path(): function clear_os_environ (line 72) | def clear_os_environ(monkeypatch): function mock_sql_load_function (line 92) | def mock_sql_load_function(): function set_fake_llm_output (line 103) | def set_fake_llm_output(output: str): function compare_sorted_dataframe (line 108) | def compare_sorted_dataframe(df1: pd.DataFrame, df2: pd.DataFrame, colum... FILE: tests/integration_tests/local_view/test_local_view.py function local_view_dataset_slug (line 36) | def local_view_dataset_slug(): function test_slug_fixture (line 99) | def test_slug_fixture(local_view_dataset_slug): function test_local_view_files (line 106) | def test_local_view_files(local_view_dataset_slug, root_path): function test_local_view_load (line 123) | def test_local_view_load(local_view_dataset_slug): function test_local_view_chat (line 129) | def test_local_view_chat(local_view_dataset_slug): FILE: tests/integration_tests/local_view/test_local_view_grouped.py function local_view_grouped_dataset_slug (line 27) | def local_view_grouped_dataset_slug(): function test_slug_fixture (line 92) | def test_slug_fixture(local_view_grouped_dataset_slug): function test_local_view_grouped_files (line 99) | def test_local_view_grouped_files(local_view_grouped_dataset_slug, root_... function test_local_view_grouped_load (line 118) | def test_local_view_grouped_load(local_view_grouped_dataset_slug): function test_local_view_grouped_chat (line 124) | def test_local_view_grouped_chat(local_view_grouped_dataset_slug): FILE: tests/integration_tests/local_view/test_local_view_transformed.py function local_view_transformed_dataset_slug (line 31) | def local_view_transformed_dataset_slug(): function test_slug_fixture (line 110) | def test_slug_fixture(local_view_transformed_dataset_slug): function test_local_view_transformed_files (line 117) | def test_local_view_transformed_files(local_view_transformed_dataset_slu... function test_local_view_transformed_load (line 136) | def test_local_view_transformed_load(local_view_transformed_dataset_slug): function test_local_view_transformed_chat (line 142) | def test_local_view_transformed_chat(local_view_transformed_dataset_slug): FILE: tests/integration_tests/parquet/test_parquet.py function parquet_dataset_slug (line 28) | def parquet_dataset_slug(): function test_slug_fixture (line 40) | def test_slug_fixture(parquet_dataset_slug): function test_parquet_files (line 47) | def test_parquet_files(parquet_dataset_slug, root_path): function test_parquet_load (line 55) | def test_parquet_load(parquet_dataset_slug): function test_parquet_chat (line 61) | def test_parquet_chat(parquet_dataset_slug): FILE: tests/integration_tests/parquet/test_parquet_grouped.py function parquet_dataset_grouped_slug (line 24) | def parquet_dataset_grouped_slug(): function test_parquet_files (line 47) | def test_parquet_files(parquet_dataset_grouped_slug, root_path): function test_parquet_load (line 55) | def test_parquet_load(parquet_dataset_grouped_slug): function test_parquet_chat (line 61) | def test_parquet_chat(parquet_dataset_grouped_slug): FILE: tests/integration_tests/parquet/test_parquet_transformed.py function parquet_dataset_transformed_slug (line 28) | def parquet_dataset_transformed_slug(): function test_parquet_files (line 58) | def test_parquet_files(parquet_dataset_transformed_slug, root_path): function test_parquet_load (line 68) | def test_parquet_load(parquet_dataset_transformed_slug): function test_parquet_chat (line 74) | def test_parquet_chat(parquet_dataset_transformed_slug): FILE: tests/integration_tests/sql/test_sql.py function sql_dataset_slug (line 20) | def sql_dataset_slug(): function test_slug_fixture (line 52) | def test_slug_fixture(sql_dataset_slug): function test_sql_files (line 59) | def test_sql_files(sql_dataset_slug, root_path): function test_sql_load (line 65) | def test_sql_load(sql_dataset_slug): function test_sql_chat (line 71) | def test_sql_chat(sql_dataset_slug): FILE: tests/integration_tests/sql_view/test_sql_view.py function sql_view_dataset_slug (line 20) | def sql_view_dataset_slug(): function test_slug_fixture (line 101) | def test_slug_fixture(sql_view_dataset_slug): function test_sql_view_files (line 108) | def test_sql_view_files(sql_view_dataset_slug, root_path): function test_sql_view_load (line 120) | def test_sql_view_load(sql_view_dataset_slug): function test_sql_view_chat (line 126) | def test_sql_view_chat(sql_view_dataset_slug): FILE: tests/unit_tests/agent/.ipynb_checkpoints/test_agent_llm_judge-checkpoint.py class Evaluation (line 17) | class Evaluation(BaseModel): class TestAgentLLMJudge (line 26) | class TestAgentLLMJudge: method setup (line 75) | def setup(self): method test_judge_setup (line 98) | def test_judge_setup(self): method test_loans_questions (line 124) | def test_loans_questions(self, question): method test_heart_strokes_questions (line 149) | def test_heart_strokes_questions(self, question): method test_combined_questions_with_type (line 174) | def test_combined_questions_with_type(self, question): method test_average_score (line 202) | def test_average_score(self): FILE: tests/unit_tests/agent/test_agent.py class TestAgent (line 18) | class TestAgent: method llm (line 22) | def llm(self, output: Optional[str] = None) -> FakeLLM: method config (line 26) | def config(self, llm: FakeLLM) -> dict: method agent (line 30) | def agent(self, sample_df: DataFrame, config: dict) -> Agent: method mock_llm (line 34) | def mock_llm(self): method test_constructor (line 39) | def test_constructor(self, sample_df, config): method test_chat (line 51) | def test_chat(self, sample_df, config): method test_code_generation (line 63) | def test_code_generation(self, mock_generate_code, sample_df, config): method test_code_generation_with_retries (line 78) | def test_code_generation_with_retries(self, mock_generate_code, sample... method test_code_generation_with_retries_three_times (line 91) | def test_code_generation_with_retries_three_times( method test_generate_code_with (line 109) | def test_generate_code_with(self, mock_generate_code, agent: Agent): method test_generate_code_logs_generation (line 124) | def test_generate_code_logs_generation(self, mock_generate_code, agent... method test_generate_code_updates_last_prompt (line 141) | def test_generate_code_updates_last_prompt(self, mock_generate_code, a... method test_execute_code_successful_execution (line 158) | def test_execute_code_successful_execution(self, mock_code_executor, a... method test_execute_code (line 175) | def test_execute_code(self, mock_code_executor, agent: Agent): method test_execute_code_logs_execution (line 195) | def test_execute_code_logs_execution(self, mock_code_executor, agent: ... method test_execute_code_with_missing_dependencies (line 216) | def test_execute_code_with_missing_dependencies( method test_execute_code_handles_empty_code (line 236) | def test_execute_code_handles_empty_code(self, mock_code_executor, age... method test_start_new_conversation (line 250) | def test_start_new_conversation(self, sample_df, config): method test_code_generation_success (line 259) | def test_code_generation_success(self, agent: Agent): method test_execute_with_retries_max_retries_exceeds (line 269) | def test_execute_with_retries_max_retries_exceeds(self, agent: Agent): method test_execute_with_retries_success (line 286) | def test_execute_with_retries_success(self, agent: Agent): method test_execute_with_retries_custom_retries (line 310) | def test_execute_with_retries_custom_retries(self, agent: Agent): method test_load_llm_with_pandasai_llm (line 325) | def test_load_llm_with_pandasai_llm(self, agent: Agent, llm): method test_load_llm_none (line 328) | def test_load_llm_none(self, agent: Agent, llm): method test_get_config_none (line 334) | def test_get_config_none(self, agent: Agent): method test_get_config_dict (line 341) | def test_get_config_dict(self, agent: Agent): method test_get_config_dict_with_api_key (line 351) | def test_get_config_dict_with_api_key(self, agent: Agent): method test_get_config_config (line 358) | def test_get_config_config(self, agent: Agent): method test_train_method_with_qa (line 365) | def test_train_method_with_qa(self, agent): method test_train_method_with_docs (line 375) | def test_train_method_with_docs(self, agent): method test_train_method_with_docs_and_qa (line 383) | def test_train_method_with_docs_and_qa(self, agent): method test_train_method_with_queries_but_no_code (line 396) | def test_train_method_with_queries_but_no_code(self, agent): method test_train_method_with_code_but_no_queries (line 401) | def test_train_method_with_code_but_no_queries(self, agent): method test_execute_sql_query_success_local (line 406) | def test_execute_sql_query_success_local(self, agent, sample_df): method test_execute_sql_query_success_virtual_dataframe (line 413) | def test_execute_sql_query_success_virtual_dataframe( method test_execute_sql_query_error_no_dataframe (line 438) | def test_execute_sql_query_error_no_dataframe(self, agent): method test_process_query (line 445) | def test_process_query(self, agent, config): method test_process_query_execution_error (line 464) | def test_process_query_execution_error(self, agent, config): method test_regenerate_code_after_invalid_llm_output_error (line 482) | def test_regenerate_code_after_invalid_llm_output_error(self, agent): method test_regenerate_code_after_other_error (line 503) | def test_regenerate_code_after_other_error(self, agent): method test_handle_exception (line 522) | def test_handle_exception(self, agent): method test_last_code_generated_retrieval (line 546) | def test_last_code_generated_retrieval(self, agent: Agent): FILE: tests/unit_tests/agent/test_agent_chat.py class TestAgentChat (line 26) | class TestAgentChat: method pandas_ai (line 124) | def pandas_ai(self): method test_numeric_questions (line 129) | def test_numeric_questions(self, question, expected, pandas_ai): method test_loans_questions_type (line 198) | def test_loans_questions_type(self, question, expected, pandas_ai): method test_heart_strokes_questions_type (line 212) | def test_heart_strokes_questions_type(self, question, expected, pandas... method test_combined_questions_with_type (line 226) | def test_combined_questions_with_type(self, question, expected, pandas... FILE: tests/unit_tests/agent/test_agent_llm_judge.py class Evaluation (line 17) | class Evaluation(BaseModel): class TestAgentLLMJudge (line 26) | class TestAgentLLMJudge: method setup (line 75) | def setup(self): method test_judge_setup (line 98) | def test_judge_setup(self): method test_loans_questions (line 124) | def test_loans_questions(self, question): method test_heart_strokes_questions (line 149) | def test_heart_strokes_questions(self, question): method test_combined_questions_with_type (line 174) | def test_combined_questions_with_type(self, question): method test_average_score (line 202) | def test_average_score(self): FILE: tests/unit_tests/conftest.py function sample_dict_data (line 19) | def sample_dict_data(): function sample_df (line 24) | def sample_df(sample_dict_data): function sample_dataframes (line 29) | def sample_dataframes(): function raw_sample_schema (line 36) | def raw_sample_schema(): function raw_mysql_schema (line 64) | def raw_mysql_schema(): function raw_mysql_view_schema (line 102) | def raw_mysql_view_schema(): function sample_schema (line 116) | def sample_schema(raw_sample_schema): function mysql_schema (line 121) | def mysql_schema(raw_mysql_schema): function mock_view_loader_instance_parents (line 126) | def mock_view_loader_instance_parents(sample_df): function mock_view_loader_instance_children (line 154) | def mock_view_loader_instance_children(sample_df): function mysql_view_schema (line 182) | def mysql_view_schema(raw_mysql_view_schema): function mysql_view_dependencies_dict (line 187) | def mysql_view_dependencies_dict( function mock_json_load (line 197) | def mock_json_load(): function pytest_terminal_summary (line 204) | def pytest_terminal_summary(terminalreporter, exitstatus): function mock_loader_instance (line 221) | def mock_loader_instance(sample_df): function mock_file_manager (line 238) | def mock_file_manager(): function llm (line 249) | def llm(output: Optional[str] = None) -> FakeLLM: FILE: tests/unit_tests/core/code_execution/test_code_execution.py class TestCodeExecutor (line 9) | class TestCodeExecutor(unittest.TestCase): method setUp (line 10) | def setUp(self): method test_initialization (line 14) | def test_initialization(self): method test_add_to_env (line 18) | def test_add_to_env(self): method test_execute_valid_code (line 23) | def test_execute_valid_code(self): method test_execute_code_with_variable (line 29) | def test_execute_code_with_variable(self): method test_execute_and_return_result (line 35) | def test_execute_and_return_result(self): method test_execute_and_return_result_no_result (line 41) | def test_execute_and_return_result_no_result(self): method test_execute_and_return_result_with_plot (line 47) | def test_execute_and_return_result_with_plot(self): method test_execute_with_syntax_error (line 54) | def test_execute_with_syntax_error(self): FILE: tests/unit_tests/core/code_execution/test_environment.py class TestEnvironmentFunctions (line 11) | class TestEnvironmentFunctions(unittest.TestCase): method test_get_environment_with_secure_mode (line 13) | def test_get_environment_with_secure_mode(self, mock_import_dependency): method test_get_environment_without_secure_mode (line 23) | def test_get_environment_without_secure_mode(self, mock_import_depende... method test_import_dependency_success (line 34) | def test_import_dependency_success(self, mock_import_module): method test_import_dependency_missing (line 42) | def test_import_dependency_missing(self, mock_import_module): method test_import_dependency_with_extra_message (line 49) | def test_import_dependency_with_extra_message(self, mock_import_module): method test_get_version_success (line 58) | def test_get_version_success(self, mock_import_module): method test_get_version_failure (line 65) | def test_get_version_failure(self, mock_import_module): FILE: tests/unit_tests/core/code_generation/test_code_cleaning.py class TestCodeCleaner (line 13) | class TestCodeCleaner(unittest.TestCase): method setUp (line 14) | def setUp(self): method test_check_direct_sql_func_def_exists_true (line 31) | def test_check_direct_sql_func_def_exists_true(self): method test_replace_table_names_valid (line 49) | def test_replace_table_names_valid(self): method test_replace_table_names_invalid (line 58) | def test_replace_table_names_invalid(self): method test_clean_sql_query (line 67) | def test_clean_sql_query(self): method test_validate_and_make_table_name_case_sensitive (line 78) | def test_validate_and_make_table_name_case_sensitive(self): method test_replace_output_filenames_with_temp_chart (line 92) | def test_replace_output_filenames_with_temp_chart(self): method test_replace_output_filenames_with_temp_chart_windows_paths (line 109) | def test_replace_output_filenames_with_temp_chart_windows_paths(self): method test_replace_output_filenames_with_temp_chart_empty_code (line 149) | def test_replace_output_filenames_with_temp_chart_empty_code(self): method test_replace_output_filenames_with_temp_chart_no_png (line 161) | def test_replace_output_filenames_with_temp_chart_no_png(self): FILE: tests/unit_tests/core/code_generation/test_code_validation.py class TestCodeRequirementValidator (line 9) | class TestCodeRequirementValidator(unittest.TestCase): method setUp (line 10) | def setUp(self): method test_validate_code_without_execute_sql_query (line 15) | def test_validate_code_without_execute_sql_query(self): method test_validate_code_with_execute_sql_query (line 27) | def test_validate_code_with_execute_sql_query(self): method test_validate_code_with_function_calls (line 34) | def test_validate_code_with_function_calls(self): method test_validate_code_with_multiple_calls (line 46) | def test_validate_code_with_multiple_calls(self): FILE: tests/unit_tests/core/prompts/test_base.py class TestBasePrompt (line 9) | class TestBasePrompt: method test_to_json_without_context (line 10) | def test_to_json_without_context(self): method test_to_json_with_context (line 25) | def test_to_json_with_context(self): method test_render_with_variables (line 49) | def test_render_with_variables(self): method test_render_with_template_path (line 65) | def test_render_with_template_path(self): FILE: tests/unit_tests/core/prompts/test_correct_execute_sql_query_usage_error_prompt.py function test_to_json (line 10) | def test_to_json(): FILE: tests/unit_tests/core/prompts/test_correct_output_type_error_prompt.py function test_to_json (line 10) | def test_to_json(): FILE: tests/unit_tests/core/prompts/test_generate_python_code_with_sql_prompt.py function mock_context (line 9) | def mock_context(): function test_to_json (line 20) | def test_to_json(mock_context): FILE: tests/unit_tests/core/prompts/test_prompts.py class TestChatPrompts (line 19) | class TestChatPrompts(unittest.TestCase): method setUp (line 20) | def setUp(self): method test_get_chat_prompt_for_sql (line 27) | def test_get_chat_prompt_for_sql(self): method test_get_correct_error_prompt_for_sql (line 35) | def test_get_correct_error_prompt_for_sql(self): method test_get_correct_output_type_error_prompt (line 44) | def test_get_correct_output_type_error_prompt(self): FILE: tests/unit_tests/data_loader/test_duckdbmanager.py class TestDuckDBConnectionManager (line 6) | class TestDuckDBConnectionManager: method duck_db_manager (line 8) | def duck_db_manager(self): method test_connection_correct_closing_doesnt_throw (line 11) | def test_connection_correct_closing_doesnt_throw(self, duck_db_manager): method test_unregister (line 14) | def test_unregister(self, duck_db_manager, sample_df): FILE: tests/unit_tests/data_loader/test_loader.py class TestDatasetLoader (line 13) | class TestDatasetLoader: method test_load_from_local_source_valid (line 14) | def test_load_from_local_source_valid(self, sample_schema): method test_local_loader_properties (line 31) | def test_local_loader_properties(self, sample_schema): method test_load_schema_mysql_invalid_name (line 35) | def test_load_schema_mysql_invalid_name(self, mysql_schema): method test_load_from_local_source_invalid_source_type (line 47) | def test_load_from_local_source_invalid_source_type(self, sample_schema): method test_load_schema (line 54) | def test_load_schema(self, sample_schema): method test_load_schema_mysql (line 61) | def test_load_schema_mysql(self, mysql_schema): method test_load_schema_file_not_found (line 68) | def test_load_schema_file_not_found(self): method test_read_file (line 73) | def test_read_file(self, sample_schema): method test_build_dataset_csv_schema (line 87) | def test_build_dataset_csv_schema(self, sample_schema): method test_malicious_query (line 106) | def test_malicious_query(self, sample_schema): method test_runtime_error (line 111) | def test_runtime_error(self, sample_schema): method test_read_parquet_file (line 116) | def test_read_parquet_file(self, sample_schema): method test_read_parquet_file_with_mock_query_validator (line 127) | def test_read_parquet_file_with_mock_query_validator(self, sample_sche... FILE: tests/unit_tests/data_loader/test_sql_loader.py class TestSqlDatasetLoader (line 13) | class TestSqlDatasetLoader: method test_load_mysql_source (line 14) | def test_load_mysql_source(self, mysql_schema): method test_mysql_malicious_query (line 54) | def test_mysql_malicious_query(self, mysql_schema): method test_mysql_safe_query (line 82) | def test_mysql_safe_query(self, mysql_schema): method test_mysql_malicious_with_no_import (line 110) | def test_mysql_malicious_with_no_import(self, mysql_schema): FILE: tests/unit_tests/data_loader/test_transformation_schema.py function test_basic_transformation_params (line 14) | def test_basic_transformation_params(): function test_transformation_params_value_types (line 21) | def test_transformation_params_value_types(): function test_mapping_transformation (line 34) | def test_mapping_transformation(): function test_invalid_mapping_values (line 45) | def test_invalid_mapping_values(): function test_optional_params_defaults (line 57) | def test_optional_params_defaults(): function test_numeric_params (line 69) | def test_numeric_params(): function test_complete_transformation (line 86) | def test_complete_transformation(): function test_schema_with_transformations (line 100) | def test_schema_with_transformations(): function test_invalid_transformation_type (line 125) | def test_invalid_transformation_type(): function test_date_range_params (line 134) | def test_date_range_params(): function test_complex_transformation_chain (line 147) | def test_complex_transformation_chain(): function test_rename_transformation (line 195) | def test_rename_transformation(): function test_rename_transformation_missing_params (line 216) | def test_rename_transformation_missing_params(): function test_column_expression_parse_error (line 234) | def test_column_expression_parse_error(): function test_incompatible_source (line 239) | def test_incompatible_source(): function test_source_or_view_error (line 257) | def test_source_or_view_error(): function test_column_must_be_defined_for_view (line 262) | def test_column_must_be_defined_for_view(): FILE: tests/unit_tests/data_loader/test_view_loader.py class TestViewDatasetLoader (line 13) | class TestViewDatasetLoader: method view_schema (line 15) | def view_schema(self): method view_schema_with_group_by (line 36) | def view_schema_with_group_by(self): method create_mock_loader (line 65) | def create_mock_loader(self, name, source_type="csv"): method test_init (line 83) | def test_init(self, view_schema): method test_get_dependencies_datasets (line 112) | def test_get_dependencies_datasets(self, view_schema): method test_get_dependencies_schemas_missing_dependency (line 134) | def test_get_dependencies_schemas_missing_dependency(self, view_schema): method test_get_dependencies_schemas_incompatible_sources (line 145) | def test_get_dependencies_schemas_incompatible_sources(self, view_sche... method test_load (line 172) | def test_load(self, view_schema): method test_execute_local_query (line 195) | def test_execute_local_query(self, view_schema): method test_execute_local_query_error (line 237) | def test_execute_local_query_error(self, view_schema): method test_execute_query_with_group_by (line 272) | def test_execute_query_with_group_by(self, view_schema_with_group_by): method test_execute_query_with_custom_fixtures (line 357) | def test_execute_query_with_custom_fixtures( FILE: tests/unit_tests/dataframe/test_dataframe.py class TestDataFrame (line 12) | class TestDataFrame: method reset_current_agent (line 14) | def reset_current_agent(self): method test_dataframe_initialization (line 19) | def test_dataframe_initialization(self, sample_dict_data, sample_df): method test_dataframe_operations (line 24) | def test_dataframe_operations(self, sample_df): method test_chat_creates_agent (line 31) | def test_chat_creates_agent(self, mock_env, mock_agent, sample_dict_da... method test_chat_creates_agent_with_sandbox (line 39) | def test_chat_creates_agent_with_sandbox( method test_chat_reuses_existing_agent (line 49) | def test_chat_reuses_existing_agent(self, sample_df): method test_follow_up_without_chat_raises_error (line 59) | def test_follow_up_without_chat_raises_error(self, sample_df): method test_follow_up_after_chat (line 63) | def test_follow_up_after_chat(self, sample_df): method test_chat_method (line 70) | def test_chat_method(self, sample_df): method test_column_hash (line 79) | def test_column_hash(self, sample_df): FILE: tests/unit_tests/dataframe/test_semantic_layer_schema.py class TestSemanticLayerSchema (line 12) | class TestSemanticLayerSchema: method test_valid_schema (line 13) | def test_valid_schema(self, raw_sample_schema): method test_valid_raw_mysql_schema (line 23) | def test_valid_raw_mysql_schema(self, raw_mysql_schema): method test_valid_raw_mysql_view_schema (line 33) | def test_valid_raw_mysql_view_schema(self, raw_mysql_view_schema): method test_invalid_name (line 40) | def test_invalid_name(self, raw_sample_schema): method test_missing_source_path (line 46) | def test_missing_source_path(self, raw_sample_schema): method test_missing_source_table (line 52) | def test_missing_source_table(self, raw_mysql_schema): method test_missing_mysql_connection (line 58) | def test_missing_mysql_connection(self, raw_mysql_schema): method test_invalid_schema_missing_name (line 64) | def test_invalid_schema_missing_name(self, raw_sample_schema): method test_invalid_column_type (line 70) | def test_invalid_column_type(self, raw_sample_schema): method test_invalid_source_type (line 76) | def test_invalid_source_type(self, raw_sample_schema): method test_valid_transformations (line 82) | def test_valid_transformations(self): method test_valid_destination (line 93) | def test_valid_destination(self): method test_invalid_destination_format (line 106) | def test_invalid_destination_format(self): method test_invalid_transformation_type (line 116) | def test_invalid_transformation_type(self): method test_is_schema_source_same_true (line 125) | def test_is_schema_source_same_true(self, raw_mysql_schema): method test_is_schema_source_same_false (line 131) | def test_is_schema_source_same_false(self, raw_mysql_schema, raw_sampl... method test_invalid_view_and_source (line 137) | def test_invalid_view_and_source(self, raw_mysql_schema): method test_invalid_source_missing_view_or_table (line 143) | def test_invalid_source_missing_view_or_table(self, raw_mysql_schema): method test_invalid_no_relation_for_view (line 149) | def test_invalid_no_relation_for_view(self, raw_mysql_view_schema): method test_invalid_duplicated_columns (line 155) | def test_invalid_duplicated_columns(self, raw_sample_schema): method test_invalid_wrong_column_format_in_view (line 161) | def test_invalid_wrong_column_format_in_view(self, raw_mysql_view_sche... method test_invalid_wrong_column_format (line 167) | def test_invalid_wrong_column_format(self, raw_sample_schema): method test_invalid_wrong_relation_format_in_view (line 173) | def test_invalid_wrong_relation_format_in_view(self, raw_mysql_view_sc... method test_invalid_uncovered_columns_in_view (line 179) | def test_invalid_uncovered_columns_in_view(self, raw_mysql_view_schema): FILE: tests/unit_tests/helpers/test_dataframe_serializer.py class TestDataframeSerializer (line 4) | class TestDataframeSerializer: method test_serialize_with_name_and_description (line 5) | def test_serialize_with_name_and_description(self, sample_df): method test_serialize_with_name_and_description_with_dialect (line 18) | def test_serialize_with_name_and_description_with_dialect(self, sample... method test_serialize_with_dataframe_long_strings (line 31) | def test_serialize_with_dataframe_long_strings(self, sample_df): FILE: tests/unit_tests/helpers/test_folder.py function test_create_chart_directory (line 12) | def test_create_chart_directory(): FILE: tests/unit_tests/helpers/test_json_encoder.py function test_convert_numpy_types (line 23) | def test_convert_numpy_types(input_value, expected_output): function test_custom_json_encoder_numpy_types (line 29) | def test_custom_json_encoder_numpy_types(): function test_custom_json_encoder_pandas_types (line 45) | def test_custom_json_encoder_pandas_types(): function test_custom_json_encoder_unsupported_type (line 73) | def test_custom_json_encoder_unsupported_type(): function test_custom_json_encoder_datetime (line 85) | def test_custom_json_encoder_datetime(): FILE: tests/unit_tests/helpers/test_logger.py function test_verbose_setter (line 6) | def test_verbose_setter(): function test_save_logs_property (line 43) | def test_save_logs_property(): function test_save_logs_property (line 63) | def test_save_logs_property(): FILE: tests/unit_tests/helpers/test_optional_dependency.py function test_import_optional (line 14) | def test_import_optional(): function test_xlrd_version_fallback (line 25) | def test_xlrd_version_fallback(): function test_env_for_necessary_deps (line 30) | def test_env_for_necessary_deps(): FILE: tests/unit_tests/helpers/test_responses.py class TestResponseParser (line 19) | class TestResponseParser(unittest.TestCase): method setUpClass (line 21) | def setUpClass(cls): method test_parse_valid_number (line 24) | def test_parse_valid_number(self): method test_parse_valid_string (line 32) | def test_parse_valid_string(self): method test_parse_valid_dataframe (line 40) | def test_parse_valid_dataframe(self): method test_parse_valid_plot (line 50) | def test_parse_valid_plot(self): method test_plot_img_show_triggered (line 58) | def test_plot_img_show_triggered(self): method test_parse_with_last_code_executed (line 81) | def test_parse_with_last_code_executed(self): method test_parse_invalid_type (line 90) | def test_parse_invalid_type(self): method test_parse_missing_type (line 95) | def test_parse_missing_type(self): method test_parse_missing_value (line 100) | def test_parse_missing_value(self): method test_validate_invalid_number_type (line 105) | def test_validate_invalid_number_type(self): method test_validate_invalid_string_type (line 110) | def test_validate_invalid_string_type(self): method test_validate_invalid_dataframe_type (line 115) | def test_validate_invalid_dataframe_type(self): method test_validate_invalid_plot_type (line 120) | def test_validate_invalid_plot_type(self): method test_validate_plot_with_base64 (line 125) | def test_validate_plot_with_base64(self): method test_validate_valid_plot_path (line 129) | def test_validate_valid_plot_path(self): method test_get_base64_image (line 134) | def test_get_base64_image(self, mock_image_open): FILE: tests/unit_tests/helpers/test_session.py function test_session_init_without_api_key (line 13) | def test_session_init_without_api_key(): function test_session_init_with_none_api_key (line 24) | def test_session_init_with_none_api_key(): function test_session_init_with_api_key (line 35) | def test_session_init_with_api_key(): function test_session_init_with_default_api_url (line 42) | def test_session_init_with_default_api_url(): function test_session_init_with_custom_api_url (line 49) | def test_session_init_with_custom_api_url(): function test_session_init_with_env_api_key (line 57) | def test_session_init_with_env_api_key(): function test_session_init_with_env_api_url (line 67) | def test_session_init_with_env_api_url(): function test_get_PandasAI_session_without_credentials (line 74) | def test_get_PandasAI_session_without_credentials(): function test_get_PandasAI_session_with_default_api_url (line 85) | def test_get_PandasAI_session_with_default_api_url(): function test_get_PandasAI_session_with_env_credentials (line 96) | def test_get_PandasAI_session_with_env_credentials(): function test_get_PandasAI_session_with_env_api_url (line 108) | def test_get_PandasAI_session_with_env_api_url(): function test_make_request_success (line 116) | def test_make_request_success(mock_request): function test_make_request_error_response (line 143) | def test_make_request_error_response(mock_request): function test_make_request_network_error (line 158) | def test_make_request_network_error(mock_request): function test_make_request_custom_headers (line 171) | def test_make_request_custom_headers(mock_request): FILE: tests/unit_tests/helpers/test_sql_sanitizer.py class TestSqlSanitizer (line 9) | class TestSqlSanitizer: method test_sanitize_file_name_valid (line 10) | def test_sanitize_file_name_valid(self): method test_sanitize_file_name_special_characters (line 15) | def test_sanitize_file_name_special_characters(self): method test_sanitize_file_name_long_name (line 20) | def test_sanitize_file_name_long_name(self): method test_sanitize_relation_name_valid (line 26) | def test_sanitize_relation_name_valid(self): method test_safe_select_query (line 31) | def test_safe_select_query(self): method test_safe_with_query (line 35) | def test_safe_with_query(self): method test_unsafe_insert_query (line 39) | def test_unsafe_insert_query(self): method test_unsafe_update_query (line 43) | def test_unsafe_update_query(self): method test_unsafe_delete_query (line 47) | def test_unsafe_delete_query(self): method test_unsafe_drop_query (line 51) | def test_unsafe_drop_query(self): method test_unsafe_alter_query (line 55) | def test_unsafe_alter_query(self): method test_unsafe_create_query (line 59) | def test_unsafe_create_query(self): method test_safe_select_with_comment (line 63) | def test_safe_select_with_comment(self): method test_safe_select_with_inline_comment (line 67) | def test_safe_select_with_inline_comment(self): method test_unsafe_query_with_subquery (line 71) | def test_unsafe_query_with_subquery(self): method test_unsafe_query_with_subquery_insert (line 75) | def test_unsafe_query_with_subquery_insert(self): method test_invalid_sql (line 81) | def test_invalid_sql(self): method test_safe_query_with_multiple_keywords (line 85) | def test_safe_query_with_multiple_keywords(self): method test_safe_query_with_subquery (line 89) | def test_safe_query_with_subquery(self): method test_safe_query_with_query_params (line 95) | def test_safe_query_with_query_params(self): method test_plain_text (line 99) | def test_plain_text(self): method test_sql_queries (line 104) | def test_sql_queries(self): method test_case_insensitivity (line 112) | def test_case_insensitivity(self): method test_edge_cases (line 119) | def test_edge_cases(self): method test_mixed_input (line 127) | def test_mixed_input(self): FILE: tests/unit_tests/llms/test_base_llm.py class TestBaseLLM (line 10) | class TestBaseLLM: method test_type (line 13) | def test_type(self): method test_is_pandasai_llm (line 17) | def test_is_pandasai_llm(self): method test_polish_code (line 20) | def test_polish_code(self): method test_is_python_code (line 34) | def test_is_python_code(self): method test_extract_code (line 48) | def test_extract_code(self): method test_get_system_prompt_empty_memory (line 106) | def test_get_system_prompt_empty_memory(self): method test_get_system_prompt_memory_with_agent_description (line 109) | def test_get_system_prompt_memory_with_agent_description(self): method test_get_system_prompt_memory_with_agent_description_messages (line 113) | def test_get_system_prompt_memory_with_agent_description_messages(self): method test_prepend_system_prompt_with_empty_mem (line 124) | def test_prepend_system_prompt_with_empty_mem(self): method test_prepend_system_prompt_with_non_empty_mem (line 127) | def test_prepend_system_prompt_with_non_empty_mem(self): method test_prepend_system_prompt_with_memory_none (line 137) | def test_prepend_system_prompt_with_memory_none(self): FILE: tests/unit_tests/prompts/test_sql_prompt.py class TestGeneratePythonCodeWithSQLPrompt (line 16) | class TestGeneratePythonCodeWithSQLPrompt: method test_str_with_args (line 44) | def test_str_with_args(self, output_type, output_type_template): FILE: tests/unit_tests/query_builders/test_group_by.py class TestGroupByQueries (line 16) | class TestGroupByQueries(unittest.TestCase): method setUp (line 17) | def setUp(self): method test_base_query_builder (line 77) | def test_base_query_builder(self): method test_local_query_builder (line 94) | def test_local_query_builder(self): method test_sql_query_builder (line 118) | def test_sql_query_builder(self): method test_invalid_group_by (line 135) | def test_invalid_group_by(self): method test_no_group_by (line 169) | def test_no_group_by(self): FILE: tests/unit_tests/query_builders/test_paginator.py class TestPaginationParams (line 10) | class TestPaginationParams: method test_valid_pagination_params (line 11) | def test_valid_pagination_params(self): method test_invalid_page_number (line 28) | def test_invalid_page_number(self): method test_invalid_page_size (line 34) | def test_invalid_page_size(self): method test_invalid_sort_order (line 40) | def test_invalid_sort_order(self): method test_sql_injection_prevention (line 46) | def test_sql_injection_prevention(self): class TestDatasetPaginator (line 53) | class TestDatasetPaginator: method sample_query (line 55) | def sample_query(self): method sample_columns (line 59) | def sample_columns(self): method test_basic_pagination (line 70) | def test_basic_pagination(self, sample_query, sample_columns): method test_search_string_column (line 79) | def test_search_string_column(self, sample_query, sample_columns): method test_search_numeric_columns (line 89) | def test_search_numeric_columns(self, sample_query, sample_columns): method test_search_datetime (line 100) | def test_search_datetime(self, sample_query, sample_columns): method test_filters (line 115) | def test_filters(self, sample_query, sample_columns): method test_sorting (line 129) | def test_sorting(self, sample_query, sample_columns): method test_invalid_sort_column (line 139) | def test_invalid_sort_column(self, sample_query, sample_columns): method test_type_validation_methods (line 148) | def test_type_validation_methods(self): method test_no_pagination (line 172) | def test_no_pagination(self, sample_query, sample_columns): method test_boolean_search (line 180) | def test_boolean_search(self, sample_query, sample_columns): method test_uuid_search (line 189) | def test_uuid_search(self, sample_query, sample_columns): method test_filter_single_value (line 199) | def test_filter_single_value(self, sample_query, sample_columns): method test_invalid_json_filter (line 212) | def test_invalid_json_filter(self, sample_query, sample_columns): method test_combined_functionality (line 219) | def test_combined_functionality(self, sample_query, sample_columns): FILE: tests/unit_tests/query_builders/test_query_builder.py class TestQueryBuilder (line 15) | class TestQueryBuilder: method mysql_schema (line 17) | def mysql_schema(self): method test_build_query_csv (line 54) | def test_build_query_csv(self, sample_schema): method test_build_query_csv_with_transformation (line 76) | def test_build_query_csv_with_transformation(self, raw_sample_schema): method test_build_query_parquet (line 106) | def test_build_query_parquet(self, sample_schema): method test_build_query (line 129) | def test_build_query(self, mysql_schema): method test_build_query_with_transformation (line 144) | def test_build_query_with_transformation(self, raw_mysql_schema): method test_build_query_invalid (line 167) | def test_build_query_invalid(self, mysql_schema): method test_build_query_without_order_by (line 176) | def test_build_query_without_order_by(self, mysql_schema): method test_build_query_without_limit (line 183) | def test_build_query_without_limit(self, mysql_schema): method test_build_query_with_multiple_order_by (line 198) | def test_build_query_with_multiple_order_by(self, mysql_schema): method test_table_name_injection (line 215) | def test_table_name_injection(self, mysql_schema): method test_column_name_injection (line 230) | def test_column_name_injection(self, mysql_schema): method test_table_name_union_injection (line 245) | def test_table_name_union_injection(self, mysql_schema): method test_column_name_union_injection (line 260) | def test_column_name_union_injection(self, mysql_schema): method test_table_name_comment_injection (line 277) | def test_table_name_comment_injection(self, mysql_schema): method test_column_name_comment_injection (line 292) | def test_column_name_comment_injection(self, mysql_schema): method test_table_name_stacked_query_injection (line 307) | def test_table_name_stacked_query_injection(self, mysql_schema): method test_table_name_batch_injection (line 322) | def test_table_name_batch_injection(self, mysql_schema): method test_table_name_time_based_injection (line 337) | def test_table_name_time_based_injection(self, mysql_schema): method test_order_by_injection (line 362) | def test_order_by_injection(self, injection, mysql_schema): method test_build_query_distinct (line 368) | def test_build_query_distinct(self, sample_schema): method test_build_query_distinct_head (line 376) | def test_build_query_distinct_head(self, sample_schema): method test_build_query_order_by (line 384) | def test_build_query_order_by(self, sample_schema): method test_get_group_by_columns (line 390) | def test_get_group_by_columns(self, sample_schema): FILE: tests/unit_tests/query_builders/test_sql_parser.py class TestSqlParser (line 7) | class TestSqlParser: method test_replace_table_names (line 80) | def test_replace_table_names(query, table_mapping, expected): method test_mysql_transpilation (line 84) | def test_mysql_transpilation(self): method test_extract_table_names (line 134) | def test_extract_table_names(sql_query, dialect, expected_tables): FILE: tests/unit_tests/query_builders/test_sql_transformation_manager.py function validate_sql (line 17) | def validate_sql(sql: str) -> bool: function test_anonymize_transformation (line 26) | def test_anonymize_transformation(): function test_fill_na_transformation (line 34) | def test_fill_na_transformation(): function test_map_values_transformation (line 42) | def test_map_values_transformation(): function test_to_lowercase_transformation (line 54) | def test_to_lowercase_transformation(): function test_round_numbers_transformation (line 62) | def test_round_numbers_transformation(): function test_format_date_transformation (line 72) | def test_format_date_transformation(): function test_normalize_transformation (line 82) | def test_normalize_transformation(): function test_multiple_transformations (line 90) | def test_multiple_transformations(): function test_no_transformations (line 101) | def test_no_transformations(): function test_invalid_transformation_type (line 108) | def test_invalid_transformation_type(): function test_bin_transformation (line 113) | def test_bin_transformation(): function test_clip_transformation (line 132) | def test_clip_transformation(): function test_to_uppercase_transformation (line 142) | def test_to_uppercase_transformation(): function test_truncate_transformation (line 150) | def test_truncate_transformation(): function test_scale_transformation (line 158) | def test_scale_transformation(): function test_standardize_transformation (line 166) | def test_standardize_transformation(): function test_convert_timezone_transformation (line 174) | def test_convert_timezone_transformation(): function test_strip_transformation (line 185) | def test_strip_transformation(): function test_to_numeric_transformation (line 193) | def test_to_numeric_transformation(): function test_to_datetime_transformation (line 201) | def test_to_datetime_transformation(): function test_replace_transformation (line 211) | def test_replace_transformation(): function test_extract_transformation (line 221) | def test_extract_transformation(): function test_pad_transformation (line 231) | def test_pad_transformation(): function test_validate_email_transformation (line 249) | def test_validate_email_transformation(): function test_validate_date_range_transformation (line 257) | def test_validate_date_range_transformation(): function test_normalize_phone_transformation (line 271) | def test_normalize_phone_transformation(): function test_remove_duplicates_transformation (line 281) | def test_remove_duplicates_transformation(): function test_validate_foreign_key_transformation (line 306) | def test_validate_foreign_key_transformation(): function test_ensure_positive_transformation (line 320) | def test_ensure_positive_transformation(): function test_standardize_categories_transformation (line 328) | def test_standardize_categories_transformation(): function test_rename_transformation (line 340) | def test_rename_transformation(): FILE: tests/unit_tests/query_builders/test_view_query_builder.py class TestViewQueryBuilder (line 14) | class TestViewQueryBuilder: method view_query_builder (line 16) | def view_query_builder(self, mysql_view_schema, mysql_view_dependencie... method _create_mock_loader (line 19) | def _create_mock_loader(self, table_name): method test__init__ (line 42) | def test__init__(self, mysql_view_schema, mysql_view_dependencies_dict): method test_build_query (line 49) | def test_build_query(self, view_query_builder): method test_build_query_distinct (line 81) | def test_build_query_distinct(self, view_query_builder): method test_build_query_distinct_head (line 88) | def test_build_query_distinct_head(self, view_query_builder): method test_build_query_order_by (line 95) | def test_build_query_order_by(self, view_query_builder): method test_build_query_limit (line 100) | def test_build_query_limit(self, view_query_builder): method test_get_columns (line 105) | def test_get_columns(self, view_query_builder): method test_get__group_by_columns (line 112) | def test_get__group_by_columns(self, view_query_builder): method test_get_table_expression (line 117) | def test_get_table_expression(self, view_query_builder): method test_table_name_injection (line 145) | def test_table_name_injection(self, view_query_builder): method test_column_name_injection (line 178) | def test_column_name_injection(self, view_query_builder): method test_table_name_union_injection (line 211) | def test_table_name_union_injection(self, view_query_builder): method test_column_name_union_injection (line 244) | def test_column_name_union_injection(self, view_query_builder): method test_table_name_comment_injection (line 279) | def test_table_name_comment_injection(self, view_query_builder): method test_multiple_joins_same_table (line 312) | def test_multiple_joins_same_table(self): method test_multiple_joins_same_table_with_aliases (line 366) | def test_multiple_joins_same_table_with_aliases(self): method test_three_table_join (line 422) | def test_three_table_join(self, mysql_view_dependencies_dict): method test_column_name_comment_injection (line 477) | def test_column_name_comment_injection(self, view_query_builder): FILE: tests/unit_tests/response/test_chart_response.py function sample_base64_image (line 11) | def sample_base64_image(): function chart_response (line 21) | def chart_response(sample_base64_image): function test_chart_response_initialization (line 25) | def test_chart_response_initialization(chart_response): function test_get_image_from_base64 (line 30) | def test_get_image_from_base64(chart_response): function test_get_image_from_file (line 36) | def test_get_image_from_file(tmp_path): function test_save_image (line 48) | def test_save_image(chart_response, tmp_path): function test_str_representation (line 59) | def test_str_representation(chart_response, monkeypatch): FILE: tests/unit_tests/response/test_dataframe_response.py function test_dataframe_response_initialization (line 7) | def test_dataframe_response_initialization(sample_df): function test_dataframe_response_minimal (line 15) | def test_dataframe_response_minimal(): function test_dataframe_response_with_dict (line 24) | def test_dataframe_response_with_dict(sample_dict_data): function test_dataframe_response_with_existing_dataframe (line 32) | def test_dataframe_response_with_existing_dataframe(sample_df): function test_format_value_with_dict (line 39) | def test_format_value_with_dict(sample_dict_data): function test_format_value_with_dataframe (line 46) | def test_format_value_with_dataframe(sample_df): FILE: tests/unit_tests/response/test_error_response.py function test_error_response_initialization (line 4) | def test_error_response_initialization(): function test_error_response_minimal (line 14) | def test_error_response_minimal(): function test_error_response_with_only_value (line 25) | def test_error_response_with_only_value(): function test_error_response_with_non_string_value (line 33) | def test_error_response_with_non_string_value(): function test_error_response_format_alignment (line 41) | def test_error_response_format_alignment(): function test_error_response_format_with_fstring (line 48) | def test_error_response_format_with_fstring(): FILE: tests/unit_tests/response/test_number_response.py function test_number_response_initialization (line 4) | def test_number_response_initialization(): function test_number_response_minimal (line 11) | def test_number_response_minimal(): function test_number_response_with_float (line 18) | def test_number_response_with_float(): function test_number_response_with_string_number (line 25) | def test_number_response_with_string_number(): function test_number_response_format_decimal (line 31) | def test_number_response_format_decimal(): function test_number_response_format_with_fstring (line 38) | def test_number_response_format_with_fstring(): function test_number_response_format_function (line 45) | def test_number_response_format_function(): function test_number_response_format_scientific (line 51) | def test_number_response_format_scientific(): function test_number_response_format_percentage (line 57) | def test_number_response_format_percentage(): function test_number_response_format_padding (line 63) | def test_number_response_format_padding(): function test_number_response_format_integer (line 70) | def test_number_response_format_integer(): function test_number_response_format_with_str_format (line 76) | def test_number_response_format_with_str_format(): FILE: tests/unit_tests/response/test_string_response.py function test_string_response_initialization (line 4) | def test_string_response_initialization(): function test_string_response_minimal (line 11) | def test_string_response_minimal(): function test_string_response_with_non_string_value (line 18) | def test_string_response_with_non_string_value(): function test_string_response_format_alignment (line 25) | def test_string_response_format_alignment(): function test_string_response_format_with_fstring (line 33) | def test_string_response_format_with_fstring(): function test_string_response_format_function (line 40) | def test_string_response_format_function(): function test_string_response_format_truncate (line 46) | def test_string_response_format_truncate(): function test_string_response_format_with_str_format (line 52) | def test_string_response_format_with_str_format(): FILE: tests/unit_tests/sandbox/test_sandbox.py class TestSandbox (line 7) | class TestSandbox(unittest.TestCase): method setUp (line 8) | def setUp(self): method test_start (line 26) | def test_start(self): method test_stop (line 31) | def test_stop(self): method test_execute_calls_start_if_not_started (line 37) | def test_execute_calls_start_if_not_started(self): method test_execute_does_not_call_start_if_already_started (line 45) | def test_execute_does_not_call_start_if_already_started(self): method test_transfer_file (line 57) | def test_transfer_file(self): method test_extract_sql_queries (line 61) | def test_extract_sql_queries(self): method test_extract_single_sql_queries (line 71) | def test_extract_single_sql_queries(self): method test_compile_code_valid (line 79) | def test_compile_code_valid(self): method test_compile_code_invalid (line 84) | def test_compile_code_invalid(self): method test_not_implemented_methods (line 90) | def test_not_implemented_methods(self): FILE: tests/unit_tests/skills/test_shared_template.py class TestSharedTemplate (line 15) | class TestSharedTemplate: method setup_method (line 18) | def setup_method(self): method get_template_environment (line 23) | def get_template_environment(self): method test_shared_template_without_skills (line 35) | def test_shared_template_without_skills(self): method test_shared_template_with_skills (line 57) | def test_shared_template_with_skills(self): method test_shared_template_formatting (line 92) | def test_shared_template_formatting(self): method test_shared_template_conditional_rendering (line 129) | def test_shared_template_conditional_rendering(self): method test_shared_template_skill_string_formatting (line 163) | def test_shared_template_skill_string_formatting(self): method test_shared_template_multiple_skills_order (line 187) | def test_shared_template_multiple_skills_order(self): method test_shared_template_no_extra_newlines (line 230) | def test_shared_template_no_extra_newlines(self): FILE: tests/unit_tests/skills/test_skill.py class TestSkill (line 13) | class TestSkill: method setup_method (line 16) | def setup_method(self): method test_skill_creation_with_function (line 23) | def test_skill_creation_with_function(self): method test_skill_creation_with_custom_name (line 37) | def test_skill_creation_with_custom_name(self): method test_skill_creation_with_custom_description (line 50) | def test_skill_creation_with_custom_description(self): method test_skill_creation_without_docstring_raises_error (line 63) | def test_skill_creation_without_docstring_raises_error(self): method test_skill_creation_with_empty_docstring_raises_error (line 72) | def test_skill_creation_with_empty_docstring_raises_error(self): method test_skill_creation_with_lambda_requires_name (line 81) | def test_skill_creation_with_lambda_requires_name(self): method test_skill_creation_with_lambda_and_name (line 88) | def test_skill_creation_with_lambda_and_name(self): method test_skill_call (line 98) | def test_skill_call(self): method test_skill_string_representation (line 113) | def test_skill_string_representation(self): method test_skill_stringify (line 128) | def test_skill_stringify(self): method test_skill_from_function_classmethod (line 141) | def test_skill_from_function_classmethod(self): method test_skill_with_parameters (line 154) | def test_skill_with_parameters(self): method test_skill_inherits_from_basemodel (line 167) | def test_skill_inherits_from_basemodel(self): method test_skill_private_attr_initialization (line 180) | def test_skill_private_attr_initialization(self): FILE: tests/unit_tests/skills/test_skill_decorator.py class TestSkillDecorator (line 16) | class TestSkillDecorator: method setup_method (line 19) | def setup_method(self): method test_skill_decorator_without_arguments (line 24) | def test_skill_decorator_without_arguments(self): method test_skill_decorator_with_custom_name (line 42) | def test_skill_decorator_with_custom_name(self): method test_skill_decorator_with_parentheses (line 60) | def test_skill_decorator_with_parentheses(self): method test_skill_decorator_multiple_skills (line 78) | def test_skill_decorator_multiple_skills(self): method test_skill_decorator_with_parameters (line 110) | def test_skill_decorator_with_parameters(self): method test_skill_decorator_calling_function (line 126) | def test_skill_decorator_calling_function(self): method test_skill_decorator_without_docstring_raises_error (line 138) | def test_skill_decorator_without_docstring_raises_error(self): method test_skill_decorator_too_many_arguments_raises_error (line 146) | def test_skill_decorator_too_many_arguments_raises_error(self): method test_skill_decorator_duplicate_names_raises_error (line 155) | def test_skill_decorator_duplicate_names_raises_error(self): method test_skill_decorator_string_representation (line 173) | def test_skill_decorator_string_representation(self): method test_skill_decorator_stringify (line 187) | def test_skill_decorator_stringify(self): FILE: tests/unit_tests/skills/test_skills_integration.py class TestSkillsIntegration (line 17) | class TestSkillsIntegration: method setup_method (line 20) | def setup_method(self): method test_skill_decorator_auto_registration (line 25) | def test_skill_decorator_auto_registration(self): method test_agent_state_includes_skills (line 41) | def test_agent_state_includes_skills(self): method test_skills_available_in_templates (line 70) | def test_skills_available_in_templates(self): method test_skills_work_with_different_function_signatures (line 99) | def test_skills_work_with_different_function_signatures(self): method test_skills_clear_and_rebuild (line 129) | def test_skills_clear_and_rebuild(self): method test_skills_with_complex_descriptions (line 165) | def test_skills_with_complex_descriptions(self): method test_skills_error_handling (line 194) | def test_skills_error_handling(self): FILE: tests/unit_tests/skills/test_skills_manager.py class TestSkillsManager (line 13) | class TestSkillsManager: method setup_method (line 16) | def setup_method(self): method test_initial_state (line 21) | def test_initial_state(self): method test_add_single_skill (line 26) | def test_add_single_skill(self): method test_add_multiple_skills (line 40) | def test_add_multiple_skills(self): method test_add_duplicate_skill_raises_error (line 62) | def test_add_duplicate_skill_raises_error(self): method test_skill_exists (line 79) | def test_skill_exists(self): method test_get_skill_by_func_name (line 92) | def test_get_skill_by_func_name(self): method test_get_skills_returns_copy (line 111) | def test_get_skills_returns_copy(self): method test_clear_skills (line 128) | def test_clear_skills(self): method test_string_representation (line 150) | def test_string_representation(self): method test_global_state_persistence (line 173) | def test_global_state_persistence(self): FILE: tests/unit_tests/smart_dataframe/test_smart_dataframe.py function test_smart_dataframe_init_basic (line 11) | def test_smart_dataframe_init_basic(): function test_smart_dataframe_init_with_all_params (line 26) | def test_smart_dataframe_init_with_all_params(): function test_smart_dataframe_deprecation_warning (line 50) | def test_smart_dataframe_deprecation_warning(): function test_load_df_success (line 66) | def test_load_df_success(): function test_load_df_invalid_input (line 85) | def test_load_df_invalid_input(): function test_load_smartdataframes (line 103) | def test_load_smartdataframes(): FILE: tests/unit_tests/smart_datalake/test_smart_datalake.py function sample_dataframes (line 11) | def sample_dataframes(): function test_dfs_property (line 17) | def test_dfs_property(sample_dataframes): FILE: tests/unit_tests/test_api_key_manager.py function test_set_api_key (line 9) | def test_set_api_key(): function test_get_api_key (line 22) | def test_get_api_key(): function test_get_api_key_when_none (line 34) | def test_get_api_key_when_none(): FILE: tests/unit_tests/test_cli.py function test_validate_api_key (line 10) | def test_validate_api_key(): function test_login_command (line 30) | def test_login_command(tmp_path): function test_login_command_preserves_existing_env (line 52) | def test_login_command_preserves_existing_env(tmp_path): function test_get_validated_dataset_path_valid (line 77) | def test_get_validated_dataset_path_valid(): function test_get_validated_dataset_path_invalid_format (line 84) | def test_get_validated_dataset_path_invalid_format(): function test_get_validated_dataset_path_invalid_org (line 92) | def test_get_validated_dataset_path_invalid_org(): function test_get_validated_dataset_path_invalid_dataset (line 101) | def test_get_validated_dataset_path_invalid_dataset(): function test_get_validated_dataset_path_start_with_hyphen (line 110) | def test_get_validated_dataset_path_start_with_hyphen(): function test_get_validated_dataset_path_end_with_hyphen (line 119) | def test_get_validated_dataset_path_end_with_hyphen(): function mock_dataset_loader (line 129) | def mock_dataset_loader(): function mock_project_root (line 136) | def mock_project_root(tmp_path): function test_dataset_create_command (line 145) | def test_dataset_create_command(mock_schema, mock_project_root, tmp_path): function test_dataset_create_existing (line 179) | def test_dataset_create_existing(mock_schema, mock_project_root, tmp_path): FILE: tests/unit_tests/test_config.py class TestConfigManager (line 7) | class TestConfigManager: method setup_method (line 8) | def setup_method(self): method test_config_without_llm (line 13) | def test_config_without_llm(self): method test_config_without_api_key (line 20) | def test_config_without_api_key(self): method test_update_config (line 29) | def test_update_config(self): method test_set_api_key (line 44) | def test_set_api_key(self): FILE: tests/unit_tests/test_memory.py function test_to_json_empty_memory (line 4) | def test_to_json_empty_memory(): function test_to_json_with_messages (line 9) | def test_to_json_with_messages(): function test_to_json_message_order (line 26) | def test_to_json_message_order(): function test_to_openai_messages_empty (line 44) | def test_to_openai_messages_empty(): function test_to_openai_messages_with_agent_description (line 49) | def test_to_openai_messages_with_agent_description(): function test_to_openai_messages_without_agent_description (line 63) | def test_to_openai_messages_without_agent_description(): FILE: tests/unit_tests/test_pandasai_init.py function create_test_zip (line 15) | def create_test_zip(): class TestPandasAIInit (line 22) | class TestPandasAIInit: method mysql_connection_json (line 24) | def mysql_connection_json(self): method postgresql_connection_json (line 38) | def postgresql_connection_json(self): method sqlite_connection_json (line 52) | def sqlite_connection_json(self): method test_chat_creates_agent (line 55) | def test_chat_creates_agent(self, sample_df): method test_chat_sandbox_passed_to_agent (line 60) | def test_chat_sandbox_passed_to_agent(self, sample_df): method test_chat_without_dataframes_raises_error (line 66) | def test_chat_without_dataframes_raises_error(self): method test_follow_up_without_chat_raises_error (line 70) | def test_follow_up_without_chat_raises_error(self): method test_follow_up_after_chat (line 75) | def test_follow_up_after_chat(self, sample_df): method test_chat_with_multiple_dataframes (line 82) | def test_chat_with_multiple_dataframes(self, sample_dataframes): method test_chat_with_single_dataframe (line 96) | def test_chat_with_single_dataframe(self, sample_dataframes): method test_load_valid_dataset (line 114) | def test_load_valid_dataset( method test_load_dataset_not_found (line 132) | def test_load_dataset_not_found(self, mockenviron, mock_bytes_io, mock... method test_load_missing_api_url (line 147) | def test_load_missing_api_url(self, mock_exists): method test_load_missing_not_found (line 158) | def test_load_missing_not_found(self, mock_session, mock_exists): method test_load_invalid_name (line 169) | def test_load_invalid_name(self): method test_load_with_default_api_url (line 181) | def test_load_with_default_api_url( method test_load_with_custom_api_url (line 200) | def test_load_with_custom_api_url( method test_create_valid_dataset_no_params (line 211) | def test_create_valid_dataset_no_params( method test_create_valid_dataset_group_by (line 237) | def test_create_valid_dataset_group_by( method test_create_invalid (line 253) | def test_create_invalid(self, sample_df, mock_loader_instance, mock_fi... method test_create_invalid_path_format (line 258) | def test_create_invalid_path_format(self, sample_df): method test_create_invalid_org_name (line 265) | def test_create_invalid_org_name(self, sample_df): method test_create_invalid_dataset_name (line 270) | def test_create_invalid_dataset_name(self, sample_df): method test_create_empty_org_name (line 275) | def test_create_empty_org_name(self, sample_df): method test_create_empty_dataset_name (line 282) | def test_create_empty_dataset_name(self, sample_df): method test_create_existing_dataset (line 290) | def test_create_existing_dataset(self, mock_find_project_root, sample_... method test_create_existing_directory_no_dataset (line 310) | def test_create_existing_directory_no_dataset( method test_create_valid_dataset_with_description (line 337) | def test_create_valid_dataset_with_description( method test_create_valid_dataset_with_columns (line 375) | def test_create_valid_dataset_with_columns( method test_create_dataset_wrong_columns (line 410) | def test_create_dataset_wrong_columns( method test_create_valid_dataset_with_mysql (line 428) | def test_create_valid_dataset_with_mysql( method test_create_valid_dataset_with_postgres (line 456) | def test_create_valid_dataset_with_postgres( method test_create_with_no_dataframe_and_connector (line 479) | def test_create_with_no_dataframe_and_connector( method test_create_with_no_dataframe_with_incorrect_type (line 490) | def test_create_with_no_dataframe_with_incorrect_type( method test_create_valid_view (line 498) | def test_create_valid_view( method test_config_change_after_df_creation (line 530) | def test_config_change_after_df_creation( FILE: tests/unit_tests/test_pandasai_read_excel.py class TestReadExcel (line 9) | class TestReadExcel: method test_read_excel_single_sheet_string_filepath (line 12) | def test_read_excel_single_sheet_string_filepath(self): method test_read_excel_single_sheet_bytesio_filepath (line 21) | def test_read_excel_single_sheet_bytesio_filepath(self): method test_read_excel_multi_sheet_unspecified_sheet_name_string_filepath (line 31) | def test_read_excel_multi_sheet_unspecified_sheet_name_string_filepath... method test_read_excel_multi_sheet_unspecified_sheet_name_bytesio_filepath (line 42) | def test_read_excel_multi_sheet_unspecified_sheet_name_bytesio_filepat... method test_read_excel_multi_sheet_no_sheet_name_string_filepath (line 56) | def test_read_excel_multi_sheet_no_sheet_name_string_filepath(self): method test_read_excel_multi_sheet_no_sheet_name_bytesio_filepath (line 72) | def test_read_excel_multi_sheet_no_sheet_name_bytesio_filepath(self): method test_read_excel_multi_sheet_specific_sheet_name_string_filepath (line 91) | def test_read_excel_multi_sheet_specific_sheet_name_string_filepath(se... method test_read_excel_multi_sheet_specific_sheet_name_bytesio_filepath (line 101) | def test_read_excel_multi_sheet_specific_sheet_name_bytesio_filepath(s... method test_read_excel_multi_sheet_specific_sheet_name_with_space_string_filepath (line 113) | def test_read_excel_multi_sheet_specific_sheet_name_with_space_string_... method test_read_excel_multi_sheet_specific_sheet_name_with_space_bytesio_filepath (line 125) | def test_read_excel_multi_sheet_specific_sheet_name_with_space_bytesio... method test_read_excel_multi_sheet_nonexistent_sheet_name (line 139) | def test_read_excel_multi_sheet_nonexistent_sheet_name(self): method test_read_excel_pandas_exception (line 148) | def test_read_excel_pandas_exception(self): method test_read_excel_empty_sheet_name_string (line 157) | def test_read_excel_empty_sheet_name_string(self): method test_read_excel_type_hints (line 166) | def test_read_excel_type_hints(self):