Skip to content

Commit 6cb078e

Browse files
authored
Merge branch 'main' into qa-report
2 parents 00b31a4 + ef010fd commit 6cb078e

1,416 files changed

Lines changed: 54578 additions & 40920 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.editorconfig

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
# Copyright 2026 Google LLC
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
15+
root = true
16+
17+
[*]
18+
indent_style = space
19+
indent_size = 2
20+
end_of_line = lf
21+
charset = utf-8
22+
insert_final_newline = true

.gemini/GEMINI.md

Lines changed: 51 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -6,40 +6,40 @@ This document serves as a guide for using the Gemini agent within the A2UI repos
66

77
The A2UI repository is organized into several key directories:
88

9-
- `specification/`: Contains the A2UI protocol specifications.
10-
- `v0_8/`: The stable protocol version.
11-
- `docs/`: Human-readable documentation.
12-
- `json/`: JSON schema definitions.
13-
- `eval/`: Genkit-based evaluation framework.
14-
- `v0_9/`: The draft protocol version (in development).
15-
- `docs/`: Human-readable documentation.
16-
- `json/`: JSON schema definitions.
17-
- `eval/`: Genkit-based evaluation framework.
18-
- `v0_10/`: The proposed protocol version (next version).
19-
- `docs/`: Human-readable documentation.
20-
- `json/`: JSON schema definitions.
21-
- `eval/`: Genkit-based evaluation framework.
22-
- `samples/`: Contains sample implementations.
23-
- `agent/`:
24-
- `adk/`: Python-based ADK agent samples (e.g., `contact_lookup`, `restaurant_finder`, `rizzcharts`, `orchestrator`).
25-
- `mcp/`: MCP server sample (A2UI over MCP).
26-
- `client/`: Web client implementations.
27-
- `lit/`: Clients using Lit and Vite (e.g., `contact`, `shell`).
28-
- `angular/`: Clients using Angular (e.g., `contact`, `orchestrator`).
29-
- `personalized_learning/`: Personalized learning sample implementation.
30-
- `agent_sdks/`: Contains source code for Agent integrations.
31-
- `python/`: Python implementation of the A2UI agent library.
32-
- `java/`: Java implementation of the A2UI agent library.
33-
- `renderers/`: Contains renderer libraries.
34-
- `lit/`: The shared Lit renderer library used by the Lit clients.
35-
- `angular/`: The shared Angular renderer library used by the Angular clients.
36-
- `web_core/`: The shared core library used by web renderers.
37-
- `markdown/`: Markdown rendering utilities.
38-
- `tools/`: Helper tools for development.
39-
- `editor/`: A web-based editor for generating and visualizing A2UI.
40-
- `inspector/`: A web-based inspector for A2UI responses.
41-
- `composer/`: Visual composer tool.
42-
- `build_catalog/`: Catalog building utility.
9+
- `specification/`: Contains the A2UI protocol specifications.
10+
- `v0_8/`: The stable protocol version.
11+
- `docs/`: Human-readable documentation.
12+
- `json/`: JSON schema definitions.
13+
- `eval/`: Genkit-based evaluation framework.
14+
- `v0_9/`: The draft protocol version (in development).
15+
- `docs/`: Human-readable documentation.
16+
- `json/`: JSON schema definitions.
17+
- `eval/`: Genkit-based evaluation framework.
18+
- `v0_10/`: The proposed protocol version (next version).
19+
- `docs/`: Human-readable documentation.
20+
- `json/`: JSON schema definitions.
21+
- `eval/`: Genkit-based evaluation framework.
22+
- `samples/`: Contains sample implementations.
23+
- `agent/`:
24+
- `adk/`: Python-based ADK agent samples (e.g., `contact_lookup`, `restaurant_finder`, `rizzcharts`, `orchestrator`).
25+
- `mcp/`: MCP server sample (A2UI over MCP).
26+
- `client/`: Web client implementations.
27+
- `lit/`: Clients using Lit and Vite (e.g., `contact`, `shell`).
28+
- `angular/`: Clients using Angular (e.g., `contact`, `orchestrator`).
29+
- `personalized_learning/`: Personalized learning sample implementation.
30+
- `agent_sdks/`: Contains source code for Agent integrations.
31+
- `python/`: Python implementation of the A2UI agent library.
32+
- `kotlin/`: Kotlin implementation of the A2UI agent library.
33+
- `renderers/`: Contains renderer libraries.
34+
- `lit/`: The shared Lit renderer library used by the Lit clients.
35+
- `angular/`: The shared Angular renderer library used by the Angular clients.
36+
- `web_core/`: The shared core library used by web renderers.
37+
- `markdown/`: Markdown rendering utilities.
38+
- `tools/`: Helper tools for development.
39+
- `editor/`: A web-based editor for generating and visualizing A2UI.
40+
- `inspector/`: A web-based inspector for A2UI responses.
41+
- `composer/`: Visual composer tool.
42+
- `build_catalog/`: Catalog building utility.
4343

