As one poster replied above, there is code one doesn't need to understand if what you care about works. A good example is when I first tried a couple of local AI models on my highly unusual inference hardware.
It ran like a dog. Few nights of running Fable (later Opus 5.5) with a 7 strong team of DeepSeek v4.1 Flash 1017 (don't mistake it with 0731 that is crap) and llama was running 10x faster and vllm was running even faster when before it would not work at all.
I've run similarity and needle tests and the results are exactly the same content wise. But 10x faster. I've relied on this for a month now and I'm pretty happy with how it runs.
Do I now need to learn CUDA Kernel programming to understand how it was done? I don't think so. It's for my personal use. Not for a paying client so no warranty is perfectly fine.
But I also use a lot of AI at work in an I dusty where people may die if the code is buggy. So I absolutely verify and understand everything.
There is a middle ground too. Understanding the architecture.
For example I used a bunch of DeepSeek models supervised by Qwen to build adaptive-acl. A pi coding agent plugin that deterministicly checks if every tool used by an ai during an agentic session matches user intent to give permissions for those actions (reading/writing data, network access etc), as a part of this plugin I run an llm, a classifier that runs over user's prompts and extracts these permission grants then saving them in a format deterministic layer can process.
The design includes massive number of assumptions and compromises. For example, if a user allows writing this implies permission to delete and reading if what was written etc.
The thing also includes over 4 thousand actual instances of tool use preceded by "permissions talk" from my live sessions and that whole collection can be run to test for regression etc.
At some point during one night the AI had a regression and decided the best way to resolve it would be to add regex based language processing elements to the deterministic layer (a huge no no, this has to work regardless of the user speak English or Swahili, also regexing natural language is a disaster waiting to happen).
I knew enough about the architecture to notice that and burn it out with a hot iron.
That is the problem with AI. It sometimes solves problems the easiest possible way causing massive issues for later. So if one uses it for important stuff it is good to understand the architecture and the plan of what it is going to build at the very least.