Copilot stops working on code that contains hardcoded banned words from GitHub
49 comments
·February 7, 2025klibertp
The news is that it actually started working again some time ago. Indeed, this:
(cl-defstruct person gender)
(make-person :gender "m<|>")
with cursor at <|> does elicit "male" completion. Yay for normalcy?(Though honestly, I didn't notice this earlier - Copilot tends to hang for me too often in all kinds of files for me to identify these stopwords.)
(EDIT: gotta admit though, this is hilarious: https://github.com/orgs/community/discussions/72603#discussi...)
mycall
I have a simple question. If censorship is considered evil regarding the written word and communications between humans, why do we want to then censor LLMs differently? It is either counterintuitive or simply a false concept we should abandon. Perhaps it is more about training, similar to how children are 'monsters' and need to be socialized/tamed.
StableAlkyne
> why do we want to then censor LLMs differently?
Because of the obvious PR implications of having a program one's company wrote spewing controversial takes. That's what it boils down to - and it's entirely reasonable.
Personally, I wish these things could have a configurable censorship setting. Everyone has different things that get under their skin, after all (and this would satisfy both the pro-censor and pro-uncensored groups). It's a good argument for self hosting, too, because those can be filtered to your own sensitivities.
That would help with cases where the censorship is just dead wrong. A friend was working with one of the coding ones in VS Code, and expressed his frustration that as soon as the codebase included the standard acronym for "Highest Occupied Molecular Orbital" (HOMO) it just refused any further completion. We both guessed the censor was catching it as a false positive for the slur.
thatguy0900
It wouldn't satisfy both groups, the people who want the censorship want it censored for everyone
nkrisc
I censor myself all the time when speaking, depending on the context and who I’m speaking to. I do it because it’s typically in my best interest to do so, and because I believe that it is respectful in that moment. The things I say represent me. I don’t find it too surprising that a company might want to censor their own AI product as it represents them and their reputation.
pjc50
They're not being censored by the state in this case (unlike the gotcha everyone keeps using when deepseek is mentioned). They're being limited by their developers for brand safety.
There's still career-ending possibilities from saying things even in the overtly antiwoke government: https://www.independent.co.uk/news/world/americas/us-politic... ; people are not going to trust an LLM which might say such things on their behalf.
Not to mention questions like "who is liable if an LLM libels someone".
sfn42
That's easy. The person who used an LLM to generate the text and then published it as their own without even proofreading it is liable for the text they published.
anal_reactor
> If censorship is considered evil regarding the written word and communications between humans
It's not. Most people do support censorship. They just don't admit that.
sfn42
Because the people in charge are morons and the public is full of morons and the morons in charge are scared that the morons of the public will get mad and make a big deal about some inconsequential bullshit like "your llm said a naughty word!!"
And that's why we can't have nice things.
nemomarx
I think your first premise is incorrect, ie the groups doing this do not largely think censorship is evil.
conartist6
It's to draw attention away from the fact that LLMs are amoral.
You clearly have a moral spine because you're standing up and asking questions about what is right.
LLMs can't do anything like that so they need to be constrained by more direct methods in order to not appear to be evil
gedy
> If censorship is considered evil regarding the written word and communications between humans
Oh it's certainly not by many people. It's fine with them if you are censoring what they don't like.
It took me a long time to realize the "free speech" advocates of the 60s-80s were long gone from the left.
precommunicator
I had similar issues when trying to ask Copilot about master/slave replication, just error, no explanation
CapsAdmin
On a slightly related note, does anyone feel copilot is not as powerful as it used to be? It's kind of hard to pinpoint exactly what it is, but it feels like it often either does nothing, or generates the bare minimum.
I think one concrete thing is writing a comment about a function, then expecting that function below the comment, but instead you get more comments.
sixothree
I haven’t literally never gotten my copilot integration in visual studio to provide anything usable. I don’t mean this hyperbolically. I literally don’t understand what we are paying for.
emsign
I didn't notice any decline, it still gives me code that is wrong almost every time.
jkukul
Agree 100%. I noticed that on the Copilot settings page [1] you can switch to Claude Sonnet model (instead of a model trained by Github I assume?). In my experience this improves things.
whywhywhywhy
Seems the trend with most LLM tech is once the users are there the model is quantized or downgraded down to the bare minimum level of usefulness either silently or through new versions that are just not better in real use.
bshacklett
Just a data point my experience with ChatGPT has only gotten better and better.
bugtodiffer
You're just disillusioned, AI was never that good
spiderfarmer
Close the comment, write 'function' and wait a little.
littlecranky67
Very same experience. Plus, the guardrails have just become ridicioulus.
sfn42
I've only tried copilot once and this is exactly my experience. I'd write a comment to try to prompt it, then it would keep writing the comment instead of the function. Best I could do was make it write the function as a comment then uncomment it.
I prefer to just write code myself
travisjungroth
You can also take care of this by ending the comment and writing the function or class keyword for your language, like “def”.
xyproto
I wonder if one can sneak in words into code to avoid public code to be used for training AI. Perhaps just a tiny little nazi reference.
arrowsmith
I was reading someone the other day (it might have been on HN) saying they use this strategy to prevent candidates from using LLMs in interviews.
E.g. a system design interview question about building an app to manage all your drug shipments and nuclear bombs.
worksonmine
Probably not that useful to prevent the use of AI, just prompt for any shipments. In a real app the contents of the packages shouldn't be hard-coded anyway. Might prevent the really stupid who can't figure that out though.
thrance
Current administration is fine with nazi stuff, just put "cisgender" in your code and you should be safe.
alistairSH
2023. And apparently working based on the most recent comment.
bugtodiffer
This title does not do the issue justice
regularjack
Title has been editorialized, the correct title is:
Copilot stops working on gender related subjects
KronisLV
Time to buy some beefy professional GPUs with plenty of VRAM and run models locally (for example, with Ollama and Continue.dev), to get around things like this.
wiredfool
M-x spook maybe needs a bit of an update.
klibertp
How could I not have known about this gem for so long?!
;; Created: May 1987
Guess I'm one of today's lucky 10000 :)null
I’m somewhat “rude” in my code comments and was tripped up by this last month… took me a while to figure out while on that specific file autocomplete would stop working https://bsky.app/profile/giorgio.azzinna.ro/post/3lecq3v5gts...
Not to mention, there’s apparently some research saying code with swear words has higher quality, so if AI causes some decline there, we now know why it is https://www.reddit.com/r/programming/comments/110mj6p/open_s...