4444
## A2UI Specification Overview
4545

@@ -49,17 +49,17 @@ The A2UI protocol is a JSONL-based, streaming UI protocol designed to be easily
4949

5050
The core concepts of the A2UI protocol are detailed in the main specification document. Refer to the authoritative source for the current version (0.9):
5151

52-
- **A2UI Protocol Specification**: `@specification/v0_9/docs/a2ui_protocol.md`
52+
- **A2UI Protocol Specification**: `@specification/v0_9/docs/a2ui_protocol.md`
5353

5454
This document covers the design philosophy, architecture, data flow, and core concepts of the protocol.
5555

5656
### Schemas
5757

5858
The formal, machine-readable definitions of the protocol are maintained as JSON schemas. For version 0.9:
5959

60-
- **Server-to-Client Schema**: `@specification/v0_9/json/server_to_client.json`
61-
- **Client-to-Server Schema**: `@specification/v0_9/json/client_to_server.json`
62-
- **Basic Catalog**: `@specification/v0_9/json/basic_catalog.json`
60+
- **Server-to-Client Schema**: `@specification/v0_9/json/server_to_client.json`
61+
- **Client-to-Server Schema**: `@specification/v0_9/json/client_to_server.json`
62+
- **Basic Catalog**: `@specification/v0_9/json/basic_catalog.json`
6363

6464
## Running the Demos
6565

@@ -82,6 +82,7 @@ The Lit clients are located in `samples/client/lit/`.
8282

8383
1. **Build the Renderer**:
8484
First, ensure the shared renderers are built:
85+
8586
```bash
8687
cd renderers/markdown/markdown-it
8788
npm install
@@ -109,6 +110,7 @@ The Lit clients are located in `samples/client/lit/`.
109110
The Angular clients are located in `samples/client/angular/`.
110111

111112
First, ensure the shared renderers are built (if not already done):
113+
112114
```bash
113115
cd renderers/markdown/markdown-it
114116
npm install
@@ -124,6 +126,7 @@ npm run build
124126
```
125127

126128
Then run the Angular client:
129+
127130
```bash
128131
cd samples/client/angular
129132
npm install
@@ -132,25 +135,25 @@ npm start -- contact # Replace 'contact' with the desired project name (e.g., r
132135

133136
### Running Tools
134137

135-
- **Editor**: Located in `tools/editor`. Run with `npm install && npm run dev`.
136-
- Requires a Gemini API key in `.env` (`GEMINI_API_KEY=<key>`).
137-
- **Inspector**: Located in `tools/inspector`. Run with `npm install && npm run dev`.
138+
- **Editor**: Located in `tools/editor`. Run with `npm install && npm run dev`.
139+
- Requires a Gemini API key in `.env` (`GEMINI_API_KEY=<key>`).
140+
- **Inspector**: Located in `tools/inspector`. Run with `npm install && npm run dev`.
138141

139142
## Renderers
140143

141144
There are three renderers available for A2UI:
142145

