Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: support system prompt #13

Merged
merged 24 commits into from
Jan 14, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
7feedb2
feat: support stability.sd3 series and generate similar style images
zhu-xiaowei Jan 3, 2025
3497bb0
fix: chinese prompt for sd3, add sd3 price
zhu-xiaowei Jan 3, 2025
cbca7aa
feat: revert release template
zhu-xiaowei Jan 3, 2025
8715330
fix: model selection empty when switch region
zhu-xiaowei Jan 6, 2025
892fa61
feat: optimize DropdownComponent display mode
zhu-xiaowei Jan 7, 2025
4d63f5f
feat: add PromptListComponent
zhu-xiaowei Jan 7, 2025
971812f
feat: add draggable flatlist
zhu-xiaowei Jan 7, 2025
102f593
feat: update react-navigation to 7.x and fix the animation between sc…
zhu-xiaowei Jan 8, 2025
e9bc327
feat: support system prompt and update api
zhu-xiaowei Jan 8, 2025
a54a915
feat: update template
zhu-xiaowei Jan 8, 2025
fc5e4a5
fix: all eslint issues
zhu-xiaowei Jan 9, 2025
824f772
feat: support auto scroll when reach edge, add delete dialog
zhu-xiaowei Jan 9, 2025
893e8a2
feat: support mac UI, add quick access to settings page
zhu-xiaowei Jan 10, 2025
34727c9
feat: add drawer always permanent
zhu-xiaowei Jan 12, 2025
3d8a00c
fix: drawerStyle for mobile
zhu-xiaowei Jan 12, 2025
e8f6056
fix: prompt ScrollView can't scroll to bottom issue
zhu-xiaowei Jan 12, 2025
d33c17a
feat: add default system prompt
zhu-xiaowei Jan 12, 2025
3421248
fix: format
zhu-xiaowei Jan 12, 2025
8236802
feat: optimize mac drawer Permanent implementation and support prompt…
zhu-xiaowei Jan 13, 2025
98205e8
feat: optimize history selected status
zhu-xiaowei Jan 13, 2025
17ae549
feat: update readme
zhu-xiaowei Jan 13, 2025
7cc717f
feat: add readme doc for mac ui
zhu-xiaowei Jan 13, 2025
f7314be
feat: speedup launch speed
zhu-xiaowei Jan 14, 2025
2e0b577
feat: update mac ui screen shoot
zhu-xiaowei Jan 14, 2025
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
19 changes: 17 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,9 @@ macOS platforms.
- Tablet-optimized for iPad and Android tablets
- Fast launch and responsive performance
- Multiple AI model support and switching
- Fully Customizable System Prompt Assistant (New feature from v1.9.0 🎉)

**New Features For Amazon Nova 🎉🎉🎉**
**Supported Features For Amazon Nova**

- Stream conversations with Amazon Nova Micro, Lite and Pro
- Understand images, documents and videos with Nova Lite and Pro
Expand All @@ -43,6 +44,15 @@ macOS platforms.
<img src="assets/avif/video_summary.avif" width=24%>
</div>

**System Prompt Assistant**: Useful Preset System Prompts with Full Management Capabilities (Add/Edit/Sort/Delete)

<div style="display: flex; flex-direction: 'row'; background-color: #888888;">
<img src="assets/avif/prompt_translate.avif" width=24%>
<img src="assets/avif/prompt_code.avif" width=24%>
<img src="assets/avif/prompt_add_chef.avif" width=24%>
<img src="assets/avif/prompt_edit.avif" width=24%>
</div>

**Creative Image Suite**: Generation, Style Replication, Background Removal & Replacement

<div style="display: flex; flex-direction: 'row'; background-color: #888888;">
Expand Down Expand Up @@ -82,7 +92,7 @@ Ensure you have access to Amazon Bedrock foundation models. SwiftChat default se

- Region: `us-west-2`
- Text Model: `Amazon Nova Pro`
- Image Model: `Stable Image Core 1.0`
- Image Model: `Stable Diffusion 3.5 Large`

