Skip to content

Standard Schema for Signature Input/Output? #348

@austinm911

Description

@austinm911

I've only recently came across DSPy and ax so I might not be so familiar with the paradigms here. But as a TS person, the familiarity of zod, valibot, arktype, effect/schema, etc is probably important for people to gain an immediate understanding of a new project. Especially since most are going to be more familiar with Zod usage patterns, like with Vercel AI and something like Mastra.

It's also not immediately clear to me that if you have types/schemas defined that you want to use as Input/Output Signatures, can you reuse those? As I'm looking through, it seems like you have to manually maintain the special Signature string when your project may be using Standard Schema for the same schema logic. I could very well be missing something though.

For example here, would you be able to reuse the SearchResult output schema with ax?

Anyways, I thought a newcomer's thoughts might be helpful as I really like to idea of not maintaining prompts that DSPy as I understand, really revolves around.

Haven't used this but looks like this may be relevant to mention as a Standard Schema -> JSON Schema converter https://xsai.js.org/docs/packages-top/xsschema

My attempt at trying to answer this myself, leaving this here. https://chatgpt.com/share/68c217a6-c35c-8013-88d1-8488d78b49a9

Maybe this is more of a discussion than an issue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions