Delete all code use for lombok
This commit is contained in:
parent
0fc2159293
commit
0dda9fc1f4
|
@ -2,13 +2,13 @@
|
|||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
|
||||
<groupId>com.ossez</groupId>
|
||||
<groupId>com.ossez.openai</groupId>
|
||||
<artifactId>openai-j-api</artifactId>
|
||||
<packaging>jar</packaging>
|
||||
|
||||
|
||||
<parent>
|
||||
<groupId>com.ossez</groupId>
|
||||
<groupId>com.ossez.openai</groupId>
|
||||
<artifactId>openai-j</artifactId>
|
||||
<version>0.0.1-SNAPSHOT</version>
|
||||
</parent>
|
||||
|
@ -52,42 +52,7 @@
|
|||
<url>http://bug.ossez.com/projects/USVisaTrack</url>
|
||||
</issueManagement>
|
||||
|
||||
<modules>
|
||||
<module>openai-j-api</module>
|
||||
<module>openai-j-client</module>
|
||||
</modules>
|
||||
|
||||
<properties>
|
||||
<!-- *.html files are in UTF-8, and *.properties are in iso-8859-1, so this configuration is actually incorrect, but this suppresses a warning
|
||||
from Maven, and as long as we don't do filtering we should be OK. -->
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
<build.type>private</build.type>
|
||||
|
||||
<!-- configuration for patch tracker plugin -->
|
||||
<project.patchManagement.system>github</project.patchManagement.system>
|
||||
<patch.request.organisation>jenkinsci</patch.request.organisation>
|
||||
<patch.request.repository>jenkins</patch.request.repository>
|
||||
<project.patchManagement.url>https://api.github.com</project.patchManagement.url>
|
||||
<patch.tracker.serverId>jenkins-jira</patch.tracker.serverId>
|
||||
|
||||
<slf4j.version>1.7.25</slf4j.version>
|
||||
<log4j.version>2.8.2</log4j.version>
|
||||
<maven-plugin.version>2.14</maven-plugin.version>
|
||||
<matrix-project.version>1.4.1</matrix-project.version>
|
||||
<sorcerer.version>0.11</sorcerer.version>
|
||||
<findbugs-maven-plugin.version>3.0.4</findbugs-maven-plugin.version>
|
||||
<findbugs.failOnError>true</findbugs.failOnError>
|
||||
<test-annotations.version>1.2</test-annotations.version>
|
||||
<access-modifier.version>1.11</access-modifier.version>
|
||||
<access-modifier-annotation.version>${access-modifier.version}
|
||||
</access-modifier-annotation.version> <!-- differing only where needed for timestamped snapshots -->
|
||||
<access-modifier-checker.version>${access-modifier.version}</access-modifier-checker.version>
|
||||
<junit-jupiter.version>5.9.0</junit-jupiter.version>
|
||||
|
||||
<java.level>11</java.level>
|
||||
|
||||
<changelog.url>https://upcex.com/changelog</changelog.url>
|
||||
</properties>
|
||||
|
||||
<!-- Note that the 'repositories' and 'pluginRepositories' blocks below are actually copy-pasted from the Jenkins org pom. This is on purpose
|
||||
to keep jenkins core buildable even if one has *not* defined the specific details in the settings.xml file. -->
|
||||
|
@ -260,7 +225,7 @@
|
|||
</dependencies>
|
||||
|
||||
<build>
|
||||
<defaultGoal>install</defaultGoal>
|
||||
<defaultGoal>package</defaultGoal>
|
||||
<resources>
|
||||
<resource>
|
||||
<directory>${basedir}/src/main/resources</directory>
|
||||
|
@ -271,228 +236,10 @@
|
|||
<filtering>true</filtering>
|
||||
</resource>
|
||||
</resources>
|
||||
<pluginManagement>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-maven-plugin</artifactId>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-deploy-plugin</artifactId>
|
||||
<version>3.0.0</version>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.sonatype.plugins</groupId>
|
||||
<artifactId>nexus-staging-maven-plugin</artifactId>
|
||||
<version>1.6.13</version>
|
||||
</plugin>
|
||||
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-dependency-plugin</artifactId>
|
||||
<version>2.8</version>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-compiler-plugin</artifactId>
|
||||
<version>3.5.1</version>
|
||||
<configuration>
|
||||
<fork>true</fork>
|
||||
<compilerReuseStrategy>alwaysNew</compilerReuseStrategy>
|
||||
<source>${java.version}</source>
|
||||
<target>${java.version}</target>
|
||||
</configuration>
|
||||
</plugin>
|
||||
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-gpg-plugin</artifactId>
|
||||
<version>1.4</version>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-install-plugin</artifactId>
|
||||
<version>2.3.1</version>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-javadoc-plugin</artifactId>
|
||||
<version>2.10.3</version>
|
||||
<configuration>
|
||||
<quiet>true</quiet>
|
||||
</configuration>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-jar-plugin</artifactId>
|
||||
<version>2.6</version>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-war-plugin</artifactId>
|
||||
<version>2.6</version>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-surefire-plugin</artifactId>
|
||||
<version>2.20</version>
|
||||
<configuration>
|
||||
<argLine>-noverify
|
||||
</argLine> <!-- some versions of JDK7/8 causes VerifyError during mock tests: http://code.google.com/p/powermock/issues/detail?id=504 -->
|
||||
<systemPropertyVariables>
|
||||
<java.io.tmpdir>${project.build.directory}</java.io.tmpdir>
|
||||
<forkedProcessTimeoutInSeconds>3600</forkedProcessTimeoutInSeconds>
|
||||
<java.awt.headless>true</java.awt.headless>
|
||||
</systemPropertyVariables>
|
||||
<trimStackTrace>false</trimStackTrace>
|
||||
<skipTests>true</skipTests>
|
||||
</configuration>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-assembly-plugin</artifactId>
|
||||
<version>2.5.5</version>
|
||||
</plugin>
|
||||
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-resources-plugin</artifactId>
|
||||
<version>2.6</version>
|
||||
</plugin>
|
||||
|
||||
<plugin>
|
||||
<groupId>org.kohsuke</groupId>
|
||||
<artifactId>access-modifier-checker</artifactId>
|
||||
<version>${access-modifier-checker.version}</version>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>com.cloudbees</groupId>
|
||||
<artifactId>maven-license-plugin</artifactId>
|
||||
<version>1.7</version>
|
||||
<executions>
|
||||
<execution>
|
||||
<goals>
|
||||
<goal>process</goal>
|
||||
</goals>
|
||||
<phase>compile</phase>
|
||||
<configuration>
|
||||
<requireCompleteLicenseInfo>true</requireCompleteLicenseInfo>
|
||||
<script>../licenseCompleter.groovy</script>
|
||||
</configuration>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.jvnet.localizer</groupId>
|
||||
<artifactId>maven-localizer-plugin</artifactId>
|
||||
<version>1.24</version>
|
||||
<configuration>
|
||||
<outputEncoding>UTF-8</outputEncoding>
|
||||
</configuration>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.jvnet.hudson.tools</groupId>
|
||||
<artifactId>maven-encoding-plugin</artifactId>
|
||||
<version>1.1</version>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>com.infradna.tool</groupId>
|
||||
<artifactId>bridge-method-injector</artifactId>
|
||||
<version>1.17</version>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.codehaus.mojo</groupId>
|
||||
<artifactId>antlr-maven-plugin</artifactId>
|
||||
<version>2.1</version>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.codehaus.mojo</groupId>
|
||||
<artifactId>cobertura-maven-plugin</artifactId>
|
||||
<version>2.5.2</version>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.codehaus.mojo</groupId>
|
||||
<artifactId>findbugs-maven-plugin</artifactId>
|
||||
<version>${findbugs-maven-plugin.version}</version>
|
||||
<configuration>
|
||||
<effort>Max</effort>
|
||||
<threshold>High</threshold>
|
||||
<!--Excludes file is located on the top level -->
|
||||
<excludeFilterFile>../src/findbugs/findbugs-excludes.xml</excludeFilterFile>
|
||||
<xmlOutput>true</xmlOutput>
|
||||
<findbugsXmlOutput>false</findbugsXmlOutput>
|
||||
</configuration>
|
||||
<executions>
|
||||
<execution>
|
||||
<id>findbugs</id>
|
||||
<goals>
|
||||
<goal>check</goal>
|
||||
</goals>
|
||||
<phase>verify</phase>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-pmd-plugin</artifactId>
|
||||
<version>3.19.0</version>
|
||||
</plugin>
|
||||
|
||||
<plugin>
|
||||
<groupId>org.jvnet.updatecenter2</groupId>
|
||||
<artifactId>maven-makepkgs-plugin</artifactId>
|
||||
<version>0.6.2</version>
|
||||
</plugin>
|
||||
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-site-plugin</artifactId>
|
||||
<version>3.3</version>
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>org.kohsuke</groupId>
|
||||
<artifactId>doxia-module-markdown</artifactId>
|
||||
<version>1.0</version>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
</plugin>
|
||||
|
||||
|
||||
</plugins>
|
||||
</pluginManagement>
|
||||
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-compiler-plugin</artifactId>
|
||||
<version>3.10.1</version>
|
||||
<configuration>
|
||||
<release>11</release>
|
||||
</configuration>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-deploy-plugin</artifactId>
|
||||
<executions>
|
||||
<execution>
|
||||
<id>default-deploy</id>
|
||||
<phase>deploy</phase>
|
||||
<goals>
|
||||
<goal>deploy</goal>
|
||||
</goals>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
</plugins>
|
||||
|
||||
<extensions>
|
||||
<extension>
|
||||
<groupId>org.kohsuke</groupId>
|
||||
<artifactId>wagon-gitsite</artifactId>
|
||||
<version>0.3.5</version>
|
||||
</extension>
|
||||
</extensions>
|
||||
</build>
|
||||
|
||||
<profiles>
|
||||
|
|
|
@ -1,13 +1,12 @@
|
|||
package com.theokanning.openai.edit;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* An edit generated by GPT-3
|
||||
*
|
||||
* https://beta.openai.com/docs/api-reference/edits/create
|
||||
*/
|
||||
@Data
|
||||
|
||||
public class EditChoice {
|
||||
|
||||
/**
|
||||
|
@ -19,4 +18,20 @@ public class EditChoice {
|
|||
* This index of this completion in the returned list.
|
||||
*/
|
||||
Integer index;
|
||||
|
||||
public String getText() {
|
||||
return text;
|
||||
}
|
||||
|
||||
public void setText(String text) {
|
||||
this.text = text;
|
||||
}
|
||||
|
||||
public Integer getIndex() {
|
||||
return index;
|
||||
}
|
||||
|
||||
public void setIndex(Integer index) {
|
||||
this.index = index;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,6 +1,8 @@
|
|||
package com.theokanning.openai.edit;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import org.checkerframework.checker.nullness.qual.NonNull;
|
||||
|
||||
/**
|
||||
* Given a prompt and an instruction, OpenAi will return an edited version of the prompt
|
||||
*
|
||||
|
|
|
@ -2,6 +2,8 @@ package com.theokanning.openai.embedding;
|
|||
|
||||
|
||||
|
||||
import org.checkerframework.checker.nullness.qual.NonNull;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
|
|
|
@ -1,13 +1,12 @@
|
|||
package com.theokanning.openai.finetune;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* An object representing an event in the lifecycle of a fine-tuning job
|
||||
*
|
||||
* https://beta.openai.com/docs/api-reference/fine-tunes
|
||||
*/
|
||||
@Data
|
||||
|
||||
public class FineTuneEvent {
|
||||
/**
|
||||
* The type of object returned, should be "fine-tune-event".
|
||||
|
@ -28,4 +27,36 @@ public class FineTuneEvent {
|
|||
* The event message.
|
||||
*/
|
||||
String message;
|
||||
|
||||
public String getObject() {
|
||||
return object;
|
||||
}
|
||||
|
||||
public void setObject(String object) {
|
||||
this.object = object;
|
||||
}
|
||||
|
||||
public Long getCreatedAt() {
|
||||
return createdAt;
|
||||
}
|
||||
|
||||
public void setCreatedAt(Long createdAt) {
|
||||
this.createdAt = createdAt;
|
||||
}
|
||||
|
||||
public String getLevel() {
|
||||
return level;
|
||||
}
|
||||
|
||||
public void setLevel(String level) {
|
||||
this.level = level;
|
||||
}
|
||||
|
||||
public String getMessage() {
|
||||
return message;
|
||||
}
|
||||
|
||||
public void setMessage(String message) {
|
||||
this.message = message;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
package com.theokanning.openai.finetune;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import org.checkerframework.checker.nullness.qual.NonNull;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
package com.theokanning.openai.image;
|
||||
|
||||
import lombok.*;
|
||||
|
||||
import org.checkerframework.checker.nullness.qual.NonNull;
|
||||
|
||||
/**
|
||||
* A request for OpenAi to edit an image based on a prompt
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
package com.theokanning.openai.image;
|
||||
|
||||
import lombok.*;
|
||||
import org.checkerframework.checker.nullness.qual.NonNull;
|
||||
|
||||
/**
|
||||
* A request for OpenAi to create an image based on a prompt
|
||||
|
@ -8,10 +8,7 @@ import lombok.*;
|
|||
*
|
||||
* https://beta.openai.com/docs/api-reference/images/create
|
||||
*/
|
||||
@Builder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@Data
|
||||
|
||||
public class CreateImageRequest {
|
||||
|
||||
/**
|
||||
|
|
|
@ -1,17 +1,12 @@
|
|||
package com.theokanning.openai.image;
|
||||
|
||||
import lombok.*;
|
||||
|
||||
/**
|
||||
* A request for OpenAi to create a variation of an image
|
||||
* All fields are optional
|
||||
*
|
||||
* https://beta.openai.com/docs/api-reference/images/create-variation
|
||||
*/
|
||||
@Builder
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@Data
|
||||
|
||||
public class CreateImageVariationRequest {
|
||||
|
||||
/**
|
||||
|
|
|
@ -1,14 +1,13 @@
|
|||
package com.theokanning.openai.image;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* An object containing either a URL or a base 64 encoded image.
|
||||
*
|
||||
* https://beta.openai.com/docs/api-reference/images
|
||||
*/
|
||||
@Data
|
||||
|
||||
public class Image {
|
||||
/**
|
||||
* The URL where the image can be accessed.
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
package com.theokanning.openai.image;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
@ -9,7 +8,7 @@ import java.util.List;
|
|||
*
|
||||
* https://beta.openai.com/docs/api-reference/images
|
||||
*/
|
||||
@Data
|
||||
|
||||
public class ImageResult {
|
||||
|
||||
/**
|
||||
|
|
|
@ -1,7 +1,5 @@
|
|||
package com.theokanning.openai.model;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
|
@ -9,7 +7,7 @@ import java.util.List;
|
|||
*
|
||||
* https://beta.openai.com/docs/api-reference/models
|
||||
*/
|
||||
@Data
|
||||
|
||||
public class Model {
|
||||
/**
|
||||
* An identifier for this model, used to specify the model when making completions, etc
|
||||
|
|
|
@ -1,7 +1,5 @@
|
|||
package com.theokanning.openai.model;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* GPT-3 model permissions
|
||||
* I couldn't find documentation for the specific permissions, and I've elected to leave them undocumented rather than
|
||||
|
@ -9,7 +7,7 @@ import lombok.Data;
|
|||
*
|
||||
* https://beta.openai.com/docs/api-reference/models
|
||||
*/
|
||||
@Data
|
||||
|
||||
public class Permission {
|
||||
/**
|
||||
* An identifier for this model permission
|
||||
|
|
|
@ -1,13 +1,11 @@
|
|||
package com.theokanning.openai.moderation;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* An object containing the moderation data for a single input string
|
||||
*
|
||||
* https://beta.openai.com/docs/api-reference/moderations/create
|
||||
*/
|
||||
@Data
|
||||
|
||||
public class Moderation {
|
||||
/**
|
||||
* Set to true if the model classifies the content as violating OpenAI's content policy, false otherwise
|
||||
|
|
|
@ -1,17 +1,13 @@
|
|||
package com.theokanning.openai.moderation;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.theokanning.openai.completion.CompletionChoice;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* An object containing the flags for each moderation category
|
||||
*
|
||||
* https://beta.openai.com/docs/api-reference/moderations/create
|
||||
*/
|
||||
@Data
|
||||
|
||||
public class ModerationCategories {
|
||||
|
||||
public boolean hate;
|
||||
|
|
|
@ -1,14 +1,13 @@
|
|||
package com.theokanning.openai.moderation;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* An object containing the scores for each moderation category
|
||||
*
|
||||
* https://beta.openai.com/docs/api-reference/moderations/create
|
||||
*/
|
||||
@Data
|
||||
|
||||
public class ModerationCategoryScores {
|
||||
|
||||
public double hate;
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
package com.theokanning.openai.moderation;
|
||||
|
||||
|
||||
import org.checkerframework.checker.nullness.qual.NonNull;
|
||||
|
||||
/**
|
||||
* A request for OpenAi to detect if text violates OpenAi's content policy.
|
||||
|
|
5
pom.xml
5
pom.xml
|
@ -2,7 +2,7 @@
|
|||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
|
||||
<groupId>com.ossez</groupId>
|
||||
<groupId>com.ossez.openai</groupId>
|
||||
<artifactId>openai-j</artifactId>
|
||||
<version>0.0.1-SNAPSHOT</version>
|
||||
<packaging>pom</packaging>
|
||||
|
@ -47,7 +47,7 @@
|
|||
|
||||
<modules>
|
||||
<module>openai-j-api</module>
|
||||
<!-- <module>openai-j-client</module>-->
|
||||
<!-- <module>openai-j-client</module>-->
|
||||
</modules>
|
||||
|
||||
<properties>
|
||||
|
@ -219,7 +219,6 @@
|
|||
<!-- /UTILITIES -->
|
||||
|
||||
|
||||
|
||||
<!-- Date and Time -->
|
||||
<dependency>
|
||||
<groupId>joda-time</groupId>
|
||||
|
|
Loading…
Reference in New Issue