chore: change to using dict instead of model_info class#3294
chore: change to using dict instead of model_info class#3294jaideepr97 wants to merge 1 commit intoinstructlab:mainfrom
Conversation
f03b14f to
3d8c34b
Compare
|
E2E (NVIDIA L40S x4) LLAMA workflow launched on this PR: View run |
|
e2e workflow failed on this PR: View run, please investigate. |
|
E2E (NVIDIA L40S x4) LLAMA workflow launched on this PR: View run |
|
e2e workflow failed on this PR: View run, please investigate. |
3d8c34b to
cfe26a6
Compare
cfe26a6 to
9abaf8b
Compare
|
E2E (NVIDIA L40S x4) LLAMA workflow launched on this PR: View run |
|
e2e workflow failed on this PR: View run, please investigate. |
| yaml.indent(mapping=2, sequence=4, offset=2) | ||
|
|
||
| # yaml.representer.add_representer(BaseModel, lambda r, d: r.represent_dict(d.model_dump())) | ||
|
|
There was a problem hiding this comment.
Was this some debugging code?
There was a problem hiding this comment.
oops, yeah leftover from a different approach i was trying first
|
E2E (NVIDIA L40S x4) LLAMA workflow launched on this PR: View run |
|
e2e workflow failed on this PR: View run, please investigate. |
9abaf8b to
4390e17
Compare
Signed-off-by: Jaideep Rao <[email protected]>
4390e17 to
f5d40ba
Compare
There was a problem hiding this comment.
This is not ideal because we lose comments. There's no reason for us not to handle this scenario properly. So I'd rather fix our code that converts configMap to dict for ruamel to handle iterables of models instead. I'll send a fix in a few. Stand by.
|
Please see #3295 |
|
closing in favor of #3295 |
using a custom class
model_infoto represent 3rd party model info seems to not play well with ruamel yaml representation anytime the config object needs to be dumped either to file or stdout leading to a yaml representation error.This seems to be happening because we load a list of model_info objects into memory rather than just the model_info object directly like for the other fields
It's easier to just work with a list of dicts instead
Checklist:
conventional commits.