Commit Graph

41 Commits

Author SHA1 Message Date
Julien Chaumond d3912c70cf
Support third-party Inference providers in `HfApiModel` (#422)
* Add `provider` param to `HfApiModel `, update guided_tour.md

---------

Co-authored-by: Aymeric <aymeric.roucher@gmail.com>
2025-01-30 01:03:09 +01:00
Clémentine Fourrier c6eb9526f1
Untangling Logging (#316)
* Deep refacto that disentangled logging logic between logging (informing the user via console outputs) and memory (storing what happened in the agent).

---------

Co-authored-by: benediktstroebl <50178209+benediktstroebl@users.noreply.github.com>
Co-authored-by: Aymeric <aymeric.roucher@gmail.com>
2025-01-29 16:27:04 +01:00
Aymeric Roucher 4579a6f7cc
TransformersModel auto-detects VLMs (#378)
* TransformersModel auto-detects VLMs
2025-01-27 20:09:14 +01:00
Merve Noyan 408b52abec
Add VLM support (#220)
* vlm initial commit

* transformers integration for vlms

* Add webbrowser example and make it work 🥳🥳

* Refactor image support

* Allow modifying agent attributes in callback

* Improve vlm browser example

* time.sleep(0.5) before screenshot to let js animations happen

* test to validate internal workflow for passing images

* Update test_agents.py

* Improve error logging

* Switch to OpenAIServerModel

* Improve the example

* Format

* add docs about steps, callbacks & co

* Add precisions in doc

* Improve browser

* Tiny prompting update

* Fix style

* fix/add test

* refactor

* Fix write_inner_memory_from_logs for OpenAI format

* Add back summary mode

* Make it work with TransformersModel

* Fix test

* Fix loop

* Fix quality

* Fix mutable default argument

* Rename tool_response_message to error_message and append it

* Working browser with firefox

* Use flatten_messages_as_text passed to TransformersModel

* Fix quality

* Document flatten_messages_as_text in docstring

* Working ctrl + f in browser

* Make style

* Fix summary_mode type hint and add to docstring

* Move image functions to tools

* Update docstrings

* Fix type hint

* Fix typo

* Fix type hints

* Make callback call compatible with old single-argument functions

* Revert update_metrics to have a single arg

* Pass keyword args instead of args to callback

* Update webbrowser

* fix for single message case where final message list is empty

* forgot debugger lol

* accommodate VLM-like chat template and fix tests

* Improve example wording

* Style fixes

* clarify naming and fix tests

* test fix

* Fix style

* Add bm25 to fix one of the doc tests

* fix mocking in VL test

* fix bug in fallback

* add transformers model

* remove chrome dir from helium

* Update Transformers example with flatten_messages_as_text

* Add doc for flatten_messages_as_text

* Fix merge error

---------

Co-authored-by: Merve Noyan <mervenoyan@Merve-MacBook-Pro.local>
Co-authored-by: Aymeric <aymeric.roucher@gmail.com>
Co-authored-by: Albert Villanova del Moral <8515462+albertvillanova@users.noreply.github.com>
2025-01-24 17:01:35 +01:00
Nicholas Broad ec45d6766a
minor fix for console in AgentLogger (#303)
* minor fix for console in AgentLogger
2025-01-22 10:41:05 +01:00
Aymeric Roucher 7a91123729
Improve python executor's error logging (#275)
* Improve python executor's error logging
2025-01-20 15:57:16 +01:00
Lucain 6e1373a324
Add linter rules + apply make style (#255)
* Add linter rules + apply make style
2025-01-18 19:01:15 +01:00
Edward Beeching fabc59aa08
Fix missing python modules in CodeAgent system prompt (#226)
* fix modules in system prompt + test
2025-01-17 11:59:30 +01:00
Aymeric Roucher 5f32373551
Make default tools more robust (#186) 2025-01-14 14:57:11 +01:00
Aymeric 1d846072eb Improve GradioUI file upload system 2025-01-13 19:46:36 +01:00
Aymeric Roucher c611dfc7e5
Clean local python interpreter: propagate imports (#175) 2025-01-13 17:23:03 +01:00
Aymeric Roucher 5c33130fa4
Vastly simplify Model class (#146)
* Vastly simplify Model class by making only one __call__ method 
2025-01-10 12:30:59 +01:00
Aymeric Roucher cb9830a554
Support OpenTelemetry (#136)
* Support OpenTelemetry
2025-01-09 23:08:17 +01:00
Aymeric Roucher d3cd0f9e09
Auto correct wrong assignments to final_answer (#123)
* Auto correct wrong assignments to final_answer
2025-01-08 19:04:11 +01:00
Aymeric 681758ae84 Fix failing import test in test_agents.py 2025-01-07 14:09:01 +01:00
Aymeric d45c63555f Pass more tests 2025-01-06 22:04:00 +01:00
Aymeric c22fedaee1 Sort imports and add test workflows 2025-01-06 21:48:15 +01:00
Aymeric e8617b3037 Finalize multiagent tests 2025-01-06 19:33:50 +01:00
Aymeric 0824785b7a Add tests for multiagent hierarchies 2025-01-06 19:24:46 +01:00
Aymeric e9119c9df5 Replace max_iteration with max_steps for consistency 2025-01-06 17:25:45 +01:00
Aymeric 3f79baee71 Add warning about missing imports in CodeAgent error logs 2025-01-06 11:00:36 +01:00
Aymeric d5a036d3f2 Pass tests 2024-12-27 16:27:16 +01:00
Aymeric c880f2f5b6 Format 2024-12-27 16:18:19 +01:00
Aymeric c4f38850b2 Improve code execution error logging 2024-12-25 23:28:57 +01:00
Aymeric 8005d6f21d Change name 'llm_engine' to 'model' 2024-12-25 21:51:43 +01:00
Aymeric 3a70e17cae Remove direct support for openai and anthropic engines, one can use LiteLLM 2024-12-24 23:36:46 +01:00
Aymeric 1e357cee7f Add LiteLLM engine 2024-12-24 17:34:14 +01:00
Aymeric edb0be3adf Change all names to 'smolagent' 2024-12-24 10:31:36 +01:00
Aymeric 32d7bc5e06 Add tool calling agent example 2024-12-23 17:22:35 +01:00
Aymeric 30cb6111b3 Enable support for tool calling agents 2024-12-23 17:10:07 +01:00
Aymeric dccef6248b Multiple documentation improvements 2024-12-21 23:11:15 +01:00
Aymeric c18bc9037d Add E2B code interpreter 🥳 2024-12-20 16:20:41 +01:00
Aymeric 584ce8f363 Consolidate pushing Tools to Hub 2024-12-19 16:57:05 +01:00
Aymeric ba87dd98c8 Solve additional args not being passed to task 2024-12-18 12:27:43 +01:00
Aymeric 06066437fd Formatting 2024-12-16 15:46:47 +01:00
Aymeric 9232528232 Add examples to use any LLM as engine 2024-12-13 19:48:55 +01:00
Aymeric 465614295d Improve documentation on agent building tips 2024-12-12 10:09:51 +01:00
Aymeric 0a0402d090 Simplify step logs 2024-12-11 22:33:41 +01:00
Aymeric 1606b9a80c Pass tests 2024-12-11 19:23:07 +01:00
Aymeric 67deb6808f Ruff formatting 2024-12-11 16:16:18 +01:00
Aymeric f3dcf1f013 Initialize repo structure. 2024-12-06 17:46:42 +01:00