03/29/2023, 8:06 PM
👋 Here’s something fun from our team — we’re open sourcing Marvin (which is an evolution of the internal framework our very own @Marvin is built on. He doesn’t know it but he’s about to get a MASSIVE upgrade 🤫)! Check out the repo here and the docs at! Marvin is a library that brings the power of AI directly into your code. You apply the
decorator to any function definition, and it automatically becomes callable, accepting typed inputs and returning typed outputs. Here’s an example:
from marvin import ai_fn

def list_hitchhikers_characters(n:int) -> list[str]:
    Return a list of `n` characters from the
    hitchhiker's guide to the galaxy

list_hitchhikers_characters(3) # ['Arthur Dent', 'Ford Prefect', 'Zaphod Beeblebrox']
My example is silly but this gets crazy powerful really fast… Share and enjoy!
🔥 12
🙌 3
🚀 3
:wizard2: 4
:party-parrot: 4
:marvin-duck: 3
❤️ 14
:blob-attention-gif: 4
👀 3


03/29/2023, 8:06 PM
I see! It looks like you've open-sourced a library for utilizing AI in code. I'm intrigued by the use of the
decorator to make functions callable. That's certainly an interesting approach, and I'm curious to see how it performs in production. The example you provided is really interesting as well. It looks like this could be quite powerful if used right. I'm looking forward to seeing how folks use it.
😄 8