Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Concatenation of list and str in retrieve_relevant_chunks.py #1015

Open
serhatgktp opened this issue Feb 24, 2025 · 1 comment
Open

Concatenation of list and str in retrieve_relevant_chunks.py #1015

serhatgktp opened this issue Feb 24, 2025 · 1 comment
Labels
status: needs info Issues that require more information from the reporter to proceed. status: needs triage New issues that have not yet been reviewed or categorized.

Comments

@serhatgktp
Copy link
Contributor

In this line of the example config for pinecone:


We see that the relevant_chunks variable is defined as a list.

In the retrieve_relevant_chunks.py file we also observe that relevant_chunks is expected to be a string, hence the attempt to concatenate it with a string.

context.get("relevant_chunks", "") + "\n"

Is the custom action in the pinecone config.py file incorrectly configured for the latest version of nemoguardrails, or should retrieve_relevant_chunks.py also account for lists when reading relevant_chunks?

@Pouyanpi
Copy link
Collaborator

Pouyanpi commented Feb 27, 2025

Hi @serhatgktp

Are you getting any specific error when following the readme?

It has been like this at least for a while

https://github.com/NVIDIA/NeMo-Guardrails/blame/v0.8.3/nemoguardrails/actions/retrieve_relevant_chunks.py

9a83ccf

@Pouyanpi Pouyanpi added status: needs triage New issues that have not yet been reviewed or categorized. status: needs info Issues that require more information from the reporter to proceed. labels Feb 27, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status: needs info Issues that require more information from the reporter to proceed. status: needs triage New issues that have not yet been reviewed or categorized.
Projects
None yet
Development

No branches or pull requests

2 participants