added embedding API.