API endpoints for language models