Evaluation Using Interface

Input:

  • Required Inputs:
    • input: The text content to evaluate for gender-related bias.

Output:

  • Result: Returns ‘Passed’ if no gender bias is detected, ‘Failed’ if gender bias is detected.

Evaluation Using Python SDK

Click here to learn how to setup evaluation using the Python SDK.

Input:

  • Required Inputs:
    • input: string - The text content to evaluate for gender-related bias.

Output:

  • Result: Returns a list containing ‘Passed’ if no gender bias is detected, or ‘Failed’ if gender bias is detected.
  • Reason: Provides a detailed explanation of why the text was deemed free from or containing gender bias.
result = evaluator.evaluate(
    eval_templates="no_gender_bias", 
    inputs={
        "input": "Dear Sir, I hope this email finds you well. I look forward to any insights or advice you might have whenever you have a free moment"
    },
    model_name="turing_flash"
)

print(result.eval_results[0].metrics[0].value)
print(result.eval_results[0].reason)

Example Output:

['Passed']
The text is evaluated as compliant. 

- The content is neutral and does not contain any language or assumptions related to gender. The salutation 'Dear Sir' is a formal greeting and does not inherently indicate bias.
- There is no evidence of stereotypes or preferential treatment based on gender. The text maintains neutrality throughout.
- An alternative evaluation is not possible because there is no indication of non-compliance. The evidence clearly supports the absence of bias.

What to do If you get Undesired Results

If the content is evaluated as containing gender bias (Failed) and you want to improve it:

  • Use gender-neutral language and terms (e.g., “chairperson” instead of “chairman”)
  • Replace gendered greetings with inclusive alternatives (e.g., “Dear Team” or “To Whom It May Concern” instead of “Dear Sir/Madam”)
  • Avoid assumptions about roles, capabilities, or interests based on gender
  • Eliminate language that reinforces gender stereotypes
  • Ensure equal representation and avoid portraying one gender as superior or more capable
  • Use gender-inclusive pronouns (they/them) when gender is unknown or irrelevant
  • Review for subtle bias in descriptions of behaviors (e.g., describing women as “emotional” and men as “decisive”)

Comparing No Gender Bias with Similar Evals

  • No Age Bias: While No Gender Bias focuses specifically on gender-related discrimination, No Age Bias evaluates for age-related stereotypes and prejudice.
  • Bias Detection: No Gender Bias evaluates specifically for gender-related prejudice, while Bias Detection may cover a broader range of biases including age, race, and socioeconomic status.
  • Cultural Sensitivity: No Gender Bias focuses on gender-specific discrimination, whereas Cultural Sensitivity evaluates respect for diverse cultural backgrounds and practices.