Skip to content

What can we do about the over aggressive content filter at GitHub #711

@SamSaffron

Description

@SamSaffron

I am getting this way too much on Sonnet 3.5, so much that it is becoming unusable:

  choices = { {
      content_filter_offsets = {
        check_offset = 0,
        end_offset = 152,
        start_offset = 0
      },
      content_filter_results = {
        error = {
          code = "",
          message = ""
        },
        hate = {
          filtered = false,
          severity = "0"
        },
        self_harm = {
          filtered = false,
          severity = "0"
        },
        sexual = {
          filtered = false,
          severity = "0"
        },
        violence = {
          filtered = false,
          severity = "0"
        }
      },
      delta = {
        content = "d version:\n\n```javascript",
        copilot_annotations = {
          TextCopyright = { {
              citations = vim.empty_dict(),
              details = vim.empty_dict(),
              id = 0
            } }
        },
        role = "assistant"
      },
      finish_reason = "content_filter",
      index = 0
    } },
  created = 1736400745,
  id = "msg_bdrk_0115ZxJEq23SU48ZmC6mvKB1",
  model = "claude-3.5-sonnet",
  usage = {
    completion_tokens = 17,
    prompt_tokens = 3893,
    total_tokens = 3910
  }

I just discovered this is due to the suggestions matching public code here:

image

⏫ it was set to block

I guess the 2 possible action items here:

  1. Display a nice error message when we hit finish_reason of "content_filter"
  2. Add something to the readme about it

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions