Finding training data in million‑scale machine learning repositories is essentially a web search problem where plain text relevance is insufficient. A query must couple a semantic training goal with constraints such as task, license, and training stage, yet the metadata needed to verify these constraints is often missing. Traditional text retrieval ranks dataset cards by similarity only, cannot enforce hard constraints, and struggles to follow sparse relational links to the desired dataset. Free‑form tool‑calling agents are more flexible, but the same model that selects a dataset also declares it a match, without any check that the query’s constraints are truly satisfied, so there is no guarantee the returned data will improve model training.
To address this, we propose AgenticDS, a contract‑governed agentic framework. Every language‑model decision instantiates a typed object that deterministic code then consumes. The process compiles a query into a typed search plan, executes it via admissible deterministic operators over hybrid retrieval and bounded graph expansion, and verifies provenance‑grounded evidence before accepting a ranking or emitting a typed diagnosis that permits only local repairs.
On the newly introduced HuDS‑Bench (200 queries, 24 908 graded judgments across 15 systems), AgenticDS improves NDCG@10 by 25.7% over the strongest dense‑sparse hybrid and by 18.9% over a commercial LLM agent. A controlled search‑to‑train study further shows that datasets retrieved by AgenticDS yield the best downstream accuracy in mathematics, code, and medicine. Code and data are publicly available at https://github.com/nju-websoft/AgenticDS.
Review: AgenticDS introduces contract enforcement and verifiable execution into dataset search, providing a reliable pathway that demonstrably enhances downstream model performance.