diff --git a/README.en.md b/README.en.md new file mode 100644 index 0000000000000000000000000000000000000000..4a1e2bec1288f8cbaa4cbcfcb2ded031e020d5d8 --- /dev/null +++ b/README.en.md @@ -0,0 +1,110 @@ +Based on the provided code map and my analysis, here is a comprehensive README for the Trident AI Partner project: + +# Trident AI Partner + +## Project Overview + +Trident AI Partner is a Python-based AI assistant application providing session management and session ID generation functionality. The project adopts a modular design, primarily consisting of Flask/Web application core logic and utility function modules. + +## Main Features + +### Session Management (`main.py`) +- **save_session()**: Save session data +- **get_sessions()**: Retrieve list of all sessions +- **load_session()**: Load specified session + +### Utility Functions (`utils/helpers.py`) +- **get_session_id()**: Generate unique session identifier + +## Tech Stack + +- **Backend Framework**: Flask +- **Programming Language**: Python 3.13+ +- **Static Resources**: Image resources (logo.png, favicon.ico, background image) + +## Project Structure + +``` +trident-ai-partner/ +├── main.py # Application Entry Point +├── utils/ +│ ├── __pycache__/ # Python Cache Files +│ └── helpers.py # Utility Functions +├── static/ +│ └── images/ # Static Image Resources +│ ├── favicon.ico +│ ├── logo.png +│ └── 365767238_1686812437309_830x600.png +└── README.md # Project Documentation +``` + +## Quick Start + +### Environment Requirements + +- Python 3.13+ +- Flask Framework + +### Installation Steps + +1. Clone the project: +```bash +git clone https://gitee.com/trident_python/trident-ai-partner.git +cd trident-ai-partner +``` + +2. Install dependencies: +```bash +pip install -r requirements.txt +``` + +3. Run the application: +```bash +python main.py +``` + +## Usage Instructions + +### Session Management API + +1. **Create Session** + ```python + from main import save_session + session_id = save_session(session_data) + ``` + +2. **Get All Sessions** + ```python + from main import get_sessions + sessions = get_sessions() + ``` + +3. **Load Session** + ```python + from main import load_session + session = load_session(session_id) + ``` + +### Generate Session ID +```python +from utils.helpers import get_session_id +session_id = get_session_id() +``` + +## Directory Description + +- **static/**: Stores frontend static resources (images, stylesheets, etc.) +- **utils/**: Contains utility functions and auxiliary modules required by the project + +## Contribution Guide + +Welcome to submit Issues and Pull Requests to improve this project. + +## License + +This project follows an open-source license agreement. + +## Contact Information + +- Project URL: https://gitee.com/trident_python/trident-ai-partner +- Issue Feedback: https://gitee.com/trident_python/trident-ai-partner/issues \ No newline at end of file diff --git a/README.md b/README.md new file mode 100644 index 0000000000000000000000000000000000000000..2335b5429a7b78cb70fc9ea993244081e2c77639 --- /dev/null +++ b/README.md @@ -0,0 +1,112 @@ + + +Based on the provided code map and my analysis, here is a comprehensive README for the Trident AI Partner project: + +# Trident AI Partner + +## 项目简介 + +Trident AI Partner 是一个基于 Python 的 AI 助手应用程序,提供会话管理和会话 ID 生成功能。该项目采用模块化设计,主要包含 Flask/Web 应用核心逻辑和工具函数两个部分。 + +## 主要功能 + +### 会话管理 (`main.py`) +- **save_session()**: 保存会话数据 +- **get_sessions()**: 获取所有会话列表 +- **load_session()**: 加载指定会话 + +### 工具函数 (`utils/helpers.py`) +- **get_session_id()**: 生成唯一的会话标识符 + +## 技术栈 + +- **后端框架**: Flask +- **编程语言**: Python 3.13 +- **静态资源**: 图片资源 (logo.png, favicon.ico, 背景图) + +## 项目结构 + +``` +trident-ai-partner/ +├── main.py # 应用主入口 +├── utils/ +│ ├── __pycache__/ # Python 缓存文件 +│ └── helpers.py # 工具函数 +├── static/ +│ └── images/ # 静态图片资源 +│ ├── favicon.ico +│ ├── logo.png +│ └── 365767238_1686812437309_830x600.png +└── README.md # 项目文档 +``` + +## 快速开始 + +### 环境要求 + +- Python 3.13+ +- Flask 框架 + +### 安装步骤 + +1. 克隆项目: +```bash +git clone https://gitee.com/trident_python/trident-ai-partner.git +cd trident-ai-partner +``` + +2. 安装依赖: +```bash +pip install -r requirements.txt +``` + +3. 运行应用: +```bash +python main.py +``` + +## 使用说明 + +### 会话管理 API + +1. **创建会话** + ```python + from main import save_session + session_id = save_session(session_data) + ``` + +2. **获取所有会话** + ```python + from main import get_sessions + sessions = get_sessions() + ``` + +3. **加载会话** + ```python + from main import load_session + session = load_session(session_id) + ``` + +### 生成会话 ID +```python +from utils.helpers import get_session_id +session_id = get_session_id() +``` + +## 目录说明 + +- **static/**: 存放前端静态资源(图片、样式表等) +- **utils/**: 包含项目所需的工具函数和辅助模块 + +## 贡献指南 + +欢迎提交 Issue 和 Pull Request 来改进本项目。 + +## 许可证 + +本项目遵循开源许可证协议。 + +## 联系信息 + +- 项目地址: https://gitee.com/trident_python/trident-ai-partner +- 问题反馈: https://gitee.com/trident_python/trident-ai-partner/issues \ No newline at end of file