Coder Social home page Coder Social logo

Typing about dspy HOT 3 CLOSED

stanfordnlp avatar stanfordnlp commented on July 22, 2024
Typing

from dspy.

Comments (3)

okhat avatar okhat commented on July 22, 2024

Hey, this sounds excellent and I want to dig deeper. Not sure if you follow my Twitter updates on this, but we have built a v2 (called DSPy) that we're releasing like ... in 2-3 days. It's not a rewrite actually, it's a much cleaner and more powerful wrapper around DSPv1, but I can't tell if it will resolve some of your concerns or not.

So I'd like to understand your concerns.

dynamic behavior that could lead to hard to debug errors when something will change between versions

Versions of? The framework itself? Or a program built in it? Basically, I might need an example of this to understand what you mean.

What is the advantage of Pydantic here? What kind of validation are you thinking of?

from dspy.

okhat avatar okhat commented on July 22, 2024

One issue we did fix in DSPy (i.e., v2) is that the generate functions will take kwargs and not "x" (dsp.Example). This is a lot less opaque and causes fewer issues.

This sounds like it interacts with your concerns on validating which fields are where.

from dspy.

lambdaofgod avatar lambdaofgod commented on July 22, 2024

By validation I meant that for example when I removed 'demos' argument in vanilla_LM_QA from "demonstrate_search_predict" notebook I got an error in generate function and not in Example itself. Pydantic wouldn't let me create an object if I didn't pass the required field or if it had incorrect type (it would fail instantly thus making debugging far easier).

I'm looking forward for v2, when it drops I'll try to write these classes for validation.

from dspy.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.