mirror of
https://github.com/Significant-Gravitas/AutoGPT.git
synced 2026-01-06 22:03:59 -05:00
master
226 Commits
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
|
37b3e4e82e |
feat(blocks)!: Update Exa search block to match latest API specification (#11185)
BREAKING CHANGE: Removed deprecated use_auto_prompt field from Input
schema. Existing workflows using this field will need to be updated to
use the type field set to "auto" instead.
## Summary of Changes 📝
This PR comprehensively updates all Exa search blocks to match the
latest Exa API specification and adds significant new functionality
through the Websets API integration.
### Core API Updates 🔄
- **Migration to Exa SDK**: Replaced manual API calls with the official
`exa_py` AsyncExa SDK across all blocks for better reliability and
maintainability
- **Removed deprecated fields**: Eliminated
`use_auto_prompt`/`useAutoprompt` field (breaking change)
- **Fixed incomplete field definitions**: Corrected `user_location`
field definition
- **Added new input fields**: Added `moderation` and `context` fields
for enhanced content filtering
### Enhanced Content Settings 🛠️
- **Text field improvements**: Support both boolean and advanced object
configurations
- **New content options**:
- Added `livecrawl` settings (never, fallback, always, preferred)
- Added `subpages` support for deeper content retrieval
- Added `extras` settings for links and images
- Added `context` settings for additional contextual information
- **Updated settings**: Enhanced `highlight` and `summary`
configurations with new query and schema options
### Comprehensive Cost Tracking 💰
- Added detailed cost tracking models:
- `CostDollars` for monetary costs
- `CostCredits` for API credit tracking
- `CostDuration` for time-based costs
- New output fields: `request_id`, `resolved_search_type`,
`cost_dollars`
- Improved response handling to conditionally yield fields based on
availability
### New Websets API Integration 🚀
Added eight new specialized blocks for Exa's Websets API:
- **`websets.py`**: Core webset management (create, get, list, delete)
- **`websets_search.py`**: Search operations within websets
- **`websets_items.py`**: Individual item management (add, get, update,
delete)
- **`websets_enrichment.py`**: Data enrichment operations
- **`websets_import_export.py`**: Bulk import/export functionality
- **`websets_monitor.py`**: Monitor and track webset changes
- **`websets_polling.py`**: Poll for updates and changes
### New Special-Purpose Blocks 🎯
- **`code_context.py`**: Code search capabilities for finding relevant
code snippets from open source repositories, documentation, and Stack
Overflow
- **`research.py`**: Asynchronous research capabilities that explore the
web, gather sources, synthesize findings, and return structured results
with citations
### Code Organization Improvements 📁
- **Removed legacy code**: Deleted `model.py` file containing deprecated
API models
- **Centralized helpers**: Consolidated shared models and utilities in
`helpers.py`
- **Improved modularity**: Each webset operation is now in its own
dedicated file
### Other Changes 🔧
- Updated `.gitignore` for better development workflow
- Updated `CLAUDE.md` with project-specific instructions
- Updated documentation in `docs/content/platform/new_blocks.md` with
error handling, data models, and file input guidelines
- Improved webhook block implementations with SDK integration
### Files Changed 📂
- **Modified (11 files)**:
- `.gitignore`
- `autogpt_platform/CLAUDE.md`
- `autogpt_platform/backend/backend/blocks/exa/answers.py`
- `autogpt_platform/backend/backend/blocks/exa/contents.py`
- `autogpt_platform/backend/backend/blocks/exa/helpers.py`
- `autogpt_platform/backend/backend/blocks/exa/search.py`
- `autogpt_platform/backend/backend/blocks/exa/similar.py`
- `autogpt_platform/backend/backend/blocks/exa/webhook_blocks.py`
- `autogpt_platform/backend/backend/blocks/exa/websets.py`
- `docs/content/platform/new_blocks.md`
- **Added (8 files)**:
- `autogpt_platform/backend/backend/blocks/exa/code_context.py`
- `autogpt_platform/backend/backend/blocks/exa/research.py`
- `autogpt_platform/backend/backend/blocks/exa/websets_enrichment.py`
- `autogpt_platform/backend/backend/blocks/exa/websets_import_export.py`
- `autogpt_platform/backend/backend/blocks/exa/websets_items.py`
- `autogpt_platform/backend/backend/blocks/exa/websets_monitor.py`
- `autogpt_platform/backend/backend/blocks/exa/websets_polling.py`
- `autogpt_platform/backend/backend/blocks/exa/websets_search.py`
- **Deleted (1 file)**:
- `autogpt_platform/backend/backend/blocks/exa/model.py`
### Migration Guide 🚦
For users with existing workflows using the deprecated `use_auto_prompt`
field:
1. Remove the `use_auto_prompt` field from your input configuration
2. Set the `type` field to `ExaSearchTypes.AUTO` (or "auto" in JSON) to
achieve the same behavior
3. Review any custom content settings as the structure has been enhanced
### Testing Recommendations ✅
- Test existing workflows to ensure they handle the breaking change
- Verify cost tracking fields are properly returned
- Test new content settings options (livecrawl, subpages, extras,
context)
- Validate websets functionality if using the new Websets API blocks
🤖 Generated with [Claude Code](https://claude.com/claude-code)
### Checklist 📋
#### For code changes:
- [x] I have clearly listed my changes in the PR description
- [x] I have made a test plan
- [x] I have tested my changes according to the test plan:
- [x] made + ran a test agent for the blocks and flows between them
[Exa
Tests_v44.json](https://github.com/user-attachments/files/23226143/Exa.Tests_v44.json)
<!-- CURSOR_SUMMARY -->
---
> [!NOTE]
> Migrates Exa blocks to AsyncExa SDK, adds comprehensive
Websets/research/code-context blocks, updates existing
search/content/answers/similar, deletes legacy models, adjusts
tests/docs; breaking: remove `use_auto_prompt` in favor of
`type="auto"`.
>
> - **Backend — Exa integration (SDK migration & BREAKING)**:
> - Replace manual HTTP calls with `exa_py.AsyncExa` across `search`,
`similar`, `contents`, `answers`, and webhooks; richer outputs
(citations, context, costs, resolved search type).
> - BREAKING: remove `Input.use_auto_prompt`; use `type = "auto"`.
> - Centralize models/utilities in `exa/helpers.py` (content settings,
cost models, result mappers).
> - **New Blocks**:
> - **Websets**: management (`websets.py`), searches, items,
enrichments, imports/exports, monitors, polling (new files under
`exa/websets_*`).
> - **Research**: async research task create/get/wait/list
(`exa/research.py`).
> - **Code Context**: code snippet/context retrieval
(`exa/code_context.py`).
> - **Removals**:
> - Delete deprecated `exa/model.py`.
> - **Docs & DX**:
> - Update `docs/new_blocks.md` (error handling, models, file input) and
`CLAUDE.md`; ignore backend logs in `.gitignore`.
> - **Frontend Tests**:
> - Split/extend “e” block tests and improve block add robustness in
Playwright (`build.spec.ts`, `build.page.ts`).
>
> <sup>Written by [Cursor
Bugbot](https://cursor.com/dashboard?tab=bugbot) for commit
|
||
|
|
2f8cdf62ba |
feat(backend): Standardize error handling with BlockSchemaInput & BlockSchemaOutput base class (#11257)
<!-- Clearly explain the need for these changes: --> This PR addresses the need for consistent error handling across all blocks in the AutoGPT platform. Previously, each block had to manually define an `error` field in their output schema, leading to code duplication and potential inconsistencies. Some blocks might forget to include the error field, making error handling unpredictable. ### Changes 🏗️ <!-- Concisely describe all of the changes made in this pull request: --> - **Created `BlockSchemaOutput` base class**: New base class that extends `BlockSchema` with a standardized `error` field - **Created `BlockSchemaInput` base class**: Added for consistency and future extensibility - **Updated 140+ block implementations**: Changed all block `Output` classes from `class Output(BlockSchema):` to `class Output(BlockSchemaOutput):` - **Removed manual error field definitions**: Eliminated hundreds of duplicate `error: str = SchemaField(...)` definitions - **Updated type annotations**: Changed `Block[BlockSchema, BlockSchema]` to `Block[BlockSchemaInput, BlockSchemaOutput]` throughout the codebase - **Fixed imports**: Added `BlockSchemaInput` and `BlockSchemaOutput` imports to all relevant files - **Maintained backward compatibility**: Updated `EmptySchema` to inherit from `BlockSchemaOutput` **Key Benefits:** - Consistent error handling across all blocks - Reduced code duplication (removed ~200 lines of repetitive error field definitions) - Type safety improvements with distinct input/output schema types - Blocks can still override error field with more specific descriptions when needed ### Checklist 📋 #### For code changes: - [x] I have clearly listed my changes in the PR description - [x] I have made a test plan - [x] I have tested my changes according to the test plan: <!-- Put your test plan here: --> - [x] Verified `poetry run format` passes (all linting, formatting, and type checking) - [x] Tested block instantiation works correctly (MediaDurationBlock, UnrealTextToSpeechBlock) - [x] Confirmed error fields are automatically present in all updated blocks - [x] Verified block loading system works (successfully loads 353+ blocks) - [x] Tested backward compatibility with EmptySchema - [x] Confirmed blocks can still override error field with custom descriptions - [x] Validated core schema inheritance chain works correctly #### For configuration changes: - [x] `.env.default` is updated or already compatible with my changes - [x] `docker-compose.yml` is updated or already compatible with my changes - [x] I have included a list of my configuration changes in the PR description (under **Changes**) *Note: No configuration changes were needed for this refactoring.* 🤖 Generated with [Claude Code](https://claude.ai/code) --------- Co-authored-by: Claude <noreply@anthropic.com> Co-authored-by: Lluis Agusti <hi@llu.lu> Co-authored-by: Ubbe <hi@ubbe.dev> |
||
|
|
90af8f8e1a |
feat(backend): Add language fallback for YouTube transcription block (#11057)
## Problem The YouTube transcription block would fail when attempting to transcribe videos that only had transcripts available in non-English languages. Even when usable transcripts existed in other languages, the block would raise a `NoTranscriptFound` error because it only requested English transcripts. **Example video that would fail:** https://www.youtube.com/watch?v=3AMl5d2NKpQ (only has Hungarian transcripts) **Error message:** ``` Could not retrieve a transcript for the video https://www.youtube.com/watch?v=3AMl5d2NKpQ! No transcripts were found for any of the requested language codes: ('en',) For this video (3AMl5d2NKpQ) transcripts are available in the following languages: (GENERATED) - hu ("Hungarian (auto-generated)") ``` ## Solution Implemented intelligent language fallback in the `TranscribeYoutubeVideoBlock.get_transcript()` method: 1. **First**, tries to fetch English transcript (maintains backward compatibility) 2. **If English unavailable**, lists all available transcripts and selects the first one using this priority: - Manually created transcripts (any language) - Auto-generated transcripts (any language) 3. **Only fails** if no transcripts exist at all **Example behavior:** ```python # Before: Video with only Hungarian transcript get_transcript("3AMl5d2NKpQ") # ❌ Raises NoTranscriptFound # After: Video with only Hungarian transcript get_transcript("3AMl5d2NKpQ") # ✅ Returns Hungarian transcript ``` ## Changes - **Modified** `backend/blocks/youtube.py`: Added try-catch logic to fallback to any available language when English is not found - **Added** `test/blocks/test_youtube.py`: Comprehensive test suite covering URL extraction, language fallback, transcript preferences, and error handling (7 tests) - **Updated** `docs/content/platform/blocks/youtube.md`: Documented the language fallback behavior and transcript priority order ## Testing - ✅ All 7 new unit tests pass - ✅ Block integration test passes - ✅ Full test suite: 621 passed, 0 failed (no regressions) - ✅ Code formatting and linting pass ## Impact This fix enables the YouTube transcription block to work with international content while maintaining full backward compatibility: - ✅ Videos in any language can now be transcribed - ✅ English is still preferred when available - ✅ No breaking changes to existing functionality - ✅ Graceful degradation to available languages Fixes #10637 Fixes https://linear.app/autogpt/issue/OPEN-2626 > [!WARNING] > > <details> > <summary>Firewall rules blocked me from connecting to one or more addresses (expand for details)</summary> > > #### I tried to connect to the following addresses, but was blocked by firewall rules: > > - `www.youtube.com` > - Triggering command: `/home/REDACTED/.cache/pypoetry/virtualenvs/autogpt-platform-backend-Ajv4iu2i-py3.11/bin/python3` (dns block) > > If you need me to access, download, or install something from one of these locations, you can either: > > - Configure [Actions setup steps](https://gh.io/copilot/actions-setup-steps) to set up my environment, which run before the firewall is enabled > - Add the appropriate URLs or hosts to the custom allowlist in this repository's [Copilot coding agent settings](https://github.com/Significant-Gravitas/AutoGPT/settings/copilot/coding_agent) (admins only) > > </details> <!-- START COPILOT CODING AGENT SUFFIX --> <details> <summary>Original prompt</summary> > Issue Title: if theres only one lanague available for transcribe youtube return that langage not an error > Issue Description: `Could not retrieve a transcript for the video https://www.youtube.com/watch?v=3AMl5d2NKpQ! This is most likely caused by: No transcripts were found for any of the requested language codes: ('en',) For this video (3AMl5d2NKpQ) transcripts are available in the following languages: (MANUALLY CREATED) None (GENERATED) - hu ("Hungarian (auto-generated)") (TRANSLATION LANGUAGES) None If you are sure that the described cause is not responsible for this error and that a transcript should be retrievable, please create an issue at https://github.com/jdepoix/youtube-transcript-api/issues. Please add which version of youtube_transcript_api you are using and provide the information needed to replicate the error. Also make sure that there are no open issues which already describe your problem!` you can use this video to test: [https://www.youtube.com/watch?v=3AMl5d2NKpQ\`](https://www.youtube.com/watch?v=3AMl5d2NKpQ%60) > Fixes https://linear.app/autogpt/issue/OPEN-2626/if-theres-only-one-lanague-available-for-transcribe-youtube-return > > > Comment by User : > This thread is for an agent session with githubcopilotcodingagent. > > Comment by User : > This thread is for an agent session with githubcopilotcodingagent. > > Comment by User : > This comment thread is synced to a corresponding [GitHub issue](https://github.com/Significant-Gravitas/AutoGPT/issues/10637). All replies are displayed in both locations. > > </details> <!-- START COPILOT CODING AGENT TIPS --> --- ✨ Let Copilot coding agent [set things up for you](https://github.com/Significant-Gravitas/AutoGPT/issues/new?title=✨+Set+up+Copilot+instructions&body=Configure%20instructions%20for%20this%20repository%20as%20documented%20in%20%5BBest%20practices%20for%20Copilot%20coding%20agent%20in%20your%20repository%5D%28https://gh.io/copilot-coding-agent-tips%29%2E%0A%0A%3COnboard%20this%20repo%3E&assignees=copilot) — coding agent works faster and does higher quality work when set up for your repo. --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: ntindle <8845353+ntindle@users.noreply.github.com> Co-authored-by: Nicholas Tindle <nicholas.tindle@agpt.co> |
||
|
|
9bc9b53b99 |
fix(backend): Add channel ID support to SendDiscordMessageBlock for consistency with other Discord blocks (#11055)
## Problem
The `SendDiscordMessageBlock` only accepted channel names, while other
Discord blocks like `SendDiscordFileBlock` and `SendDiscordEmbedBlock`
accept both channel IDs and channel names. This inconsistency made it
difficult to use channel IDs with the message sending block, which is
often more reliable and direct than name-based lookup.
## Solution
Updated `SendDiscordMessageBlock` to accept both channel IDs and channel
names through the `channel_name` field, matching the implementation
pattern used in other Discord blocks.
### Changes Made
1. **Enhanced channel resolution logic** to try parsing the input as a
channel ID first, then fall back to name-based search:
```python
# Try to parse as channel ID first
try:
channel_id = int(channel_name)
channel = client.get_channel(channel_id)
except ValueError:
# Not an ID, treat as channel name
# ... search guilds for matching channel name
```
2. **Updated field descriptions** to clarify the dual functionality:
- `channel_name`: Now describes that it accepts "Channel ID or channel
name"
- `server_name`: Clarified as "only needed if using channel name"
3. **Added type checking** to ensure the resolved channel can send
messages before attempting to send
4. **Updated documentation** to reflect the new capability
## Backward Compatibility
✅ **Fully backward compatible**: The field name remains `channel_name`
(not renamed), and all existing workflows using channel names will
continue to work exactly as before.
✅ **New capability**: Users can now also provide channel IDs (e.g.,
`"123456789012345678"`) for more direct channel targeting.
## Testing
- All existing tests pass, including `SendDiscordMessageBlock` and all
other Discord block tests
- Implementation verified to match the pattern used in
`SendDiscordFileBlock` and `SendDiscordEmbedBlock`
- Code passes all linting, formatting, and type checking
Fixes https://github.com/Significant-Gravitas/AutoGPT/issues/10909
<!-- START COPILOT CODING AGENT SUFFIX -->
<details>
<summary>Original prompt</summary>
> Issue Title: SendDiscordMessage needs to take a channel id as an
option under channelname the same as the other discord blocks
> Issue Description: with how we can process the other discord blocks we
should do the same here with the identifiers being allowed to be a
channel name or id. we can't rename the field though or that will break
backwards compatibility
> Fixes
https://linear.app/autogpt/issue/OPEN-2701/senddiscordmessage-needs-to-take-a-channel-id-as-an-option-under
>
>
> Comment by User :
> This thread is for an agent session with githubcopilotcodingagent.
>
> Comment by User :
> This thread is for an agent session with githubcopilotcodingagent.
>
> Comment by User 055a3053-5ab6-449a-bcfa-990768594185:
> the ones with boxes around them need confirmed for lables but yeah its
related but not dupe
>
> Comment by User 264d7bf4-db2a-46fa-a880-7d67b58679e6:
> this might be a duplicate since there is a related ticket but not sure
>
> Comment by User :
> This comment thread is synced to a corresponding [GitHub
issue](https://github.com/Significant-Gravitas/AutoGPT/issues/10909).
All replies are displayed in both locations.
>
>
</details>
<!-- START COPILOT CODING AGENT TIPS -->
---
💬 Share your feedback on Copilot coding agent for the chance to win a
$200 gift card! Click
[here](https://survey3.medallia.com/?EAHeSx-AP01bZqG0Ld9QLQ) to start
the survey.
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit
* New Features
* Send Discord Message block now accepts a channel ID in addition to
channel name.
* Server name is only required when using a channel name.
* Improved channel detection and validation with clearer errors if the
channel isn’t found.
* Documentation
* Updated block documentation to reflect support for channel ID or name
and clarify when server name is needed.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: ntindle <8845353+ntindle@users.noreply.github.com>
Co-authored-by: claude[bot] <41898282+claude[bot]@users.noreply.github.com>
Co-authored-by: Nicholas Tindle <ntindle@users.noreply.github.com>
Co-authored-by: Bently <Github@bentlybro.com>
|
||
|
|
c5b90f7b09 |
feat(platform): Simplify running of core docker services (#11113)
Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com> |
||
|
|
4663066e65 |
feat(blocks): Implement AI Condition Block for natural language condition evaluation (#10996)
This PR implements the AI Condition Block as requested in issue
AUTOMAT-60. The new block enables users to define conditional logic
using natural language descriptions instead of traditional comparison
operators, while maintaining the same yes/no data pass-through
functionality as the existing ConditionBlock.
## Overview
The AI Condition Block uses Large Language Models to evaluate conditions
written in plain English, such as:
- "the input is the body of an email"
- "the input is a City in the USA"
- "the input is an error or a refusal"
## Key Features
**Natural Language Processing**: Users can express complex conditions in
everyday English rather than programming logic, making agent workflows
more intuitive and accessible.
**Consistent Interface**: Maintains the same input/output schema as the
standard ConditionBlock:
- Boolean `result` output indicating condition evaluation
- `yes_output` and `no_output` for conditional data flow
- Optional custom values for yes/no cases
**Robust Error Handling**: Defaults to `false` on AI evaluation failures
to ensure safe operation and prevent workflow interruption.
**Performance Optimized**: Uses minimal token limits (10 tokens) for
true/false responses to reduce latency and API costs.
## Implementation Details
The block is implemented as `AIConditionBlock` in
`backend/blocks/ai_condition.py` and inherits from `AIBlockBase`
following established platform patterns. It includes:
- Proper LLM integration with credential management
- Token usage tracking and statistics
- Comprehensive test mocking for reliable CI/CD
- Full documentation with examples and use cases
## Use Cases
This block enables more sophisticated conditional logic for:
- **Content Classification**: Automatically categorize text, emails, or
documents
- **Data Validation**: Validate inputs using natural language rules
- **Smart Routing**: Route data based on AI-evaluated conditions
- **Error Detection**: Identify and handle error messages or problematic
inputs
- **Quality Control**: Check content against flexible quality standards
## Testing
The implementation includes comprehensive testing that integrates with
the existing platform test suite. All tests pass, including:
- Unit tests with proper LLM response mocking
- Code quality checks (linting, formatting, type checking)
- Security analysis via CodeQL
- Integration testing to ensure proper block discovery and loading
The block is automatically discovered by the platform's block loading
system and is immediately available for use in agent workflows.
## PR Checklist
- [x] **Have you listed your changes in the description?**
- Added new `AIConditionBlock` in `backend/blocks/ai_condition.py`
- Added comprehensive documentation in
`docs/content/platform/blocks/ai_condition.md`
- Implemented natural language condition evaluation using LLMs
- [x] **Have you included a test plan?**
- Unit tests with mocked LLM responses
- Integration tests for block discovery and loading
- Error handling validation
- Token usage tracking verification
- [x] **Have you tested your changes according to the test plan?**
- All existing tests pass
- Linting and formatting checks pass
- Type checking passes
- Security analysis via CodeQL passes
- Fixed `json_format` parameter to `force_json_output` per recent API
changes
> [!WARNING]
>
> <details>
> <summary>Firewall rules blocked me from connecting to one or more
addresses (expand for details)</summary>
>
> #### I tried to connect to the following addresses, but was blocked by
firewall rules:
>
> - `api.openai.com`
> - Triggering command:
`/home/REDACTED/.cache/pypoetry/virtualenvs/autogpt-platform-backend-Ajv4iu2i-py3.11/bin/python
/home/REDACTED/.cache/pypoetry/virtualenvs/autogpt-platform-backend-Ajv4iu2i-py3.11/bin/pytest
backend/blocks/test/test_block.py::test_available_blocks -k
AIConditionBlock -v` (dns block)
> -
`https://api.github.com/repos/Significant-Gravitas/Significant-Gravitas%2FAutoGPT/languages`
> - Triggering command:
`/home/REDACTED/work/_temp/ghcca-node/node/bin/node --enable-source-maps
/home/REDACTED/work/_temp/copilot-developer-action-main/dist/index.js`
(http block)
>
> If you need me to access, download, or install something from one of
these locations, you can either:
>
> - Configure [Actions setup
steps](https://gh.io/copilot/actions-setup-steps) to set up my
environment, which run before the firewall is enabled
> - Add the appropriate URLs or hosts to the custom allowlist in this
repository's [Copilot coding agent
settings](https://github.com/Significant-Gravitas/AutoGPT/settings/copilot/coding_agent)
(admins only)
>
> </details>
<!-- START COPILOT CODING AGENT SUFFIX -->
<details>
<summary>Original prompt</summary>
> Issue Title: AI Condition Block
> Issue Description: A version of the condition/if block that uses an AI
powered condition.
>
> It should have the same yes/no data pass throughs, as well as
outputting a result Boolean.
>
> The condition is plaintext English, provided by the user, and could be
anything.
>
> e.g
> If `[the input] is the body of an email`
> If `[the input] is a City in the USA`
> If `[the input] is an error or a refusal`
> Fixes https://linear.app/autogpt/issue/AUTOMAT-60/ai-condition-block
>
>
> Comment by User 4bcbb358-1758-43e4-abef-a0a42b63442f:
> 📋 I need a **repo** label on this issue to determine which GitHub
repository to work in.
>
> Please add a repo label to this issue with the format
`owner/repository-name` (e.g., `github/copilot`), then I'll
automatically start working on it!
>
> Comment by User :
> This thread is for an agent session with githubcopilotcodingagent.
>
>
</details>
<!-- START COPILOT CODING AGENT TIPS -->
---
✨ Let Copilot coding agent [set things up for
you](https://github.com/Significant-Gravitas/AutoGPT/issues/new?title=✨+Set+up+Copilot+instructions&body=Configure%20instructions%20for%20this%20repository%20as%20documented%20in%20%5BBest%20practices%20for%20Copilot%20coding%20agent%20in%20your%20repository%5D%28https://gh.io/copilot-coding-agent-tips%29%2E%0A%0A%3COnboard%20this%20repo%3E&assignees=copilot)
— coding agent works faster and does higher quality work when set up for
your repo.
<!-- CURSOR_SUMMARY -->
---
> [!NOTE]
> Introduces `AIConditionBlock` that uses an LLM to evaluate
natural-language conditions and outputs boolean result with yes/no
pass-through, plus accompanying documentation.
>
> - **Backend**:
> - **New block**: `backend/blocks/ai_condition.py`
> - Evaluates natural-language conditions via `llm_call` using
selectable `LlmModel` and credentials.
> - Parses strict true/false responses (with fallback token matching),
yields `result`, `yes_output`/`no_output`, and `error` on
ambiguity/failure.
> - Tracks token usage via `NodeExecutionStats`; includes test
inputs/mocks and `force_json_output=False`.
> - **Docs**:
> - Adds `docs/content/platform/blocks/ai_condition.md` with usage,
inputs/outputs, examples, and considerations.
>
> <sup>Written by [Cursor
Bugbot](https://cursor.com/dashboard?tab=bugbot) for commit
|
||
|
|
ad49946890 |
feat(frontend): New Run Agent Modal (2/2) (#10769)
## Changes 🏗️ <img width="400" height="821" alt="Screenshot 2025-08-28 at 23 57 41" src="https://github.com/user-attachments/assets/f5f7c0a6-0b87-4c1f-b644-3ee2ddd1db95" /> <img width="400" height="822" alt="Screenshot 2025-08-28 at 23 57 47" src="https://github.com/user-attachments/assets/120dbb60-d9e1-4a4a-a593-971badb4a97a" /> This is the final piece of work on the new **Run Agent Modal**... It is all behind a feature flag so I'm relatively comfortable is safe. The idea is to test with the team once it lands into dev to try different combinations of agent inputs / credentials and schedules... I have moved and tied a lot of the original logic around running agents. Mostly importantly, I have made all the dynamic inputs adhere to the design system. ### AI changes summary - Allow to run schedules in the main modal body - Integrate and tidy old logic around dynamic run agent inputs - Integrate and tidy old logic around credentials inputs - Refactor: `<TypeBasedInputs />` to use Design System components (`atoms/Input`, `atoms/Select`, `molecules/MultiToggle`, and native date/time picker via `<Input />` using the browser's date picker ) - Added support for `type="date"` and `type="datetime-local"` to `<Input />` ( _for the above_ ) - On the `<Select />` component: - added `size` prop (`small` | `medium`). - added rich items: `icon`, `disabled`, `separator`, `onSelect`, and `renderItem` prop. - stories updated/added for size variants, icons/separators, and custom rendering. - Added and documented to the design system: - `molecules/TimePicker` + story. - `atoms/FileInput`: added `accept` and `maxFileSize` props; story documents constraints. - `atoms/Progress` stories (Basic, CustomMax, Sizes, Live) with fixed-width container. - `atoms/Switch` stories (Basic, Disabled, WithLabel). - `molecules/Dialog` story: Modal-over-Modal example. ## Checklist 📋 ### For code changes: - [x] I have clearly listed my changes in the PR description - [x] I have made a test plan - [x] I have tested my changes according to the test plan: - [x] Open Storybook and verify new/updated stories render correctly. - [x] In app, validate modals open/close correctly using DS `Dialog`. - [x] Validate DS Select rich items (icon, separator, disabled, action) behave as expected. - [x] Run lints and ensure no errors. - [x] Manually test File upload constraints (type/size) and progress. ### For configuration changes: None |
||
|
|
3e4ca19036 |
docs: Add comprehensive Block SDK guide (#10767)
## Summary - Added comprehensive Block SDK guide documenting the new SDK pattern for creating blocks - Integrated the guide into the documentation structure - Updated existing documentation to reference the new guide ## Changes - Created `docs/content/platform/block-sdk-guide.md` with detailed instructions for: - Provider configuration using `ProviderBuilder` - Block schema definition and implementation - Authentication methods (API keys, OAuth, webhooks) - Testing and validation - File organization and best practices - Updated documentation structure: - Added guide to `mkdocs.yml` navigation - Added cross-references in `new_blocks.md` - Added links in `blocks/blocks.md` overview - Updated `CLAUDE.md` with reference to the new guide ## Test plan - [ ] Documentation builds correctly with mkdocs - [ ] All internal links resolve properly - [ ] Guide examples are syntactically correct - [ ] Navigation structure is logical and accessible |
||
|
|
fa5ff9ca3c |
feat(docs): Update Ollama setup docs with new methods (#10693)
### Changes 🏗️
Expanded the Ollama setup instructions to include desktop app, Docker,
and legacy CLI methods. Added new screenshots for network exposure and
model selection. Clarified steps for starting the AutoGPT platform,
configuring models, and troubleshooting. Included instructions for
adding custom models and improved overall documentation structure.
#### For code changes:
- [x] I have clearly listed my changes in the PR description
- [x] I have made a test plan
- [x] I have tested my changes according to the test plan:
<!-- Put your test plan here: -->
- [x] Look at the new ollama doc to make sure it makes sense and is easy
to follow
|
||
|
|
4bfeddc03d |
feat(platform/docker): add frontend service to docker-compose with env config improvements (#10615)
## Summary This PR adds the frontend service to the Docker Compose configuration, enabling `docker compose up` to run the complete stack, including the frontend. It also implements comprehensive environment variable improvements, unified .env file support, and fixes Docker networking issues. ## Key Changes ### 🐳 Docker Compose Improvements - **Added frontend service** to `docker-compose.yml` and `docker-compose.platform.yml` - **Production build**: Uses `pnpm build + serve` instead of dev server for better stability and lower memory usage - **Service dependencies**: Frontend now waits for backend services (`rest_server`, `websocket_server`) to be ready - **YAML anchors**: Implemented DRY configuration to avoid duplicating environment values ### 📁 Unified .env File Support - **Frontend .env loading**: Automatically loads `.env` file during Docker build and runtime - **Backend .env loading**: Optional `.env` file support with fallback to sensible defaults in `settings.py` - **Single source of truth**: All `NEXT_PUBLIC_*` and API keys can be defined in respective `.env` files - **Docker integration**: Updated `.dockerignore` to include `.env` files in build context - **Git tracking**: Frontend and backend `.env` files are now trackable (removed from gitignore) ### 🔧 Environment Variable Architecture - **Dual environment strategy**: - Server-side code uses Docker service names (`http://rest_server:8006/api`) - Client-side code uses localhost URLs (`http://localhost:8006/api`) - **Comprehensive config**: Added build args and runtime environment variables - **Network compatibility**: Fixes connection issues between frontend and backend containers - **Shared backend variables**: Common environment variables (service hosts, auth settings) centralized using YAML anchors ### 🛠️ Code Improvements - **Centralized env-config helper** (`/frontend/src/lib/env-config.ts`) with server-side priority - **Updated all frontend code** to use shared environment helpers instead of direct `process.env` access - **Consistent API**: All environment variable access now goes through helper functions - **Settings.py improvements**: Better defaults for CORS origins and optional .env file loading ### 🔗 Files Changed - `docker-compose.yml` & `docker-compose.platform.yml` - Added frontend service and shared backend env vars - `frontend/Dockerfile` - Simplified build process to use .env files directly - `backend/settings.py` - Optional .env loading and better defaults - `frontend/src/lib/env-config.ts` - New centralized environment configuration - `.dockerignore` - Allow .env files in build context - `.gitignore` - Updated to allow frontend/backend .env files - Multiple frontend files - Updated to use env helpers - Updates to both auto installer scripts to work with the latest setup! ## Benefits - ✅ **Single command deployment**: `docker compose up` now runs everything - ✅ **Better reliability**: Production build reduces memory usage and crashes - ✅ **Network compatibility**: Proper container-to-container communication - ✅ **Maintainable config**: Centralized environment variable management with .env files - ✅ **Development friendly**: Works in both Docker and local development - ✅ **API key management**: Easy configuration through .env files for all services - ✅ **No more manual env vars**: Frontend and backend automatically load their respective .env files ## Testing - ✅ Verified Docker service communication works correctly - ✅ Frontend responds and serves content properly - ✅ Environment variables are correctly resolved in both server and client contexts - ✅ No connection errors after implementing service dependencies - ✅ .env file loading works correctly in both build and runtime phases - ✅ Backend services work with and without .env files present ### Checklist 📋 #### For configuration changes: - [x] `.env.default` is updated or already compatible with my changes - [x] `docker-compose.yml` is updated or already compatible with my changes - [x] I have included a list of my configuration changes in the PR description (under **Changes**) 🤖 Generated with [Claude Code](https://claude.ai/code) --------- Co-authored-by: Lluis Agusti <hi@llu.lu> Co-authored-by: Claude <noreply@anthropic.com> Co-authored-by: Nicholas Tindle <nicholas.tindle@agpt.co> Co-authored-by: Claude <claude@users.noreply.github.com> Co-authored-by: Bentlybro <Github@bentlybro.com> |
||
|
|
0dd30e275c |
docs(blocks): Add AI/ML API integration guide and update LLM headers (#10402)
### Summary Added a new documentation page and images for integrating AI/ML API with AutoGPT, including step-by-step instructions. Updated LLM block to send additional headers for requests to aimlapi.com. Improved provider listing in index.md and added the new guide to mkdocs navigation. Builds on and extends the integration work from https://github.com/Significant-Gravitas/AutoGPT/pull/9996 ### Changes 🏗️ This PR introduces official support and documentation for using **AI/ML API** with the **AutoGPT platform**: * 📄 **Added a new documentation page** `platform/aimlapi.md` with a detailed step-by-step integration guide. * 🖼️ **Added 12+ reference images** to `docs/content/imgs/aimlapi/` for clear visual walkthrough. * 🧠 **Updated the LLM block** (`llm.py`) to send extra headers (`X-Project`, `X-Title`, `Referer`) in requests to `aimlapi.com` for analytics and source attribution. * 📚 **Improved provider listing** in `index.md` — added section about AI/ML API models and benefits. * 🧭 **Added the new guide to the mkdocs navigation** via `mkdocs.yml`. --- ### Checklist 📋 #### For code changes: * [x] I have clearly listed my changes in the PR description * [x] I have made a test plan * [x] I have tested my changes according to the test plan: * [x] Successfully authenticated against `api.aimlapi.com` * [x] Verified requests use correct headers * [x] Confirmed `AI Text Generator` block returns completions for all supported models * [x] End-to-end tested: created, saved, and ran agent with AI/ML API successfully * [x] Verified outputs render correctly in the Output panel No breaking changes introduced. Let me know if you'd like this guide cross-referenced from other onboarding pages. ✅ --------- Co-authored-by: Nicholas Tindle <nicholas.tindle@agpt.co> |
||
|
|
c972f34713 |
Revert "feat(docker): add frontend service to docker-compose with env config improvements" (#10577)
Reverts Significant-Gravitas/AutoGPT#10536 to bring platform back up due to this error: ``` │ Error creating Supabase client Error: @supabase/ssr: Your project's URL and API key are required to create a Supabase client! │ │ │ │ Check your Supabase project's API settings to find these values │ │ │ │ https://supabase.com/dashboard/project/_/settings/api │ │ at <unknown> (https://supabase.com/dashboard/project/_/settings/api) │ │ at bX (.next/server/chunks/3873.js:6:90688) │ │ at <unknown> (.next/server/chunks/150.js:6:13460) │ │ at n (.next/server/chunks/150.js:6:13419) │ │ at o (.next/server/chunks/150.js:6:14187) │ │ ⨯ Error: Your project's URL and Key are required to create a Supabase client! │ │ │ │ Check your Supabase project's API settings to find these values │ │ │ │ https://supabase.com/dashboard/project/_/settings/api │ │ at <unknown> (https://supabase.com/dashboard/project/_/settings/api) │ │ at bY (.next/server/chunks/3006.js:10:486) │ │ at g (.next/server/app/(platform)/auth/callback/route.js:1:5890) │ │ at async e (.next/server/chunks/9836.js:1:101814) │ │ at async k (.next/server/chunks/9836.js:1:15611) │ │ at async l (.next/server/chunks/9836.js:1:15817) { │ │ digest: '424987633' │ │ } │ │ Error creating Supabase client Error: @supabase/ssr: Your project's URL and API key are required to create a Supabase client! │ │ │ │ Check your Supabase project's API settings to find these values │ │ │ │ https://supabase.com/dashboard/project/_/settings/api │ │ at <unknown> (https://supabase.com/dashboard/project/_/settings/api) │ │ at bX (.next/server/chunks/3873.js:6:90688) │ │ at <unknown> (.next/server/chunks/150.js:6:13460) │ │ at n (.next/server/chunks/150.js:6:13419) │ │ at j (.next/server/chunks/150.js:6:7482) │ │ Error creating Supabase client Error: @supabase/ssr: Your project's URL and API key are required to create a Supabase client! │ │ │ │ Check your Supabase project's API settings to find these values │ │ │ │ https://supabase.com/dashboard/project/_/settings/api │ │ at <unknown> (https://supabase.com/dashboard/project/_/settings/api) │ │ at bX (.next/server/chunks/3873.js:6:90688) │ │ at <unknown> (.next/server/chunks/150.js:6:13460) │ │ at n (.next/server/chunks/150.js:6:13419) │ │ at h (.next/server/chunks/150.js:6:10561) │ │ Error creating Supabase client Error: @supabase/ssr: Your project's URL and API key are required to create a Supabase client! │ │ │ │ Check your Supabase project's API settings to find these values │ │ │ │ https://supabase.com/dashboard/project/_/settings/api │ │ at <unknown> (https://supabase.com/dashboard/project/_/settings/api) │ │ at bX (.next/server/chunks/3873.js:6:90688) │ │ at <unknown> (.next/server/chunks/150.js:6:13460) │ │ at n (.next/server/chunks/150.js:6:13419) ``` |
||
|
|
f172b314a4 |
feat(docker): add frontend service to docker-compose with env config improvements (#10536)
## Summary This PR adds the frontend service to the Docker Compose configuration, enabling `docker compose up` to run the complete stack including the frontend. It also implements comprehensive environment variable improvements and fixes Docker networking issues. ## Key Changes ### 🐳 Docker Compose Improvements - **Added frontend service** to `docker-compose.yml` and `docker-compose.platform.yml` - **Production build**: Uses `pnpm build + serve` instead of dev server for better stability and lower memory usage - **Service dependencies**: Frontend now waits for backend services (`rest_server`, `websocket_server`) to be ready - **YAML anchors**: Implemented DRY configuration to avoid duplicating environment values ### 🔧 Environment Variable Architecture - **Dual environment strategy**: - Server-side code uses Docker service names (`http://rest_server:8006/api`) - Client-side code uses localhost URLs (`http://localhost:8006/api`) - **Comprehensive config**: Added build args and runtime environment variables - **Network compatibility**: Fixes connection issues between frontend and backend containers ### 🛠️ Code Improvements - **Centralized env-config helper** (`/frontend/src/lib/env-config.ts`) with server-side priority - **Updated all frontend code** to use shared environment helpers instead of direct `process.env` access - **Consistent API**: All environment variable access now goes through helper functions ### 🔗 Files Changed - `docker-compose.yml` & `docker-compose.platform.yml` - Added frontend service - `frontend/Dockerfile` - Added build args for environment variables - `frontend/src/lib/env-config.ts` - New centralized environment configuration - Multiple frontend files - Updated to use env helpers ## Benefits - ✅ **Single command deployment**: `docker compose up` now runs everything - ✅ **Better reliability**: Production build reduces memory usage and crashes - ✅ **Network compatibility**: Proper container-to-container communication - ✅ **Maintainable config**: Centralized environment variable management - ✅ **Development friendly**: Works in both Docker and local development ## Testing - ✅ Verified Docker service communication works correctly - ✅ Frontend responds and serves content properly - ✅ Environment variables are correctly resolved in both server and client contexts - ✅ No connection errors after implementing service dependencies 🤖 Generated with [Claude Code](https://claude.ai/code) --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
f7c1906364 |
feat(frontend, backend): Publish Agent Dialog Agent List Pagination (#10023)
We want scrolling for agent dialog list - Based on #9833 ### Changes 🏗️ - adds backend support for paginating this content - adds frontend support for scrolling pagination <!-- Concisely describe all of the changes made in this pull request: --> ### Checklist 📋 #### For code changes: - [x] I have clearly listed my changes in the PR description - [x] I have made a test plan - [x] I have tested my changes according to the test plan: <!-- Put your test plan here: --> - [x] test UI for this --------- Co-authored-by: Venkat Sai Kedari Nath Gandham <154089422+Kedarinath1502@users.noreply.github.com> Co-authored-by: Claude <claude@users.noreply.github.com> Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
c451337cb5 |
fix(docs): missing tags from code that are referenced in docs (#10400)
<!-- Clearly explain the need for these changes: --> The docs have an issue with not building due to changes made in the process of updating the e2e testing to remove the monitor page. ### Changes 🏗️ <!-- Concisely describe all of the changes made in this pull request: --> fixes the missing start and end tags that prevent docs from building. ### Checklist 📋 #### For code changes: - [x] I have clearly listed my changes in the PR description - [x] I have made a test plan - [x] I have tested my changes according to the test plan: <!-- Put your test plan here: --> - [x] run the build and check for no errors indicating missing tags - [x] deploy to netlify |
||
|
|
e50366726c |
feat(blocks/gmail): add Gmail thread blocks (#9965)
This PR adds two new Gmail integration blocks—**Gmail Get Thread** and **Gmail Reply**—to the platform, enhancing threaded email workflows. Key changes include: - **GmailGetThreadBlock**: - New block that retrieves an entire Gmail thread by `threadId`, with an option to include or exclude messages from Spam and Trash. - Supports use cases like fetching all messages in a conversation to check for responses. - **GmailReplyBlock**: - New block that sends a reply within an existing Gmail thread, maintaining the thread context. - Accepts detailed input fields including recipients, CC, BCC, subject, body, and attachments. - Ensures replies are properly associated with their parent message and thread. - **Enhancements to existing Gmail blocks**: - The `Email` model and related outputs now include a `threadId` field. - Updated test data and mock data to support threaded operations. - Expanded OAuth scopes for actions requiring thread metadata. - **Documentation updates**: - Added documentation for the new Gmail blocks in both the general block listing and the detailed Gmail block docs. - Clarified that the `Email` output now includes the `threadId`. These updates enable more advanced and context-aware Gmail automations, such as fetching full conversations and replying inline, supporting richer communication workflows with Gmail. ## Checklist 📋 ### For code changes - [x] I have clearly listed my changes in the PR description - [x] I have made a test plan - [x] I have tested my changes according to the test plan: - [x] Try all the gmail blocks - [x] Send an email reply based on a thread from the get thread block --------- Co-authored-by: Nicholas Tindle <nicholas.tindle@agpt.co> |
||
|
|
f45bf53681 |
feat(docs): Add info about auto setup script to docs + readme (#10347)
Updates to the readme + docs to add info about the newly added auto setup script. Changes to ``new_blocks.md`` and ``installer.md`` are to make netlify CI happy and pass --------- Co-authored-by: Reinier van der Leer <pwuts@agpt.co> |
||
|
|
22d58367ec |
dx(platform): Add initial setup scripts for linux and windows (#9912)
This PR adds two setup scripts that will setup autogpt fully, it has a windows .bat and a linux/mac .sh script, for now they are placed in a new folder called "Installer" ### Note, the installers are supposed to be run outside of the autogpt repo folder like Desktop/in a new empy folder because it will clone the repo into the current directory. I have had to add ``cross-env`` via ``pnpm add cross-env `` as on windows the env is set differently in the ``package.json`` build section ``"build": "cross-env pnpm run generate:api-client && SKIP_STORYBOOK_TESTS=true next build"`` once fully setup i plan to make it so these commands can be run with the following commands Linux/Mac ```bash curl -fsSL https://setup.agpt.co/install.sh -o install.sh && bash install.sh ``` Windows cmd/powershell ```bash powershell -c "iwr https://setup.agpt.co/install.bat -o install.bat; ./install.bat" ``` Currently the commands above dont work but will later on! ### Checklist 📋 #### For code changes: - [x] I have clearly listed my changes in the PR description - [x] I have made a test plan - [x] I have tested my changes according to the test plan: - [x] I have tested the linux ``install.sh`` on a ubuntu system and it setup the platform fully. - [x] I have tested the windows ``install.bat`` on my windows system and it setup the platform fully. - [x] I have tested on both OS's and checked with missing prerequisites to see if it shows the errors and it does |
||
|
|
83dbcd11e4 |
docs(frontend, backend): add OAuth security boundary docs (#10202)
### Why are these changes needed? <!-- Clearly explain the need for these changes: --> These changes document the OAuth integration flow for CASA lvl 2 compliance, specifically addressing the requirement to "Verify documentation and justification of all the application's trust boundaries, components, and significant data flows." The documentation clarifies the two distinct OAuth implementations in AutoGPT: user authentication via Supabase SSO and API integration credentials for third-party services. ### Changes 🏗️ <!-- Concisely describe all of the changes made in this pull request: --> - Created comprehensive OAuth integration flow documentation at `/docs/content/platform/contributing/oauth-integration-flow.md` - Documented trust boundaries between frontend (untrusted), backend API (trusted), and external providers (semi-trusted) - Added detailed component architecture for both frontend and backend OAuth implementations - Included mermaid diagrams illustrating: - OAuth flow sequences (initiation, authorization, token refresh) - System architecture showing SSO vs API integration OAuth - Data flow diagram - Security architecture layers - Credential lifecycle state diagram - Documented security measures including CSRF protection, PKCE implementation, and token management - Clarified the distinction between Supabase SSO for user login and custom OAuth for API integrations - Added references to source files for up-to-date provider lists rather than hard-coding all providers ### Checklist 📋 #### For code changes: - [x] I have clearly listed my changes in the PR description - [x] I have made a test plan - [x] I have tested my changes according to the test plan: <!-- Put your test plan here: --> - [x] Created documentation file with proper markdown formatting - [x] Verified all file paths referenced in documentation exist - [x] Confirmed mermaid diagrams render correctly - [x] Validated that the documentation accurately reflects the codebase implementation --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
f950f35af8 |
[Snyk] Security upgrade requests from 2.31.0 to 2.32.4 (#10148)
 ### Snyk has created this PR to fix 1 vulnerabilities in the pip dependencies of this project. #### Snyk changed the following file(s): - `docs/requirements.txt` <details> <summary>⚠️ <b>Warning</b></summary> ``` mkdocs-material 9.2.8 requires requests, which is not installed. mkdocs-material 9.2.8 has requirement pymdown-extensions~=10.3, but you have pymdown-extensions 10.2.1. ``` </details> --- > [!IMPORTANT] > > - Check the changes in this PR to ensure they won't cause issues with your project. > - Max score is 1000. Note that the real score may have changed since the PR was raised. > - This PR was automatically created by Snyk using the credentials of a real user. > - Some vulnerabilities couldn't be fully fixed and so Snyk will still find them when the project is tested again. This may be because the vulnerability existed within more than one direct dependency, but not all of the affected dependencies could be upgraded. --- **Note:** _You are seeing this because you or someone else with access to this repository has authorized Snyk to open fix PRs._ For more information: <img src="https://api.segment.io/v1/pixel/track?data=eyJ3cml0ZUtleSI6InJyWmxZcEdHY2RyTHZsb0lYd0dUcVg4WkFRTnNCOUEwIiwiYW5vbnltb3VzSWQiOiIxYjFlMDQ4NS1jMzZlLTRjYjgtYTAzYy00MjIwNTdjYzViMjEiLCJldmVudCI6IlBSIHZpZXdlZCIsInByb3BlcnRpZXMiOnsicHJJZCI6IjFiMWUwNDg1LWMzNmUtNGNiOC1hMDNjLTQyMjA1N2NjNWIyMSJ9fQ==" width="0" height="0"/> 🧐 [View latest project report](https://app.snyk.io/org/significant-gravitas/project/7c1b6d4c-2625-44c8-8403-42505b3997f8?utm_source=github&utm_medium=referral&page=fix-pr) 📜 [Customise PR templates](https://docs.snyk.io/scan-using-snyk/pull-requests/snyk-fix-pull-or-merge-requests/customize-pr-templates?utm_source=github&utm_content=fix-pr-template) 🛠 [Adjust project settings](https://app.snyk.io/org/significant-gravitas/project/7c1b6d4c-2625-44c8-8403-42505b3997f8?utm_source=github&utm_medium=referral&page=fix-pr/settings) 📚 [Read about Snyk's upgrade logic](https://docs.snyk.io/scan-with-snyk/snyk-open-source/manage-vulnerabilities/upgrade-package-versions-to-fix-vulnerabilities?utm_source=github&utm_content=fix-pr-template) --- **Learn how to fix vulnerabilities with free interactive lessons:** 🦉 [Learn about vulnerability in an interactive lesson of Snyk Learn.](https://learn.snyk.io/?loc=fix-pr) [//]: # 'snyk:metadata:{"customTemplate":{"variablesUsed":[],"fieldsUsed":[]},"dependencies":[{"name":"requests","from":"2.31.0","to":"2.32.4"}],"env":"prod","issuesToFix":["SNYK-PYTHON-REQUESTS-10305723"],"prId":"1b1e0485-c36e-4cb8-a03c-422057cc5b21","prPublicId":"1b1e0485-c36e-4cb8-a03c-422057cc5b21","packageManager":"pip","priorityScoreList":[678],"projectPublicId":"7c1b6d4c-2625-44c8-8403-42505b3997f8","projectUrl":"https://app.snyk.io/org/significant-gravitas/project/7c1b6d4c-2625-44c8-8403-42505b3997f8?utm_source=github&utm_medium=referral&page=fix-pr","prType":"fix","templateFieldSources":{"branchName":"default","commitMessage":"default","description":"default","title":"default"},"templateVariants":["updated-fix-title","pr-warning-shown","priorityScore"],"type":"auto","upgrade":[],"vulns":["SNYK-PYTHON-REQUESTS-10305723"],"patch":[],"isBreakingChange":false,"remediationStrategy":"vuln"}' --------- Co-authored-by: Swifty <craigswift13@gmail.com> Co-authored-by: snyk-bot <snyk-bot@snyk.io> |
||
|
|
a259eac9ff |
feat(blocks): Add AI/ML API support to LLM blocks (#9996)
Hi! Taking over this feature from the previous author in [#9163](https://github.com/Significant-Gravitas/AutoGPT/pull/9163). This PR continues the work to integrate AI/ML API support into LLM blocks, addressing pending review comments and ensuring compatibility with the current codebase. I’ve reviewed and fixed the outstanding issues from the previous PR. Kindly recheck the previous concerns — let me know if anything still needs improvement. Previous description: > Changes 🏗️ > > - Added basic functionality to enable users to send requests to our models. > - Added instructions for users on how to use the AI/ML API in AutoGPT. > > Checklist 📋 > For code changes: > > - [x] I have clearly listed my changes in the PR description > - [x] I have made a test plan > - [x] I have tested my changes according to the test plan: > - [x] The API key has been successfully added and saved to the user's profile. > - [x] Sending requests to each model provided by us, enabling users to test them in a project with various max_tokens parameter values and other configurations. --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: Ivan <waterstark97@yandex.ru> Co-authored-by: waterstark <84220220+waterstark@users.noreply.github.com> Co-authored-by: Aarushi <50577581+aarushik93@users.noreply.github.com> Co-authored-by: Reinier van der Leer <github@pwuts.nl> Co-authored-by: Nicholas Tindle <nicholas.tindle@agpt.co> Co-authored-by: snyk-bot <snyk-bot@snyk.io> Co-authored-by: Krzysztof Czerwinski <34861343+kcze@users.noreply.github.com> Co-authored-by: Zamil Majdy <zamil.majdy@agpt.co> Co-authored-by: Krzysztof Czerwinski <kpczerwinski@gmail.com> Co-authored-by: Reinier van der Leer <pwuts@agpt.co> Co-authored-by: Bently <tomnoon9@gmail.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Ayush Mittal <130590402+Ayush-Mittal10@users.noreply.github.com> Co-authored-by: Azraf Nahian <69325302+turboslapper@users.noreply.github.com> Co-authored-by: Nicholas Tindle <nicktindle@outlook.com> Co-authored-by: Swifty <craigswift13@gmail.com> Co-authored-by: Mario Sacaj <mariosacaj@gmail.com> Co-authored-by: Toran Bruce Richards <toran.richards@gmail.com> Co-authored-by: Abhimanyu Yadav <122007096+Abhi1992002@users.noreply.github.com> Co-authored-by: Ritik Dutta <ritikduttagd@gmail.com> Co-authored-by: Pratim Sadhu <pratimsadhu@icloud.com> |
||
|
|
a3d082a5fa |
feat(backend): snapshot test responses (#10039)
This pull request introduces a comprehensive backend testing guide and adds new tests for analytics logging and various API endpoints, focusing on snapshot testing. It also includes corresponding snapshot files for these tests. Below are the most significant changes: ### Documentation Updates: * Added a detailed `TESTING.md` file to the backend, providing a guide for running tests, snapshot testing, writing API route tests, and best practices. It includes examples for mocking, fixtures, and CI/CD integration. ### Analytics Logging Tests: * Implemented tests for logging raw metrics and analytics in `analytics_test.py`, covering success scenarios, various input values, invalid requests, and complex nested data. These tests utilize snapshot testing for response validation. * Added snapshot files for analytics logging tests, including responses for success cases, various metric values, and complex analytics data. [[1]](diffhunk://#diff-654bc5aa1951008ec5c110a702279ef58709ee455ba049b9fa825fa60f7e3869R1-R3) [[2]](diffhunk://#diff-e0a434b107abc71aeffb7d7989dbfd8f466b5e53f8dea25a87937ec1b885b122R1-R3) [[3]](diffhunk://#diff-dd0bc0b72264de1a0c0d3bd0c54ad656061317f425e4de461018ca51a19171a0R1-R3) [[4]](diffhunk://#diff-63af007073db553d04988544af46930458a768544cabd08412265e0818320d11R1-R30) ### Snapshot Files for API Endpoints: * Added snapshot files for various API endpoint tests, such as: - Graph-related operations (`graphs_get_single_response`, `graphs_get_all_response`, `blocks_get_all_response`). [[1]](diffhunk://#diff-b25dba271606530cfa428c00073d7e016184a7bb22166148ab1726b3e113dda8R1-R29) [[2]](diffhunk://#diff-1054e58ec3094715660f55bfba1676d65b6833a81a91a08e90ad57922444d056R1-R31) [[3]](diffhunk://#diff-cfd403ab6f3efc89188acaf993d85e6f792108d1740c7e7149eb05efb73d918dR1-R14) - User-related operations (`auth_get_or_create_user_response`, `auth_update_email_response`). [[1]](diffhunk://#diff-49e65ab1eb6af4d0163a6c54ed10be621ce7336b2ab5d47d47679bfaefdb7059R1-R5) [[2]](diffhunk://#diff-ac1216f96878bd4356454c317473654d5d5c7c180125663b80b0b45aa5ab52cbR1-R3) - Credit-related operations (`credits_get_balance_response`, `credits_get_auto_top_up_response`, `credits_top_up_request_response`). [[1]](diffhunk://#diff-189488f8da5be74d80ac3fb7f84f1039a408573184293e9ba2e321d535c57cddR1-R3) [[2]](diffhunk://#diff-ba3c4a6853793cbed24030cdccedf966d71913451ef8eb4b2c4f426ef18ed87aR1-R4) [[3]](diffhunk://#diff-43d7daa0c82070a9b6aee88a774add8e87533e630bbccbac5a838b7a7ae56a75R1-R3) - Graph execution and deletion (`blocks_execute_response`, `graphs_delete_response`). [[1]](diffhunk://#diff-a2ade7d646ad85a2801e7ff39799a925a612548a1cdd0ed99b44dd870d1465b5R1-R12) [[2]](diffhunk://#diff-c0d1cd0a8499ee175ce3007c3a87ba5f3235ce02d38ce837560b36a44fdc4a22R1-R3)## Summary - add pytest-snapshot to backend dev requirements - snapshot server route response JSONs - mention how to update stored snapshots ## Testing - `poetry run format` - `poetry run test` ### Checklist 📋 #### For code changes: - [x] I have clearly listed my changes in the PR description - [x] I have made a test plan - [x] I have tested my changes according to the test plan: <!-- Put your test plan here: --> - [x] run poetry run test --------- Co-authored-by: Claude <noreply@anthropic.com> Co-authored-by: Nicholas Tindle <nicholas.tindle@agpt.co> |
||
|
|
79b38343c2 |
docs(ollama): Update to add info on how to properly setup ollama environment variables (#10089)
Update ollama docs to add info on how to setup ollama environment vars for proper access This includes properly setting the "OLLAMA_HOST" env var with the ip and port "0.0.0.0:11434" which makes it accessible to AutoGPT thats running inside of docker #### For code changes: - [x] I have clearly listed my changes in the PR description - [x] I have made a test plan - [x] I have tested my changes according to the test plan: <!-- Put your test plan here: --> - [x] Follow the latest setup to test Ollama to make sure it works |
||
|
|
73a3d980ca |
chore(frontend): move from yarn1 to pnpm (#10072)
## 🧢 Overview This PR migrates the AutoGPT Platform frontend from [yarn 1](https://classic.yarnpkg.com/lang/en/) to [pnpm](https://pnpm.io/) using **corepack** for automatic package manager management. **yarn1** is not longer maintained and a bit old, moving to **pnpm** we get: - ⚡ Significantly faster install times, - 💾 Better disk space efficiency, - 🛠️ Better community support and maintenance, - 💆🏽♂️ Config swap very easy ## 🏗️ Changes ### Package Management Migration - updated [corepack](https://github.com/nodejs/corepack) to use [pnpm](https://pnpm.io/) - Deleted `yarn.lock` and generated new `pnpm-lock.yaml` - Updated `.gitignore` ### Documentation Updates - `frontend/README.md`: - added comprehensive tech stack overview with links - updated all commands to use pnpm - added corepack setup instructions - and included migration disclaimer for yarn users - `backend/README.md`: - Updated installation instructions to use pnpm with corepack - `AGENTS.md`: - Updated testing commands from yarn to pnpm ### CI/CD & Infrastructure - **GitHub Workflows** : - updated all jobs to use pnpm with corepack enable - cleaned FE Playwright test workflow to avoid Sentry noise - **Dockerfile**: - updated to use pnpm with corepack, changed lock file reference, and updated cache mount path ### 📋 Checklist #### For code changes: - [x] I have clearly listed my changes in the PR description - [x] I have made a test plan - [x] I have tested my changes according to the test plan: **Test Plan:** > assuming you are on the `frontend` folder - [x] Clean installation works: `rm -rf node_modules && corepack enable && pnpm install` - [x] Development server starts correctly: `pnpm dev` - [x] Build process works: `pnpm build` - [x] Linting and formatting work: `pnpm lint` and `pnpm format` - [x] Type checking works: `pnpm type-check` - [x] Tests run successfully: `pnpm test` - [x] Storybook starts correctly: `pnpm storybook` - [x] Docker build succeeds with new pnpm configuration - [x] GitHub Actions workflow passes with pnpm commands #### For configuration changes: - [x] `.env.example` is updated or already compatible with my changes - [x] `docker-compose.yml` is updated or already compatible with my changes - [x] I have included a list of my configuration changes in the PR description (under **Changes**) |
||
|
|
3f6585f763 |
feat(platform/blocks): add AI Image Editor Block powered by flux kontext (#10063)
<!-- Clearly explain the need for these changes: --> This PR adds a new internal block, **AI Image Editor**, which enables **text-based image editing** via BlackForest Labs’ Flux Kontext models on Replicate. This block allows users to input a prompt and optionally a reference image, and returns a transformed image URL. It supports two model variants (Pro and Max), with different cost tiers. This functionality will enhance multimedia capabilities across internal agent workflows and support richer AI-powered image manipulation. --- ### Changes 🏗️ * Added `FluxKontextBlock` in `backend/blocks/flux_kontext.py` * Uses `ReplicateClient` to call Flux Kontext Pro or Max models * Supports inputs for `prompt`, `input_image`, `aspect_ratio`, `seed`, and `model` * Outputs transformed image URL or error * Added credit pricing logic for Flux Kontext models to `block_cost_config.py`: * Pro: 10 credits * Max: 20 credits * Added documentation for the new block at `docs/content/platform/blocks/flux_kontext.md` * Updated block index at `docs/content/platform/blocks/blocks.md` to include Flux Kontext ---  ### Checklist 📋 #### For code changes: * [x] I have clearly listed my changes in the PR description * [x] I have made a test plan * [x] I have tested my changes according to the test plan: <!-- Put your test plan here: --> * [x] Prompt-only input generates an image * [x] Prompt with image applies edit correctly * [x] Image respects specified aspect ratio * [x] Invalid image URL returns helpful error * [x] Using the same seed gives consistent output * [x] Output chaining works: result URI can be used in downstream blocks * [x] Output from Max model shows higher fidelity than Pro <details> <summary>Example test plan</summary> * [x] Create from scratch and execute an agent using Flux Kontext with at least 3 blocks * [x] Import agent with Flux Kontext from file upload, and confirm execution * [x] Upload agent (with Flux Kontext block) to marketplace (internal test) * [x] Import agent from marketplace and confirm correct execution * [x] Edit agent with Flux Kontext block from monitor and confirm output </details> #### For configuration changes: * [x] `.env.example` is updated or already compatible with my changes * [x] `docker-compose.yml` is updated or already compatible with my changes * [x] I have included a list of my configuration changes in the PR description (under **Changes**) * No new environment variables or services introduced <details> <summary>Examples of configuration changes</summary> * N/A </details> --------- Co-authored-by: Zamil Majdy <zamil.majdy@agpt.co> |
||
|
|
453834f475 |
fix(docs): comment out segment about video because we removed video (#10073)
<!-- Clearly explain the need for these changes: --> We removed the linked video because out of date so unlink it ### Changes 🏗️ <!-- Concisely describe all of the changes made in this pull request: --> Comment out video segment until new one posted ### Checklist 📋 #### For code changes: - [x] no code changes made |
||
|
|
2dc038b6c0 |
Add Llama API Support (#9899)
The changes in this PR are to add Llama API support. ### Changes 🏗️ We add both backend and frontend support. **Backend**: - Add llama_api provider - Include models supported by Llama API along with configs - llm_call - credential store and llama_api_key field in Settings **Frontend**: - Llama API as a type - Credentials input and provider for Llama API ### Checklist 📋 #### For code changes: - [X] I have clearly listed my changes in the PR description - [X] I have tested my changes according to the test plan: **Test Plan**: <details> <summary>AI Text Generator</summary> - [X] Start-up backend and frontend: - Start backend with Docker services: `docker compose up -d --build` - Start frontend: `npm install && npm run dev` - By visiting http://localhost:3000/, test inference and structured outputs - [X] Create from scratch - [X] Request for Llama API Credentials <img width="2015" alt="image" src="https://github.com/user-attachments/assets/3dede402-3718-4441-9327-ecab25c63ebf" /> - [X] Execute an agent with at least 3 blocks <img width="2026" alt="image" src="https://github.com/user-attachments/assets/59d6d56b-2ccc-4af5-b511-4af312c3f7f8" /> - [X] Confirm it executes correctly </details> <details> <summary>Structured Response Generator</summary> - [X] Start-up backend and frontend: - Start backend with Docker services: `docker compose up -d --build` - Start frontend: `npm install && npm run dev` - By visiting http://localhost:3000/, test inference and structured outputs - [X] Create from scratch - [X] Execute an agent <img width="2023" alt="image" src="https://github.com/user-attachments/assets/d1107638-bf1b-45b1-a296-1e0fac29525b" /> - [X] Confirm it executes correctly </details> --------- Co-authored-by: Nicholas Tindle <nicholas.tindle@agpt.co> |
||
|
|
505320fcd3 |
feat(backend): Move Scheduler (#9904)
<!-- Clearly explain the need for these changes: --> We want the scheduler shouldn't scale with the rest API lol ### Changes 🏗️ pulls out the scheduler into its own service <!-- Concisely describe all of the changes made in this pull request: --> ### Checklist 📋 #### For code changes: - [x] I have clearly listed my changes in the PR description - [x] I have made a test plan - [x] I have tested my changes according to the test plan: <!-- Put your test plan here: --> - [x] test it --------- Co-authored-by: Zamil Majdy <zamil.majdy@agpt.co> |
||
|
|
fb5ce0a16d |
Add Note to "Getting Started" page for Raspberry Pi 5 page size issue (#9888)
Add Note to "Getting Started" page for Raspberry Pi 5 page size issue with `supabase-vector` that prevents `docker compose up` from running successfully. <!-- Clearly explain the need for these changes: --> ### Changes 🏗️ - Added a Note to the "Getting Started" page that explains a change in Raspberry Pi OS for Raspberry Pi 5s, and how to revert the change to avoid an issue running the backend on Docker. <!-- Concisely describe all of the changes made in this pull request: --> ### Checklist 📋 #### For code changes: - [x] No code changes #### For configuration changes: - [x] No configuration changes --------- Co-authored-by: Zamil Majdy <zamil.majdy@agpt.co> Co-authored-by: Nicholas Tindle <nicholas.tindle@agpt.co> |
||
|
|
3cf30c22fb |
update(docs): Remove outdated submodule command from docs (#9836)
### Changes 🏗️
Updates to the setup docs to remove the old unneeded ``git submodule
update --init --recursive --progress`` command + some other small tweaks
around it
|
||
|
|
ce98925d58 |
update(docs): Remove out dated tutorial video from docs & readme (#9753)
This is to remove the out dated tutorial video from docs & readme and add a direct link to the docs in the readme ### Changes 🏗️ Remove video link from readme.md Remove video link from https://github.com/Significant-Gravitas/AutoGPT/blob/dev/docs/content/platform/getting-started.md Add direct link to docs in readme.me |
||
|
|
d0d610720c |
docs(platform): Add WSL 2 recommendation for Docker on Windows (#9749)
In this pull request, the following changes have been made in response to Issue #9190: Documentation Changes: - Added a note to the AutoGPT documentation regarding Docker installation on Windows. - Specifically, the note advises users to opt for WSL2 (Windows Subsystem for Linux version 2) instead of Hyper-V during Docker setup to prevent issues with Supabase, such as the "unhealthy" status for supabase-db. --------- Co-authored-by: Madura Herath <madurah@verdentra.com> Co-authored-by: Bently <tomnoon9@gmail.com> |
||
|
|
4ca1a453c9 |
refactor(backend): Defer loading of .blocks and .integrations.webhooks on module init (#9664)
Currently, an import statement like `from backend.blocks.basic import AgentInputBlock` will initialize `backend.blocks` and thereby load all other blocks. This has quite high potential to cause circular import issues, and it's bad for performance in cases where we don't want to load all blocks (yet). The same goes for `backend.integrations.webhooks`. ### Changes 🏗️ - Change `__init__.py` of `backend.blocks` and `backend.integrations.webhooks` to cached loader functions rather than init-time code - Change type of `BlockWebhookConfig.provider` to `ProviderName` <!-- test edit to check that this doesn't break anything --> ### Checklist 📋 #### For code changes: - [x] I have clearly listed my changes in the PR description - [x] I have made a test plan - [x] I have tested my changes according to the test plan: - [x] Set up and use an agent with a webhook-triggered block --------- Co-authored-by: Zamil Majdy <zamil.majdy@agpt.co> |
||
|
|
780fddc2a0 |
feat(platform)!: Lock Supabase docker-compose code (#9620)
We have been submoduling Supabase for provisioning local Supabase instances using docker-compose. Aside from the huge size of unrelated code being pulled, there is also the risk of pulling unintentional breaking change from the upstream to the platform. The latest Supabase changes hide the 5432 port from the supabase-db container and shift it to the supavisor, the instance that we are currently not using. This causes an error in the existing setup. ## BREAKING CHANGES This change will introduce different volume locations for the database content, pulling this change will make the data content fresh from the start. To keep your old data with this change, execute this command: ``` cp -r supabase/docker/volumes/db/data db/docker/volumes/db/data ``` ### Changes 🏗️ The scope of this PR is snapshotting the current docker-compose code obtained from the Supabase repository and embedding it into our repository. This will eliminate the need for submodule / recursive cloning and bringing the entire Supabase repository into the platform. ### Checklist 📋 #### For code changes: - [x] I have clearly listed my changes in the PR description - [x] I have made a test plan - [x] I have tested my changes according to the test plan: <!-- Put your test plan here: --> - [x] Existing CI |
||
|
|
fa97632eae |
docs(online/offline): #8887 Move to a single source of truth for docs — Remove duplicate info from backend readme[.advanced].md (#9580)
addresses the changes requested here [Move to a single source of truth for docs — Remove duplicate info from readme #8887](https://github.com/Significant-Gravitas/AutoGPT/issues/8887) ### Changes 🏗️ <!-- Concisely describe all of the changes made in this pull request: --> changed readme files |
||
|
|
d050a3f77c |
docs: Provide feedback when cloning submodules (#9448)
<!-- Clearly explain the need for these changes: --> ### Changes 🏗️ Added `--progress` to the submodule update, so that cloning progress can be tracked and does not appear to hang. <!-- Concisely describe all of the changes made in this pull request: --> ### Checklist 📋 #### For code changes: - [x] No code change, just docs. <details> <summary>Example test plan</summary> - [ ] 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 </details> #### For configuration changes: - [x] No configuration change, just docs. <details> <summary> Provide feedback when cloning submodules </summary> - now updating submodules shows the cloning repo's progress </details> Co-authored-by: Your Name <you@example.com> |
||
|
|
a44c9333d3 |
feat(block) : Todoist rest api blocks (#9369)
- Resolves - #9303 and #9304 - Depends on - https://github.com/Significant-Gravitas/AutoGPT/pull/9319 ### Blocks list Block Name | What It Does | Manually Tested -- | -- | -- Todoist Create Label | Creates a new label in Todoist | ✅ Todoist List Labels | Retrieves all personal labels from Todoist | ✅ Todoist Get Label | Retrieves a specific label by ID | ✅ Todoist Create Task | Creates a new task in Todoist | ✅ Todoist Get Tasks | Retrieves active tasks from Todoist | ✅ Todoist Update Task | Updates an existing task | ✅ Todoist Close Task | Completes/closes a task | ✅ Todoist Reopen Task | Reopens a completed task | ✅ Todoist Delete Task | Permanently deletes a task | ✅ Todoist List Projects | Retrieves all projects from Todoist | ✅ Todoist Create Project | Creates a new project in Todoist | ✅ Todoist Get Project | Retrieves details for a specific project | ✅ Todoist Update Project | Updates an existing project | ✅ Todoist Delete Project | Deletes a project and its contents | ✅ Todoist List Collaborators | Retrieves collaborators on a project | ✅ Todoist List Sections | Retrieves sections from Todoist | ✅ Todoist Get Section | Retrieves details for a specific section | ✅ Todoist Delete Section | Deletes a section and its tasks | ✅ Todoist Create Comment | Creates a new comment on a task or project | ✅ Todoist Get Comments | Retrieves all comments for a task or project | ✅ Todoist Get Comment | Retrieves a specific comment by ID | ✅ Todoist Update Comment | Updates an existing comment | ✅ Todoist Delete Comment | Deletes a comment | ✅ > I’ve only created action blocks in Todoist because webhooks can only be manually created [we can't do it programatically right now]. I’ve already emailed Todoist for help, but they haven’t replied yet. Once I receive a reply, I’ll create a pull request for webhook triggers in Todoist. |
||
|
|
c5747c59d7 |
feat: mem0 ai memory block (#9285)
We want to have some more intelligent and less user managed memory methods, so we add mem0 ### Changes 🏗️ - Adds user_id to kwargs for blocks - Add mem0 blocks <!-- Concisely describe all of the changes made in this pull request: --> ### Checklist 📋 - [x] document adding user_id to kwargs for blocks - [x] Add run and agent Id as optional checkboxes that will be passed down to mem0 #### For code changes: - [x] I have clearly listed my changes in the PR description - [x] I have made a test plan - [ ] I have tested my changes according to the test plan: <!-- Put your test plan here: --> - [ ] Build and submit an agent to @Torantulino and the marketplace for a personal AI tutor based on recommendations from the mem0 team --------- Co-authored-by: Aarushi <50577581+aarushik93@users.noreply.github.com> Co-authored-by: Zamil Majdy <zamil.majdy@agpt.co> |
||
|
|
ac8a466cda |
feat(platform): Add username+password credentials type; fix email and reddit blocks (#9113)
<!-- Clearly explain the need for these changes: --> Update and adds a basic credential field for use in integrations like reddit ### Changes 🏗️ <!-- Concisely describe all of the changes made in this pull request: --> - Reddit - Drops the Username and Password for reddit from the .env - Updates Reddit block with modern provider and credential system - moves clientid and secret to reading from `Settings().secrets` rather than input on the block - moves user agent to `Settings().config` - SMTP - update the block to support user password and modern credentials - Add `UserPasswordCredentials` - Default API key expiry to None explicitly to help type cohesion - add `UserPasswordCredentials` with a weird form of `bearer` which we ideally remove because `basic` is a more appropriate name. This is dependent on `Webhook _base` allowing a subset of `Credentials` - Update `Credentials` and `CredentialsType` - Fix various `OAuth2Credentials | APIKeyCredentials` -> `Credentials` mismatches between base and derived classes - Replace `router/@post(create_api_key_credentials)` with `create_credentials` which now takes a credential and is discriminated by `type` provided by the credential - UI/Frontend - Updated various pages to have saved credential types, icons, and text for User Pass Credentials - Update credential input to have an input/modals/selects for user/pass combos - Update the types to support having user/pass credentials too (we should make this more centralized) - Update Credential Providres to support user_password - Update `client.ts` to support the new streamlined credential creation method and endpoint - DX - Sort the provider names **again** TODO: - [x] Reactivate Conditionally Disabling Reddit ~~- [ ] Look into moving Webhooks base to allow subset of `Credentials` rather than requiring all webhooks to support the input of all valid `Credentials` types~~ Out of scope - [x] Figure out the `singleCredential` calculator in `credentials-input.tsx` so that it also respects User Pass credentials and isn't a logic mess ### Checklist 📋 #### For code changes: - [x] I have clearly listed my changes in the PR description - [x] I have made a test plan - [x] I have tested my changes according to the test plan: <!-- Put your test plan here: --> - [x] Test with agents --------- Co-authored-by: Zamil Majdy <zamil.majdy@agpt.co> |
||
|
|
3c30783b14 |
docs(Ollama): Remove steps about adding ollama credentials (#9288)
Since ["feat: no longer require ollama key #9287"](https://github.com/Significant-Gravitas/AutoGPT/pull/9287) we no longer need the steps for adding ollama credentials so this removes them from the docs |
||
|
|
a1889e6212 |
docs(Ollama): Update Ollama docs (#9234)
The Ollama docs where very out of date and needed updating so I have updated them and added some screenshots so its easier to follow. I have also added a new Ollama model to the platform, "llama3.2" as that is what i based the tutorial off and its name is easy to find in the list of models I also added a new folder in the "imgs" dir to store the Ollama related photo just to keep things tidy |
||
|
|
b4a0100c22 |
feat(platform): Add Twitter integration (#8754)
- Resolves #8326 Create a Twitter integration with some small frontend changes. ### Changes 1. Add Twitter OAuth 2.0 with PKCE support for authentication. 2. Add a way to multi-select from a list of enums by creating a multi-select on the frontend. 3. Add blocks for Twitter integration. 4. `_types.py` for repetitive enums and input types. 5. `_builders.py` for creating parameters without repeating the same logic. 6. `_serializer.py` to serialize the Tweepy enums into dictionaries so they can travel easily from Pyro5. 7. `_mappers.py` to map the frontend values to the correct request values. > I have added a new multi-select feature because my list contains many items, and selecting all of them makes the block cluttered. This new block displays only the first two items and then show something like "2 more" . It works only for list of enums. ### Blocks Block Name | What It Does | Error Reason | Manual Testing -- | -- | -- | -- `TwitterBookmarkTweetBlock` | Bookmark a tweet on Twitter | No error | ✅ `TwitterGetBookmarkedTweetsBlock` | Get all your bookmarked tweets from Twitter | No error | ✅ `TwitterRemoveBookmarkTweetBlock` | Remove a bookmark for a tweet on Twitter | No error | ✅ `TwitterHideReplyBlock` | Hides a reply of one of your tweets | No error | ✅ `TwitterUnhideReplyBlock` | Unhides a reply to a tweet | No error | ✅ `TwitterLikeTweetBlock` | Likes a tweet | No error | ✅ `TwitterGetLikingUsersBlock` | Gets information about users who liked one of your tweets | No error | ✅ `TwitterGetLikedTweetsBlock` | Gets information about tweets liked by you | No error | ✅ `TwitterUnlikeTweetBlock` | Unlikes a tweet that was previously liked | No error | ✅ `TwitterPostTweetBlock` | Create a tweet on Twitter with the option to include one additional element such as media, quote, or deep link. | No error | ✅ `TwitterDeleteTweetBlock` | Deletes a tweet on Twitter using Twitter ID | No error | ✅ `TwitterSearchRecentTweetsBlock` | Searches all public Tweets in Twitter history | No error | ✅ `TwitterGetQuoteTweetsBlock` | Gets quote tweets for a specified tweet ID | No error | ✅ `TwitterRetweetBlock` | Retweets a tweet on Twitter | No error | ✅ `TwitterRemoveRetweetBlock` | Removes a retweet on Twitter | No error | ✅ `TwitterGetRetweetersBlock` | Gets information about who has retweeted a tweet | No error | ✅ `TwitterGetUserMentionsBlock` | Returns Tweets where a single user is mentioned, just put that user ID | No error | ✅ `TwitterGetHomeTimelineBlock` | Returns a collection of the most recent Tweets and Retweets posted by you and users you follow | No error | ✅ `TwitterGetUserTweetsBlock` | Returns Tweets composed by a single user, specified by the requested user ID | No error | ✅ `TwitterGetTweetBlock` | Returns information about a single Tweet specified by the requested ID | No error | ✅ `TwitterGetTweetsBlock` | Returns information about multiple Tweets specified by the requested IDs | No error | ✅ `TwitterUnblockUserBlock` | Unblock a specific user on Twitter | No error | ✅ `TwitterGetBlockedUsersBlock` | Get a list of users who are blocked by the authenticating user | No error | ✅ `TwitterBlockUserBlock` | Block a specific user on Twitter | No error | ✅ `TwitterUnfollowUserBlock` | Allows a user to unfollow another user specified by target user ID | No error | ✅ `TwitterFollowUserBlock` | Allows a user to follow another user specified by target user ID | No error | ✅ `TwitterGetFollowersBlock` | Retrieves a list of followers for a specified Twitter user ID | Need Enterprise level access | ❌ `TwitterGetFollowingBlock` | Retrieves a list of users that a specified Twitter user ID is following | Need Enterprise level access | ❌ `TwitterUnmuteUserBlock` | Allows a user to unmute another user specified by target user ID | No error | ✅ `TwitterGetMutedUsersBlock` | Returns a list of users who are muted by the authenticating user | No error | ✅ `TwitterMuteUserBlock` | Allows a user to mute another user specified by target user ID | No error | ✅ `TwitterGetUserBlock` | Gets information about a single Twitter user specified by ID or username | No error | ✅ `TwitterGetUsersBlock` | Gets information about multiple Twitter users specified by IDs or usernames | No error | ✅ `TwitterSearchSpacesBlock` | Returns live or scheduled Spaces matching specified search terms [for a week only] | No error | ✅ `TwitterGetSpacesBlock` | Gets information about multiple Twitter Spaces specified by Space IDs or creator user IDs | No error | ✅ `TwitterGetSpaceByIdBlock` | Gets information about a single Twitter Space specified by Space ID | No error | ✅ `TwitterGetSpaceBuyersBlock` | Gets list of users who purchased a ticket to the requested Space | I do not have a monetized account for this | ✅ `TwitterGetSpaceTweetsBlock` | Gets list of Tweets shared in the requested Space | No error | ✅ `TwitterUnfollowListBlock` | Unfollows a Twitter list for the authenticated user | No error | ✅ `TwitterFollowListBlock` | Follows a Twitter list for the authenticated user | No error | ✅ `TwitterListGetFollowersBlock` | Gets followers of a specified Twitter list | Enterprise level access | ❌ `TwitterGetFollowedListsBlock` | Gets lists followed by a specified Twitter user | Enterprise level access | ❌ `TwitterGetListBlock` | Gets information about a Twitter List specified by ID | No error | ✅ `TwitterGetOwnedListsBlock` | Gets all Lists owned by the specified user | No error | ✅ `TwitterRemoveListMemberBlock` | Removes a member from a Twitter List that the authenticated user owns | No error | ✅ `TwitterAddListMemberBlock` | Adds a member to a Twitter List that the authenticated user owns | No error | ✅ `TwitterGetListMembersBlock` | Gets the members of a specified Twitter List | No error | ✅ `TwitterGetListMembershipsBlock` | Gets all Lists that a specified user is a member of | No error | ✅ `TwitterGetListTweetsBlock` | Gets tweets from a specified Twitter list | No error | ✅ `TwitterDeleteListBlock` | Deletes a Twitter List owned by the authenticated user | No error | ✅ `TwitterUpdateListBlock` | Updates a Twitter List owned by the authenticated user | No error | ✅ `TwitterCreateListBlock` | Creates a Twitter List owned by the authenticated user | No error | ✅ `TwitterUnpinListBlock` | Enables the authenticated user to unpin a List. | No error | ✅ `TwitterPinListBlock` | Enables the authenticated user to pin a List. | No error | ✅ `TwitterGetPinnedListsBlock` | Returns the Lists pinned by the authenticated user. | No error | ✅ `TwitterGetDMEventsBlock` | Gets a list of Direct Message events for the authenticated user | Need Enterprise level access | ❌ `TwitterSendDirectMessageBlock` | Sends a direct message to a Twitter user | Need Enterprise level access | ❌ `TwitterCreateDMConversationBlock` | Creates a new group direct message | Need Enterprise level access | ❌ ### Need to add more stuff 1. A normal input to select date and time. 2. Some more enterprise-level blocks, especially webhook triggers. Supported triggers Event Name | Description -- | -- Posts (by user) | User creates a new post. Post deletes (by user) | User deletes an existing post. @mentions (of user) | User is mentioned in a post. Replies (to or from user) | User replies to a post or receives a reply from another user. Retweets (by user or of user) | User retweets a post or someone retweets the user's post. Quote Tweets (by user or of user) | User quote tweets a post or someone quote tweets the user's post. Retweets of Quoted Tweets (by user or of user) | Retweets of quote tweets by the user or of the user. Likes (by user or of user) | User likes a post or someone likes the user's post. Follows (by user or of user) | User follows another user or another user follows the user. Unfollows (by user) | User unfollows another user. Blocks (by user) | User blocks another user. Unblocks (by user) | User unblocks a previously blocked user. Mutes (by user) | User mutes another user. Unmutes (by user) | User unmutes a previously muted user. Direct Messages sent (by user) | User sends direct messages to other users. Direct Messages received (by user) | User receives direct messages from other users. Typing indicators (to user) | Indicators showing when someone is typing a message to the user. Read receipts (to user) | Indicators showing when the user has read a message. Subscription revokes (by user) | User revokes a subscription to a service or content. --------- Co-authored-by: Nicholas Tindle <nicholas.tindle@agpt.co> Co-authored-by: Nicholas Tindle <nicktindle@outlook.com> |
||
|
|
1375a0fdbc |
feat(platform): Support multiple credentials inputs on blocks (#8932)
- Resolves #8930 - Depends on #8725 ### Changes 🏗️ - feat(platform): Support multiple credentials inputs on blocks Aside from `credentials`, fields within the name pattern `*_credentials` are now also supported! - Update docs with info on multi credentials support ### Checklist 📋 #### For code changes: - [x] I have clearly listed my changes in the PR description - [x] I have made a test plan - [x] I have tested my changes according to the test plan: - [x] Ask @aarushik93 to test |
||
|
|
bb8a37911c |
feat: default for is featured (#9061)
<!-- Clearly explain the need for these changes: --> defaults is_featured to false |
||
|
|
33b9eef376 |
refactor(backend): Simplify CredentialsField usage + use ProviderName globally (#8725)
- Resolves #8931 - Follow-up to #8358 ### Changes 🏗️ - Avoid double specifying provider and cred types on `credentials` inputs - Move `credentials` sub-schema validation from `CredentialsField` to `CredentialsMetaInput.validate_credentials_field_schema(..)`, which is called in `BlockSchema.__pydantic_init_subclass__` - Use `ProviderName` enum globally |
||
|
|
b62f411518 |
feat(frontend): monitor tests (#8880)
<!-- Clearly explain the need for these changes: --> We want to be able to test the monitor page with importing and exporting agents ### Changes 🏗️ - Adds more test ids - Builds out monitor.page.ts - adds import export tests - Fixes #8791, fixes #8795, fixes #8792 <!-- Concisely describe all of the changes made in this pull request: --> ### 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: Writing/Running the automated tests |
||
|
|
eb79c04855 |
Incremental additions to platform documentation (#8898)
### Changes 🏗️ Adding incremental documentation based on YouTube series: - How to Submit an Agent to the AutoGPT Marketplace - How to Download and Import an Agent from the AutoGPT Marketplace (Local Hosting) - Creating a Basic AI Agent with AutoGPT - How to Edit an Agent in AutoGPT - How to Delete an Agent in AutoGPT --------- Co-authored-by: Bently <tomnoon9@gmail.com> Co-authored-by: Nicholas Tindle <nicholas.tindle@agpt.co> |
||
|
|
6b742d1a8c |
docs: add docs for writing playwright tests (#8877)
<!-- Clearly explain the need for these changes: --> Nick wants others to be able to write tests besides Nick ### Changes 🏗️ <!-- Concisely describe all of the changes made in this pull request: --> - Fixes various import errors across the docs to fix dead links - Adds Docs for making and debugging your own tests --------- Co-authored-by: Swifty <craigswift13@gmail.com> |
||
|
|
758edaec9e |
Adding Docs for Agent Blocks (#8845)
### Changes 🏗️ Adding docs for Agent Blocks Co-authored-by: Bently <tomnoon9@gmail.com> |
||
|
|
75f9b072a6 |
refactor(backend): Rename & move IntegrationCredentialsStore to backend (#8648)
- Move `autogpt_libs.supabase_integration_credentials_store` into `backend` - `.store` -> `backend.integrations.credentials_store` - `.types` -> added to `backend.data.model` - Rename `SupabaseIntegrationCredentialsStore` to `IntegrationCredentialsStore` We wanted to get a few security things in quickly in #8403 and had to make some compromises to do so. This picks those up and fixes them. - Resolves #8540 ### Checklist 📋 #### For code changes: - [x] I have clearly listed my changes in the PR description - [x] I have made a test plan - [x] I have tested my changes according to the test plan: <!-- Put your test plan here: --> --------- Co-authored-by: Reinier van der Leer <pwuts@agpt.co> Co-authored-by: Aarushi <50577581+aarushik93@users.noreply.github.com> |