Skip to content

Commit

Permalink
released 0.23.0
Browse files Browse the repository at this point in the history
  • Loading branch information
deep-learning-dynamo committed Sep 29, 2023
1 parent 707edd1 commit 315eab8
Show file tree
Hide file tree
Showing 21 changed files with 53 additions and 28 deletions.
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/bug_report.md
Expand Up @@ -23,7 +23,7 @@ Please provide a relevant code snippets to reproduce this bug.
A clear and concise description of what you expected to happen.

**Please complete the following information:**
- LangChain4j version: e.g. 0.22.0
- LangChain4j version: e.g. 0.23.0
- Java version: e.g. 11
- Spring Boot version (if applicable): e.g. 2.7.14

Expand Down
37 changes: 29 additions & 8 deletions README.md
Expand Up @@ -27,6 +27,17 @@ Please see examples of how LangChain4j can be used in `langchain4j-examples` rep

## News

29 September:
- Updates to models API: return `Response<T>` instead of `T`. `Response<T>` contains token usage and finish reason.
- All model and embedding store integrations now live in their own modules
- Integration with [Vespa](https://vespa.ai/) by [@Heezer](https://github.com/Heezer)
- Integration with [Elasticsearch](https://www.elastic.co/) by [@Martin7-1](https://github.com/Martin7-1)
- Integration with [Redis](https://redis.io/) by [@Martin7-1](https://github.com/Martin7-1)
- Integration with [Milvus](https://milvus.io/) by [@IuriiKoval](https://github.com/IuriiKoval)
- Integration with [Astra DB](https://www.datastax.com/products/datastax-astra) and [Cassandra](https://cassandra.apache.org/) by [@clun](https://github.com/clun)
- Added support for overlap in document splitters
- Some bugfixes and smaller improvements

29 August:
- Offline [text classification with embeddings](https://github.com/langchain4j/langchain4j-examples/blob/main/other-examples/src/main/java/embedding/classification/EmbeddingModelTextClassifierExample.java)
- Integration with [Google Vertex AI](https://cloud.google.com/vertex-ai) by [@kuraleta](https://github.com/kuraleta)
Expand Down Expand Up @@ -197,12 +208,12 @@ See example [here](https://github.com/langchain4j/langchain4j-examples/blob/main
<dependency>
<groupId>dev.langchain4j</groupId>
<artifactId>langchain4j</artifactId>
<version>0.22.0</version>
<version>0.23.0</version>
</dependency>
```
- Gradle:
```
implementation 'dev.langchain4j:langchain4j:0.22.0'
implementation 'dev.langchain4j:langchain4j:0.23.0'
```

2. Import your OpenAI/HuggingFace API key:
Expand All @@ -217,9 +228,9 @@ See example [here](https://github.com/langchain4j/langchain4j-examples/blob/main
```java
OpenAiChatModel model = OpenAiChatModel.withApiKey(apiKey);

AiMessage answer = model.generate("Hello world!").get();
String answer = model.generate("Hello world!");

System.out.println(answer.text()); // Hello! How can I assist you today?
System.out.println(answer); // Hello! How can I assist you today?
```

## Disclaimer
Expand Down Expand Up @@ -257,21 +268,31 @@ Please note that the library is in active development and:
- Chats (sync + streaming + functions)
- Completions (sync + streaming)
- Embeddings
- Integration with [DashScope](https://dashscope.aliyun.com/) for:
- Chats (sync + streaming)
- Completions (sync + streaming)
- Embeddings
- [Chat memory](https://github.com/langchain4j/langchain4j-examples/blob/main/other-examples/src/main/java/ChatMemoryExamples.java)
- [Persistent chat memory](https://github.com/langchain4j/langchain4j-examples/blob/main/other-examples/src/main/java/ServiceWithPersistentMemoryForEachUserExample.java)
- [Chat with Documents](https://github.com/langchain4j/langchain4j-examples/blob/main/other-examples/src/main/java/ChatWithDocumentsExamples.java)
- [Integration](https://github.com/langchain4j/langchain4j-examples/blob/main/other-examples/src/main/java/embedding/store/ChromaEmbeddingStoreExample.java) with [Chroma](https://www.trychroma.com/)
- [Integration](https://github.com/langchain4j/langchain4j-examples/blob/main/other-examples/src/main/java/embedding/store/PineconeEmbeddingStoreExample.java) with [Pinecone](https://www.pinecone.io/)
- [Integration](https://github.com/langchain4j/langchain4j-examples/blob/main/other-examples/src/main/java/embedding/store/WeaviateEmbeddingStoreExample.java) with [Weaviate](https://weaviate.io/)
- Integration with [Astra DB](https://www.datastax.com/products/datastax-astra) and [Cassandra](https://cassandra.apache.org/)
- [Integration](https://github.com/langchain4j/langchain4j-examples/blob/main/chroma-example/src/main/java/ChromaEmbeddingStoreExample.java) with [Chroma](https://www.trychroma.com/)
- [Integration](https://github.com/langchain4j/langchain4j-examples/blob/main/elasticsearch-example/src/main/java/ElasticsearchEmbeddingStoreExample.java) with [Elasticsearch](https://www.elastic.co/)
- [Integration](https://github.com/langchain4j/langchain4j-examples/blob/main/milvus-example/src/main/java/MilvusEmbeddingStoreExample.java) with [Milvus](https://milvus.io/)
- [Integration](https://github.com/langchain4j/langchain4j-examples/blob/main/pinecone-example/src/main/java/PineconeEmbeddingStoreExample.java) with [Pinecone](https://www.pinecone.io/)
- [Integration](https://github.com/langchain4j/langchain4j-examples/blob/main/redis-example/src/main/java/RedisEmbeddingStoreExample.java) with [Redis](https://redis.io/)
- Integration with [Vespa](https://vespa.ai/)
- [Integration](https://github.com/langchain4j/langchain4j-examples/blob/main/weaviate-example/src/main/java/WeaviateEmbeddingStoreExample.java) with [Weaviate](https://weaviate.io/)
- [In-memory embedding store](https://github.com/langchain4j/langchain4j-examples/blob/main/other-examples/src/main/java/embedding/store/InMemoryEmbeddingStoreExample.java) (can be persisted)
- [Structured outputs](https://github.com/langchain4j/langchain4j-examples/blob/main/other-examples/src/main/java/OtherServiceExamples.java)
- [Prompt templates](https://github.com/langchain4j/langchain4j-examples/blob/main/other-examples/src/main/java/PromptTemplateExamples.java)
- [Structured prompt templates](https://github.com/langchain4j/langchain4j-examples/blob/main/other-examples/src/main/java/StructuredPromptTemplateExamples.java)
- [Streaming of LLM responses](https://github.com/langchain4j/langchain4j-examples/blob/main/other-examples/src/main/java/StreamingExamples.java)
- [Loading txt, pdf, doc, xls and ppt documents from the file system and via URL](https://github.com/langchain4j/langchain4j-examples/blob/main/other-examples/src/main/java/DocumentLoaderExamples.java)
- [Loading txt, html, pdf, doc, xls and ppt documents from the file system and via URL](https://github.com/langchain4j/langchain4j-examples/blob/main/other-examples/src/main/java/DocumentLoaderExamples.java)
- [Splitting documents into segments](https://github.com/langchain4j/langchain4j-examples/blob/main/other-examples/src/main/java/ChatWithDocumentsExamples.java):
- by paragraphs, lines, sentences, words, etc
- recursively
- with overlap
- Token count estimation (so that you can predict how much you will pay)

## Coming soon:
Expand Down
2 changes: 1 addition & 1 deletion langchain4j-azure-open-ai/pom.xml
Expand Up @@ -7,7 +7,7 @@
<parent>
<groupId>dev.langchain4j</groupId>
<artifactId>langchain4j-parent</artifactId>
<version>0.22.0</version>
<version>0.23.0</version>
<relativePath>../langchain4j-parent/pom.xml</relativePath>
</parent>

Expand Down
2 changes: 1 addition & 1 deletion langchain4j-cassandra/pom.xml
Expand Up @@ -9,7 +9,7 @@
<parent>
<groupId>dev.langchain4j</groupId>
<artifactId>langchain4j-parent</artifactId>
<version>0.22.0</version>
<version>0.23.0</version>
<relativePath>../langchain4j-parent/pom.xml</relativePath>
</parent>

Expand Down
3 changes: 2 additions & 1 deletion langchain4j-chroma/pom.xml
Expand Up @@ -3,10 +3,11 @@
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>

<parent>
<groupId>dev.langchain4j</groupId>
<artifactId>langchain4j-parent</artifactId>
<version>0.22.0</version>
<version>0.23.0</version>
<relativePath>../langchain4j-parent/pom.xml</relativePath>
</parent>

Expand Down
2 changes: 1 addition & 1 deletion langchain4j-core/pom.xml
Expand Up @@ -7,7 +7,7 @@
<parent>
<groupId>dev.langchain4j</groupId>
<artifactId>langchain4j-parent</artifactId>
<version>0.22.0</version>
<version>0.23.0</version>
<relativePath>../langchain4j-parent/pom.xml</relativePath>
</parent>

Expand Down
2 changes: 1 addition & 1 deletion langchain4j-dashscope/pom.xml
Expand Up @@ -7,7 +7,7 @@
<parent>
<groupId>dev.langchain4j</groupId>
<artifactId>langchain4j-parent</artifactId>
<version>0.22.0</version>
<version>0.23.0</version>
<relativePath>../langchain4j-parent/pom.xml</relativePath>
</parent>

Expand Down
3 changes: 2 additions & 1 deletion langchain4j-elasticsearch/pom.xml
Expand Up @@ -3,10 +3,11 @@
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>

<parent>
<groupId>dev.langchain4j</groupId>
<artifactId>langchain4j-parent</artifactId>
<version>0.22.0</version>
<version>0.23.0</version>
<relativePath>../langchain4j-parent/pom.xml</relativePath>
</parent>

Expand Down
2 changes: 1 addition & 1 deletion langchain4j-hugging-face/pom.xml
Expand Up @@ -7,7 +7,7 @@
<parent>
<groupId>dev.langchain4j</groupId>
<artifactId>langchain4j-parent</artifactId>
<version>0.22.0</version>
<version>0.23.0</version>
<relativePath>../langchain4j-parent/pom.xml</relativePath>
</parent>

Expand Down
2 changes: 1 addition & 1 deletion langchain4j-local-ai/pom.xml
Expand Up @@ -7,7 +7,7 @@
<parent>
<groupId>dev.langchain4j</groupId>
<artifactId>langchain4j-parent</artifactId>
<version>0.22.0</version>
<version>0.23.0</version>
<relativePath>../langchain4j-parent/pom.xml</relativePath>
</parent>

Expand Down
3 changes: 2 additions & 1 deletion langchain4j-milvus/pom.xml
Expand Up @@ -3,10 +3,11 @@
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>

<parent>
<groupId>dev.langchain4j</groupId>
<artifactId>langchain4j-parent</artifactId>
<version>0.22.0</version>
<version>0.23.0</version>
<relativePath>../langchain4j-parent/pom.xml</relativePath>
</parent>

Expand Down
2 changes: 1 addition & 1 deletion langchain4j-open-ai/pom.xml
Expand Up @@ -7,7 +7,7 @@
<parent>
<groupId>dev.langchain4j</groupId>
<artifactId>langchain4j-parent</artifactId>
<version>0.22.0</version>
<version>0.23.0</version>
<relativePath>../langchain4j-parent/pom.xml</relativePath>
</parent>

Expand Down
2 changes: 1 addition & 1 deletion langchain4j-parent/pom.xml
Expand Up @@ -6,7 +6,7 @@

<groupId>dev.langchain4j</groupId>
<artifactId>langchain4j-parent</artifactId>
<version>0.22.0</version>
<version>0.23.0</version>
<packaging>pom</packaging>

<name>langchain4j parent POM</name>
Expand Down
2 changes: 1 addition & 1 deletion langchain4j-pinecone/pom.xml
Expand Up @@ -7,7 +7,7 @@
<parent>
<groupId>dev.langchain4j</groupId>
<artifactId>langchain4j-parent</artifactId>
<version>0.22.0</version>
<version>0.23.0</version>
<relativePath>../langchain4j-parent/pom.xml</relativePath>
</parent>

Expand Down
3 changes: 2 additions & 1 deletion langchain4j-redis/pom.xml
Expand Up @@ -3,10 +3,11 @@
xmlns="http://maven.apache.org/POM/4.0.0"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>

<parent>
<groupId>dev.langchain4j</groupId>
<artifactId>langchain4j-parent</artifactId>
<version>0.22.0</version>
<version>0.23.0</version>
<relativePath>../langchain4j-parent/pom.xml</relativePath>
</parent>

Expand Down
2 changes: 1 addition & 1 deletion langchain4j-spring-boot-starter/pom.xml
Expand Up @@ -7,7 +7,7 @@
<parent>
<groupId>dev.langchain4j</groupId>
<artifactId>langchain4j-parent</artifactId>
<version>0.22.0</version>
<version>0.23.0</version>
<relativePath>../langchain4j-parent/pom.xml</relativePath>
</parent>

Expand Down
2 changes: 1 addition & 1 deletion langchain4j-vertex-ai/pom.xml
Expand Up @@ -7,7 +7,7 @@
<parent>
<groupId>dev.langchain4j</groupId>
<artifactId>langchain4j-parent</artifactId>
<version>0.22.0</version>
<version>0.23.0</version>
<relativePath>../langchain4j-parent/pom.xml</relativePath>
</parent>

Expand Down
2 changes: 1 addition & 1 deletion langchain4j-vespa/pom.xml
Expand Up @@ -7,7 +7,7 @@
<parent>
<groupId>dev.langchain4j</groupId>
<artifactId>langchain4j-parent</artifactId>
<version>0.22.0</version>
<version>0.23.0</version>
<relativePath>../langchain4j-parent/pom.xml</relativePath>
</parent>

Expand Down
2 changes: 1 addition & 1 deletion langchain4j-weaviate/pom.xml
Expand Up @@ -7,7 +7,7 @@
<parent>
<groupId>dev.langchain4j</groupId>
<artifactId>langchain4j-parent</artifactId>
<version>0.22.0</version>
<version>0.23.0</version>
<relativePath>../langchain4j-parent/pom.xml</relativePath>
</parent>

Expand Down
2 changes: 1 addition & 1 deletion langchain4j/pom.xml
Expand Up @@ -7,7 +7,7 @@
<parent>
<groupId>dev.langchain4j</groupId>
<artifactId>langchain4j-parent</artifactId>
<version>0.22.0</version>
<version>0.23.0</version>
<relativePath>../langchain4j-parent/pom.xml</relativePath>
</parent>

Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Expand Up @@ -6,7 +6,7 @@

<groupId>dev.langchain4j</groupId>
<artifactId>langchain4j-aggregator</artifactId>
<version>0.22.0</version>
<version>0.23.0</version>
<packaging>pom</packaging>

<modules>
Expand Down

0 comments on commit 315eab8

Please sign in to comment.