It's hard to make money by pure market-making, so it's common for market-makers to also do some amount of speculation.
After 2008, banks were banned from speculating (ish) [1], but were allowed to do market-making. It's common for market-making desks to do speculative trades under cover of market-making activity. It's hard to conclusively prove that any given trade is speculation rather than market-making (which involves hedging), so they generally get away with it.
[1] https://en.wikipedia.org/wiki/Volcker_Rule