move stuff
school starts today wish me lcuk
This commit is contained in:
parent
983c108eed
commit
111e74ca6f
18 changed files with 83 additions and 53 deletions
30
pom.xml
30
pom.xml
|
@ -31,4 +31,34 @@
|
|||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
|
||||
<distributionManagement>
|
||||
<repository>
|
||||
<id>m724</id>
|
||||
<url>https://git.m724.eu/api/packages/Minecon724/maven</url>
|
||||
</repository>
|
||||
<snapshotRepository>
|
||||
<id>m724</id>
|
||||
<url>https://git.m724.eu/api/packages/Minecon724/maven</url>
|
||||
</snapshotRepository>
|
||||
</distributionManagement>
|
||||
|
||||
<build>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-release-plugin</artifactId>
|
||||
<version>3.1.1</version>
|
||||
<configuration>
|
||||
<allowTimestampedSnapshots>true</allowTimestampedSnapshots>
|
||||
</configuration>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
|
||||
<scm>
|
||||
<developerConnection>scm:git:git@git.m724.eu:Minecon724/chatapi.git</developerConnection>
|
||||
<tag>HEAD</tag>
|
||||
</scm>
|
||||
|
||||
</project>
|
|
@ -1,14 +1,14 @@
|
|||
package eu.m724;
|
||||
package eu.m724.chatapi;
|
||||
|
||||
import eu.m724.chat.Chat;
|
||||
import eu.m724.chat.ChatEvent;
|
||||
import eu.m724.chat.ChatMessage;
|
||||
import eu.m724.example.OaiSource;
|
||||
import eu.m724.source.ChatResponse;
|
||||
import eu.m724.source.ChatSource;
|
||||
import eu.m724.source.exception.HttpException;
|
||||
import eu.m724.source.option.Option;
|
||||
import eu.m724.source.option.Options;
|
||||
import eu.m724.chatapi.chat.Chat;
|
||||
import eu.m724.chatapi.chat.ChatEvent;
|
||||
import eu.m724.chatapi.chat.ChatMessage;
|
||||
import eu.m724.chatapi.example.OaiSource;
|
||||
import eu.m724.chatapi.source.ChatResponse;
|
||||
import eu.m724.chatapi.source.ChatSource;
|
||||
import eu.m724.chatapi.source.exception.HttpException;
|
||||
import eu.m724.chatapi.source.option.Option;
|
||||
import eu.m724.chatapi.source.option.Options;
|
||||
|
||||
import java.util.NoSuchElementException;
|
||||
import java.util.Scanner;
|
|
@ -1,4 +1,4 @@
|
|||
package eu.m724.chat;
|
||||
package eu.m724.chatapi.chat;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
|
@ -1,4 +1,4 @@
|
|||
package eu.m724.chat;
|
||||
package eu.m724.chatapi.chat;
|
||||
|
||||
public record ChatEvent(
|
||||
String text,
|
|
@ -1,4 +1,4 @@
|
|||
package eu.m724.chat;
|
||||
package eu.m724.chatapi.chat;
|
||||
|
||||
public record ChatMessage(boolean assistant, String text) {
|
||||
public static ChatMessage assistant(String text) {
|
|
@ -1,13 +1,13 @@
|
|||
package eu.m724.example
|
||||
package eu.m724.chatapi.example
|
||||
|
||||
import eu.m724.chat.Chat
|
||||
import eu.m724.chat.ChatEvent
|
||||
import eu.m724.chat.ChatMessage
|
||||
import eu.m724.source.ChatResponse
|
||||
import eu.m724.source.ChatSource
|
||||
import eu.m724.source.ChatSourceInfo
|
||||
import eu.m724.source.option.Options
|
||||
import eu.m724.source.option.StringOption
|
||||
import eu.m724.chatapi.chat.Chat
|
||||
import eu.m724.chatapi.chat.ChatEvent
|
||||
import eu.m724.chatapi.chat.ChatMessage
|
||||
import eu.m724.chatapi.source.ChatResponse
|
||||
import eu.m724.chatapi.source.ChatSource
|
||||
import eu.m724.chatapi.source.ChatSourceInfo
|
||||
import eu.m724.chatapi.source.option.Options
|
||||
import eu.m724.chatapi.source.option.StringOption
|
||||
|
||||
import java.util.concurrent.CompletableFuture
|
||||
import java.util.concurrent.LinkedBlockingQueue
|
|
@ -1,14 +1,14 @@
|
|||
package eu.m724.example
|
||||
package eu.m724.chatapi.example
|
||||
|
||||
import eu.m724.chat.Chat
|
||||
import eu.m724.source.ChatResponse
|
||||
import eu.m724.source.ChatSource
|
||||
import eu.m724.source.ChatSourceInfo
|
||||
import eu.m724.source.exception.HttpException
|
||||
import eu.m724.source.impl.StreamingChatResponse
|
||||
import eu.m724.source.option.DoubleOption
|
||||
import eu.m724.source.option.Options
|
||||
import eu.m724.source.option.StringOption
|
||||
import eu.m724.chatapi.chat.Chat
|
||||
import eu.m724.chatapi.source.ChatResponse
|
||||
import eu.m724.chatapi.source.ChatSource
|
||||
import eu.m724.chatapi.source.ChatSourceInfo
|
||||
import eu.m724.chatapi.source.exception.HttpException
|
||||
import eu.m724.chatapi.source.impl.StreamingChatResponse
|
||||
import eu.m724.chatapi.source.option.DoubleOption
|
||||
import eu.m724.chatapi.source.option.Options
|
||||
import eu.m724.chatapi.source.option.StringOption
|
||||
import org.json.JSONArray
|
||||
import org.json.JSONObject
|
||||
|
|
@ -1,7 +1,7 @@
|
|||
package eu.m724.source;
|
||||
package eu.m724.chatapi.source;
|
||||
|
||||
import eu.m724.chat.ChatEvent;
|
||||
import eu.m724.chat.ChatMessage;
|
||||
import eu.m724.chatapi.chat.ChatEvent;
|
||||
import eu.m724.chatapi.chat.ChatMessage;
|
||||
|
||||
import java.util.concurrent.CompletableFuture;
|
||||
import java.util.concurrent.LinkedBlockingQueue;
|
|
@ -1,7 +1,7 @@
|
|||
package eu.m724.source;
|
||||
package eu.m724.chatapi.source;
|
||||
|
||||
import eu.m724.chat.Chat;
|
||||
import eu.m724.source.option.Options;
|
||||
import eu.m724.chatapi.chat.Chat;
|
||||
import eu.m724.chatapi.source.option.Options;
|
||||
|
||||
public interface ChatSource {
|
||||
/**
|
|
@ -1,4 +1,4 @@
|
|||
package eu.m724.source;
|
||||
package eu.m724.chatapi.source;
|
||||
|
||||
public record ChatSourceInfo(String name, String author, String versionName, int version) {
|
||||
}
|
|
@ -1,4 +1,4 @@
|
|||
package eu.m724.source.exception;
|
||||
package eu.m724.chatapi.source.exception;
|
||||
|
||||
// TODO rename?
|
||||
public class HttpException extends Exception {
|
|
@ -1,8 +1,8 @@
|
|||
package eu.m724.source.impl;
|
||||
package eu.m724.chatapi.source.impl;
|
||||
|
||||
import eu.m724.chat.ChatEvent;
|
||||
import eu.m724.chat.ChatMessage;
|
||||
import eu.m724.source.ChatResponse;
|
||||
import eu.m724.chatapi.chat.ChatEvent;
|
||||
import eu.m724.chatapi.chat.ChatMessage;
|
||||
import eu.m724.chatapi.source.ChatResponse;
|
||||
|
||||
import java.util.concurrent.CompletableFuture;
|
||||
import java.util.concurrent.LinkedBlockingQueue;
|
|
@ -1,8 +1,8 @@
|
|||
package eu.m724.source.impl;
|
||||
package eu.m724.chatapi.source.impl;
|
||||
|
||||
import eu.m724.chat.ChatEvent;
|
||||
import eu.m724.chat.ChatMessage;
|
||||
import eu.m724.source.ChatResponse;
|
||||
import eu.m724.chatapi.chat.ChatEvent;
|
||||
import eu.m724.chatapi.chat.ChatMessage;
|
||||
import eu.m724.chatapi.source.ChatResponse;
|
||||
|
||||
import java.util.concurrent.CompletableFuture;
|
||||
import java.util.concurrent.LinkedBlockingQueue;
|
|
@ -1,4 +1,4 @@
|
|||
package eu.m724.source.option;
|
||||
package eu.m724.chatapi.source.option;
|
||||
|
||||
public class DoubleOption extends Option<Double> {
|
||||
private double minValue = Double.MIN_VALUE;
|
|
@ -1,4 +1,4 @@
|
|||
package eu.m724.source.option;
|
||||
package eu.m724.chatapi.source.option;
|
||||
|
||||
public class NumberOption extends Option<Integer> {
|
||||
private int minValue = Integer.MIN_VALUE;
|
|
@ -1,4 +1,4 @@
|
|||
package eu.m724.source.option;
|
||||
package eu.m724.chatapi.source.option;
|
||||
|
||||
import java.lang.reflect.ParameterizedType;
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
package eu.m724.source.option;
|
||||
package eu.m724.chatapi.source.option;
|
||||
|
||||
import java.util.*;
|
||||
import java.util.function.Function;
|
|
@ -1,4 +1,4 @@
|
|||
package eu.m724.source.option;
|
||||
package eu.m724.chatapi.source.option;
|
||||
|
||||
import java.util.regex.Pattern;
|
||||
|
Loading…
Reference in a new issue