DAO Proposals & Community

View active proposals, submit new ideas, and connect with the SWARMS community.

enhancement
FEAT

- Make an integration with x402 perhaps into the agent.py structure or aop.py

kyegomezProposed by kyegomez
View on GitHub →
bug
tests
[TESTS]

- Update test files for sequential workflow, hiearchical workflow, concurrent workflow, groupchat,

kyegomezProposed by kyegomez
View on GitHub →
6 days ago1 comments
dependencies
python

Bumps [pypdf](https://github.com/py-pdf/pypdf) from 5.1.0 to 6.1.3. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/py-pdf/pypdf/releases">pypdf's releases</a>.</em></p> <blockquote> <h2>Version 6.1.3, 2025-10-22</h2> <h2>What's new</h2> <h3>Security (SEC)</h3> <ul> <li>Allow limiting size of LZWDecode streams (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3502">#3502</a>) by <a href="https://github.com/stefan6419846"><code>@​stefan6419846</code></a></li> <li>Avoid infinite loop when reading broken DCT-based inline images (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3501">#3501</a>) by <a href="https://github.com/stefan6419846"><code>@​stefan6419846</code></a></li> </ul> <h3>Bug Fixes (BUG)</h3> <ul> <li>PageObject.scale() scales media box incorrectly (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3489">#3489</a>) by <a href="https://github.com/Nid01"><code>@​Nid01</code></a></li> </ul> <h3>Robustness (ROB)</h3> <ul> <li>Fail with explicit exception when image mode is an empty array (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3500">#3500</a>) by <a href="https://github.com/stefan6419846"><code>@​stefan6419846</code></a></li> </ul> <p><a href="https://github.com/py-pdf/pypdf/compare/6.1.2...6.1.3">Full Changelog</a></p> <h2>Version 6.1.2, 2025-10-19</h2> <h2>What's new</h2> <h3>Bug Fixes (BUG)</h3> <ul> <li>Fix handling of zero-length StreamObject (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3485">#3485</a>) by <a href="https://github.com/Likend"><code>@​Likend</code></a></li> </ul> <h3>Robustness (ROB)</h3> <ul> <li>Deal with wrong size for incremental PDF files (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3495">#3495</a>) by <a href="https://github.com/stefan6419846"><code>@​stefan6419846</code></a></li> <li>Improve handling for malformed cross-reference tables (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3483">#3483</a>) by <a href="https://github.com/stefan6419846"><code>@​stefan6419846</code></a></li> </ul> <h3>Developer Experience (DEV)</h3> <ul> <li>Use released Python 3.14 by <a href="https://github.com/stefan6419846"><code>@​stefan6419846</code></a></li> <li>Use Mapping instead of dict in type hint of update_page_form_field_values (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3490">#3490</a>) by <a href="https://github.com/stefan6419846"><code>@​stefan6419846</code></a></li> </ul> <p><a href="https://github.com/py-pdf/pypdf/compare/6.1.1...6.1.2">Full Changelog</a></p> <h2>Version 6.1.1, 2025-09-28</h2> <h2>What's new</h2> <h3>Bug Fixes (BUG)</h3> <ul> <li>Insert new embedded files in a sorted manner (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3477">#3477</a>) by <a href="https://github.com/stefan6419846"><code>@​stefan6419846</code></a></li> <li>Fix name tree handling for embedded files with Kids-based inputs (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3475">#3475</a>) by <a href="https://github.com/stefan6419846"><code>@​stefan6419846</code></a></li> <li>Make embedding files not break PDF/A-3 compliance (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3472">#3472</a>) by <a href="https://github.com/stefan6419846"><code>@​stefan6419846</code></a></li> </ul> <h3>Documentation (DOC)</h3> <ul> <li>Document AFRelationship handling for PDF/A and provide constants (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3478">#3478</a>) by <a href="https://github.com/stefan6419846"><code>@​stefan6419846</code></a></li> </ul> <p><a href="https://github.com/py-pdf/pypdf/compare/6.1.0...6.1.1">Full Changelog</a></p> <h2>Version 6.1.0, 2025-09-21</h2> <h2>What's new</h2> <h3>New Features (ENH)</h3> <ul> <li>Enhance XMP metadata handling with creation and setter methods (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3410">#3410</a>) by <a href="https://github.com/Arya-A-Nair"><code>@​Arya-A-Nair</code></a></li> <li>Add all font metrics for base 14 Type 1 PDF fonts (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3363">#3363</a>) by <a href="https://github.com/PJBrs"><code>@​PJBrs</code></a></li> </ul> <!-- raw HTML omitted --> </blockquote> <p>... (truncated)</p> </details> <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/py-pdf/pypdf/blob/main/CHANGELOG.md">pypdf's changelog</a>.</em></p> <blockquote> <h2>Version 6.1.3, 2025-10-22</h2> <h3>Security (SEC)</h3> <ul> <li>Allow limiting size of LZWDecode streams (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3502">#3502</a>)</li> <li>Avoid infinite loop when reading broken DCT-based inline images (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3501">#3501</a>)</li> </ul> <h3>Bug Fixes (BUG)</h3> <ul> <li>PageObject.scale() scales media box incorrectly (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3489">#3489</a>)</li> </ul> <h3>Robustness (ROB)</h3> <ul> <li>Fail with explicit exception when image mode is an empty array (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3500">#3500</a>)</li> </ul> <p><a href="https://github.com/py-pdf/pypdf/compare/6.1.2...6.1.3">Full Changelog</a></p> <h2>Version 6.1.2, 2025-10-19</h2> <h3>Bug Fixes (BUG)</h3> <ul> <li>Fix handling of zero-length StreamObject (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3485">#3485</a>)</li> </ul> <h3>Robustness (ROB)</h3> <ul> <li>Deal with wrong size for incremental PDF files (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3495">#3495</a>)</li> <li>Improve handling for malformed cross-reference tables (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3483">#3483</a>)</li> </ul> <h3>Developer Experience (DEV)</h3> <ul> <li>Use released Python 3.14</li> <li>Use Mapping instead of dict in type hint of update_page_form_field_values (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3490">#3490</a>)</li> </ul> <p><a href="https://github.com/py-pdf/pypdf/compare/6.1.1...6.1.2">Full Changelog</a></p> <h2>Version 6.1.1, 2025-09-28</h2> <h3>Bug Fixes (BUG)</h3> <ul> <li>Insert new embedded files in a sorted manner (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3477">#3477</a>)</li> <li>Fix name tree handling for embedded files with Kids-based inputs (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3475">#3475</a>)</li> <li>Make embedding files not break PDF/A-3 compliance (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3472">#3472</a>)</li> </ul> <h3>Documentation (DOC)</h3> <ul> <li>Document AFRelationship handling for PDF/A and provide constants (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3478">#3478</a>)</li> </ul> <p><a href="https://github.com/py-pdf/pypdf/compare/6.1.0...6.1.1">Full Changelog</a></p> <h2>Version 6.1.0, 2025-09-21</h2> <h3>New Features (ENH)</h3> <ul> <li>Enhance XMP metadata handling with creation and setter methods (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3410">#3410</a>)</li> <li>Add all font metrics for base 14 Type 1 PDF fonts (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3363">#3363</a>)</li> <li>Allow deleting embedded files (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3461">#3461</a>)</li> <li>Add support for Python in FIPS mode for document identifier (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3438">#3438</a>)</li> </ul> <h3>Bug Fixes (BUG)</h3> <!-- raw HTML omitted --> </blockquote> <p>... (truncated)</p> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/py-pdf/pypdf/commit/4a613f3fbe7af8ef65bbae740ceabe35310db4ee"><code>4a613f3</code></a> REL: 6.1.3</li> <li><a href="https://github.com/py-pdf/pypdf/commit/e51d07807ffcdaf18077b9486dadb3dc05b368da"><code>e51d078</code></a> SEC: Allow limiting size of LZWDecode streams (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3502">#3502</a>)</li> <li><a href="https://github.com/py-pdf/pypdf/commit/f2864d6dd9bac7cecd3f4f54308b25ebbfa178f8"><code>f2864d6</code></a> SEC: Avoid infinite loop when reading broken DCT-based inline images (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3501">#3501</a>)</li> <li><a href="https://github.com/py-pdf/pypdf/commit/b751ca2d3080dc24fa50393a0af5129643b3b6ce"><code>b751ca2</code></a> ROB: Fail with explicit exception when image mode is an empty array (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3500">#3500</a>)</li> <li><a href="https://github.com/py-pdf/pypdf/commit/e13a1e0d1b01454d68973662adbeecc08b623c22"><code>e13a1e0</code></a> BUG: PageObject.scale() scales media box incorrectly (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3489">#3489</a>)</li> <li><a href="https://github.com/py-pdf/pypdf/commit/0859b3579f5a0bd7a478c5405fb876a989e3b386"><code>0859b35</code></a> REL: 6.1.2</li> <li><a href="https://github.com/py-pdf/pypdf/commit/623a700342c0a7506fc88b5d112d25f28593787b"><code>623a700</code></a> BUG: Fix handling of zero-length StreamObject (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3485">#3485</a>)</li> <li><a href="https://github.com/py-pdf/pypdf/commit/16c4c443d062efbe4ac04cd8a2ee961b289743e7"><code>16c4c44</code></a> ROB: Deal with wrong size for incremental PDF files (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3495">#3495</a>)</li> <li><a href="https://github.com/py-pdf/pypdf/commit/54c0dd71f323485f53ed47154c251899ac6b0c92"><code>54c0dd7</code></a> DEV: Use released Python 3.14</li> <li><a href="https://github.com/py-pdf/pypdf/commit/9fad9ff0f2ded6c0792953547f968bb872161737"><code>9fad9ff</code></a> DEV: Use Mapping instead of dict in type hint of update_page_form_field_value...</li> <li>Additional commits viewable in <a href="https://github.com/py-pdf/pypdf/compare/5.1.0...6.1.3">compare view</a></li> </ul> </details> <br /> [![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=pypdf&package-manager=pip&previous-version=5.1.0&new-version=6.1.3)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) You can disable automated security fix PRs for this repo from the [Security Alerts page](https://github.com/kyegomez/swarms/network/alerts). </details> <!-- readthedocs-preview swarms start --> ---- 📚 Documentation preview 📚: https://swarms--1155.org.readthedocs.build/en/1155/ <!-- readthedocs-preview swarms end -->

dependabot[bot]Proposed by dependabot[bot]
View on GitHub →

- Look for structures with no tests - Create tests for them with pytest and only functions and no classes or anything else

kyegomezProposed by kyegomez
View on GitHub →

- Follow the OpenAI streaming format to send mini json responses of the responses

kyegomezProposed by kyegomez
View on GitHub →
8 days ago1 comments
dependencies
python

Bumps [pypdf](https://github.com/py-pdf/pypdf) from 5.1.0 to 6.1.2. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/py-pdf/pypdf/releases">pypdf's releases</a>.</em></p> <blockquote> <h2>Version 6.1.2, 2025-10-19</h2> <h2>What's new</h2> <h3>Bug Fixes (BUG)</h3> <ul> <li>Fix handling of zero-length StreamObject (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3485">#3485</a>) by <a href="https://github.com/Likend"><code>@​Likend</code></a></li> </ul> <h3>Robustness (ROB)</h3> <ul> <li>Deal with wrong size for incremental PDF files (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3495">#3495</a>) by <a href="https://github.com/stefan6419846"><code>@​stefan6419846</code></a></li> <li>Improve handling for malformed cross-reference tables (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3483">#3483</a>) by <a href="https://github.com/stefan6419846"><code>@​stefan6419846</code></a></li> </ul> <h3>Developer Experience (DEV)</h3> <ul> <li>Use released Python 3.14 by <a href="https://github.com/stefan6419846"><code>@​stefan6419846</code></a></li> <li>Use Mapping instead of dict in type hint of update_page_form_field_values (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3490">#3490</a>) by <a href="https://github.com/stefan6419846"><code>@​stefan6419846</code></a></li> </ul> <p><a href="https://github.com/py-pdf/pypdf/compare/6.1.1...6.1.2">Full Changelog</a></p> <h2>Version 6.1.1, 2025-09-28</h2> <h2>What's new</h2> <h3>Bug Fixes (BUG)</h3> <ul> <li>Insert new embedded files in a sorted manner (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3477">#3477</a>) by <a href="https://github.com/stefan6419846"><code>@​stefan6419846</code></a></li> <li>Fix name tree handling for embedded files with Kids-based inputs (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3475">#3475</a>) by <a href="https://github.com/stefan6419846"><code>@​stefan6419846</code></a></li> <li>Make embedding files not break PDF/A-3 compliance (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3472">#3472</a>) by <a href="https://github.com/stefan6419846"><code>@​stefan6419846</code></a></li> </ul> <h3>Documentation (DOC)</h3> <ul> <li>Document AFRelationship handling for PDF/A and provide constants (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3478">#3478</a>) by <a href="https://github.com/stefan6419846"><code>@​stefan6419846</code></a></li> </ul> <p><a href="https://github.com/py-pdf/pypdf/compare/6.1.0...6.1.1">Full Changelog</a></p> <h2>Version 6.1.0, 2025-09-21</h2> <h2>What's new</h2> <h3>New Features (ENH)</h3> <ul> <li>Enhance XMP metadata handling with creation and setter methods (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3410">#3410</a>) by <a href="https://github.com/Arya-A-Nair"><code>@​Arya-A-Nair</code></a></li> <li>Add all font metrics for base 14 Type 1 PDF fonts (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3363">#3363</a>) by <a href="https://github.com/PJBrs"><code>@​PJBrs</code></a></li> <li>Allow deleting embedded files (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3461">#3461</a>) by <a href="https://github.com/stefan6419846"><code>@​stefan6419846</code></a></li> <li>Add support for Python in FIPS mode for document identifier (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3438">#3438</a>) by <a href="https://github.com/xnox"><code>@​xnox</code></a></li> </ul> <h3>Bug Fixes (BUG)</h3> <ul> <li>Fix handling of UTF-16 encoded destination titles (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3463">#3463</a>) by <a href="https://github.com/stefan6419846"><code>@​stefan6419846</code></a></li> <li>Guard empty input to prevent IndexError (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3448">#3448</a>) by <a href="https://github.com/KyleJung0828"><code>@​KyleJung0828</code></a></li> </ul> <h3>Developer Experience (DEV)</h3> <ul> <li>Fix type hint for XMP metadata setter to add bytes type (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3464">#3464</a>) by <a href="https://github.com/stefan6419846"><code>@​stefan6419846</code></a></li> </ul> <p><a href="https://github.com/py-pdf/pypdf/compare/6.0.0...6.1.0">Full Changelog</a></p> <h2>Version 6.0.0, 2025-08-11</h2> <h2>What's new</h2> <!-- raw HTML omitted --> </blockquote> <p>... (truncated)</p> </details> <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/py-pdf/pypdf/blob/main/CHANGELOG.md">pypdf's changelog</a>.</em></p> <blockquote> <h2>Version 6.1.2, 2025-10-19</h2> <h3>Bug Fixes (BUG)</h3> <ul> <li>Fix handling of zero-length StreamObject (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3485">#3485</a>)</li> </ul> <h3>Robustness (ROB)</h3> <ul> <li>Deal with wrong size for incremental PDF files (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3495">#3495</a>)</li> <li>Improve handling for malformed cross-reference tables (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3483">#3483</a>)</li> </ul> <h3>Developer Experience (DEV)</h3> <ul> <li>Use released Python 3.14</li> <li>Use Mapping instead of dict in type hint of update_page_form_field_values (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3490">#3490</a>)</li> </ul> <p><a href="https://github.com/py-pdf/pypdf/compare/6.1.1...6.1.2">Full Changelog</a></p> <h2>Version 6.1.1, 2025-09-28</h2> <h3>Bug Fixes (BUG)</h3> <ul> <li>Insert new embedded files in a sorted manner (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3477">#3477</a>)</li> <li>Fix name tree handling for embedded files with Kids-based inputs (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3475">#3475</a>)</li> <li>Make embedding files not break PDF/A-3 compliance (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3472">#3472</a>)</li> </ul> <h3>Documentation (DOC)</h3> <ul> <li>Document AFRelationship handling for PDF/A and provide constants (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3478">#3478</a>)</li> </ul> <p><a href="https://github.com/py-pdf/pypdf/compare/6.1.0...6.1.1">Full Changelog</a></p> <h2>Version 6.1.0, 2025-09-21</h2> <h3>New Features (ENH)</h3> <ul> <li>Enhance XMP metadata handling with creation and setter methods (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3410">#3410</a>)</li> <li>Add all font metrics for base 14 Type 1 PDF fonts (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3363">#3363</a>)</li> <li>Allow deleting embedded files (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3461">#3461</a>)</li> <li>Add support for Python in FIPS mode for document identifier (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3438">#3438</a>)</li> </ul> <h3>Bug Fixes (BUG)</h3> <ul> <li>Fix handling of UTF-16 encoded destination titles (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3463">#3463</a>)</li> <li>Guard empty input to prevent IndexError (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3448">#3448</a>)</li> </ul> <h3>Developer Experience (DEV)</h3> <ul> <li>Fix type hint for XMP metadata setter to add bytes type (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3464">#3464</a>)</li> </ul> <p><a href="https://github.com/py-pdf/pypdf/compare/6.0.0...6.1.0">Full Changelog</a></p> <h2>Version 6.0.0, 2025-08-11</h2> <h3>Security (SEC)</h3> <ul> <li>Limit decompressed size for FlateDecode filter (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3430">#3430</a>)</li> </ul> <h3>Deprecations (DEP)</h3> <!-- raw HTML omitted --> </blockquote> <p>... (truncated)</p> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/py-pdf/pypdf/commit/0859b3579f5a0bd7a478c5405fb876a989e3b386"><code>0859b35</code></a> REL: 6.1.2</li> <li><a href="https://github.com/py-pdf/pypdf/commit/623a700342c0a7506fc88b5d112d25f28593787b"><code>623a700</code></a> BUG: Fix handling of zero-length StreamObject (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3485">#3485</a>)</li> <li><a href="https://github.com/py-pdf/pypdf/commit/16c4c443d062efbe4ac04cd8a2ee961b289743e7"><code>16c4c44</code></a> ROB: Deal with wrong size for incremental PDF files (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3495">#3495</a>)</li> <li><a href="https://github.com/py-pdf/pypdf/commit/54c0dd71f323485f53ed47154c251899ac6b0c92"><code>54c0dd7</code></a> DEV: Use released Python 3.14</li> <li><a href="https://github.com/py-pdf/pypdf/commit/9fad9ff0f2ded6c0792953547f968bb872161737"><code>9fad9ff</code></a> DEV: Use Mapping instead of dict in type hint of update_page_form_field_value...</li> <li><a href="https://github.com/py-pdf/pypdf/commit/2b2eca26ac97e035044d5aa9b25c22a61594c1c8"><code>2b2eca2</code></a> ROB: Improve handling for malformed cross-reference tables (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3483">#3483</a>)</li> <li><a href="https://github.com/py-pdf/pypdf/commit/9cb878c3f90a665a59e442d3c09da7b7b2a88af6"><code>9cb878c</code></a> REL: 6.1.1</li> <li><a href="https://github.com/py-pdf/pypdf/commit/5848de32442033f03ad2c39bf3788f2853063268"><code>5848de3</code></a> DOC: Document AFRelationship handling for PDF/A and provide constants (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3478">#3478</a>)</li> <li><a href="https://github.com/py-pdf/pypdf/commit/322d810faa305f48c4cc487ea57534d87e0d0508"><code>322d810</code></a> STY: Use removeprefix (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3469">#3469</a>)</li> <li><a href="https://github.com/py-pdf/pypdf/commit/506a1102a78eda2c2c32fc424c01fc73d8f5ad0a"><code>506a110</code></a> BUG: Insert new embedded files in a sorted manner (<a href="https://redirect.github.com/py-pdf/pypdf/issues/3477">#3477</a>)</li> <li>Additional commits viewable in <a href="https://github.com/py-pdf/pypdf/compare/5.1.0...6.1.2">compare view</a></li> </ul> </details> <br /> [![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=pypdf&package-manager=pip&previous-version=5.1.0&new-version=6.1.2)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) </details> <!-- readthedocs-preview swarms start --> ---- 📚 Documentation preview 📚: https://swarms--1149.org.readthedocs.build/en/1149/ <!-- readthedocs-preview swarms end -->

dependabot[bot]Proposed by dependabot[bot]
View on GitHub →
documentation
tests
structs

- Description: NEW feature that introduces custom streaming to the consensus agent with agents running concurrently. - Issue: Resolves #1061 - DEMO: https://www.loom.com/share/c56897ab606c4b6782f905acb45e54c0 <!-- readthedocs-preview swarms start --> ---- 📚 Documentation preview 📚: https://swarms--1147.org.readthedocs.build/en/1147/ <!-- readthedocs-preview swarms end -->

aparekh02Proposed by aparekh02
View on GitHub →

- Problem: uvloop (e.g., 0.21.0) fails to install/compile/run on Python 3.14t. - Impact: Any code path that tries to set uvloop policy will error. - Only solution until uvloop supports 3.14t: use stdlib asyncio loops - Unix/macOS: SelectorEventLoop (DefaultEventLoopPolicy) - Windows: ProactorEventLoop (WindowsProactorEventLoopPolicy) Code example (swarms/structs/multi_agent_exec.py) Old code (full, uvloop/winloop): ``` def run_agents_concurrently_uvloop( agents: List[AgentType], task: str, max_workers: Optional[int] = None, ) -> List[Any]: """ Run multiple agents concurrently using optimized async performance with uvloop/winloop. """ # Platform-specific event loop policy setup if sys.platform in ("win32", "cygwin"): # Windows: Try to use winloop try: import winloop asyncio.set_event_loop_policy(winloop.EventLoopPolicy()) logger.info("Using winloop for enhanced Windows performance") except ImportError: logger.warning( "winloop not available, falling back to standard asyncio. " "Install winloop with: pip install winloop" ) except RuntimeError as e: logger.warning( f"Could not set winloop policy: {e}. Using default asyncio." ) else: # Linux/macOS: Try to use uvloop try: import uvloop asyncio.set_event_loop_policy(uvloop.EventLoopPolicy()) logger.info("Using uvloop for enhanced Unix performance") except ImportError: logger.warning( "uvloop not available, falling back to standard asyncio. " "Install uvloop with: pip install uvloop" ) except RuntimeError as e: logger.warning( f"Could not set uvloop policy: {e}. Using default asyncio." ) if max_workers is None: # Use 95% of available CPU cores for optimal performance num_cores = os.cpu_count() max_workers = int(num_cores * 0.95) if num_cores else 1 logger.info( f"Running {len(agents)} agents concurrently with uvloop (max_workers: {max_workers})" ) async def run_agents_async(): results = [] def run_agent_sync(agent: AgentType) -> Any: return agent.run(task=task) loop = asyncio.get_event_loop() with ThreadPoolExecutor(max_workers=max_workers) as executor: tasks = [ loop.run_in_executor(executor, run_agent_sync, agent) for agent in agents ] completed_tasks = await asyncio.gather( *tasks, return_exceptions=True ) for result in completed_tasks: results.append(result) return results try: return asyncio.run(run_agents_async()) except RuntimeError as e: if "already running" in str(e).lower(): loop = asyncio.get_event_loop() return loop.run_until_complete(run_agents_async()) else: raise ``` New code (full, stdlib asyncio policies): ``` def run_agents_concurrently_uvloop( agents: List[AgentType], task: str, max_workers: Optional[int] = None, ) -> List[Any]: """ Run multiple agents concurrently using stdlib asyncio policies. """ # Platform-specific event loop policy setup (stdlib asyncio only) try: if sys.platform in ("win32", "cygwin"): # import winloop # not used on Python 3.14t # asyncio.set_event_loop_policy(winloop.EventLoopPolicy()) asyncio.set_event_loop_policy(asyncio.WindowsProactorEventLoopPolicy()) logger.info("Using stdlib WindowsProactorEventLoopPolicy for Windows") else: # import uvloop # not used on Python 3.14t # asyncio.set_event_loop_policy(uvloop.EventLoopPolicy()) asyncio.set_event_loop_policy(asyncio.DefaultEventLoopPolicy()) logger.info("Using stdlib DefaultEventLoopPolicy for Unix-like systems") except RuntimeError as e: logger.warning( f"Could not set asyncio policy: {e}. Continuing with existing policy." ) if max_workers is None: # Use 95% of available CPU cores for optimal performance num_cores = os.cpu_count() max_workers = int(num_cores * 0.95) if num_cores else 1 logger.info( f"Running {len(agents)} agents concurrently with stdlib asyncio (max_workers: {max_workers})" ) async def run_agents_async(): results = [] def run_agent_sync(agent: AgentType) -> Any: return agent.run(task=task) loop = asyncio.get_event_loop() with ThreadPoolExecutor(max_workers=max_workers) as executor: tasks = [ loop.run_in_executor(executor, run_agent_sync, agent) for agent in agents ] completed_tasks = await asyncio.gather( *tasks, return_exceptions=True ) for result in completed_tasks: results.append(result) return results try: return asyncio.run(run_agents_async()) except RuntimeError as e: if "already running" in str(e).lower(): loop = asyncio.get_event_loop() return loop.run_until_complete(run_agents_async()) else: raise ```

IlumCIProposed by IlumCI
View on GitHub →

Description: Fix MultiAgentRouter model compatibility issues with structured outputs and JSON parsing Issue: https://github.com/kyegomez/swarms/issues/1137 Dependencies: none Tag maintainer: @kyegomez Twitter handle: https://x.com/IlumTheProtogen Changes made: 1. Added conditional structured outputs - only sets response_format for models that support json_schema (gpt-4.1, gpt-4o, o3-*, o4-*) 2. Added JSON parsing fallback for models without structured outputs - routes to first available agent when JSON parsing fails 3. Updated model names in test file to use correct LiteLLM conventions (anthropic/claude-*, gemini/gemini-*) Why it didn't work last time: The router was unconditionally setting response_format=MultipleHandOffsResponse for all models, causing BadRequestError on models like gpt-3.5-turbo that don't support json_schema structured outputs. Additionally, model names were using incorrect formats (claude-3-5-sonnet instead of anthropic/claude-3-5-sonnet-20241022) causing provider resolution failures. Testing: - gpt-4.1, gpt-4o, o3-mini: Success with structured outputs - gpt-3.5-turbo: Success with JSON parsing fallback - Anthropic/Google models: Fail only due to missing API keys (expected behavior) Results: ``` ===== Model Run Summary ===== gpt-4.1: ✅ Success gpt-4o: ✅ Success gpt-3.5-turbo: ✅ Success gpt-4.1: ✅ Success o3-mini: ✅ Success anthropic/claude-3-5-sonnet-20241022: ❌ Error: litellm.AuthenticationError: AnthropicException - {"type":"error","error":{"type":"authentication_error","message":"x-api-key header is required"},"request_id":"req_011CU5WbPhYDzgh6k3TCBmym"}``` <!-- readthedocs-preview swarms start --> ---- 📚 Documentation preview 📚: https://swarms--1142.org.readthedocs.build/en/1142/ <!-- readthedocs-preview swarms end -->

IlumCIProposed by IlumCI
View on GitHub →
tests
structs
tools
utils

Thank you for contributing to Swarms! Replace this comment with: - Description: a description of the change, - Issue: the issue # it fixes (if applicable), - Dependencies: any dependencies required for this change, - Tag maintainer: for a quicker response, tag the relevant maintainer (see below), - Twitter handle: we announce bigger features on Twitter. If your PR gets announced and you'd like a mention, we'll gladly shout you out! Please make sure your PR is passing linting and testing before submitting. Run `make format`, `make lint` and `make test` to check this locally. See contribution guidelines for more information on how to write/run tests, lint, etc: https://github.com/kyegomez/swarms/blob/master/CONTRIBUTING.md If you're adding a new integration, please include: 1. a test for the integration, preferably unit tests that do not rely on network access, 2. an example notebook showing its use. Maintainer responsibilities: - General / Misc / if you don't know who to tag: kye@swarms.world - DataLoaders / VectorStores / Retrievers: kye@swarms.world - swarms.models: kye@swarms.world - swarms.memory: kye@swarms.world - swarms.structures: kye@swarms.world If no one reviews your PR within a few days, feel free to email Kye at kye@swarms.world See contribution guidelines for more information on how to write/run tests, lint, etc: https://github.com/kyegomez/swarms <!-- readthedocs-preview swarms start --> ---- 📚 Documentation preview 📚: https://swarms--1133.org.readthedocs.build/en/1133/ <!-- readthedocs-preview swarms end -->

chethanukProposed by chethanuk
View on GitHub →
tests
[TESTS]

- Download python3.14t with this guide: https://medium.com/@kyeg/executing-multiple-agents-in-parallel-with-python-3-14-free-threaded-version-4d857d9c4639 - Run all the examples on the readme.md - See if everything is good

kyegomezProposed by kyegomez
View on GitHub →

- Description: Docs from 3 demo/examples: Job Finding, M&A Swarm, and Real Estate Swarm. <!-- readthedocs-preview swarms start --> ---- 📚 Documentation preview 📚: https://swarms--1127.org.readthedocs.build/en/1127/ <!-- readthedocs-preview swarms end -->

aparekh02Proposed by aparekh02
View on GitHub →
structs

## Description Fixed multiple issues in AutoSwarmBuilder that were preventing the execute-swarm-router execution type from working correctly. ## Issue https://github.com/kyegomez/swarms/issues/1115 ## Dependencies No new dependencies required. ## Tag maintainer @kyegomez ## Twitter handle https://x.com/IlumTheProtogen ## Code Changes ### Problem: Missing execute-swarm-router execution type in run method ```python # OLD CODE (broken): def run(self, task: str, *args, **kwargs): try: if self.execution_type == "return-agents": return self.create_agents(task) elif self.execution_type == "return-swarm-router-config": return self.create_router_config(task) elif self.execution_type == "return-agents-objects": agents = self.create_agents(task) return self.create_agents_from_specs(agents) else: raise ValueError(f"Invalid execution type: {self.execution_type}") ``` The execute-swarm-router execution type was missing, preventing _execute_task from being called. ### Solution: Added execute-swarm-router execution type ```python # NEW CODE (working): def run(self, task: str, *args, **kwargs): try: if self.execution_type == "return-agents": return self.create_agents(task) elif self.execution_type == "execute-swarm-router": return self._execute_task(task) elif self.execution_type == "return-swarm-router-config": return self.create_router_config(task) elif self.execution_type == "return-agents-objects": agents = self.create_agents(task) return self.create_agents_from_specs(agents) else: raise ValueError(f"Invalid execution type: {self.execution_type}") ``` ### Problem: Missing JSON parsing in create_agents method ```python # OLD CODE (broken): def create_agents(self, task: str): try: logger.info("Creating agents from specifications") model = self.build_llm_agent(config=Agents) agents_dictionary = model.run(task) return agents_dictionary ``` The LLM returns a JSON string, but the code expected a dictionary. ### Solution: Added JSON parsing ```python # NEW CODE (working): def create_agents(self, task: str): try: logger.info("Creating agents from specifications") model = self.build_llm_agent(config=Agents) agents_dictionary = model.run(task) # Parse JSON string if needed if isinstance(agents_dictionary, str): agents_dictionary = json.loads(agents_dictionary) return agents_dictionary ``` ### Problem: AgentSpec to Agent conversion issue ```python # OLD CODE (broken): for agent_config in agents_list: if isinstance(agent_config, dict): agent_config = AgentSpec(**agent_config) agent = Agent(**agent_config) # TypeError: Agent() argument after ** must be a mapping, not AgentSpec ``` ### Solution: Convert AgentSpec to dictionary ```python # NEW CODE (working): for agent_config in agents_list: if isinstance(agent_config, dict): agent_config = AgentSpec(**agent_config) # Convert AgentSpec to dict for Agent constructor if hasattr(agent_config, 'dict'): agent_dict = agent_config.dict() elif hasattr(agent_config, 'model_dump'): agent_dict = agent_config.model_dump() else: agent_dict = agent_config agent = Agent(**agent_dict) agents.append(agent) ``` The fix ensures AutoSwarmBuilder can successfully create agents and execute swarm workflows with the execute-swarm-router execution type. <!-- readthedocs-preview swarms start --> ---- 📚 Documentation preview 📚: https://swarms--1117.org.readthedocs.build/en/1117/ <!-- readthedocs-preview swarms end -->

IlumCIProposed by IlumCI
View on GitHub →
documentation

- Description: a swarm that helps advise in Mergers & Acquisition (M&A) for a user based on a given company with a mix of specialized agents. - DEMO: https://www.loom.com/share/921ac68f5f5d4ae8bf715cc8afb3cda8 <!-- readthedocs-preview swarms start --> ---- 📚 Documentation preview 📚: https://swarms--1107.org.readthedocs.build/en/1107/ <!-- readthedocs-preview swarms end -->

aparekh02Proposed by aparekh02
View on GitHub →
documentation

- Description: Helping user find jobs in different needs and searching on internet to find the most optimal job opportunities for the user based on personalized info. - DEMO: https://www.loom.com/share/a1c78fbb4ecf498ca4e4983a3fab0eb5?sid=921b9444-9670-45e6-b647-c26298a920b0 <!-- readthedocs-preview swarms start --> ---- 📚 Documentation preview 📚: https://swarms--1103.org.readthedocs.build/en/1103/ <!-- readthedocs-preview swarms end -->

aparekh02Proposed by aparekh02
View on GitHub →
documentation
dependencies
python

Updates the requirements on [markdown](https://github.com/Python-Markdown/markdown) to permit the latest version. <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/Python-Markdown/markdown/blob/master/docs/changelog.md">markdown's changelog</a>.</em></p> <blockquote> <p>title: Changelog toc_depth: 2</p> <h1>Python-Markdown Changelog</h1> <p>All notable changes to this project will be documented in this file.</p> <p>The format is based on <a href="https://keepachangelog.com/en/1.1.0/">Keep a Changelog</a>, and this project adheres to the <a href="https://packaging.python.org/en/latest/specifications/version-specifiers/">Python Version Specification</a>. See the <a href="https://github.com/Python-Markdown/markdown/blob/master/docs/contributing.md">Contributing Guide</a> for details.</p> <h2>[Unreleased]</h2> <h3>Fixed</h3> <ul> <li>Fix an HTML comment parsing case in some Python versions that can cause an infinite loop (<a href="https://redirect.github.com/Python-Markdown/markdown/issues/1554">#1554</a>).</li> </ul> <h2>[3.9.0] - 2025-09-04</h2> <h3>Changed</h3> <ul> <li>Footnotes are now ordered by the occurrence of their references in the document. A new configuration option for the footnotes extension, <code>USE_DEFINITION_ORDER</code>, has been added to support restoring the previous behavior of ordering footnotes by the occurrence of definitions (<a href="https://redirect.github.com/Python-Markdown/markdown/issues/1367">#1367</a>).</li> </ul> <h3>Fixed</h3> <ul> <li>Ensure inline processing iterates through elements in document order (<a href="https://redirect.github.com/Python-Markdown/markdown/issues/1546">#1546</a>).</li> <li>Fix handling of incomplete HTML tags in code spans in Python 3.14 (<a href="https://redirect.github.com/Python-Markdown/markdown/issues/1547">#1547</a>).</li> </ul> <h2>[3.8.2] - 2025-06-19</h2> <h3>Fixed</h3> <ul> <li>Fix <code>codecs</code> deprecation in Python 3.14 (<a href="https://redirect.github.com/Python-Markdown/markdown/issues/1537">#1537</a>).</li> <li>Fix issue with unclosed comment parsing in Python 3.14 (<a href="https://redirect.github.com/Python-Markdown/markdown/issues/1537">#1537</a>).</li> <li>Fix issue with unclosed declarations in Python 3.14 (<a href="https://redirect.github.com/Python-Markdown/markdown/issues/1537">#1537</a>).</li> <li>Fix issue with unclosed HTML tag <code>&lt;foo</code> and Python 3.14 (<a href="https://redirect.github.com/Python-Markdown/markdown/issues/1537">#1537</a>).</li> </ul> <h2>[3.8.1] - 2025-06-18</h2> <h3>Fixed</h3> <ul> <li>Ensure incomplete markup declaration in raw HTML doesn't crash parser (<a href="https://redirect.github.com/Python-Markdown/markdown/issues/1534">#1534</a>).</li> <li>Fixed dropped content in <code>md_in_html</code> (<a href="https://redirect.github.com/Python-Markdown/markdown/issues/1526">#1526</a>).</li> <li>Fixed HTML handling corner case that prevented some content from not being rendered (<a href="https://redirect.github.com/Python-Markdown/markdown/issues/1528">#1528</a>).</li> </ul> <h2>[3.8.0] - 2025-04-09</h2> <!-- raw HTML omitted --> </blockquote> <p>... (truncated)</p> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/Python-Markdown/markdown/commit/f39cf84a24124526c1a0efbe52219fa9950774f6"><code>f39cf84</code></a> Bump version to 3.9</li> <li><a href="https://github.com/Python-Markdown/markdown/commit/07bf2076623be5de9952e1f35bfb8c218b699300"><code>07bf207</code></a> Order footnotes by reference</li> <li><a href="https://github.com/Python-Markdown/markdown/commit/23c301de28e12426408656efdfa153b11d4ff558"><code>23c301d</code></a> Fix failing cases for Python 3.14</li> <li><a href="https://github.com/Python-Markdown/markdown/commit/4669a09894d4a35cd5f5d2106b0da95e48d1a3f9"><code>4669a09</code></a> fix typo</li> <li><a href="https://github.com/Python-Markdown/markdown/commit/d9c8431e404d614812e39a11109afbe9981bba13"><code>d9c8431</code></a> Bump version to 3.8.2</li> <li><a href="https://github.com/Python-Markdown/markdown/commit/9980cb5b27b07ff48283178d98213e41543701ec"><code>9980cb5</code></a> Fixes for Python 3.14</li> <li><a href="https://github.com/Python-Markdown/markdown/commit/3561310d30dac10c47f0b9fc404b167fc65331b0"><code>3561310</code></a> Properly document version specification.</li> <li><a href="https://github.com/Python-Markdown/markdown/commit/3bb9d42b93dae519d4f5a6eea970a571232e05e2"><code>3bb9d42</code></a> Update documentation for release process</li> <li><a href="https://github.com/Python-Markdown/markdown/commit/3870f20ba1dd214609b380e921dffc5f115730f5"><code>3870f20</code></a> Bump version to 3.8.1</li> <li><a href="https://github.com/Python-Markdown/markdown/commit/820721485c928c6f97f3d74f37afb6d2450aef9e"><code>8207214</code></a> Ensure incomplete markup declaration in raw HTML doesn't crash parser.</li> <li>Additional commits viewable in <a href="https://github.com/Python-Markdown/markdown/compare/3.8...3.9.0">compare view</a></li> </ul> </details> <br /> Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) </details> <!-- readthedocs-preview swarms start --> ---- 📚 Documentation preview 📚: https://swarms--1100.org.readthedocs.build/en/1100/ <!-- readthedocs-preview swarms end -->

dependabot[bot]Proposed by dependabot[bot]
View on GitHub →
30 days ago0 comments
documentation

- Description: A swarm that helps with getting data on customer preferences and provides with a full report on how to progress with real estate purchases & consulting. - Demo: https://www.loom.com/share/3c38858615bd48b9840ada03483a3f9b?sid=ffe4eefd-5f00-4494-9c6e-cbd75a7a259e <!-- readthedocs-preview swarms start --> ---- 📚 Documentation preview 📚: https://swarms--1097.org.readthedocs.build/en/1097/ <!-- readthedocs-preview swarms end -->

aparekh02Proposed by aparekh02
View on GitHub →

## Description This PR introduces **ElectionSwarm**, a sophisticated multi-agent orchestrator selection system that implements democratic decision-making protocols for leadership selection in multi-agent workflows. The system enables agent voters to elect the best orchestrator candidate through various coordination algorithms, providing a structured approach to leadership selection. ### Key Features Added: 1. **ElectionSwarm Core System** (`swarms/structs/election_swarm.py`): - Democratic election workflow with voter registration and candidate presentation - Multiple election algorithms: Leader Election, Consensus Building, Director-CEO Matching - AGENTSNET-inspired message passing protocols for voter coordination - Structured voting with detailed reasoning, confidence scores, and candidate rankings - Vote counting system with dedicated vote counter role - Comprehensive election result tracking and presentation 2. **Vote Counter Integration**: - New `VoteCounterProfile` dataclass for dedicated vote counting agents - `VoteCountingResult` dataclass for detailed vote analysis - Enhanced `ElectionResult` to include vote counting information - Automated vote counting and result presentation 3. **Real-World Example** (`examples/multi_agent/election_swarm/real_world_election.py`): - Complete CEO election simulation with board of directors - Multiple candidate profiles with different leadership styles - Vote counter integration for transparent results - Elected CEO task execution with renewable energy market expansion - Silent operation with no print statements 4. **Documentation** (`docs/swarms/structs/election_swarm.md`): - Comprehensive documentation with architecture diagrams - Usage examples and API reference - Quick start guide with import instructions 5. **Package Integration**: - Added `ElectionSwarm` to `swarms/structs/__init__.py` exports - Proper module structure for public API access ### Architecture: ```mermaid graph TD A[User Task] --> B[ElectionSwarm] B --> C[Voter Registration] B --> D[Candidate Registration] C --> E[Agent Voters] D --> F[Orchestrator Candidates] E --> G[Message Passing Protocol] F --> G G --> H[AGENTSNET Communication] H --> I[Voting Process] I --> J[Election Algorithms] J --> K[Consensus Building] J --> L[Leader Election] J --> M[Matching Algorithm] J --> N[Coloring Algorithm] J --> O[Vertex Cover] K --> P[Election Result] L --> P M --> P N --> P O --> P P --> Q[Selected Orchestrator] ``` ### Technical Implementation: - **Robust JSON Parsing**: Handles LLM agent responses with multiple fallback strategies - **Error Handling**: Comprehensive exception handling for election processes - **Type Safety**: Full type annotations with Pydantic validation - **Modular Design**: Clean separation of concerns with dedicated roles - **Extensible Architecture**: Easy to add new election algorithms and voting methods ## Issue https://github.com/kyegomez/swarms/issues/957 ## Dependencies - No new external dependencies required - Uses existing Swarms framework components - Compatible with current Swarms architecture ## Tag Maintainer @kyegomez ## Twitter Handle [x.com/IlumTheProtogen](https://x.com/IlumTheProtogen) ## Testing The implementation includes: - Comprehensive error handling and validation - Real-world example demonstrating full workflow - Silent operation for production use - Type safety with Pydantic validation ## Files Changed - `swarms/structs/election_swarm.py` - Core ElectionSwarm implementation - `examples/multi_agent/election_swarm/real_world_election.py` - Real-world CEO election example - `docs/swarms/structs/election_swarm.md` - Comprehensive documentation - `swarms/structs/__init__.py` - Added ElectionSwarm to exports - `examples/multi_agent/election_swarm/basic_usage.py` - Basic Usage example - `examples/multi_agent/election_swarm/specialized_session.py` - advanced(more complex) example - `docs/mkdocs.yml` - added election_swarm under advanced workflows ## Usage Example ```python from swarms.structs import ElectionSwarm # Create election swarm with voters and candidates election = ElectionSwarm( voters=[voter1, voter2, voter3], candidates=[candidate1, candidate2], vote_counter=vote_counter ) # Run election result = election.run( task="Elect the best CEO for our company", election_type=ElectionAlgorithm.LEADER_ELECTION, max_rounds=3 ) # Get elected leader winner = result.election_result.winner ``` This PR significantly enhances the Swarms framework with democratic decision-making capabilities, enabling more sophisticated multi-agent coordination and leadership selection. <!-- readthedocs-preview swarms start --> ---- 📚 Documentation preview 📚: https://swarms--1095.org.readthedocs.build/en/1095/ <!-- readthedocs-preview swarms end -->

IlumCIProposed by IlumCI
View on GitHub →

## Description This PR introduces **CorporateSwarm**, a sophisticated multi-agent orchestration system that simulates a complete corporate structure with advanced board governance, executive leadership, departmental operations, and democratic decision-making processes. Built on the foundation of EuroSwarm Parliament with corporate-specific enhancements, CorporateSwarm provides a comprehensive corporate simulation including board of directors with democratic voting, executive leadership team coordination, departmental swarm management, financial oversight and reporting, strategic decision-making processes, and compliance and governance frameworks. The system includes advanced ESG (Environmental, Social, Governance) scoring, comprehensive risk assessment and management, stakeholder engagement frameworks, regulatory compliance monitoring (SOX, GDPR, ISO 27001, HIPAA), AI ethics and responsible AI governance, crisis management and business continuity planning, and innovation governance. CorporateSwarm enables organizations to model complex corporate governance scenarios, conduct board meetings, manage committee structures, and make strategic decisions through AI-powered democratic processes. CorporateSwarm represents a revolutionary advancement in multi-agent systems for corporate governance, providing exceptional simulation capabilities for training, analysis, and decision support. ## Issue This addresses the need for sophisticated corporate governance simulation capabilities in multi-agent systems, enabling organizations to model complex decision-making processes, board structures, and strategic planning scenarios. ## Dependencies - `loguru` for logging - `pydantic` for data validation - `swarms.structs.agent.Agent` for individual member agents - `swarms.structs.conversation.Conversation` for conversation tracking - `swarms.structs.hybrid_hiearchical_peer_swarm.HybridHierarchicalClusterSwarm` for democratic decision-making - `swarms.structs.swarm_router.SwarmRouter` for swarm orchestration - `swarms.utils.history_output_formatter` for output formatting ## Tag Maintainer @kyegomez ## Twitter Handle https://[x.com/IlumTheProtogen](https://x.com/IlumTheProtogen) ## Full Board/Corporate Governance CorporateSwarm implements an exceptional board governance system that surpasses traditional corporate structures and decision-making processes. The system features a sophisticated board of directors with independent and executive directors, each with specific roles, expertise areas, and voting weights. The board operates through advanced specialized committees including Audit, Compensation, Nominating, Risk, Technology, ESG, Sustainability, Cybersecurity, Innovation, Stakeholder, Crisis Management, AI Ethics, and Data Privacy committees, each with defined responsibilities and meeting schedules. The governance framework includes democratic voting mechanisms where board members and executives participate in strategic decision-making through weighted voting systems. The system tracks comprehensive board performance metrics, monitors compliance with governance standards, and ensures proper quorum requirements for meetings and decisions. CorporateSwarm enables organizations to simulate complex governance scenarios, conduct board meetings with realistic discussion and voting processes, and evaluate the effectiveness of different governance structures. The system supports both regular board meetings and special sessions, with comprehensive minute-taking and resolution tracking. This advanced governance framework provides a foundation for understanding how AI agents can collaborate in complex organizational structures while maintaining accountability, transparency, and effective decision-making processes. The system includes advanced ESG scoring, comprehensive risk assessment and management, stakeholder engagement frameworks, regulatory compliance monitoring, AI ethics governance, crisis management planning, and innovation pipeline management, representing the highest level of corporate governance simulation available. ## Architecture Overview CorporateSwarm is built on a hierarchical structure with multiple layers of governance and decision-making: ```python # Core Corporate Structure class CorporateSwarm: def __init__(self, name="CorporateSwarm", max_loops=1, enable_democratic_discussion=True, enable_departmental_work=True, enable_financial_oversight=True): self.members: Dict[str, CorporateMember] = {} self.departments: Dict[str, CorporateDepartment] = {} self.board_committees: Dict[str, BoardCommittee] = {} self.board_meetings: List[BoardMeeting] = [] self.proposals: List[CorporateProposal] = [] self.votes: List[CorporateVote] = [] # Advanced Governance Features self.esg_scores: Dict[str, ESGScore] = {} self.risk_assessments: Dict[str, RiskAssessment] = {} self.stakeholder_engagements: Dict[str, StakeholderEngagement] = {} self.compliance_frameworks: Dict[str, ComplianceFramework] = {} self.crisis_management_plans: Dict[str, Dict[str, Any]] = {} self.innovation_pipeline: Dict[str, Dict[str, Any]] = {} self.audit_trails: List[Dict[str, Any]] = [] self.performance_metrics: Dict[str, Any] = {} self.sustainability_targets: Dict[str, Dict[str, Any]] = {} self.ai_ethics_framework: Dict[str, Any] = {} ``` ## Key Components ### 1. Corporate Members and Roles ```python class CorporateRole(str, Enum): CEO = "ceo" CFO = "cfo" CTO = "cto" COO = "coo" BOARD_CHAIR = "board_chair" BOARD_MEMBER = "board_member" INDEPENDENT_DIRECTOR = "independent_director" EXECUTIVE_DIRECTOR = "executive_director" @dataclass class CorporateMember: member_id: str name: str role: CorporateRole department: DepartmentType expertise_areas: List[str] voting_weight: float independence_status: bool agent: Optional[Agent] ``` ### 2. Board Committees and Governance ```python class BoardCommitteeType(str, Enum): AUDIT = "audit" COMPENSATION = "compensation" NOMINATING = "nominating" GOVERNANCE = "governance" RISK = "risk" TECHNOLOGY = "technology" ESG = "esg" SUSTAINABILITY = "sustainability" CYBERSECURITY = "cybersecurity" INNOVATION = "innovation" STAKEHOLDER = "stakeholder" CRISIS_MANAGEMENT = "crisis_management" AI_ETHICS = "ai_ethics" DATA_PRIVACY = "data_privacy" @dataclass class BoardCommittee: committee_id: str name: str committee_type: BoardCommitteeType chair: str members: List[str] responsibilities: List[str] quorum_required: int ``` ### 3. Democratic Decision-Making ```python def conduct_corporate_vote(self, proposal_id: str, participants: List[str] = None) -> CorporateVote: """Conduct a democratic vote on a corporate proposal.""" # Use democratic swarm for decision-making if self.democratic_swarm is not None: decision_task = f""" Corporate Proposal Vote: {proposal.title} As a corporate decision-making body, please: 1. Analyze the proposal's strategic value 2. Evaluate financial implications 3. Assess implementation feasibility 4. Consider risk factors 5. Make a recommendation """ democratic_result = self.democratic_swarm.run(decision_task) # Conduct individual member votes individual_votes = {} for member_id in participants: member = self.members[member_id] vote_prompt = f""" As {member.name}, {member.role.value.title()}: Please provide your vote: APPROVE, REJECT, or ABSTAIN """ response = member.agent.run(vote_prompt) individual_votes[member_id] = self._parse_vote_response(response) return CorporateVote(proposal=proposal, individual_votes=individual_votes) ``` ### 4. Board Meeting Management ```python def conduct_board_meeting(self, meeting_id: str, discussion_topics: List[str] = None) -> BoardMeeting: """Conduct a board meeting with discussion and decisions.""" meeting = self._find_meeting(meeting_id) minutes = [] resolutions = [] for topic in discussion_topics: # Create proposal for discussion topic proposal_id = self.create_proposal( title=f"Board Discussion: {topic}", proposal_type=ProposalType.BOARD_RESOLUTION, sponsor_id=self.board_members[0] ) # Conduct vote vote = self.conduct_corporate_vote(proposal_id, meeting.attendees) # Record minutes and resolutions minutes.append(f"Topic: {topic}\nVote Result: {vote.result.value}") if vote.result in [VoteResult.APPROVED, VoteResult.UNANIMOUS]: resolutions.append(f"RESOLVED: {topic} - APPROVED") meeting.minutes = "\n\n".join(minutes) meeting.resolutions = resolutions return meeting ``` ## Usage Examples ### Basic Corporate Setup ```python from swarms.structs.corporate_swarm import CorporateSwarm, CorporateRole, DepartmentType # Initialize corporate swarm corporate = CorporateSwarm( name="TechCorp Governance", enable_democratic_discussion=True, enable_departmental_work=True, verbose=True ) # Add new board member board_member_id = corporate.add_member( name="Dr. Jane Smith", role=CorporateRole.INDEPENDENT_DIRECTOR, department=DepartmentType.TECHNOLOGY, expertise_areas=["AI", "cybersecurity", "governance"], voting_weight=2.5 ) ``` ### Strategic Decision Making ```python # Create strategic proposal proposal_id = corporate.create_proposal( title="AI Transformation Initiative", description="Comprehensive AI adoption strategy across all departments", proposal_type=ProposalType.STRATEGIC_INITIATIVE, sponsor_id=ceo_id, department=DepartmentType.TECHNOLOGY, budget_impact=5000000.0, timeline="18 months" ) # Conduct democratic vote vote_result = corporate.conduct_corporate_vote(proposal_id) print(f"Proposal Result: {vote_result.result.value}") ``` ### Board Meeting Simulation ```python # Schedule board meeting meeting_id = corporate.schedule_board_meeting( meeting_type=MeetingType.REGULAR_BOARD, agenda=["Q4 Financial Review", "Strategic Planning", "Risk Assessment"] ) # Conduct meeting meeting = corporate.conduct_board_meeting( meeting_id=meeting_id, discussion_topics=["Q4 Financial Review", "Strategic Planning"] ) print(f"Meeting completed with {len(meeting.resolutions)} resolutions") ``` ### Committee Operations ```python # Conduct committee meeting committee_results = corporate.conduct_committee_meeting( committee_id=audit_committee_id, agenda=["Financial Controls Review", "Risk Assessment", "Compliance Update"] ) print(f"Issues Discussed: {committee_results['issues_discussed']}") print(f"Recommendations: {committee_results['recommendations']}") ``` ### Advanced Governance Features #### ESG Scoring and Sustainability ```python # Calculate comprehensive ESG score esg_score = corporate.calculate_esg_score() print(f"Environmental Score: {esg_score.environmental_score}") print(f"Social Score: {esg_score.social_score}") print(f"Governance Score: {esg_score.governance_score}") print(f"Overall ESG Score: {esg_score.overall_score}") # Get sustainability goals and carbon footprint sustainability_goals = corporate._get_sustainability_goals() carbon_footprint = corporate._calculate_carbon_footprint() print(f"Carbon Footprint: {carbon_footprint} tons CO2") ``` #### Risk Assessment and Management ```python # Conduct comprehensive risk assessment risk_assessments = corporate.conduct_risk_assessment("comprehensive") for category, assessment in risk_assessments.items(): print(f"{category}: {assessment.risk_level} risk (Score: {assessment.risk_score})") print(f"Mitigation: {assessment.mitigation_strategies}") ``` #### Stakeholder Engagement ```python # Manage stakeholder engagement stakeholder_engagements = corporate.manage_stakeholder_engagement("all") for stakeholder_type, engagement in stakeholder_engagements.items(): print(f"{stakeholder_type}: Satisfaction {engagement.satisfaction_score}%") print(f"Concerns: {engagement.concerns}") ``` #### Compliance Framework ```python # Establish compliance framework compliance_frameworks = corporate.establish_compliance_framework("comprehensive") for regulation, framework in compliance_frameworks.items(): print(f"{regulation}: {framework.compliance_status}") print(f"Controls: {framework.controls}") ``` #### Comprehensive Governance Review ```python # Conduct comprehensive governance review governance_review = corporate.conduct_comprehensive_governance_review() print(f"ESG Analysis: {governance_review['esg_analysis']}") print(f"Risk Analysis: {governance_review['risk_analysis']}") print(f"Stakeholder Analysis: {governance_review['stakeholder_analysis']}") print(f"Compliance Analysis: {governance_review['compliance_analysis']}") print(f"Governance Recommendations: {governance_review['governance_recommendations']}") ``` ## System Architecture Diagrams ### Corporate Governance Structure ```mermaid graph TB subgraph "Corporate Governance Hierarchy" CEO[CEO - Chief Executive Officer] CFO[CFO - Chief Financial Officer] CTO[CTO - Chief Technology Officer] COO[COO - Chief Operating Officer] subgraph "Board of Directors" BC[Board Chair] BVC[Board Vice Chair] ID1[Independent Director 1] ID2[Independent Director 2] ID3[Independent Director 3] ED[Executive Director] end subgraph "Board Committees" AC[Audit Committee] CC[Compensation Committee] NC[Nominating Committee] RC[Risk Committee] TC[Technology Committee] EC[ESG Committee] SC[Sustainability Committee] CYB[Cybersecurity Committee] IC[Innovation Committee] STC[Stakeholder Committee] CMC[Crisis Management Committee] AIC[AI Ethics Committee] DPC[Data Privacy Committee] end subgraph "Departments" FD[Finance Department] OD[Operations Department] MD[Marketing Department] HRD[HR Department] LD[Legal Department] TD[Technology Department] end end CEO --> BC CFO --> BC CTO --> BC COO --> BC BC --> AC BC --> CC BC --> NC BC --> RC BC --> TC BC --> EC BC --> SC BC --> CYB BC --> IC BC --> STC BC --> CMC BC --> AIC BC --> DPC AC --> FD CC --> HRD NC --> LD RC --> OD TC --> TD ``` ### Decision-Making Flow ```mermaid flowchart TD A[Proposal Creation] --> B[Committee Review] B --> C{Committee Recommendation} C -->|Approve| D[Board Discussion] C -->|Reject| E[Proposal Rejected] C -->|Modify| F[Proposal Revision] F --> B D --> G[Democratic Voting Process] G --> H[Individual Member Votes] H --> I[Vote Analysis] I --> J{Vote Result} J -->|Approved| K[Implementation] J -->|Rejected| L[Proposal Failed] J -->|Tabled| M[Further Discussion] M --> D K --> N[Department Execution] N --> O[Progress Monitoring] O --> P[Board Reporting] ``` ### Multi-Agent Interaction Network ```mermaid graph LR subgraph "Executive Team" CEO_Agent[CEO Agent] CFO_Agent[CFO Agent] CTO_Agent[CTO Agent] COO_Agent[COO Agent] end subgraph "Board Members" BC_Agent[Board Chair Agent] ID1_Agent[Independent Director 1] ID2_Agent[Independent Director 2] ID3_Agent[Independent Director 3] ED_Agent[Executive Director] end subgraph "Committee Agents" AC_Agent[Audit Committee] CC_Agent[Compensation Committee] NC_Agent[Nominating Committee] RC_Agent[Risk Committee] TC_Agent[Technology Committee] EC_Agent[ESG Committee] SC_Agent[Sustainability Committee] CYB_Agent[Cybersecurity Committee] IC_Agent[Innovation Committee] STC_Agent[Stakeholder Committee] CMC_Agent[Crisis Management Committee] AIC_Agent[AI Ethics Committee] DPC_Agent[Data Privacy Committee] end subgraph "Democratic Swarm" DS[HybridHierarchicalClusterSwarm] SR1[Governance Swarm Router] SR2[Executive Swarm Router] end CEO_Agent --> DS CFO_Agent --> DS CTO_Agent --> DS COO_Agent --> DS BC_Agent --> DS ID1_Agent --> DS ID2_Agent --> DS ID3_Agent --> DS ED_Agent --> DS AC_Agent --> SR1 CC_Agent --> SR1 NC_Agent --> SR1 RC_Agent --> SR1 TC_Agent --> SR1 EC_Agent --> SR1 SC_Agent --> SR1 CYB_Agent --> SR1 IC_Agent --> SR1 STC_Agent --> SR1 CMC_Agent --> SR1 AIC_Agent --> SR1 DPC_Agent --> SR1 CEO_Agent --> SR2 CFO_Agent --> SR2 CTO_Agent --> SR2 COO_Agent --> SR2 DS --> SR1 DS --> SR2 ``` ### Corporate Decision-Making Process ```mermaid sequenceDiagram participant P as Proposal Sponsor participant C as Committee participant B as Board participant D as Democratic Swarm participant M as Members P->>C: Submit Proposal C->>C: Committee Review C->>B: Committee Recommendation B->>D: Initiate Democratic Process D->>M: Distribute Proposal M->>M: Individual Analysis M->>D: Submit Votes & Reasoning D->>D: Aggregate Results D->>B: Voting Results B->>B: Final Decision alt Approved B->>P: Approval Notification P->>P: Implementation else Rejected B->>P: Rejection Notification else Tabled B->>C: Request Further Review end ``` ### Board Performance Evaluation ```mermaid graph TD subgraph "Performance Metrics" A[Board Composition] B[Governance Structure] C[Decision Making] D[Compliance] end subgraph "Composition Metrics" A1[Total Members] A2[Independent Directors] A3[Executive Directors] A4[Independence Ratio] end subgraph "Structure Metrics" B1[Committee Count] B2[Committee Types] B3[Meeting Frequency] end subgraph "Decision Metrics" C1[Meetings Held] C2[Proposals Processed] C3[Votes Conducted] C4[Approval Rate] end subgraph "Compliance Metrics" D1[Quorum Met] D2[Resolutions Passed] D3[Governance Score] end A --> A1 A --> A2 A --> A3 A --> A4 B --> B1 B --> B2 B --> B3 C --> C1 C --> C2 C --> C3 C --> C4 D --> D1 D --> D2 D --> D3 ``` ### Complete Corporate Task Processing Workflow ```mermaid sequenceDiagram participant User as User/Stakeholder participant CS as CorporateSwarm<br/>Main Orchestrator participant BC as Board Chair participant AC as Audit Committee participant CEO as CEO participant CFO as CFO participant CTO as CTO participant FD as Finance Director participant TD as Technology Director participant FA as Financial Analysts participant SE as Senior Engineers participant DS as Democratic Swarm participant ESG as ESG Swarm participant RISK as Risk Swarm participant COMP as Compliance Swarm Note over User, COMP: TASK INITIATION & ROUTING PHASE User->>CS: Submit Strategic Task<br/>"Implement AI Transformation" CS->>CS: Analyze Task Type<br/>& Route to Appropriate Process Note over User, COMP: BOARD GOVERNANCE PHASE CS->>BC: Notify Board Chair<br/>Strategic Initiative Request BC->>AC: Request Committee Review<br/>Financial & Risk Assessment AC->>CFO: Financial Impact Analysis AC->>RISK: Risk Assessment Request AC->>COMP: Compliance Review Request Note over User, COMP: EXECUTIVE PLANNING PHASE BC->>CEO: Strategic Planning Session CEO->>CTO: Technology Feasibility Study CEO->>CFO: Budget & Resource Planning CTO->>TD: Technical Architecture Design CFO->>FD: Financial Modeling & Budget Note over User, COMP: DEPARTMENTAL ANALYSIS PHASE TD->>SE: Technical Implementation Plan SE->>SE: Architecture Design<br/>AI Infrastructure Planning FD->>FA: Cost-Benefit Analysis<br/>ROI Calculations FA->>FA: Financial Modeling<br/>Budget Allocation Note over User, COMP: ESG & SUSTAINABILITY REVIEW CS->>ESG: ESG Impact Assessment ESG->>ESG: Environmental Impact<br/>Social Responsibility<br/>Governance Compliance Note over User, COMP: DEMOCRATIC DECISION MAKING CS->>DS: Initiate Democratic Process DS->>BC: Board Discussion & Debate DS->>CEO: Executive Team Input DS->>AC: Committee Recommendations DS->>ESG: ESG Committee Input DS->>RISK: Risk Committee Assessment DS->>COMP: Compliance Committee Review Note over User, COMP: VOTING & CONSENSUS PHASE DS->>DS: Aggregate All Inputs<br/>Weighted Voting Process DS->>BC: Voting Results & Analysis BC->>CS: Final Decision & Authorization Note over User, COMP: IMPLEMENTATION PLANNING CS->>CEO: Implementation Authorization CEO->>CTO: Technology Implementation CEO->>CFO: Budget Release & Monitoring CTO->>TD: Project Kickoff CFO->>FD: Budget Allocation & Tracking Note over User, COMP: EXECUTION & MONITORING PHASE TD->>SE: Development Team Assignment SE->>SE: AI System Development<br/>Infrastructure Setup FD->>FA: Budget Monitoring<br/>Cost Tracking FA->>FA: Financial Reporting<br/>ROI Tracking Note over User, COMP: COMPLIANCE & GOVERNANCE MONITORING CS->>COMP: Ongoing Compliance Monitoring CS->>RISK: Risk Monitoring & Mitigation CS->>ESG: ESG Performance Tracking Note over User, COMP: PROGRESS REPORTING & FEEDBACK SE->>TD: Technical Progress Reports TD->>CTO: Implementation Updates FA->>FD: Financial Performance Reports FD->>CFO: Budget & ROI Updates CTO->>CEO: Technology Status Updates CFO->>CEO: Financial Performance Updates CEO->>BC: Executive Summary Reports BC->>CS: Board Oversight Reports Note over User, COMP: REVIEW & OPTIMIZATION CS->>DS: Performance Review Session DS->>DS: Multi-Stakeholder Feedback<br/>Process Optimization DS->>CS: Recommendations & Improvements Note over User, COMP: COMPLETION & DELIVERY CS->>User: Final Results & Implementation Report<br/>AI Transformation Complete CS->>CS: Update Corporate Status<br/>Record Lessons Learned ``` ### Corporate Departmental Workflow Architecture ```mermaid graph TD subgraph "TASK INTAKE & ROUTING" A[User Task Submission] --> B[CorporateSwarm run method] B --> C{Task Type Analysis} C -->|Strategic| D[Board Governance Process] C -->|Financial| E[Finance Department Process] C -->|Technical| F[Technology Department Process] C -->|Operational| G[Operations Department Process] C -->|Marketing| H[Marketing Department Process] C -->|HR| I[HR Department Process] C -->|Legal| J[Legal Department Process] C -->|R&D| K[R&D Department Process] C -->|Customer| L[Customer Success Process] end subgraph "BOARD GOVERNANCE WORKFLOW" D --> D1[Board Chair Notification] D1 --> D2[Committee Assignment] D2 --> D3[Committee Review] D3 --> D4[Democratic Swarm Discussion] D4 --> D5[Voting & Consensus] D5 --> D6[Board Resolution] D6 --> D7[Executive Implementation] end subgraph "FINANCE DEPARTMENT WORKFLOW" E --> E1[Finance Director Assignment] E1 --> E2[Financial Analysis Team] E2 --> E3[Budget Planning] E3 --> E4[Cost-Benefit Analysis] E4 --> E5[ROI Calculations] E5 --> E6[Financial Approval] E6 --> E7[Budget Allocation] E7 --> E8[Financial Monitoring] end subgraph "TECHNOLOGY DEPARTMENT WORKFLOW" F --> F1[Technology Director Assignment] F1 --> F2[Technical Architecture Team] F2 --> F3[System Design] F3 --> F4[Development Planning] F4 --> F5[Implementation Team] F5 --> F6[Code Development] F6 --> F7[Testing & QA] F7 --> F8[Deployment & Monitoring] end subgraph "OPERATIONS DEPARTMENT WORKFLOW" G --> G1[Operations Director Assignment] G1 --> G2[Project Management Team] G2 --> G3[Process Design] G3 --> G4[Resource Planning] G4 --> G5[Implementation Team] G5 --> G6[Process Execution] G6 --> G7[Quality Control] G7 --> G8[Performance Monitoring] end subgraph "MARKETING DEPARTMENT WORKFLOW" H --> H1[Marketing Director Assignment] H1 --> H2[Brand Management Team] H2 --> H3[Campaign Planning] H3 --> H4[Content Creation] H4 --> H5[Digital Marketing Team] H5 --> H6[Campaign Execution] H6 --> H7[Analytics & Optimization] H7 --> H8[Performance Reporting] end subgraph "AI AGENT MANAGEMENT WORKFLOW" I --> I1[Agent Management Director Assignment] I1 --> I2[Agent Performance Team] I2 --> I3[Agent Optimization Planning] I3 --> I4[Agent Resource Allocation] I4 --> I5[Agent Deployment Process] I5 --> I6[Agent Training & Development] I6 --> I7[Agent Performance Monitoring] I7 --> I8[Agent Lifecycle Management] end subgraph "LEGAL DEPARTMENT WORKFLOW" J --> J1[Legal Director Assignment] J1 --> J2[Legal Analysis Team] J2 --> J3[Compliance Review] J3 --> J4[Risk Assessment] J4 --> J5[Legal Documentation] J5 --> J6[Contract Management] J6 --> J7[Regulatory Compliance] J7 --> J8[Legal Monitoring] end subgraph "R&D DEPARTMENT WORKFLOW" K --> K1[R&D Director Assignment] K1 --> K2[Research Team] K2 --> K3[Research Planning] K3 --> K4[Experimentation] K4 --> K5[Data Analysis] K5 --> K6[Product Development] K6 --> K7[Testing & Validation] K7 --> K8[Innovation Pipeline] end subgraph "CUSTOMER SUCCESS WORKFLOW" L --> L1[Customer Success Director Assignment] L1 --> L2[Customer Success Team] L2 --> L3[Customer Analysis] L3 --> L4[Success Planning] L4 --> L5[Implementation Support] L5 --> L6[Customer Onboarding] L6 --> L7[Success Monitoring] L7 --> L8[Customer Feedback] end subgraph "CROSS-DEPARTMENTAL COORDINATION" D7 --> M[Executive Coordination] E8 --> M F8 --> M G8 --> M H8 --> M I8 --> M J8 --> M K8 --> M L8 --> M M --> N[CorporateSwarm Integration] N --> O[Final Results & Reporting] end subgraph "SPECIALIZED GOVERNANCE MONITORING" N --> P[ESG Monitoring] N --> Q[Risk Management] N --> R[Compliance Tracking] N --> S[AI Ethics Review] N --> T[Crisis Management] N --> U[Innovation Pipeline] P --> O Q --> O R --> O S --> O T --> O U --> O end ``` ## Key Features 1. **Comprehensive Corporate Structure**: Complete board of directors, executive team, and departmental organization 2. **Democratic Decision-Making**: AI-powered voting and consensus building with intelligent task routing 3. **Advanced Board Governance**: Committee structures, meeting management, and performance evaluation 4. **Financial Oversight**: Budget tracking and cost management with real-time monitoring 5. **Strategic Planning**: Proposal creation, evaluation, and implementation tracking 6. **Advanced Compliance Framework**: Governance standards and regulatory compliance (SOX, GDPR, ISO 27001, HIPAA) 7. **Performance Analytics**: Board effectiveness and decision-making metrics 8. **ESG Scoring and Sustainability**: Comprehensive environmental, social, and governance scoring 9. **Risk Assessment and Management**: Multi-category risk assessment with mitigation strategies 10. **Stakeholder Engagement**: Multi-stakeholder engagement and satisfaction tracking 11. **AI Ethics and Responsible AI Governance**: Dedicated AI ethics frameworks and governance 12. **Crisis Management and Business Continuity**: Crisis response and business continuity planning 13. **Innovation Governance**: R&D strategy and digital transformation oversight 14. **Standard Agent Interface**: Primary `run()`, `arun()`, and `__call__()` methods following Swarms architecture patterns 15. **Bleeding-Edge Performance**: Concurrency and parallelism optimization for multi-agent collaboration ## Testing The implementation includes comprehensive error handling and fallback mechanisms to ensure robust operation even when individual agents encounter issues. The system gracefully handles API failures, parsing errors, and budget constraints while maintaining corporate governance integrity. This CorporateSwarm implementation provides an exceptional foundation for sophisticated corporate governance simulation and decision-making support systems, representing the highest level of corporate governance simulation available in multi-agent systems.

IlumCIProposed by IlumCI
View on GitHub →
documentation
structs

- Description: Added an option (not required) to add a streaming callback to the Sequential Workflow with an example attached as well. - Issue: Resolves #1059 DEMO: https://www.loom.com/share/94233587645848aa9747adc6e56710d0 <!-- readthedocs-preview swarms start --> ---- 📚 Documentation preview 📚: https://swarms--1081.org.readthedocs.build/en/1081/ <!-- readthedocs-preview swarms end -->

aparekh02Proposed by aparekh02
View on GitHub →
about 2 months ago0 comments
documentation

This pull request reorganizes and expands the documentation for RAG (Retrieval-Augmented Generation) vector database integrations in Swarms. It introduces a new section with comprehensive guides for multiple vector databases, adds a detailed integration guide for ChromaDB, and updates the navigation structure to reflect these changes. **Documentation Structure Improvements:** * The `docs/mkdocs.yml` navigation is restructured to group all RAG-related content under a new "RAG Vector Databases" section, listing individual guides for each supported database. * A new overview page, `rag-vector-databases/overview.md`, summarizes available integrations, key features, and guidance for choosing the right vector database for different use cases. **New Integration Guide:** * A comprehensive guide for integrating ChromaDB with Swarms agents is added (`rag-vector-databases/chromadb.md`). This includes setup instructions, a full code example with unified LiteLLM embeddings, use cases, performance tips, deployment options, configuration, best practices, and troubleshooting. These changes make it easier for developers to find, understand, and implement RAG solutions with a variety of vector databases using Swarms. --- **References:** [[1]](diffhunk://#diff-7618337a88ea47f9b778a21f0e17d43eab2aba4880c6be2d95a7bf95e4b8b2dfL436-R448) [[2]](diffhunk://#diff-2eb3d870162da73c76c3de95784fbd76962cc459d0435bf9b33249cbdad27f1fR1-R78) [[3]](diffhunk://#diff-484ccd510e1f408305463f12c7a3f3e53aaa77f2f606a4e6b7c52d6510711891R1-R373) <!-- readthedocs-preview swarms start --> ---- 📚 Documentation preview 📚: https://swarms--1067.org.readthedocs.build/en/1067/ <!-- readthedocs-preview swarms end -->

harshalmore31Proposed by harshalmore31
View on GitHub →