Plausible? Not especially. There’s three problems.
First, knife fighting is very dangerous. There’s no margin for error, and screwing around is a fantastic way to end up dead with no warning. Trying to get hurt, is a fantastic way to end up dead, because your character wouldn’t be able to pick and choose between a strike that would kill them (or could lead to certain death) and one that would be superficial.
This is actually one way a lot of real world martial artists get themselves killed. They approach a situation with a knife (or another weapon), the way they approach sparring, and they get shanked (or shot).
Also, getting stabbed in the eye usually means it no longer works. Which means they should not be getting into knife fights under any circumstances. The lack of depth perception would be fatal there.
Second, your character has no way of knowing their opponent is unskilled. This is actually getting into general writing advice, but you always need to keep what your character knows separate from what you, as the writer, knows. Always.
Your character has no way of knowing this is an unskilled amateur. They have no way of knowing that they can jump into a fight with this assassin and not give it their all. For that matter, they may not even know the guy is an untrained assassin, because whatever tells they’re expecting to see from a trained killer won’t be there.
Third, what are they blowing their cover for? Your character went undercover for a reason, and it wasn’t to deal with this one off, random, untrained assassin that any security guard could deal with. He’s got an actual job to do, probably surveillance, based on the information you’ve given. Risking their cover to deal with this one guy isn’t heroic, it’s sabotaging their work.
Going undercover isn’t about being a secret good guy, it’s about disappearing and passing yourself off as someone else. This whole, Clark Kent would change in a phone booth, but he doesn’t have the time, so he’ll just have to do this out of costume thing doesn’t apply for undercover operations. That’s superheroes, and it’s very different.
Your character would need to do whatever a janitor in their position should, which is contact security or trigger a silent alarm and let the people who are actually being paid to deal with situations like this do their jobs. They should not jeopardize their position by exposing themselves so they can pretend to be a superhero.
If your character is a competent spy, they’re not going to risk their cover unless it is necessary to achieve their goals.
As a stray note, if your character’s lost an eye, they’re going to be a sub par choice for undercover work. Ironically not because of the vision issues. The problem is they’d be more memorable. Which is exactly what you don’t want. While an actual janitor with a missing eye makes perfect sense, they’re also someone you’re more likely or remember than “that nondescript guy over there mopping.”
Now, if the point was to get noticed by someone, your one eye janitor getting shanked by some crazy would be a good way to do that. In that case, the missing eye is a good way to keep in people’s minds. Along with a story about being some blacklisted/burned out/screwed over badass who’s been reduced to cleaning up other peoples’ vomit.
But, that approach would be more about ingratiating your character to the villain. It would require your “untrained assassin” to be an accomplice, who can stab your character safe(ish)ly, before taking off. Because the entire thing is a scripted act and not just improv night with knives.