Fast Algorithms for Large-State-Space HMMs with Applications to Web Usage Analysis