Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/bug_report.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ body:
validations:
required: true
- type: input
id: vifchat-version
id: ai-assistant-version
attributes:
label: App Version
placeholder: e.g. 1.0.0
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ jobs:
git add .
git config user.name '${{ vars.USER_NAME }}'
git config user.email '${{ vars.USER_EMAIL }}'
git commit -m 'release: VifChat v${{ env.NEW_VERSION }}'
git commit -m 'release: AI Assistant v${{ env.NEW_VERSION }}'
git push
git tag ${{ env.NEW_VERSION }}
git push origin ${{ env.NEW_VERSION }}
Expand All @@ -51,7 +51,7 @@ jobs:
- name: Create GitHub release
uses: softprops/action-gh-release@v2
with:
name: "VifChat v${{ env.NEW_VERSION }}"
name: "AI Assistant v${{ env.NEW_VERSION }}"
files: |
react-native/android/app/build/outputs/apk/release/*.apk
tag_name: "${{ env.NEW_VERSION }}"
Expand Down
12 changes: 12 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,15 @@
#
.DS_Store
.idea

# Swift Package Manager build cache
.build/
react-native/ios/LocalPackages/LiteRT-LM/.build/
assets/test_agent_imgs/

# Python
__pycache__/
*.py[cod]

# Claude Code
.claude/
36 changes: 18 additions & 18 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
# Sample Vif Chat App — A Cross-platform AI Assistant
# Sample Mobile AI Assistant — A Cross-platform AI Chat & Creation App

> 🚀 Your Personal AI Workspace — Chat, Create Apps, and More

[![GitHub Release](https://img.shields.io/github/v/release/aws-samples/sample-vif-chat-app)](https://github.com/aws-samples/sample-vif-chat-app/releases)
[![GitHub Release](https://img.shields.io/github/v/release/aws-samples/sample-mobile-ai-assistant)](https://github.com/aws-samples/sample-mobile-ai-assistant/releases)
[![License](https://img.shields.io/badge/license-MIT--0-green)](LICENSE)

[中文](/README_CN.md)

VifChat is a fast and responsive AI assistant developed with [React Native](https://reactnative.dev/) and
AI Assistant is a fast and responsive cross-platform app developed with [React Native](https://reactnative.dev/) and
powered by [Amazon Bedrock](https://aws.amazon.com/bedrock/), with compatibility extending to other model providers such
as Ollama, DeepSeek, OpenAI and OpenAI Compatible. With its minimalist design philosophy and robust privacy protection,
it delivers real-time streaming conversations, AI image generation, instant web app creation and voice conversation
Expand All @@ -20,7 +20,7 @@ capabilities across Android, iOS, and macOS platforms.
- 🚀 Upgrade to React Native 0.83 with New Architecture enabled (From v2.8.0).
- 🚀 Support create or edit instant web apps with one prompt (From v2.7.0).
- 🚀 Support Web Search for real-time information retrieval (From v2.7.0).
- 🚀 Update VifChat Server with API Gateway + Lambda deployment supporting 15-minute streaming output (From v2.7.0).
- 🚀 Update App Server with API Gateway + Lambda deployment supporting 15-minute streaming output (From v2.7.0).
- 🚀 Support Image Gallery for browsing and managing generated images (From v2.7.0).

**Create App**: Generate, Edit, Share and Preview Instant Web Apps
Expand Down Expand Up @@ -65,15 +65,15 @@ You can choose one of the following two methods for configuration
long-term API
key.

2. Copy and paste the API key to the (Amazon Bedrock -> Bedrock API Key) under VifChat Settings page.
2. Copy and paste the API key to the (Amazon Bedrock -> Bedrock API Key) under AI Assistant Settings page.

3. The App will automatically get the latest model list based on the region you currently selected. If multiple models
appear in the list, it means the configuration is successful.

</details>

<details>
<summary><b>🔧 Configure VifChat Server (Click to expand)</b></summary>
<summary><b>🔧 Configure App Server (Click to expand)</b></summary>

### Architecture

Expand All @@ -88,30 +88,30 @@ We use **API Gateway** combined with **AWS Lambda** to enable streaming response
**Deploy with one command:**

```bash
curl -fsSL https://raw.githubusercontent.com/aws-samples/sample-vif-chat-app/main/server/install.sh | bash
curl -fsSL https://raw.githubusercontent.com/aws-samples/sample-mobile-ai-assistant/main/server/install.sh | bash
```

By default this deploys to **the account of your current AWS profile**, in the region from `$AWS_REGION` or your `aws configure` default (fallback: `us-east-1`), with stack name `VifChat`. Wait about 3-4 minutes to see your **API URL**, **API Key** obtain link, and a scannable QR code for auto-configuring the app.
By default this deploys to **the account of your current AWS profile**, in the region from `$AWS_REGION` or your `aws configure` default (fallback: `us-east-1`), with stack name `AIAssistant`. Wait about 3-4 minutes to see your **API URL**, **API Key** obtain link, and a scannable QR code for auto-configuring the app.

To target a different account, region, or stack:

```bash
./install.sh --region us-west-2 --stack MyVifChat --profile myprofile
./install.sh --region us-west-2 --stack MyAIAssistant --profile myprofile
```

| Flag | Purpose | Default |
|---|---|---|
| `--region` | AWS region to deploy into | `$AWS_REGION` or `us-east-1` |
| `--stack` | CloudFormation stack name | `VifChat` |
| `--stack` | CloudFormation stack name | `AIAssistant` |
| `--profile` | AWS CLI profile to use | current default profile |

### Step 2: Open the App and setup with API URL and API Key

1. Launch the App, open the drawer menu, and tap **Settings**.
2. Under Amazon Bedrock → VifChat Server, tap the scan icon next to **API URL** to scan the QR (iOS/Android) — or paste `API URL` and `API Key` manually.
2. Under Amazon Bedrock → App Server, tap the scan icon next to **API URL** to scan the QR (iOS/Android) — or paste `API URL` and `API Key` manually.
3. Select your Region, then tap the top right ✓ to save.

Congratulations 🎉 Your VifChat App is ready to use!
Congratulations 🎉 Your AI Assistant App is ready to use!

</details>

Expand Down Expand Up @@ -173,7 +173,7 @@ Congratulations 🎉 Your VifChat App is ready to use!
- `GPT-4o`
- `GPT-4o mini`

Additionally, if you have deployed and configured the [VifChat Server](#getting-started-with-amazon-bedrock), you
Additionally, if you have deployed and configured the [App Server](#getting-started-with-amazon-bedrock), you
can enable the **Use Proxy** option to forward your requests.

</details>
Expand Down Expand Up @@ -281,7 +281,7 @@ https://github.com/user-attachments/assets/ebf21b12-9c93-4d2e-a109-1d6484019838

https://github.com/user-attachments/assets/c70fc2b4-8960-4a5e-b4f8-420fcd5eafd4

> Note: Amazon Nova Sonic currently only available with VifChat server.
> Note: Amazon Nova Sonic currently only available with App Server.

#### Other Features

Expand Down Expand Up @@ -341,7 +341,7 @@ landscape orientation.

![](assets/animations/landscape.avif)

## What Makes VifChat Really "Vif"?
## What Makes AI Assistant Really Fast?

🚀 **Fast Launch Speed**

Expand Down Expand Up @@ -403,7 +403,7 @@ npm run ios
### Build for macOS

1. Execute `npm start`.
2. Double click `ios/VifChat.xcworkspace` to open the project in your Xcode.
2. Double click `ios/AIAssistant.xcworkspace` to open the project in your Xcode.
3. Change the build destination to `My Mac (Mac Catalyst)` then click the ▶ Run button.

## API Reference
Expand All @@ -416,11 +416,11 @@ Please refer [API Reference](server/README.md)

- **Android** and **macOS**: Navigate to **Settings** Page, if there is a new version, you will find it at the bottom
of this page, then click the app version to download and install it.
- **iOS**: If a new version is released in the [Release page](https://github.com/aws-samples/sample-vif-chat-app/releases),
- **iOS**: If a new version is released in the [Release page](https://github.com/aws-samples/sample-mobile-ai-assistant/releases),
update your local code, rebuild and install your app by Xcode.

**Note**: After downloading a new version, please check
the [release notes](https://github.com/aws-samples/sample-vif-chat-app/releases) to see if an API version update is required.
the [release notes](https://github.com/aws-samples/sample-mobile-ai-assistant/releases) to see if an API version update is required.

### Upgrade API

Expand Down
36 changes: 18 additions & 18 deletions README_CN.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
# Sample Vif Chat App — 跨平台 AI 助手
# Sample Mobile AI Assistant — 跨平台 AI 对话与创作应用

> 🚀 您的个人 AI 工作空间 — 聊天、创建应用等

[![GitHub Release](https://img.shields.io/github/v/release/aws-samples/sample-vif-chat-app)](https://github.com/aws-samples/sample-vif-chat-app/releases)
[![GitHub Release](https://img.shields.io/github/v/release/aws-samples/sample-mobile-ai-assistant)](https://github.com/aws-samples/sample-mobile-ai-assistant/releases)
[![License](https://img.shields.io/badge/license-MIT--0-green)](LICENSE)

[English](/README.md)

VifChat 是一款快速响应的 AI 助手,采用 [React Native](https://reactnative.dev/)
AI Assistant 是一款快速响应的跨平台应用,采用 [React Native](https://reactnative.dev/)
开发,并依托 [Amazon Bedrock](https://aws.amazon.com/bedrock/) 提供强大支持,同时兼容 Ollama、DeepSeek、OpenAI 和 OpenAI
兼容的其他模型供应商。凭借其极简设计理念与坚实的隐私保护措施,该应用在 Android、iOS 和 macOS 平台上实现了实时流式对话、AI
图像生成、极速 Web 应用创建和语音对话功能。
Expand All @@ -19,7 +19,7 @@ VifChat 是一款快速响应的 AI 助手,采用 [React Native](https://react
- 🚀 升级至 React Native 0.83,启用 New Architecture(自 v2.8.0 起)。
- 🚀 支持一句话创建或编辑极速 Web 应用(自 v2.7.0 起)。
- 🚀 支持网络搜索,获取实时信息(自 v2.7.0 起)。
- 🚀 更新 VifChat 服务器,支持 API Gateway + Lambda 部署,最长支持 15 分钟流式输出(自 v2.7.0 起)。
- 🚀 更新 App 服务器,支持 API Gateway + Lambda 部署,最长支持 15 分钟流式输出(自 v2.7.0 起)。
- 🚀 支持图片画廊,浏览和管理生成的图片(自 v2.7.0 起)。

**创建应用**:生成、编辑、分享和预览极速 Web 应用
Expand Down Expand Up @@ -62,14 +62,14 @@ VifChat 是一款快速响应的 AI 助手,采用 [React Native](https://react

1. 点击 [Amazon Bedrock 控制台](https://console.aws.amazon.com/bedrock/home#/api-keys/long-term/create) 创建长期 API 密钥。

2. 复制并粘贴 API 密钥到 VifChat 设置页面的(Amazon Bedrock -> Bedrock API Key)中。
2. 复制并粘贴 API 密钥到 AI Assistant 设置页面的(Amazon Bedrock -> Bedrock API Key)中。

3. 应用程序将根据您当前选择的区域自动获取最新的模型列表。如果列表中出现多个模型,说明配置成功。

</details>

<details>
<summary><b>🔧 配置 VifChat 服务器(点击展开)</b></summary>
<summary><b>🔧 配置 App 服务器(点击展开)</b></summary>

### 架构

Expand All @@ -84,30 +84,30 @@ VifChat 是一款快速响应的 AI 助手,采用 [React Native](https://react
**一行命令部署:**

```bash
curl -fsSL https://raw.githubusercontent.com/aws-samples/sample-vif-chat-app/main/server/install.sh | bash
curl -fsSL https://raw.githubusercontent.com/aws-samples/sample-mobile-ai-assistant/main/server/install.sh | bash
```

默认部署到**当前 AWS profile 的账户**,region 取 `$AWS_REGION` 或 `aws configure` 的默认值(都未设置则为 `us-east-1`),堆栈名为 `VifChat`。等待约 3-4 分钟,您会看到 **API URL**、**API Key** 获取链接,以及可用手机扫描自动配置的二维码。
默认部署到**当前 AWS profile 的账户**,region 取 `$AWS_REGION` 或 `aws configure` 的默认值(都未设置则为 `us-east-1`),堆栈名为 `AIAssistant`。等待约 3-4 分钟,您会看到 **API URL**、**API Key** 获取链接,以及可用手机扫描自动配置的二维码。

需要指定其他目标时:

```bash
./install.sh --region us-west-2 --stack MyVifChat --profile myprofile
./install.sh --region us-west-2 --stack MyAIAssistant --profile myprofile
```

| 参数 | 作用 | 默认值 |
|---|---|---|
| `--region` | 部署到的 AWS region | `$AWS_REGION` 或 `us-east-1` |
| `--stack` | CloudFormation 堆栈名 | `VifChat` |
| `--stack` | CloudFormation 堆栈名 | `AIAssistant` |
| `--profile` | 使用的 AWS CLI profile | 当前默认 profile |

### 步骤 2:打开应用并使用 API URL 和 API Key 进行设置

1. 启动应用,打开抽屉菜单,点击 **设置**。
2. 在 Amazon Bedrock → VifChat Server 下,点击 **API URL** 右侧的扫码图标扫描二维码(iOS/Android),或手动粘贴 `API URL` 和 `API Key`。
2. 在 Amazon Bedrock → App Server 下,点击 **API URL** 右侧的扫码图标扫描二维码(iOS/Android),或手动粘贴 `API URL` 和 `API Key`。
3. 选择 Region,然后点击右上角 ✓ 保存。

恭喜 🎉 您的 VifChat 应用已准备就绪!
恭喜 🎉 您的 AI Assistant 应用已准备就绪!

</details>

Expand Down Expand Up @@ -168,7 +168,7 @@ curl -fsSL https://raw.githubusercontent.com/aws-samples/sample-vif-chat-app/mai
- `GPT-4o`
- `GPT-4o mini`

此外,如果您已部署并配置了 [VifChat 服务器](#amazon-bedrock-入门指南),可以启用 **Use Proxy** 选项来转发您的请求。
此外,如果您已部署并配置了 [App 服务器](#amazon-bedrock-入门指南),可以启用 **Use Proxy** 选项来转发您的请求。

</details>

Expand Down Expand Up @@ -271,7 +271,7 @@ https://github.com/user-attachments/assets/ebf21b12-9c93-4d2e-a109-1d6484019838

https://github.com/user-attachments/assets/c70fc2b4-8960-4a5e-b4f8-420fcd5eafd4

> 注意:Amazon Nova Sonic 目前仅在 VifChat 服务器中可用。
> 注意:Amazon Nova Sonic 目前仅在 App 服务器中可用。

#### 其他功能

Expand Down Expand Up @@ -329,7 +329,7 @@ https://github.com/user-attachments/assets/c70fc2b4-8960-4a5e-b4f8-420fcd5eafd4

![](assets/animations/landscape.avif)

## 什么让 VifChat 真正"Vif"
## 什么让 AI Assistant 如此快速

🚀 **快速启动速度**

Expand Down Expand Up @@ -389,7 +389,7 @@ npm run ios
### 构建 macOS

1. 执行 `npm start`。
2. 双击 `ios/VifChat.xcworkspace` 在 Xcode 中打开项目。
2. 双击 `ios/AIAssistant.xcworkspace` 在 Xcode 中打开项目。
3. 将构建目标更改为 `My Mac (Mac Catalyst)` 然后点击 ▶ 运行按钮。

## API 参考
Expand All @@ -401,10 +401,10 @@ npm run ios
### 升级应用

- **Android** 和 **macOS**:导航到 **设置** 页面,如果有新版本,您将在此页面底部找到它,然后点击应用版本下载并安装。
- **iOS**:如果在 [发布页面](https://github.com/aws-samples/sample-vif-chat-app/releases) 发布了新版本,请更新您的本地代码,通过
- **iOS**:如果在 [发布页面](https://github.com/aws-samples/sample-mobile-ai-assistant/releases) 发布了新版本,请更新您的本地代码,通过
Xcode 重新构建并安装您的应用。

**注意**:下载新版本后,请查看 [发布说明](https://github.com/aws-samples/sample-vif-chat-app/releases) 确认是否需要 API 版本更新。
**注意**:下载新版本后,请查看 [发布说明](https://github.com/aws-samples/sample-mobile-ai-assistant/releases) 确认是否需要 API 版本更新。

### 升级 API

Expand Down
2 changes: 1 addition & 1 deletion react-native/README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# VifChat React Native
# AI Assistant React Native

## Tech Stack

Expand Down
2 changes: 1 addition & 1 deletion react-native/android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ android {
variant.outputs.each { output ->
def outputFile = output.outputFile
if (outputFile != null && outputFile.name.endsWith('.apk')) {
def fileName = "VifChat.apk"
def fileName = "AIAssistant.apk"
output.outputFileName = fileName
}
}
Expand Down
2 changes: 1 addition & 1 deletion react-native/android/app/src/main/res/values/strings.xml
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
<resources>
<string name="app_name">VifChat</string>
<string name="app_name">AI Assistant</string>
</resources>
2 changes: 1 addition & 1 deletion react-native/ios/Podfile
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ prepare_react_native_project!

# Pin the generated workspace name (the .xcodeproj is still SwiftChat, so without
# this `pod install` would regenerate a SwiftChat.xcworkspace).
workspace 'VifChat'
workspace 'AIAssistant'

linkage = ENV['USE_FRAMEWORKS']
if linkage != nil
Expand Down
2 changes: 1 addition & 1 deletion react-native/ios/SwiftChat/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<key>CFBundleDevelopmentRegion</key>
<string>en</string>
<key>CFBundleDisplayName</key>
<string>VifChat</string>
<string>AI Assistant</string>
<key>CFBundleExecutable</key>
<string>$(EXECUTABLE_NAME)</string>
<key>CFBundleIdentifier</key>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ struct SwiftChatLiveActivity: Widget {
Image(systemName: "checkmark.circle.fill")
.foregroundColor(.green)
.font(.title2)
Text("VifChat · All Completed")
Text("AI Assistant · All Completed")
.font(.headline)
.foregroundColor(.green)
} else {
Expand Down Expand Up @@ -58,7 +58,7 @@ struct SwiftChatLiveActivity: Widget {
Image(systemName: "checkmark.circle.fill")
.font(.system(size: 20))
.foregroundColor(.green)
Text("VifChat · All Completed")
Text("AI Assistant · All Completed")
.font(.system(size: 15, weight: .semibold))
.foregroundColor(.green)
}
Expand Down
6 changes: 3 additions & 3 deletions react-native/package.json
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
{
"name": "vif-chat",
"description": "Sample Bedrock Cross-platform App - VifChat",
"name": "ai-assistant",
"description": "Sample Bedrock Cross-platform App - AI Assistant",
"version": "2.9.0",
"private": true,
"scripts": {
"android": "react-native run-android",
"ios": "react-native run-ios",
"build:ios": "cd ios && xcodebuild -workspace VifChat.xcworkspace -scheme SwiftChat -sdk iphonesimulator -configuration Release -destination generic/platform=iOS CODE_SIGN_IDENTITY=\"\" CODE_SIGNING_REQUIRED=NO CODE_SIGNING_ALLOWED=NO clean archive | xcpretty",
"build:ios": "cd ios && xcodebuild -workspace AIAssistant.xcworkspace -scheme SwiftChat -sdk iphonesimulator -configuration Release -destination generic/platform=iOS CODE_SIGN_IDENTITY=\"\" CODE_SIGNING_REQUIRED=NO CODE_SIGNING_ALLOWED=NO clean archive | xcpretty",
"format": "npx prettier --check '*.{js,ts}'",
"lint": "npx eslint .",
"start": "react-native start",
Expand Down
8 changes: 4 additions & 4 deletions react-native/release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,9 @@ sed -i "s/MARKETING_VERSION = ${regex};/MARKETING_VERSION = ${version};/g" ios/S
sed -i "s/CURRENT_PROJECT_VERSION = ${version_code_regex};/CURRENT_PROJECT_VERSION = ${version_code};/g" ios/SwiftChat.xcodeproj/project.pbxproj

# modify README download link
sed -i "s/download\/${regex}\/VifChat.apk/download\/${version}\/VifChat.apk/g" ../README.md
sed -i "s/download\/${regex}\/VifChat.dmg/download\/${version}\/VifChat.dmg/g" ../README.md
sed -i "s/download\/${regex}\/VifChat.apk/download\/${version}\/VifChat.apk/g" ../README_CN.md
sed -i "s/download\/${regex}\/VifChat.dmg/download\/${version}\/VifChat.dmg/g" ../README_CN.md
sed -i "s/download\/${regex}\/AIAssistant.apk/download\/${version}\/AIAssistant.apk/g" ../README.md
sed -i "s/download\/${regex}\/AIAssistant.dmg/download\/${version}\/AIAssistant.dmg/g" ../README.md
sed -i "s/download\/${regex}\/AIAssistant.apk/download\/${version}\/AIAssistant.apk/g" ../README_CN.md
sed -i "s/download\/${regex}\/AIAssistant.dmg/download\/${version}\/AIAssistant.dmg/g" ../README_CN.md


2 changes: 1 addition & 1 deletion react-native/src/api/ChatProviderRouter.ts
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ export const invokeChatProvider = async (
}
if (bedrockConfigMode !== 'bedrock' && !isConfigured()) {
callback(
'Please configure your VifChat Server API URL and API Key',
'Please configure your App Server API URL and API Key',
true,
false
);
Expand Down
Loading
Loading