feat(config): add optional dataset.tags and dataset.category fields - #434
Merged
Conversation
Aggiunge i campi opzionali tags (list[str]) e category (str | None) al blocco dataset: del dataset.yml, con propagazione in: - DatasetBlock Pydantic model (shared_models.py) - ToolkitConfig dataclass pubblica (config.py) - load_config() — popolamento da YAML - load_dataset_manifest() — manifest pubblico - dataset_info() — esposizione via MCP server I campi sono backward-compatibili: dataset.yml esistenti continuano a funzionare senza modifiche. tags defaulta a [], category a None. Test: 5 nuovi test in test_config_loading.py (contract + policy), 4 nuovi test in test_dataset_loader.py (pure_unit).
Gabrymi93
force-pushed
the
feat/dataset-tags-category
branch
from
July 29, 2026 19:38
af5c6e8 to
f12ee3e
Compare
Allinea dataset_info() con tags/category — espone anche source_id per coerenza nei metadati del dataset via MCP.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Sintesi
Aggiunge
tags(list[str]) ecategory(str | None) come campi opzionali del bloccodataset:in dataset.yml, con propagazione in modello Pydantic, dataclass pubblica, manifest e MCP server. Base per i selettori batch semantici (futuro).Contesto collegato
Nessuna issue — richiesta diretta per organizzare batch smart in dataset-incubator.
Cosa cambia
Impatto su contratti pubblici
dataset.yml(nuovo campo, cambio obbligatorietà)Downstream aggiornato:
dataset-incubator— x [x]docs/Verifica
pytest -m corepassaruff check .passamypy toolkit/passa (o motiva le eccezioni)contract/policy/pure_unit)Checklist PR
Note per chi revisiona
I campi sono parsati dal Pydantic
DatasetBlocke propagati in:ToolkitConfig(dataclass pubblica) — accesso viacfg.tags,cfg.categoryload_dataset_manifest()— per cataloghi e CIdataset_info()(MCP server) — esposizione ad agenti AIFix minore:
_modelfield inToolkitConfigora hadefault=Noneesplicito (erafield()senza default, che causava errore dataclass quando altri campi con default vengono aggiunti prima).