How Alipay Built an AI Travel Assistant in Two Months Using xUI, gRPC, and KMP

This article details the rapid two‑month development of Alipay’s AI Travel Assistant, covering product goals, challenges of fragmented travel services, the adoption of the xUI framework, gRPC streaming, KMP cross‑platform code, and the resulting performance and engineering benefits.

Alibaba Cloud Developer
Alibaba Cloud Developer
Alibaba Cloud Developer
How Alipay Built an AI Travel Assistant in Two Months Using xUI, gRPC, and KMP

Abstract

The article introduces Alipay’s AI Travel Assistant, describing its end‑to‑end development from product inception to full launch within two months by a four‑person client team, leveraging the Alipay terminal’s xUI framework and Kotlin Multiplatform (KMP).

Product Overview

AI Travel Assistant is an intelligent, conversation‑driven travel service that integrates bus/metro QR codes, train/flight ticket booking, bike/taxi, route planning, and travel itinerary generation, providing a complete travel experience within the Alipay app (version 10.7.30+).

Project Background

Traditional travel apps require users to switch between multiple apps, leading to inefficient, multi‑step processes that cannot meet personalized user demands. A new, vertically integrated technical foundation was needed to replace the legacy “support‑small‑treasure” (支小宝) system.

AI Dialogue Exploration

Prior AI assistants (AI Search, AQ) explored xUI‑generated cards and gRPC streaming, establishing a foundation for the AI Travel Assistant’s unified interaction model.

Technical Solution

1. xUI Framework – Provides a reusable AI interaction layer with standardized protocols for data, rendering, and control, enabling rapid feature integration and reduced maintenance.

2. Multi‑Technology Stack (KMP) – Uses native components for performance‑critical features and KMP for cross‑platform modules, balancing efficiency and development speed.

3. gRPC Streaming – Replaces mixed RPC/SYNC communication with a single bidirectional streaming channel, simplifying the communication stack and improving latency.

Reconstruction Practices

The migration kept existing card logic unchanged while adapting data structures (e.g., templateData) to the new standardized protocol. Rendering responsibilities were split into template (card creation) and display (content filling), abstracting business logic from UI rendering.

Challenges and Solutions

Standardizing fragmented card protocols and handling over 40 diverse cards.

Maintaining backward‑compatible JSAPI calls and custom parameters during migration.

Ensuring stable end‑to‑end communication across multiple services and native components.

Adapters were built to translate legacy RPC/SYNC data into the new gRPC protocol, allowing parallel development and reducing cross‑team dependencies.

Performance and Metrics

Key metrics such as first‑token latency, xUI data callback time, and rendering time were instrumented. The new stack achieved a 65% performance boost for streaming scenarios and improved reliability through unified gRPC communication.

Results

Business metrics: higher click‑through rates on travel tips and steady growth.

Engineering efficiency: reduced development cycle from months to 30 days; KMP saved one full‑time engineer.

Future Outlook

Plans include adopting advanced xUI features (TTS, ASR), expanding KMP usage, and further refining the framework for better debugging and cross‑platform stability.

Team Introduction

The team invites interested candidates to join Alipay’s core client development group, emphasizing opportunities to impact billions of users.

AIgRPCmultiplatformKMPAlipayxUITravel Assistant
Alibaba Cloud Developer
Written by

Alibaba Cloud Developer

Alibaba's official tech channel, featuring all of its technology innovations.

0 followers
Reader feedback

How this landed with the community

Sign in to like

Rate this article

Was this worth your time?

Sign in to rate
Discussion

0 Comments

Thoughtful readers leave field notes, pushback, and hard-won operational detail here.