Add pattern matching library to project deps
Update API for decoder