# Catalog of valid arguments in model cards?

**URL:** <https://discuss.huggingface.co/t/catalog-of-valid-arguments-in-model-cards/154507>\
**Category:** Models\
**Created:** [May 11, 2025, 4:54am UTC](https://discuss.huggingface.co/t/catalog-of-valid-arguments-in-model-cards/154507 "2025-05-11T04:54:46Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![STARBORN](https://sea2.discourse-cdn.com/hellohellohello/user_avatar/discuss.huggingface.co/starborn/32/47289_2.png) [@STARBORN](https://discuss.huggingface.co/u/STARBORN)\
**Post date:** [May 11, 2025, 4:54am UTC](https://discuss.huggingface.co/t/catalog-of-valid-arguments-in-model-cards/154507/1 "2025-05-11T04:54:46Z")

</div>

Greetings, good people  
I am researching the structure of the [model card template](https://github.com/huggingface/huggingface_hub/blob/main/src/huggingface_hub/templates/modelcard_template.md) and wonder what argument can each slot accept as input  
For example: in the field MODEL SOURCE, I can assument the choice of argument is paper/repo/demo \*taken from the info in the field description , but in other fields such as for example MODEL TYPE or TRAINING PROCEDURE etc there arent any clues. just wondering. thanks, pointers appreciated

---

<div class="post-metadata">

**Author:** ![John6666](https://sea2.discourse-cdn.com/hellohellohello/user_avatar/discuss.huggingface.co/john6666/32/27664_2.png) [@John6666](https://discuss.huggingface.co/u/John6666)\
**Post date:** [May 11, 2025, 9:46am UTC](https://discuss.huggingface.co/t/catalog-of-valid-arguments-in-model-cards/154507/2 "2025-05-11T09:46:20Z")

</div>

I think anything is acceptable as long as it does not violate the YAML format. Whether or not it will be interpreted in a special way depends on the implementation of the Hub. For example, this.

> <https://github.com/huggingface/huggingface.js/blob/main/packages/tasks/src/model-libraries.ts>

---

<div class="post-metadata">

**Author:** ![STARBORN](https://sea2.discourse-cdn.com/hellohellohello/user_avatar/discuss.huggingface.co/starborn/32/47289_2.png) [@STARBORN](https://discuss.huggingface.co/u/STARBORN)\
**Post date:** [May 11, 2025, 1:01pm UTC](https://discuss.huggingface.co/t/catalog-of-valid-arguments-in-model-cards/154507/3 "2025-05-11T13:01:59Z")

</div>

Thank you John, things is I dont speak much code so I really stick with model cards. if I understand you correctlyl, any litteral string , Like in this example? [How to represent strings in YAML](https://how.dev/answers/how-to-represent-strings-in-yaml) Is there a way to look up the list of arguments already used in HF? \*so that I may derive a model from that?

---

<div class="post-metadata">

**Author:** ![John6666](https://sea2.discourse-cdn.com/hellohellohello/user_avatar/discuss.huggingface.co/john6666/32/27664_2.png) [@John6666](https://discuss.huggingface.co/u/John6666)\
**Post date:** [May 11, 2025, 11:18pm UTC](https://discuss.huggingface.co/t/catalog-of-valid-arguments-in-model-cards/154507/4 "2025-05-11T23:18:41Z")

</div>

In that case, it would probably be safer to use `HfApi` for crawling. When I searched for tags before, there were more than I expected…

> **[subtags.json · John6666/hfsearch at main](https://huggingface.co/spaces/John6666/hfsearch/blob/main/subtags.json)**
>
> We’re on a journey to advance and democratize artificial intelligence through open source and open science.

> **[HfApi Client](https://huggingface.co/docs/huggingface_hub/main/en/package_reference/hf_api)**
>
> We’re on a journey to advance and democratize artificial intelligence through open source and open science.

---

<div class="post-metadata">

**Author:** ![STARBORN](https://sea2.discourse-cdn.com/hellohellohello/user_avatar/discuss.huggingface.co/starborn/32/47289_2.png) [@STARBORN](https://discuss.huggingface.co/u/STARBORN)\
**Post date:** [May 12, 2025, 2:56am UTC](https://discuss.huggingface.co/t/catalog-of-valid-arguments-in-model-cards/154507/5 "2025-05-12T02:56:06Z")

</div>

Thank you John  
any chance of a tutorial?

---

<div class="post-metadata">

**Author:** ![John6666](https://sea2.discourse-cdn.com/hellohellohello/user_avatar/discuss.huggingface.co/john6666/32/27664_2.png) [@John6666](https://discuss.huggingface.co/u/John6666)\
**Post date:** [May 12, 2025, 6:20am UTC](https://discuss.huggingface.co/t/catalog-of-valid-arguments-in-model-cards/154507/6 "2025-05-12T06:20:42Z")

</div>

I got it like this. Nothing special. 😅

```py
from huggingface_hub import HfApi
from collections import Counter

def get_tags():
    api = HfApi()
    tags_list = []
    spaces = api.list_spaces(full=True, limit=10)
    for i in spaces:
        if i.tags is not None: tags_list.extend(i.tags)
    models = api.list_models(full=True, cardData=True, limit=10)
    for i in models:
        if i.tags is not None: tags_list.extend(i.tags)
    datasets = api.list_datasets(full=True, limit=10)
    for i in datasets:
        if i.tags is not None: tags_list.extend(i.tags)

    tags_dict = dict(Counter(tags_list))
    print(tags_dict)

get_tags()

```
