Comments (1)
Hi @backslash112 , the description is attached with the field within the prompt.
For instance, in the intro.ipynb
notebook, the signature BasicQA
is defined as
class BasicQA(dspy.Signature):
"""Answer questions with short factoid answers."""
question = dspy.InputField()
answer = dspy.OutputField(desc="often between 1 and 5 words")
which turns into the prompt:
Answer questions with short factoid answers.
---
Follow the following format.
Question: ${question}
Answer: often between 1 and 5 words
---
Question: What is the nationality of the chef and restaurateur featured in Restaurant: Impossible?
Answer:
The description is certainly not necessary if the signature instruction covers your task requirements, but can often help in guiding the model on how to treat the corresponding Input and OutputFields.
from dspy.
Related Issues (20)
- Debug in DSPy HOT 2
- Predictors with Ollama return input prompt in answer HOT 2
- Using TypedChainOfThough caused reasoning to be replaced by output schema
- How to view the optimized prompt ? HOT 1
- ReAct Fails on minimal Examples HOT 1
- max_tokens error for google's models HOT 2
- Improper response with multiple output fields HOT 3
- Field descriptions for individual items in a Pydantic model HOT 1
- Bootstrap temperature (0.7) overrides user temperature and LM temperature
- COPRO: doc fix
- Default top_p=1 everywhere. Why? HOT 1
- LlamaIndexRM returning Example with attribute `text` instead of `long_text`
- MIPRO compile ERROR HOT 1
- Integrate dspy with qwen 72B model
- KeyError: 'max_tokens'. HOT 1
- Integrating XML Validation Feedback into Optimization Processes
- How to handle Exceptions when calling Azure OpenAI model API
- HTTP_PROXY
- Getting dependency issues with Microsoft GraphRAG HOT 1
- QdrantRM do not support passages HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from dspy.