Skip to content

Latest commit

 

History

History

cheshire-cat-java-client

cheshire-cat-java-client

😸 Cheshire-Cat API

  • API version: 1.6.1
    • Generator version: 7.8.0

Production ready AI assistant framework

Automatically generated by the OpenAPI Generator

Requirements

Building the API client library requires:

  1. Java 1.8+
  2. Maven (3.8.3+)/Gradle (7.2+)

Installation

To install the API client library to your local Maven repository, simply execute:

mvn clean install

To deploy it to a remote Maven repository instead, configure the settings of the repository and execute:

mvn clean deploy

Refer to the OSSRH Guide for more information.

Maven users

Add this dependency to your project's POM:

<dependency>
  <groupId>it.baccan</groupId>
  <artifactId>cheshire-cat-java-client</artifactId>
  <version>1.6.1</version>
  <scope>compile</scope>
</dependency>

Gradle users

Add this dependency to your project's build file:

  repositories {
    mavenCentral()     // Needed if the 'cheshire-cat-java-client' jar has been published to maven central.
    mavenLocal()       // Needed if the 'cheshire-cat-java-client' jar has been published to the local maven repo.
  }

  dependencies {
     implementation "it.baccan:cheshire-cat-java-client:1.6.1"
  }

Others

At first generate the JAR by executing:

mvn clean package

Then manually install the following JARs:

  • target/cheshire-cat-java-client-1.6.1.jar
  • target/lib/*.jar

Getting Started

Please follow the installation instruction and execute the following Java code:

// Import classes:
import it.baccan.cheshirecat.ApiClient;
import it.baccan.cheshirecat.ApiException;
import it.baccan.cheshirecat.Configuration;
import it.baccan.cheshirecat.models.*;
import it.baccan.cheshirecat.service.DefaultApi;

public class Example {
  public static void main(String[] args) {
    ApiClient defaultClient = Configuration.getDefaultApiClient();
    defaultClient.setBasePath("http://localhost");

    DefaultApi apiInstance = new DefaultApi(defaultClient);
    try {
      Object result = apiInstance.getInjectedAdmin();
      System.out.println(result);
    } catch (ApiException e) {
      System.err.println("Exception when calling DefaultApi#getInjectedAdmin");
      System.err.println("Status code: " + e.getCode());
      System.err.println("Reason: " + e.getResponseBody());
      System.err.println("Response headers: " + e.getResponseHeaders());
      e.printStackTrace();
    }
  }
}

Documentation for API Endpoints

All URIs are relative to http://localhost

Class Method HTTP request Description
DefaultApi getInjectedAdmin GET /admin/{page}/ Get Injected Admin
DefaultApi getInjectedAdmin_0 GET /admin/{page} Get Injected Admin
DefaultApi getInjectedAdmin_1 GET /admin/ Get Injected Admin
EmbedderApi getEmbedderSettings GET /embedder/settings/{languageEmbedderName} Get Embedder Settings
EmbedderApi getEmbeddersSettings GET /embedder/settings Get Embedders Settings
EmbedderApi upsertEmbedderSetting PUT /embedder/settings/{languageEmbedderName} Upsert Embedder Setting
LargeLanguageModelApi getLlmSettings GET /llm/settings/{languageModelName} Get Llm Settings
LargeLanguageModelApi getLlmsSettings GET /llm/settings Get Llms Settings
LargeLanguageModelApi upsertLlmSetting PUT /llm/settings/{languageModelName} Upsert Llm Setting
MemoryApi getCollections GET /memory/collections Get Collections
MemoryApi getConversationHistory GET /memory/conversation_history Get Conversation History
MemoryApi recallMemoriesFromText GET /memory/recall Recall Memories From Text
MemoryApi wipeCollections DELETE /memory/collections Wipe Collections
MemoryApi wipeConversationHistory DELETE /memory/conversation_history Wipe Conversation History
MemoryApi wipeMemoryPoint DELETE /memory/collections/{collection_id}/points/{memory_id} Wipe Memory Point
MemoryApi wipeMemoryPointsByMetadata DELETE /memory/collections/{collection_id}/points Wipe Memory Points By Metadata
MemoryApi wipeSingleCollection DELETE /memory/collections/{collection_id} Wipe Single Collection
PluginsApi deletePlugin DELETE /plugins/{plugin_id} Delete Plugin
PluginsApi getAvailablePlugins GET /plugins/ Get Available Plugins
PluginsApi getPluginDetails GET /plugins/{plugin_id} Get Plugin Details
PluginsApi getPluginSettings GET /plugins/settings/{plugin_id} Get Plugin Settings
PluginsApi getPluginsSettings GET /plugins/settings Get Plugins Settings
PluginsApi installPlugin POST /plugins/upload Install Plugin
PluginsApi installPluginFromRegistry POST /plugins/upload/registry Install Plugin From Registry
PluginsApi togglePlugin PUT /plugins/toggle/{plugin_id} Toggle Plugin
PluginsApi upsertPluginSettings PUT /plugins/settings/{plugin_id} Upsert Plugin Settings
RabbitHoleApi getAllowedMimetypes GET /rabbithole/allowed-mimetypes Get Allowed Mimetypes
RabbitHoleApi uploadFile POST /rabbithole/ Upload File
RabbitHoleApi uploadMemory POST /rabbithole/memory Upload Memory
RabbitHoleApi uploadUrl POST /rabbithole/web Upload Url
SettingsApi createSetting POST /settings/ Create Setting
SettingsApi deleteSetting DELETE /settings/{settingId} Delete Setting
SettingsApi getSetting GET /settings/{settingId} Get Setting
SettingsApi getSettings GET /settings/ Get Settings
SettingsApi updateSetting PUT /settings/{settingId} Update Setting
StatusApi home GET / Home
StatusApi messageWithCat POST /message Message With Cat

Documentation for Models

Documentation for Authorization

Endpoints do not require authorization.

Recommendation

It's recommended to create an instance of ApiClient per thread in a multithreaded environment to avoid any potential issues.

Author