HiveMind Memory

HiveMind Memory · GPT-Aktionen

FastGenApp Memory API

API for learning and recalling information using FastGenApp's memory service.

  • POST /learnLearn a new document

    This endpoint allows the user to input a document for the application to learn.

  • POST /enrichEnrich information about an entity

    This endpoint provides detailed information about an entity and its related entities.

Ursprüngliches API-Schema
{
  "openapi": "3.0.0",
  "info": {
    "title": "FastGenApp Memory API",
    "description": "API for learning and recalling information using FastGenApp's memory service.",
    "version": "1.0.0"
  },
  "servers": [
    {
      "url": "https://memory.fastgenapp.com"
    }
  ],
  "components": {
    "schemas": {
      "LearnRequestBody": {
        "type": "object",
        "properties": {
          "document": {
            "type": "string"
          }
        },
        "required": [
          "document"
        ]
      },
      "LearnResponse": {
        "type": "object",
        "properties": {
          "entities": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Entity"
            }
          }
        }
      },
      "Entity": {
        "type": "object",
        "properties": {
          "description": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "system_id": {
            "type": "integer",
            "format": "int64"
          }
        }
      },
      "EnrichRequestBody": {
        "type": "object",
        "properties": {
          "entity_name": {
            "type": "string"
          }
        },
        "required": [
          "entity_name"
        ]
      },
      "EnrichResponse": {
        "type": "object",
        "properties": {
          "entity": {
            "$ref": "#/components/schemas/Entity"
          },
          "related_to": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/RelatedEntity"
            }
          }
        }
      },
      "RelatedEntity": {
        "type": "object",
        "properties": {
          "child_entity": {
            "type": "integer",
            "format": "int64"
          },
          "child_entity_description": {
            "type": "string"
          },
          "child_entity_name": {
            "type": "string"
          },
          "depth": {
            "type": "integer",
            "format": "int32"
          },
          "relationship_name": {
            "type": "string"
          },
          "root_entity": {
            "type": "integer",
            "format": "int64"
          }
        }
      }
    }
  },
  "paths": {
    "/learn": {
      "post": {
        "x-openai-isConsequential": false,
        "operationId": "learnDocument",
        "summary": "Learn a new document",
        "description": "This endpoint allows the user to input a document for the application to learn.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/LearnRequestBody"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Document learned successfully.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LearnResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request. The request body is not as per the required format."
          },
          "500": {
            "description": "Internal Server Error. An error occurred in the server while processing the request."
          }
        }
      }
    },
    "/enrich": {
      "post": {
        "operationId": "enrichEntity",
        "x-openai-isConsequential": false,
        "summary": "Enrich information about an entity",
        "description": "This endpoint provides detailed information about an entity and its related entities.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/EnrichRequestBody"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successfully retrieved enriched information about the entity.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EnrichResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request. The request body is not as per the required format."
          },
          "500": {
            "description": "Internal Server Error. An error occurred in the server while processing the request."
          }
        }
      }
    }
  }
}