crewAI icon indicating copy to clipboard operation
crewAI copied to clipboard

[BUG]ImportError: `minds_sdk` package not found.

Open sunil448832 opened this issue 1 month ago • 7 comments

Description

I am using AIMindTool to connect with minds_db. but it throwing error that package is not installed even though package is there in invironment.

Steps to Reproduce

from crewai_tools import AIMindTool
import os
os.environ["MINDS_API_KEY"] = "None"

aimind_tool = AIMindTool(
    datasources=[
        {
            "description": "runs data",
            "engine": "postgres",
            "connection_data": {
                "user": "postgres",
                "password": "xxxx",
                "host": "xxxx",
                "port": 5432,
                "database": "ipdb",
                #"schema": "runs"
            },
            "tables": ["runsdev"]
        }
    ]
)

# Run a natural language query
result = aimind_tool.run("How many task get failed")
print(result)

Expected behavior

should give counts

Screenshots/Code snippets

None

Operating System

Ubuntu 24.04

Python Version

3.12

crewAI Version

1.4.1

crewAI Tools Version

1.4.1

Virtual Environment

Conda

Evidence

Traceback (most recent call last): File "/home/sunil/miniconda3/envs/mindsdb/lib/python3.13/site-packages/crewai_tools/tools/ai_mind_tool/ai_mind_tool.py", line 55, in init from minds.datasources import DatabaseConfig # type: ignore ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ImportError: cannot import name 'DatabaseConfig' from 'minds.datasources' (/home/sunil/miniconda3/envs/mindsdb/lib/python3.13/site-packages/minds/datasources/init.py)

The above exception was the direct cause of the following exception:

Traceback (most recent call last): File "/home/sunil/arias/aria-ingest-tests/minds_db.py", line 7, in aimind_tool = AIMindTool( datasources=[ ...<13 lines>... ] ) File "/home/sunil/miniconda3/envs/mindsdb/lib/python3.13/site-packages/crewai_tools/tools/ai_mind_tool/ai_mind_tool.py", line 57, in init raise ImportError( "minds_sdk package not found, please run pip install minds-sdk" ) from e ImportError: minds_sdk package not found, please run pip install minds-sdk

Possible Solution

None

Additional context

I already have minds_sdk installed.

pip show minds_sdk

Name: minds_sdk
Version: 2.0.0
Summary: An AI-Data Mind is an LLM with the built-in power to answer data questions for Agents
Home-page: https://github.com/mindsdb/minds_python_sdk
Author: MindsDB Inc
Author-email: [email protected]
License: 
Location: /home/sunil/miniconda3/envs/mindsdb/lib/python3.13/site-packages
Requires: openai, pydantic, requests
Required-by: 

sunil448832 avatar Nov 11 '25 08:11 sunil448832

I think you are right, have patched this up #3892

Vidit-Ostwal avatar Nov 11 '25 14:11 Vidit-Ostwal

I think you are right, have patched this up #3892

iirc, this causes a dependency conflict with a2a-sdk. Not 100% sure about this, but I can confirm later.

greysonlalonde avatar Nov 11 '25 16:11 greysonlalonde

I think you are right, have patched this up #3892

iirc, this causes a dependency conflict with a2a-sdk. Not 100% sure about this, but I can confirm later.

Oh, didn't knew this. Just crossed checked with creating a new virtual env, and installed crewai, crewai_tools, a2a_sdk, and minds_sdk Every package got installed with throwing any error or warnings..

Vidit-Ostwal avatar Nov 11 '25 18:11 Vidit-Ostwal

Hi, Please prioritise this.

sunil448832 avatar Nov 13 '25 05:11 sunil448832

Mind giving this feature branch a try: Just do a pip install git+https://github.com/Vidit-Ostwal/crewAI.git@vo/feat/ai-mind-tool Let me know if this works

There might be more changes into this, if there are dependency conflicts with a2a-sdk. Might have to change it back again, after the new version release.

Vidit-Ostwal avatar Nov 13 '25 05:11 Vidit-Ostwal

does it install crew ai with updated minds tool or install minds tools only?

  1. installed with existing crewai[tools], but tool code did not get updated automatically. getting same error again.
  2. removed crewai[tools] and installed above repo, got crewai not found error.

please tell me how to install it with crewai and minds-sdk

sunil448832 avatar Nov 13 '25 12:11 sunil448832

does it install crew ai with updated minds tool or install minds tools only?

  1. installed with existing crewai[tools], but tool code did not get updated automatically. getting same error again.
  2. removed crewai[tools] and installed above repo, got crewai not found error.

please tell me how to install it with crewai and minds-sdk

Oh, Can you try this pip install "git+https://github.com/Vidit-Ostwal/crewAI.git@vo/feat/ai-mind-tool#subdirectory=lib/crewai-tools "

This will just install crewai_tools library.

Vidit-Ostwal avatar Nov 13 '25 14:11 Vidit-Ostwal

This issue is stale because it has been open for 30 days with no activity. Remove stale label or comment or this will be closed in 5 days.

github-actions[bot] avatar Dec 14 '25 12:12 github-actions[bot]