- Introduced new API endpoints for generating custom content, chat titles, and prompts, enhancing the functionality of the Neo API. - Implemented handleGenerateCustom, handleGenerateTitle, and handleGeneratePrompts methods to process generation requests with appropriate validation and error handling. - Refactored the GenerateWithAI method to support different content types and system prompts, improving the flexibility of AI-generated responses. - Updated the API router to include the new generation routes, ensuring seamless integration with existing middleware.
30 lines
698 B
Go
30 lines
698 B
Go
package neo
|
|
|
|
// TestMentions contains test data for mentions
|
|
var TestMentions = []Mention{
|
|
{
|
|
ID: "assistant_1",
|
|
Name: "Alice AI",
|
|
Type: "assistant",
|
|
Avatar: "https://api.dicebear.com/7.x/avataaars/svg?seed=Alice",
|
|
},
|
|
{
|
|
ID: "assistant_2",
|
|
Name: "Bob Bot",
|
|
Type: "assistant",
|
|
Avatar: "https://api.dicebear.com/7.x/avataaars/svg?seed=Bob",
|
|
},
|
|
{
|
|
ID: "assistant_3",
|
|
Name: "Carol AI",
|
|
Type: "assistant",
|
|
Avatar: "https://api.dicebear.com/7.x/avataaars/svg?seed=Carol",
|
|
},
|
|
// ... 其他测试数据 ...
|
|
{
|
|
ID: "assistant_20",
|
|
Name: "Tara Tech",
|
|
Type: "assistant",
|
|
Avatar: "https://api.dicebear.com/7.x/avataaars/svg?seed=Tara",
|
|
},
|
|
}
|