stanfordnlp / dspy

DSPy: The framework for programming—not prompting—foundation models
https://dspy-docs.vercel.app/
MIT License
18.38k stars 1.41k forks source link

Support custom signature format #1244

Closed XiepengLi closed 1 month ago

XiepengLi commented 4 months ago
Answer questions with short factoid answers.

---

Follow the following format.

Question: ${question}
Question's Answer: often between 1 and 5 words

---

Question:

This is an extremely opinionated format

theta-lin commented 3 months ago

@XiepengLi I agree that fixing a prompt format is not a good design choice. I recommend referring to #409 for this issue.

okhat commented 1 month ago

Adapters fix this in DSPY 2.5 https://github.com/stanfordnlp/dspy/blob/main/examples/migration.ipynb