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

feat(blocks): Add pinecone and jina blocks #8401

Merged
merged 28 commits into from
Oct 24, 2024

Conversation

aarushik93
Copy link
Contributor

Background

A vector db, chunking and embeddings are the bread and butter of a lot of AI apps

Changes πŸ—οΈ

Added pincone blocks for vector DB and jina for chunking and embeddings

Testing πŸ”

Note

Only for the new autogpt platform, currently in autogpt_platform/

  • Create from scratch and execute an agent with at least 3 blocks
  • Import an agent from file upload, and confirm it executes correctly
  • Upload agent to marketplace
  • Import an agent from marketplace and confirm it executes correctly
  • Edit an agent from monitor, and confirm it executes correctly

@aarushik93 aarushik93 requested a review from a team as a code owner October 22, 2024 19:13
@aarushik93 aarushik93 requested review from ntindle and Swiftyos and removed request for a team October 22, 2024 19:13
Copy link

codiumai-pr-agent-pro bot commented Oct 22, 2024

PR Reviewer Guide πŸ”

(Review updated until commit 035fb19)

Here are some key observations to aid the review process:

⏱️ Estimated effort to review: 4 πŸ”΅πŸ”΅πŸ”΅πŸ”΅βšͺ
πŸ§ͺΒ No relevant tests
πŸ”’Β Security concerns

Sensitive information exposure:
The PR introduces new API integrations with Jina AI and Pinecone, which involve handling API keys. While the code uses SecretStr for API keys, care should be taken to ensure these keys are not logged or exposed in any way throughout the application, especially in error messages or debug outputs.

⚑ Recommended focus areas for review

Error Handling
The error handling in the run method could be improved. Currently, it only raises an exception without any specific error handling or logging.

Error Handling
The run method lacks error handling for the API request. It should handle potential exceptions and provide appropriate error messages.

Type Annotation
The run method in the PineconeQueryBlock class is missing the self parameter and its type annotation.

Copy link
Member

@ntindle ntindle left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

swap credential methods, and combine the files

autogpt_platform/backend/backend/blocks/jina_chunking.py Outdated Show resolved Hide resolved
autogpt_platform/backend/backend/blocks/pinecone.py Outdated Show resolved Hide resolved
autogpt_platform/backend/backend/blocks/pinecone_query.py Outdated Show resolved Hide resolved
@github-actions github-actions bot added platform/frontend AutoGPT Platform - Front end size/xl and removed size/l labels Oct 23, 2024
Copy link

Persistent review updated to latest commit 035fb19

@aarushik93
Copy link
Contributor Author

I'm not sure how to sort out the lockfile issue. I can't add any new libraries without deleting it and it breaks reddit with the version bump - if anyone has a suggestion lmk pls

@ntindle
Copy link
Member

ntindle commented Oct 23, 2024

I have a change incomming to the frontend providers in my PR that I think will make the frontends more clear. LMK what you think

@ntindle
Copy link
Member

ntindle commented Oct 23, 2024

Can also pull the jina extract blcok from search.py into here

aarushik93 and others added 2 commits October 24, 2024 11:22
* h

* Discard changes to autogpt_platform/backend/poetry.lock

* fix: broken dep
@github-actions github-actions bot added size/l and removed size/xl labels Oct 24, 2024
@aarushik93 aarushik93 enabled auto-merge (squash) October 24, 2024 17:18
@aarushik93 aarushik93 merged commit e2df601 into dev Oct 24, 2024
9 checks passed
@aarushik93 aarushik93 deleted the aarushikansal/set-up-rag-blocks branch October 24, 2024 20:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: βœ… Done
Development

Successfully merging this pull request may close these issues.

2 participants