Commit Graph

1453 Commits

Author SHA1 Message Date
Mark Pollack
f37999f7c3 disable pdf/epub temporarily 2023-10-06 08:02:39 +02:00
Toshiaki Maki
caa8cb2021 Add PostgresML support for EmbeddingClient
- Implement dimensions method
 - Add MetadataMode support. Defaults to EMBED
 - Drop the pgml extension between tests.
 - Disable the PostgresMlEmbeddingClientIT by default.

Resolves #33
2023-10-05 12:05:47 +02:00
Christian Tzolov
7c3c8445f0 minor javadoc 2023-10-05 11:10:21 +02:00
Mark Pollack
f6db217c65 Docs update, WIP 2023-10-04 16:37:37 -04:00
Christian Tzolov
179d1747f8 Improve parsers javadocs 2023-10-04 21:22:51 +02:00
John Blum
070c924e71 Simplify AiClient, Prompt and Message construction.
Change Generation access from AiResponse in AiCilent.generate(:String).

Include unit tests for AiClient.

Cleanup compiler warnings.
2023-10-04 15:34:24 +02:00
Michal Bernhard
e0667ddf01 Fix typo in embedding-model-dimensions.properties 2023-10-04 12:22:30 +02:00
Christian Tzolov
f4f1d6f821 Rename XXLoader to XXReader. Disable AcmeIT.acmeChain() test. 2023-10-04 11:25:01 +02:00
Christian Tzolov
3eff6a75c9 Refactoring to functional interfaces
Fixes #47

reformatting
2023-10-03 19:04:29 -04:00
Mark Pollack
46e372d95c Update README.md with new location for workshop material 2023-10-03 18:40:59 -04:00
Christian Tzolov
76e44d68e4 Improve the Document API
- Add ContentFormatter and DefaultContentFormatter that can filter the metadata
   and format the Document metadata and text according to predefined templates.
 - Add content formatter tests
 - Allow the TextSplitter to copy the document  content-formatter to the children.
    When the splitter breaks the parent Document into multiple chunks (e.g.
    into a list of children Documents) copy the source content formatter to
    the chunks by default. Use the copyContentFormatter flag to enable/disable copping.
 - Add TextSplitter IT tests
 - Add MetadataExtractors as DocumentTransformers.
 - Bump spring-ai project version to 0.7.0-SNAPSHOT
 - Configurable metadata-mode for EmbeddingClients
   - Make the metadata mode configurable for the EmbeddingClient implementations.
   - Use the EMBED mode by default.

 Resolves #44
2023-10-03 14:39:17 -04:00
Craig Walls
5c23b9d3d8 Add TextLoader implementation of Loader
- supports custom Charsets.
 - User metdata can be assigned to the generated documents.
 - Add tests.
2023-09-29 15:03:02 +02:00
Mark Pollack
c4ca58b1c4 tidy up workflow yaml 2023-09-28 09:17:04 -04:00
Christian Tzolov
65a6ffcffb Dynamic embedding dimensions resolution
Leverage #28 to allow the vector stores to resolve the embedding dimensions dynamically.
 The explicitly set dimensions (if set) precedence over other configurations.
 If the embedding dimensions are not explicitly set, the embeddingClient is used
 to determine  them dynamically. If the client fails the it falls back to 1536.
2023-09-28 08:57:20 +02:00
Christian Tzolov
cdaac4c532 Update maven-central-release.yml
Fix broken yaml
2023-09-28 06:38:51 +02:00
Christian Tzolov
12e3c7be1d Stabilize the vector store ITs
- Ensures that the vector store similarity search by threshold tests
   use dynamically computed threshold that is between the top 2 results
   from the ordered search. This ensures that the threshold value is not
   affected by changes in the embedding API results.

 - Minor code style improvments.
2023-09-28 06:25:57 +02:00
Christian Tzolov
a45e34edd7 Harden milvus IT test fixtures 2023-09-28 05:25:29 +02:00
Ueibin Kim
5ff2c3bb92 modify message type get value 2023-09-27 17:15:34 -04:00
Michael Hunger
cffa790a8b Replace spring-batch with spring-ai in GH templates 2023-09-27 17:03:44 -04:00
Michael Hunger
6554bdebda Added Record test for output parser 2023-09-27 16:40:47 -04:00
Gerrit Meier
a6fba7a3b6 GH-26 - Add support for Neo4j vector index.
This commit brings support for Neo4j graph database in general,
and uses the vector index functionality available since version 5.11.

Aligned with the existing PgVector store and its tests.

The module creates indexes, if needed, for the vector search and
the identifier of the document object.

Add neo4j to vectordb docs page