143-
- **Web (Lit)**: Located in `renderers/lit`, this is the primary web renderer used by the demos in `web/`.
144-
- **Angular**: Located in `renderers/angular`, this is an alternative web renderer for Angular applications.
145-
- **Flutter**: The Flutter renderer is in a separate repository: [https://github.com/flutter/genui](https://github.com/flutter/genui). There is a placeholder renderer folder with a README.md file at `renderers/flutter`.
146+
- **Web (Lit)**: Located in `renderers/lit`, this is the primary web renderer used by the demos in `web/`.
147+
- **Angular**: Located in `renderers/angular`, this is an alternative web renderer for Angular applications.
148+
- **Flutter**: The Flutter renderer is in a separate repository: [https://github.com/flutter/genui](https://github.com/flutter/genui). There is a placeholder renderer folder with a README.md file at `renderers/flutter`.
146149

147150
## Keeping This Guide Updated
148151

149152
This document is intended to be a living guide for the repository. As the repository evolves, it's important to keep this file up-to-date. When making changes to the repository, please consider the following:
150153
151-
- **New Demos or Clients**: If you add a new demo or client in `samples/`, add it to the "Running the Demos" section.
152-
- **Specification Changes**: If you make significant changes to the A2UI protocol, ensure that the "A2UI Specification Overview" section is updated.
153-
- **Repository Structure Changes**: If you change the directory structure of the repository, update the "Repository Structure" section.
154+
- **New Demos or Clients**: If you add a new demo or client in `samples/`, add it to the "Running the Demos" section.
155+
- **Specification Changes**: If you make significant changes to the A2UI protocol, ensure that the "A2UI Specification Overview" section is updated.
156+
- **Repository Structure Changes**: If you change the directory structure of the repository, update the "Repository Structure" section.
154157
155158
To get this file back in sync, you can run the following commands:
156159
@@ -160,4 +163,4 @@ To get this file back in sync, you can run the following commands:
160163
161164
## Change descriptions
162165
163-
If you (the agent) are generating a pull request summary, pull request description, or change description, avoid flowery or hyperbolic terms (e.g. "significantly improves", "greatly enhances", "is an incredible improvement"). Be factual and avoid marketing language: you're not selling the PR, you're describing it.
166+
If you (the agent) are generating a pull request summary, pull request description, or change description, avoid flowery or hyperbolic terms (e.g. "significantly improves", "greatly enhances", "is an incredible improvement"). Be factual and avoid marketing language: you're not selling the PR, you're describing it.

.github/ISSUE_TEMPLATE/sprint-task.md

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,4 @@ about: An issue to track a task used in a sprint
44
title: ''
55
labels: P2, sprint ready
66
assignees: ''
7-
87
---
9-
10-

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ _List which issues are fixed by this PR. For larger changes, raising an issue fi
1212
- [ ] I have added updates to the [CHANGELOG].
1313
- [ ] I updated/added relevant documentation.
1414
- [ ] My code changes (if any) have tests.
15+
- [ ] If my branch is on fork, I have verified that [scripts/e2e_test.sh](../scripts/e2e_test.sh) passes.
1516

1617
If you need help, consider asking for advice on the [discussion board].
1718

.github/workflows/auto-assignment.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,4 +41,4 @@ jobs:
4141
const fileUrl = pathToFileURL(filePath).href;
4242
4343
const importedModule = await import(fileUrl);
44-
await importedModule.default({ github, context });
44+
await importedModule.default({ github, context });

.github/workflows/check_license.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ jobs:
3131
- name: Set up Go
3232
uses: actions/setup-go@v6
3333
with:
34-
go-version: '1.21'
34+
go-version: "1.21"
3535

3636
- name: Install addlicense
3737
run: go install github.com/google/addlicense@latest
@@ -41,6 +41,10 @@ jobs:
4141
if ! addlicense -check \
4242
-l apache \
4343
-c "Google LLC" \
44+
-ignore "**/pnpm-lock.yaml" \
45+
-ignore "**/package-lock.json" \
46+
-ignore "**/yarn.lock" \
47+
-ignore "eval/datasets/*.yaml" \
4448
.; then
4549
echo "License check failed. To fix this, install addlicense and run it:"
4650
echo " go install github.com/google/addlicense@latest"

.github/workflows/composer_build_and_test.yml

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -17,16 +17,16 @@ name: Composer
1717
on:
1818
push:
1919
paths:
20-
- 'tools/composer/**'
21-
- 'renderers/react/**'
22-
- 'renderers/web_core/**'
23-
- '.github/workflows/composer_build_and_test.yml'
20+
- "tools/composer/**"
21+
- "renderers/react/**"
22+
- "renderers/web_core/**"
23+
- ".github/workflows/composer_build_and_test.yml"
2424
pull_request:
2525
paths:
26-
- 'tools/composer/**'
27-
- 'renderers/react/**'
28-
- 'renderers/web_core/**'
29-
- '.github/workflows/composer_build_and_test.yml'
26+
- "tools/composer/**"
27+
- "renderers/react/**"
28+
- "renderers/web_core/**"
29+
- ".github/workflows/composer_build_and_test.yml"
3030

3131
jobs:
3232
build-and-test:
@@ -43,9 +43,9 @@ jobs:
4343
- name: Set up Node.js
4444
uses: actions/setup-node@v6
4545
with:
46-
node-version: '20'
47-
cache: 'pnpm'
48-
cache-dependency-path: 'tools/composer/pnpm-lock.yaml'
46+
node-version: "22"
47+
cache: "pnpm"
48+
cache-dependency-path: "tools/composer/pnpm-lock.yaml"
4949

5050
- name: Build web_core (dependency of @a2ui/react)
5151
working-directory: ./renderers/web_core

.github/workflows/e2e_test.yaml

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
# Copyright 2025 The Flutter Authors.
2+
# Use of this source code is governed by a BSD-style license that can be
3+
# found in the LICENSE file.
4+
5+
name: E2E Tests
6+
7+
on:
8+
push:
9+
# Workflow runs on push to any branch in the repo (not forks).
10+
schedule:
11+
- cron: "0 * * * *" # hourly
12+
13+
jobs:
14+
e2e_test:
15+
# Do not run on forked branches,
16+
# because the test does not have access to secrets in forks.
17+
if: github.repository == 'google/a2ui'
18+
runs-on: ubuntu-latest
19+
steps:
20+
- name: Check that REPO_GEMINI_API_KEY is set and available
21+
env:
22+
# REPO_GEMINI_API_KEY is expected to be set in the repository secrets
23+
# See https://docs.github.com/en/actions/security-guides/encrypted-secrets
24+
GEMINI_API_KEY: ${{ secrets.REPO_GEMINI_API_KEY }}
25+
run: |
26+
if [ -z "$GEMINI_API_KEY" ]; then
27+
echo "ERROR: REPO_GEMINI_API_KEY is not set"
28+
exit 1
29+
fi
30+
echo "GEMINI_API_KEY has ${#GEMINI_API_KEY} characters"
31+
- name: Checkout code
32+
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
33+
- name: Install uv
34+
uses: astral-sh/setup-uv@v6
35+
- name: Install Flutter
36+
# Before bumping, verify the new version is on the flutter org's
37+
# enterprise actions allowlist, or CI will fail with startup_failure.
38+
uses: subosito/flutter-action@fd55f4c5af5b953cc57a2be44cb082c8f6635e8e
39+
with:
40+
channel: beta
41+
cache: false
42+
- name: Print Flutter version
43+
run: flutter --version
44+
- name: Cache pub dependencies
45+
uses: actions/cache@668228422ae6a00e4ad889ee87cd7109ec5666a7
46+
with:
47+
path: ~/.pub-cache
48+
key: ${{ runner.os }}-pub-${{ hashFiles('**/pubspec.lock') }}
49+
restore-keys: ${{ runner.os }}-pub-
50+
- name: Install dependencies
51+
run: flutter pub get
52+
- name: Run ./scripts/e2e_test.sh
53+
env:
54+
GEMINI_API_KEY: ${{ secrets.REPO_GEMINI_API_KEY }}
55+
run: ./scripts/e2e_test.sh

.github/workflows/editor_build.yml

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -17,16 +17,16 @@ name: Editor
1717
on:
1818
push:
1919
paths:
20-
- 'tools/editor/**'
21-
- 'renderers/lit/**'
22-
- 'renderers/web_core/**'
23-
- '.github/workflows/editor_build.yml'
20+
- "tools/editor/**"
21+
- "renderers/lit/**"
22+
- "renderers/web_core/**"
23+
- ".github/workflows/editor_build.yml"
2424
pull_request:
2525
paths:
26-
- 'tools/editor/**'
27-
- 'renderers/lit/**'
28-
- 'renderers/web_core/**'
29-
- '.github/workflows/editor_build.yml'
26+
- "tools/editor/**"
27+
- "renderers/lit/**"
28+
- "renderers/web_core/**"
29+
- ".github/workflows/editor_build.yml"
3030

3131
jobs:
3232
build:
@@ -38,7 +38,7 @@ jobs:
3838
- name: Set up Node.js
3939
uses: actions/setup-node@v6
4040
with:
41-
node-version: '20'
41+
node-version: "22"
4242

4343
- name: Install web_core deps
4444
working-directory: ./renderers/web_core

0 commit comments

Comments
 (0)