Validates and wraps a data frame of scholarly fields and their definitions
into a pc_taxonomy object for use with pc_classify(). A taxonomy
provides the controlled vocabulary that the LLM assigns publications to.
Examples
tax <- pc_taxonomy(data.frame(
field = c("Ecology", "Economics", "Computer Science"),
definition = c(
"Study of organisms and their interactions with the environment.",
"Study of production, distribution, and consumption of goods.",
"Study of computation, algorithms, and information systems."
)
))
print(tax)
#>
#> ── pubclassify taxonomy (3 fields) ─────────────────────────────────────────────
#> • Ecology: Study of organisms and their interactions with the environment.
#> • Economics: Study of production, distribution, and consumption of goods.
#> • Computer Science: Study of computation, algorithms, and information systems.