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

blocks(exa): Add more Exa blocks #9097

Merged
merged 12 commits into from
Dec 20, 2024
Merged

blocks(exa): Add more Exa blocks #9097

merged 12 commits into from
Dec 20, 2024

Conversation

aarushik93
Copy link
Contributor

@aarushik93 aarushik93 commented Dec 20, 2024

Revamp the Exa search block and add two more for Content and Similarity search.

Changes 🏗️

  • Updated the exa search block input names to be snakecase not camel case
  • Added Advanced to non required fields
  • Pulled Content settings into helpers for reuse across blocks
  • Updated customnode.css to handle long inputs, especially in the case of the date input

Checklist 📋

For code changes:

  • I have clearly listed my changes in the PR description
  • I have made a test plan
  • I have tested my changes according to the test plan:
    • ...

Copy link

netlify bot commented Dec 20, 2024

Deploy Preview for auto-gpt-docs-dev canceled.

Name Link
🔨 Latest commit a9bede8
🔍 Latest deploy log https://app.netlify.com/sites/auto-gpt-docs-dev/deploys/6765774bb2610d00084df747

Copy link

netlify bot commented Dec 20, 2024

Deploy Preview for auto-gpt-docs canceled.

Name Link
🔨 Latest commit a9bede8
🔍 Latest deploy log https://app.netlify.com/sites/auto-gpt-docs/deploys/6765774ba690ae0008def843

@aarushik93 aarushik93 marked this pull request as ready for review December 20, 2024 12:31
@aarushik93 aarushik93 requested a review from a team as a code owner December 20, 2024 12:31
@aarushik93 aarushik93 requested review from Swiftyos and Pwuts and removed request for a team December 20, 2024 12:31
Copy link

PR Reviewer Guide 🔍

Here are some key observations to aid the review process:

⏱️ Estimated effort to review: 3 🔵🔵🔵⚪⚪
🧪 No relevant tests
🔒 Security concerns

API Key Exposure:
The code handles API keys through credentials.api_key.get_secret_value(). While the key is not directly exposed in logs or responses, ensure that error handling does not accidentally expose the API key in error messages or stack traces.

⚡ Recommended focus areas for review

Error Handling
The error handling in the run method could be improved. Currently it catches all exceptions generically and yields both an error and empty results. Consider handling specific exceptions separately and providing more detailed error information.

Input Validation
The include_text and exclude_text fields have constraints (max 1 string, up to 5 words) that are documented but not enforced in the code. Consider adding validation logic to ensure these constraints are met.

Code Duplication
The date and field mapping logic is duplicated across multiple blocks. Consider extracting this common functionality into a shared helper module.

@github-actions github-actions bot added the platform/frontend AutoGPT Platform - Front end label Dec 20, 2024
@aarushik93 aarushik93 changed the title Aarushikansal/add exa blocks blocks(exa): Add more Exa blocks Dec 20, 2024
Swiftyos
Swiftyos previously approved these changes Dec 20, 2024
@Swiftyos Swiftyos merged commit 54f8d3b into dev Dec 20, 2024
22 checks passed
@Swiftyos Swiftyos deleted the aarushikansal/add-exa-blocks branch December 20, 2024 13:57
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.

3 participants