Add long-term-memory module: file, vector and summary memory on one Spring AI agent. AutoMemoryTools and AutoMemoryToolsAdvisor, fact extraction with a privacy gate into PostgreSQL and pgvector, VectorStoreChatMemoryAdvisor, a versioned summary, updating, forgetting, isolation, expiry, recall with all-MiniLM-L6-v2 and token cost. Scripted ChatModel; no provider or local LLM called. Spring Boot 4.2.0, Spring AI 2.1.0, Java 25.
Co-Authored-By: Claude Sonnet 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_017ic4b4RzcCS5JCAgcxLz7T
This commit is contained in:
@@ -0,0 +1,47 @@
|
||||
# 30 facts, 20 questions, all-MiniLM-L6-v2 on pgvector
|
||||
|
||||
question fact needed rank score
|
||||
Which city should the flight start from? home-city 2 0.332
|
||||
What food should I order for the flight? diet 1 0.361
|
||||
Where do I like to sit on the plane? seat 1 0.462
|
||||
Which carrier should you book? airline 2 0.323
|
||||
What kind of room should you reserve? hotel 1 0.511
|
||||
Who approves my leave? manager 2 0.201
|
||||
Can you schedule a call at 9 in the morning? meeting-hours 1 0.475
|
||||
How do I take my coffee? coffee 1 0.523
|
||||
Is my travel document still valid next year? passport-expiry 1 0.408
|
||||
Can I travel to America? visa 1 0.269
|
||||
How much can I spend on this trip to Delhi? budget 1 0.533
|
||||
Which IDE do I use? editor 1 0.269
|
||||
What do I store our data in? database 3 0.165
|
||||
When do we ship to production? release-day 1 0.519
|
||||
How should you contact me about changes? notification 1 0.266
|
||||
Do I need a taxi to the airport? cab 1 0.500
|
||||
What is my loyalty programme? frequent-flyer 2 0.280
|
||||
How do I get to work? commute 1 0.319
|
||||
Can you book a Sunday workshop for me? weekend 1 0.456
|
||||
Who pays for the tickets? payment 1 0.440
|
||||
|
||||
topK 1: the needed fact is returned for 15 of 20 questions
|
||||
topK 3: the needed fact is returned for 20 of 20 questions
|
||||
topK 5: the needed fact is returned for 20 of 20 questions
|
||||
topK 10: the needed fact is returned for 20 of 20 questions
|
||||
|
||||
questions no stored fact answers: score of the best match
|
||||
0.087 What is my shoe size? -> passport expiry: passport expires in March 2028
|
||||
0.128 What is the capital of France? -> seat: aisle seat near the front
|
||||
0.272 Which cricket team do I support? -> home city: Mumbai
|
||||
0.329 Write a haiku about rivers. -> language: writes in Marathi and English
|
||||
0.207 What is 17 times 23? -> weekend: does not work on Sundays
|
||||
|
||||
threshold needed fact survives (any rank) unanswerable questions returning something
|
||||
0.10 20 of 20 4 of 5
|
||||
0.20 19 of 20 3 of 5
|
||||
0.30 14 of 20 1 of 5
|
||||
0.40 10 of 20 0 of 5
|
||||
0.50 4 of 20 0 of 5
|
||||
|
||||
a forget request used as a search query: "Forget what I told you about food."
|
||||
0.450 diet: vegetarian
|
||||
0.242 coffee: black coffee without sugar
|
||||
0.111 database: project database is PostgreSQL
|
||||
Reference in New Issue
Block a user