Co-authored-by: Michael Simons <michael@simons.ac>
2023-09-27 16:03:51 -04:00
Christian Tzolov
92773f17c0 Add embedding model dimensions retrieval
- Add dimension method to the EmbeddingClient interface.
   Default dimension implementation uses the embed method to produce results and counts the result dimensions.
 - Add EmbeddingUtil#dimensions utilities that look up the model dimensions from a pre-defined (static) file.
   If the requested model is unknown, fallback to the default behaviour.
 - Override the dimensions method in the OpenAiEmbeddingClient and AzureOpenAiEmbeddingClient to implement local caching.
 - Add unit and IT tests.

 Resolves #28
2023-09-27 13:06:25 -04:00
Christian Tzolov
141f503341 Integrate Milvus as a Vestor Store
Resolves #19

* Clear and stream line. Inject search distance response as metadata
* Fix similarity threshold by metric type

 - Fix the similary search with threshold for L2 and IP types.
 - Create config Builder Config (inspired by Neo4jVectorStore impelementation.
   - add database-name, metric-type, index-type and index-param configurations.

* update vector store doc and readme
2023-09-27 12:24:52 -04:00
Christian Tzolov
9beb7c6b7b PgVectorStore similarity search threshold fix
Resolves #30
2023-09-22 18:54:51 +02:00
Christian Tzolov
c0aaa63411 Inject search distance as metadata in the result. Harden the tests 2023-09-21 17:07:51 +02:00
Christian Tzolov
9474999657 Merge pull request #23 from zcarroll4/main
Switch order of literals to prevent NullPointerException
2023-09-21 11:47:44 +02:00
Christian Tzolov
c852467c9c PgVectorStore improvements and fixes
- PgVectorStore implements the SmartLifecycle to initialize & clean the DB.
 - Fix a bogus threshlold similarity search and add test for it.
 - Add an internal embeddinDistance method.
2023-09-20 17:15:48 +02:00
pixeebot[bot]
ca5624169a Switch order of literals to prevent NullPointerException (#1)
Co-authored-by: pixeebot[bot] <23113631+pixeebot@users.noreply.github.com>
2023-09-20 08:43:06 -04:00
Rob Winch
768514e768 Add asciidoctor-mathjax 2023-09-18 16:25:21 -05:00
Mark Pollack
ec601c3e6d Updates for moving acme-assist fully on Spring AI
* Add SimplePersistentVectorStore
2023-09-18 14:04:58 -04:00
pir
e1b560595f Add "embeddingModel" field external injection 2023-09-17 18:10:49 -04:00
Mark Pollack
532ae01f41 bump antora ui version 2023-09-17 18:09:06 -04:00
Mark Pollack
9b0e600285 fix typo, rerun CI 2023-09-17 17:54:31 -04:00
Mark Pollack
5208c12237 add additional env var for openai key - still needs cleanup 2023-09-17 17:52:29 -04:00
Christian Tzolov
5a63cd840c Add PGVector VectorStore implementation
* Enable PGVector indexing support
* Add same document ID vector update support
* Add documentation for VectorStores
2023-09-17 17:41:37 -04:00
Craig Walls
0218069613 Enable base URL to be configurable for OpenAI using SPRING_AI_OPENAI_BASE_URL 2023-09-08 15:35:16 -04:00
mackey0225
09816b43df Fix typo 2023-08-31 02:01:44 +09:00
Mark Pollack
1c6d239ab6 Merge pull request #1 from bbenz/main
Fix errors and omissions in docs
2023-08-29 10:14:48 -04:00
Mark Pollack
c76e4ec183 Merge pull request #3 from SimonVerhoeven/main
Update documentation, remove unused imports
2023-08-29 10:13:36 -04:00
Simon Verhoeven
6b9a1dad5c Update documentation, remove unused imports
Signed-off-by: Simon Verhoeven <verhoeven.simon@gmail.com>
2023-08-26 06:50:07 +02:00
Mark Pollack
1f087427f4 update readme 2023-08-23 12:59:17 -07:00
Mark Pollack
4978e7e94b update readme 2023-08-23 12:54:06 -07:00
Mark Pollack
bc30051548 add optional ObjectMapper to BeanObjectMapper and allow for subclassing 2023-08-23 12:47:56 -07:00
Mark Pollack
c9905fdaec add duration and boot config procoessor dep 2023-08-22 16:42:28 -07:00
Mark Pollack
635a6210eb update readme 2023-08-22 12:48:57 -07:00
Brian Benz
d62d3c43f2 Firx errors and omissions in docs 2023-08-22 12:45:30 -07:00
Mark Pollack
12b0234508 format code, remove extraneous comments 2023-08-22 07:59:30 -07:00
Mark Pollack
bf8fce995a update beanoutput parser prompt 2023-08-22 07:58:48 -07:00
Mark Pollack
99f3c1da19 add beanoutput parser 2023-08-21 18:15:37 -07:00
Mark Pollack
e3da80d86e update docs 2023-08-21 08:16:05 -07:00