| foundry_grader_string_check | R Documentation |
Compare a templated input string against a reference string with an exact or pattern operation. Useful for deterministic pass/fail checks such as verifying an extracted field matches a known value.
foundry_grader_string_check(
name,
input,
reference,
operation = c("eq", "ne", "like", "ilike")
)
name |
Character. Grader name shown in results. |
input |
Character. Input text, typically a template such as
|
reference |
Character. Reference text, typically a template such as
|
operation |
Character. One of |
A named list describing a string_check grader, for use in the
testing_criteria of foundry_eval_create().
foundry_grader_string_check(
name = "exact-match",
input = "{{sample.output_text}}",
reference = "{{item.answer}}",
operation = "eq"
)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.