|
🛰️航天仿真算法库 SpaceAST 0.0.1
|
#include <ChatSession.hpp>
类 ast::ChatSession 继承关系图:Public 成员函数 | |
| ChatSession () | |
| std::string | sendMessage (StringView message) |
| void | setSystemPrompt (StringView systemPrompt) |
| ChatMessages & | messages () |
| ChatTools & | tools () |
| OpenAI & | client () |
聊天会话
| ast::ChatSession::ChatSession | ( | ) |
构造函数
| api_key | API密钥 |
| model | 模型名称 |
| base_url | API基础URL |
| OpenAI & ast::ChatSession::client | ( | ) |
获取当前使用的AI接口
|
inline |
获取消息历史
| std::string ast::ChatSession::sendMessage | ( | StringView | message | ) |
发送消息
| message | 消息内容 |
| void ast::ChatSession::setSystemPrompt | ( | StringView | systemPrompt | ) |
设置系统提示
| systemPrompt | 系统提示 |
|
inline |
获取工具集合