If you are using the image generation feature, please make sure you have enabled access to the `Amazon Nova Lite` model.
Please follow the [Amazon Bedrock User Guide](https://docs.aws.amazon.com/bedrock/latest/userguide/model-access-modify.html) to
Expand Down Expand Up @@ -168,6 +178,11 @@ We feature streamlined chat History, Settings pages, and intuitive Usage statist

![](assets/history_settings.png)

Similarly, for the Mac version, we not only support the display of history, but also added a permanent sidebar
display mode after v1.9.0.

![](assets/mac_ui.png)

### Message Handling

- [x] Text copy support:
Expand Down
20 changes: 18 additions & 2 deletions README_CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,17 @@ macOS 等多个平台。

- 与 AI 进行实时流式聊天
- 支持丰富的 Markdown 渲染:表格、代码块、LaTeX 公式等
- 可实现完全自定义的系统提示词助手
- 带进度的 AI 图像生成
- 多模态支持(相机拍照、图片选择和文档上传)
- 对话历史记录列表查看和管理
- 跨平台支持(Android、iOS、macOS)
- 针对 iPad 和 Android 平板电脑进行 UI 优化
- 快速启动和响应性能
- 支持多种 AI 模型及切换
- 支持完全自定义的系统提示词助手 (v1.9.0 的新功能 🎉)

**Amazon Nova 新功能 🎉🎉🎉**
**Amazon Nova 功能支持**

- 支持与 Amazon Nova Micro、Lite 和 Pro 进行流式对话
- 支持 Nova Lite 和 Pro 对图片、文档及视频内容的理解
Expand All @@ -40,6 +42,16 @@ macOS 等多个平台。
<img src="assets/avif/video_summary.avif" width=24%>
</div>


**系统提示词助手**: 提供实用的内置系统提示词,同时支持添加、编辑、排序和删除系统提示词来构建你自己的助手

<div style="display: flex; flex-direction: 'row'; background-color: #888888;">
<img src="assets/avif/prompt_translate.avif" width=24%>
<img src="assets/avif/prompt_code.avif" width=24%>
<img src="assets/avif/prompt_add_chef.avif" width=24%>
<img src="assets/avif/prompt_edit.avif" width=24%>
</div>

**图像创作助手**:图像生成、风格复制、背景移除与替换

<div style="display: flex; flex-direction: 'row'; background-color: #888888;">
Expand Down Expand Up @@ -75,7 +87,7 @@ macOS 等多个平台。

- 区域: `us-west-2`
- 文本模型: `Amazon Nova Pro`
- 图像模型: `Stable Image Core 1.0`
- 图像模型: `Stable Diffusion 3.5 Large`

如果您要使用图片生成功能,请确保已开启 `Amazon Nova Lite` 模型的访问权限。您可以参考 [Amazon Bedrock 用户指南](https://docs.aws.amazon.com/bedrock/latest/userguide/model-access-modify.html)
来启用您的模型。
Expand Down Expand Up @@ -154,6 +166,10 @@ macOS 等多个平台。

![](assets/history_settings_zh.png)

对于 Mac 版本,我们不仅支持历史记录的显示,还在 1.9.0 版本后添加了侧边栏固定显示模式。

![](assets/mac_ui.png)

### 消息处理

- [x] 文本复制支持:
Expand Down
Binary file added assets/avif/prompt_add_chef.avif
Binary file not shown.
Binary file added assets/avif/prompt_code.avif
Binary file not shown.
Binary file added assets/avif/prompt_edit.avif
Binary file not shown.
Binary file added assets/avif/prompt_translate.avif
Binary file not shown.
Binary file added assets/mac_ui.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions react-native/.eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,5 @@ module.exports = {
'prettier',
'@react-native',
],
ignorePatterns: ['android/**', 'ios/**'],
};
4 changes: 2 additions & 2 deletions react-native/ios/Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1306,7 +1306,7 @@ PODS:
- ReactCommon/turbomodule/bridging
- ReactCommon/turbomodule/core
- Yoga
- RNScreens (3.32.0):
- RNScreens (4.4.0):
- DoubleConversion
- glog
- hermes-engine
Expand Down Expand Up @@ -1623,7 +1623,7 @@ SPEC CHECKSUMS:
RNGestureHandler: 8dbcccada4a7e702e7dec9338c251b1cf393c960
RNReactNativeHapticFeedback: ec56a5f81c3941206fd85625fa669ffc7b4545f9
RNReanimated: f4ff116e33e0afc3d127f70efe928847c7c66355
RNScreens: 5aeecbb09aa7285379b6e9f3c8a3c859bb16401c
RNScreens: 024c5cb8569dea6667b5c73e6c119beb83f686f0
RNShare: 0fad69ae2d71de9d1f7b9a43acf876886a6cb99c
RNSVG: 7ff26379b2d1871b8571e6f9bc9630de6baf9bdf
SocketRocket: abac6f5de4d4d62d24e11868d7a2f427e0ef940d
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>SwiftChat</string>
<string></string>
<key>CFBundleExecutable</key>
<string>$(EXECUTABLE_NAME)</string>
<key>CFBundleIdentifier</key>
Expand Down
Loading
Loading