Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

[Feature Request] Add integration to smolagents

Đang mở
#398 2 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 3 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức phù hợp với người mới
35/100
Loại issue
Tính năng
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Đình trệ
Công nghệ
python
Lĩnh vực
ai, machine-learning

Hướng nghiên cứu

Bắt đầu bằng cách đọc phần tích hợp LangGraph hiện có được tham chiếu trong issue và so sánh các entry point của nó với các API art.smolagents.init_chat_model và wrap_rollout được đề xuất. Xác minh khả năng hỗ trợ bất đồng bộ của Smolagents và xác định hành vi của wrapper trước khi thêm module tích hợp, tài liệu và các ví dụ; hoàn tất khi workflow ví dụ chạy được với quá trình training ART.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

enhancement

Proposal

Hello OpenPipe Team! Thanks for creating such a cool project for agent RL.

I recently saw the LangGraph integration announcement and tested it, and it works great :)
I'd like to propose adding Smolagents integration as well.

I believe Smolagents is fit for ART for several reasons:

  • Simplicity: Smolagents follows a philosophy of simplicity, making it accessible while maintaining capabilities
  • Community: Like LangGraph, it provides diverse community examples and recipes. Particularly, recipes like open_deep_research are ideal use cases where ART's RL techniques can provide significant value
  • Integration-friendly: Smolagents' class architecture (ReACT, Memory, Message, Logging, etc.) is well-structured and easily accessible, making it straightforward to integrate with ART

Example

from art.smolagents import init_chat_model
from smolagents import CodeAgent, WebSearchTool
import art
import weave

@weave.op
async def rollout(model: art.Model, scenario: ResearchScenario) -> art.Trajectory:
    chat_model = init_chat_model(model.name, temperature=1.0)
    
    # Define available tools
    tools = [WebSearchTool()]
    
    # Create the Smolagents ReAct agent
    agent = CodeAgent(tools=tools, model=chat_model, stream_outputs=True)
    
    # Execute workflow (need to verify async support in smolagents)
    return await agent.run(scenario.messages)
    
from art.smolagents import wrap_rollout

...
for batch in training_iterator:
    groups = []
    for scenario in batch.items:
        groups.append(
            art.TrajectoryGroup([
                wrap_rollout(rollout)(model, scenario)
                for _ in range(training_config["rollouts_per_group"])
            ])
        )
...

Roadmap

  • Add art.smolagents integration module with wrapper functions
  • Add documentation and examples.

I'd be happy to work on implementing this feature if the team is interested.
Would love to hear your thoughts and any ideas! Thanks 😊

Ngôn ngữ chính
Python
Star
10.8k
Fork
989
Merge trung bình
11 giờ 38 phút
Pull request đã merge (30 ngày)
104

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của OpenPipe/ART

Tất cả issue của OpenPipe/ART

Issue tương tự

Thêm issue về Python

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.