Skip to content

Commit

Permalink
fix: use mxbai-embed-large as embedding model in local example
Browse files Browse the repository at this point in the history
  • Loading branch information
felixocker committed Jan 24, 2025
1 parent 5b369c7 commit 62d4964
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion examples/local_examples.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,12 @@
# OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#
"""
Example for using a ToolLibrary and CotTulipAgent with local models.
Assumes that environment variables are set and that the following models are available:
* language model: llama3.2, e.g., https://ollama.com/library/llama3.2
* embedding model: mxbai-embed-large, e.g., https://ollama.com/library/mxbai-embed-large
"""
import logging

from tulip_agent import BaseAgent, CotTulipAgent, ModelServeMode, ToolLibrary
Expand All @@ -40,9 +46,10 @@
ba = BaseAgent(model_serve_mode=ModelServeMode.OAI_COMPATIBLE, model="llama3.2")

tulip = ToolLibrary(
chroma_sub_dir="example/",
chroma_sub_dir="local_example/",
file_imports=[("calculator", [])],
model_serve_mode=ModelServeMode.OAI_COMPATIBLE,
embedding_model="mxbai-embed-large",
)
cta = CotTulipAgent(
tool_library=tulip,
Expand Down

0 comments on commit 62d4964

Please sign in to comment.