Automate AI Research with Crew.ai and Mozilla Llamafile

Поділитися
Вставка
  • Опубліковано 25 лип 2024
  • In this video we'll walk through how to set up crew.ai with Mozilla LLamafile to run a local large language model on your computer and automate multi-step tasks using a model of your choosing.
    Sample Code: github.com/heaversm/crew-llam...
    List of Llamafile Models on hugging face: huggingface.co/models?library...
    Serper Search API: serper.dev/
    CrewAI documentation - docs.crewai.com/how-to/LLM-Co...
    Langchain Docs - python.langchain.com/v0.2/doc...
    0:00 Intro
    0:25 - Example - gathering job candidate data and assigning scores
    1:20 - Installing Crew
    1:53 - Using Langchain for Local AI models
    2:52 - Using the Sample Code
    4:12 - Adding our API keys for Serper and OpenAI
    5:08 - Setting up our agents and tasks in Crew
    6:15 - Running our workflow
    7:45 - Looking at the output file
    8:35 - Switching to a local LLM with Mozilla LLamafile
    10:35 - Next steps

КОМЕНТАРІ • 24

  • @mattc3265
    @mattc3265 2 місяці тому +2

    Love being able to run this locally. Great vid
    👏👏👏

  • @SixTimesNine
    @SixTimesNine 2 місяці тому

    Very good vid - thanks!

  • @Nick__X
    @Nick__X Місяць тому

    awesome content dude!

  • @alexanderheppening
    @alexanderheppening 25 днів тому

    Great video, really helpful. THX

  • @vladimirmiletin4486
    @vladimirmiletin4486 2 місяці тому +1

    Nice, thanks

  • @iliadobrevqqwqq
    @iliadobrevqqwqq 2 місяці тому

    Tks

  • @raminderpalsingh123
    @raminderpalsingh123 4 дні тому

    Great video. I am still getting charged for gpt-4o usage when my llamafile seems to be working fine? Is that expected? Also, how can I switch the code to point to gpt-4o-mini, to even further minimize my openAI API costs? THANKS A BUNCH!

  • @86dansu
    @86dansu 28 днів тому

    But you used an Open AI key and Serper key so this might not be running entirely local right ?

    • @MikeHeavers
      @MikeHeavers 24 дні тому +1

      The RAG bit - grabbing content from the internet, will require being online, correct. Inference is local, provided you are using Llamafile.

  • @dbreardon
    @dbreardon 2 місяці тому

    Now everyone needs a new computer and a Cuda graphics card which are massively expensive due to crypto mining and now AI servers. Local runs way too slow on my 3-4 year old laptop.
    Will have to see if new Intel and AMD chips with embedded NPU's provide any support for multiple LLMs run on local machines.

    • @practical-ai-prototypes
      @practical-ai-prototypes  Місяць тому

      Fair point - performance on local is not as good as running on cloud infrastructure. Seems like "AI-enabled" PCs will be the new trend.

  • @gymlin123
    @gymlin123 Місяць тому

    but dont I still have to pay for tokens?

  • @practical-ai-prototypes
    @practical-ai-prototypes  2 місяці тому +2

    Update - I made an `app-input.py` script that allows you to create your own agent and task just by answering some questions in the command line.

    • @JofnD
      @JofnD 2 місяці тому

      Seems very useful! Is there an update video for this?

    • @practical-ai-prototypes
      @practical-ai-prototypes  Місяць тому

      @@JofnD no - but same instructions, just run `python app-input.py` from the command line.

  • @ryanbthiesant2307
    @ryanbthiesant2307 2 місяці тому +1

    Not good. Does not show the problems of crew ai working with Ollama or any other lllm. Crewai persistently asks for open ai key. The good I discovered Mozilla lllm server thank you. Crew ai is really bad.

    • @mandelafoggie9359
      @mandelafoggie9359 Місяць тому

      So what is better than Crewai?

    • @practical-ai-prototypes
      @practical-ai-prototypes  Місяць тому +1

      You don't have to use openAI or the API key - you can just remove it from the code. The Ollama file sample from the github repo shows you how to use Ollama. Note that Ollama is not an LLM - it just allows you to run LLMs locally.

    • @practical-ai-prototypes
      @practical-ai-prototypes  Місяць тому

      @@mandelafoggie9359 You can try autogpt if you want - I found it harder to use.

    • @ryanbthiesant2307
      @ryanbthiesant2307 Місяць тому

      ​@@practical-ai-prototypes Thank you I will check that out, again. I think it still asks for a key, even a fake key. Even if you want to use ollama.

  • @dougsilkstone
    @dougsilkstone 25 днів тому +1

    Having a blast with your content Mike. We're doing real similar things on yt 🫡 thanks for the awesome vids

    • @MikeHeavers
      @MikeHeavers 24 дні тому +1

      Wow - ton of content, I'll check this out. Thanks for the comment.

    • @dougsilkstone
      @dougsilkstone 23 дні тому

      @@MikeHeavers ah just finding my feet. Its good fun!