v1.8.0
We're excited to announce the release of Xircuits v1.8.0, which brings several enhancements and bug fixes to improve your Xircuits experience. This update from the 1.7.0 release includes automatic initialization of In/OutArgs, a new Compile Error Handler, and fixes for Literal List and Dict compile issues. We've also integrated an external XAI library with an installation command.
The display of long strings and canvas size effects on literal strings has been improved, and we've added support for multiple types of ports and input types.
We're also introducing new component libraries, including OpenAI, GPT Agent Toolkit, Slack and Discord! Lastly, we've added literal data validation to prevent compilation breaks and a new Literal Secret Component. We would like to extend a warm welcome to our new contributor @romina1601, who made their first contribution in this release.
What's Changed
Breaking Changes:
-
We've updated the way you initialize the In/OutArgs so it's automatic. If your ports are all None / empty() ports, you can remove it all together and let Xircuits auto-init it for you.
Code
Previous
@xai_component class SaveTorchModelState(Component): model: InCompArg[nn.Module] model_path: InArg[str] def __init__(self): self.done = False self.model = InCompArg(None) self.model_path = InArg(None) def execute(self,ctx) -> None: # execution code
Updated
@xai_component class SaveTorchModelState(Component): model: InCompArg[nn.Module] model_path: InArg[str] def execute(self,ctx) -> None: # execution code
-
If you need to init a value, add
super().__init__()
, remove the empty ports, then update the value like this:Code
Previous
def __init__(self): self.model_in = InArg.empty() self.loss_in = InArg.empty() self.learning_rate = InArg(1e-3) self.optimizer_in = InArg.empty() self.should_flatten = InArg(False) self.model_config = OutArg.empty() self.loss_fn = OutArg.empty() self.optimizer = OutArg.empty()
Updated
def __init__(self): super().__init__() self.learning_rate.value = 1e-3 self.should_flatten.value = False
- We've removed the old debugger to prepare for the new one. For this one, all you need to do is update your
xai_components/base.py
to the new one. You can also remove all theself.done
from your component codes.
Xircuits Core Features:
- Make initializing In/OutArgs automatic. by @wmeddie in #223
- 🔔 Compile Fail Handler by @MFA-X-AI in #224
- ⚡ Pull external XAI library and install cmd by @MFA-X-AI in #226
- 💾 Re-arrange the main Toolbar by @mansouralawi in #228
- Update Long String Overflow Display by @MFA-X-AI in #229
- Align the text for Triangle ports. by @wmeddie in #233
- 🔢 Support Multiple Types Port by @mansouralawi in #231
- Make input ports support multiple input types by @romina1601 in #201
- Fix for multi-triangle components. by @wmeddie in #234
- Remove unused code by @treo in #237
- 🧹 Remove unused debugger code from component libraries by @MFA-X-AI in #238
- ⚡ make output panel auto-scroll and spawn on the right by @MFA-X-AI in #241
- 🗝️ Add Literal Secret Component by @MFA-X-AI in #245
Component Library
- 📖 OpenAI Component Library by @MFA-X-AI in #239
- 📖 GPT Agent Toolkit Component Library by @MFA-X-AI in #240
- Add Slack Connector Components Library by @mansouralawi in #243
- [xai-rpa] Add mouse clicking and hover components by @yuenherny in #236
- 📖 Discord Component Library by @MFA-X-AI in #246
Bug Fixes:
- 🐛 Fix Literal List and Dict compile by @MFA-X-AI in #225
- 🔤 Fix Canvas Size Effect on Literal String by @mansouralawi in #232
- 🐛 Fix Action Panel Spawn Location by @mansouralawi in #235
- 🐛 Literal Data Validation to Prevent Compilation Breaks by @MFA-X-AI in #244
Other
- Bump webpack from 5.67.0 to 5.76.2 by @dependabot in #227
New Contributors
- @romina1601 made their first contribution in #201
Full Changelog: v1.7.0...v1.8.0