@@ -147,6 +152,60 @@ function apiSystemEndpoints(app) {
}
}
);
app.get(
"/v1/system/export-chats",
[validApiKey],
async (request,response)=>{
/*
#swagger.tags = ['System Settings']
#swagger.description = 'Export all of the chats from the system in a known format. Output depends on the type sent. Will be send with the correct header for the output.'
#swagger.parameters['type'] = {
in: 'query',
description: "Export format jsonl, json, csv, jsonAlpaca",
required: false,
type: 'string'
}
#swagger.responses[200] = {
content: {
"application/json": {
schema: {
type: 'object',
example: [
{
"role": "user",
"content": "What is AnythinglLM?"
},
{
"role": "assistant",
"content": "AnythingLLM is a knowledge graph and vector database management system built using NodeJS express server. It provides an interface for handling all interactions, including vectorDB management and LLM (Language Model) interactions."
"description":"Export all of the chats from the system in a known format. Output depends on the type sent. Will be send with the correct header for the output.",
"parameters":[
{
"name":"Authorization",
"in":"header",
"schema":{
"type":"string"
}
},
{
"name":"type",
"in":"query",
"description":"Export format jsonl, json, csv, jsonAlpaca",
"required":false,
"schema":{
"type":"string"
}
}
],
"responses":{
"200":{
"description":"OK",
"content":{
"application/json":{
"schema":{
"type":"object",
"example":[
{
"role":"user",
"content":"What is AnythinglLM?"
},
{
"role":"assistant",
"content":"AnythingLLM is a knowledge graph and vector database management system built using NodeJS express server. It provides an interface for handling all interactions, including vectorDB management and LLM (Language Model) interactions."