Comments (1)
if the datasets are being loaded from the dspy.datasets module then why not gsm8k dataset can be loaded in the same manner as others. And also GSM8k does not inherit from the class Dataset
if I try to change it to be child class of the Dataset class i am encountering the following error
AttributeError Traceback (most recent call last)
Cell In[2], [line 1](vscode-notebook-cell:?execution_count=2&line=1)
----> [1](vscode-notebook-cell:?execution_count=2&line=1) dataset = GSM8K()
[3](vscode-notebook-cell:?execution_count=2&line=3) print(dataset.train)
File ~/anaconda3/envs/dspy/lib/python3.10/site-packages/dspy/datasets/gsm8k.py:62, in GSM8K.__init__(self, *args, **kwargs)
[56](https://file+.vscode-resource.vscode-cdn.net/media/jayanth/DATA/Naanu/practice/DSPy/~/anaconda3/envs/dspy/lib/python3.10/site-packages/dspy/datasets/gsm8k.py:56) testset = [dspy.Example(**x).with_inputs('question') for x in testset]
[58](https://file+.vscode-resource.vscode-cdn.net/media/jayanth/DATA/Naanu/practice/DSPy/~/anaconda3/envs/dspy/lib/python3.10/site-packages/dspy/datasets/gsm8k.py:58) # print(f"Trainset size: {len(trainset)}")
[59](https://file+.vscode-resource.vscode-cdn.net/media/jayanth/DATA/Naanu/practice/DSPy/~/anaconda3/envs/dspy/lib/python3.10/site-packages/dspy/datasets/gsm8k.py:59) # print(f"Devset size: {len(devset)}")
[60](https://file+.vscode-resource.vscode-cdn.net/media/jayanth/DATA/Naanu/practice/DSPy/~/anaconda3/envs/dspy/lib/python3.10/site-packages/dspy/datasets/gsm8k.py:60) # print(f"Testset size: {len(testset)}")
---> [62](https://file+.vscode-resource.vscode-cdn.net/media/jayanth/DATA/Naanu/practice/DSPy/~/anaconda3/envs/dspy/lib/python3.10/site-packages/dspy/datasets/gsm8k.py:62) self.train = trainset
[63](https://file+.vscode-resource.vscode-cdn.net/media/jayanth/DATA/Naanu/practice/DSPy/~/anaconda3/envs/dspy/lib/python3.10/site-packages/dspy/datasets/gsm8k.py:63) self.dev = devset
[64](https://file+.vscode-resource.vscode-cdn.net/media/jayanth/DATA/Naanu/practice/DSPy/~/anaconda3/envs/dspy/lib/python3.10/site-packages/dspy/datasets/gsm8k.py:64) self.test = testset
AttributeError: can't set attribute 'train'
and i am not getting why is this error being thrown
from dspy.
Related Issues (20)
- Chat support in Ollama impacting normal generation, something with `"content": "".join(text)` HOT 1
- Claude does not work with the new experimental setting. HOT 1
- ModuleNotFoundError: No module named 'dspy.datasets'; 'dspy' is not a package
- Question: BootstrapFewShot - Intermediate Label Bootstrapping HOT 1
- Signatures rarely work out of the box HOT 2
- OpenAI + ReAct : TypeError: unhashable type: 'list' HOT 1
- How to get multiple output from the dspy program? (e.g., two answers for a question)
- Deprecation warnings point to non-existing `dspy.set_log_level` HOT 1
- BuilderConfig doesn't have "trust_remote_code" key when loading HotPotQA HOT 1
- 'ReAct' object has no attribute 'best_programs'
- dspy.Retrieve cannot read csv file HOT 1
- dsp.settings to modify templates. Where can I find them? HOT 1
- List index error using MIPROv2 HOT 1
- Miprov2 doesn't work with TypedPredictors HOT 1
- import error: AttributeError: module 'threading' has no attribute '_Condition'. Did you mean: 'Condition'? HOT 1
- semver dependency error when setting up dev container HOT 2
- dspyComponent module only allows for a dspy.Predict module as input HOT 2
- `named_parameters()` and `named_submodules()` for dictionary attributes with non-string keys
- MIPROv2 - Error generating fewshot examples: name 'metric_threshold' is not defined
- Debug in DSPy
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.