Skip to content

Commit 480df64

Browse files
Add changelog file
1 parent 9b19c1c commit 480df64

File tree

2 files changed

+63
-0
lines changed

2 files changed

+63
-0
lines changed

CHANGELOG.md

Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
# Changelog
2+
3+
Notable changes to the ObjectBox Swift library.
4+
5+
For more insights into what changed in the ObjectBox C++ core, [check the ObjectBox C changelog](https://github.com/objectbox/objectbox-c/blob/main/CHANGELOG.md).
6+
7+
## 4.0.0 - 2024-07-22
8+
9+
**ObjectBox now supports [Vector Search](https://docs.objectbox.io/ann-vector-search)** to enable efficient similarity searches.
10+
11+
This is particularly useful for AI/ML/RAG applications, e.g. image, audio, or text similarity. Other use cases include semantic search or recommendation engines.
12+
13+
Create a Vector (HNSW) index for a floating point vector property. For example, a `City` with a location vector:
14+
15+
```swift
16+
// objectbox: entity
17+
class City {
18+
19+
// objectbox:hnswIndex: dimensions=2
20+
var location: [Float]?
21+
22+
}
23+
```
24+
25+
Perform a nearest neighbor search using the new `nearestNeighbors(queryVector, maxCount)` query condition and the new "find with scores" query methods (the score is the distance to the query vector). For example, find the 2 closest cities:
26+
27+
```swift
28+
let madrid = [40.416775, -3.703790]
29+
let query = try box
30+
.query { City.coordinates.nearestNeighbors(queryVector: madrid, maxCount: 2) }
31+
.build()
32+
let closest = query.findWithScores()[0].object
33+
```
34+
35+
For an introduction to Vector Search, more details and other supported languages see the [Vector Search documentation](https://docs.objectbox.io/ann-vector-search).
36+
37+
- Built with Xcode 15.0.1 and Swift 5.9.
38+
- The generator now displays an error when using an index on a property type that can not be indexed.
39+
- Update to [ObjectBox C 4.0.1](https://github.com/objectbox/objectbox-c/releases/tag/v4.0.1).
40+
41+
## 2.0.0 - 2024-05-15
42+
43+
- Built with Xcode 15.0.1 and Swift 5.9.
44+
- Support creating file-less in-memory databases, e.g. for caching and testing. To create one instead of a directory path pass `memory:` together with an identifier string when creating a `Store`:
45+
46+
```swift
47+
inMemoryStore = try Store(directoryPath: "memory:test-db");
48+
```
49+
50+
See the `Store` documentation for details.
51+
- Change `Store.closeAndDeleteAllFiles()` to support deleting an in-memory database.
52+
- Removed some deprecated APIs:
53+
- Removed `findIntegers()` for property query, replaced by `find()`.
54+
- Removed `find()` of `Box`, replaced by `all()`.
55+
- Update to [ObjectBox C 4.0.0](https://github.com/objectbox/objectbox-c/releases/tag/v4.0.0).
56+
57+
## Previous versions
58+
59+
See the [changelog in the documentation](https://swift.objectbox.io/).

README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -160,6 +160,10 @@ Here's a list of ObjectBox releases, and the Swift versions they were compiled w
160160

161161
This might be relevant, e.g. when using Carthage. For various reasons, we recommend using the latest version.
162162

163+
## Changelog
164+
165+
For notable and important changes in new releases, read the [changelog](CHANGELOG.md).
166+
163167
## Development
164168

165169
The source code for ObjectBox's Swift binding can be found [in the Source folder](Source/README.md) of this repository.

0 commit comments

Comments
 (0)