Expand description
§Zantetsu VecDB
Canonical title matching for parsed anime names.
The current implementation supports two backends:
- A local Kitsu SQL dump (
latest.sqlorlatest.sql.gz) - A remote GraphQL endpoint compatible with the expected anime search schema
Crates:
zantetsu- unified API surfacezantetsu-core- parsing enginezantetsu-vecdb- canonical title matching
§Examples
Use a local Kitsu dump:
use zantetsu_vecdb::{MatchSource, TitleMatcher};
let matcher = TitleMatcher::new(
MatchSource::kitsu_dump("/home/user/.local/share/zantetsu/kitsu-dumps"),
)
.unwrap();
let best = matcher.match_title("Sousou no Frieren").unwrap();
assert!(best.is_some());Use a remote GraphQL endpoint:
use zantetsu_vecdb::{MatchSource, TitleMatcher};
let matcher = TitleMatcher::new(
MatchSource::remote_endpoint("https://graphql.anilist.co"),
)
.unwrap();
let best = matcher.match_title("Spy x Family").unwrap();
assert!(best.is_some());Re-exports§
pub use error::MatchResult;pub use error::MatcherError;
Modules§
Structs§
- Anime
Ids - External and internal identifiers for a matched anime.
- Anime
Title Match - The best-scoring match for a query title.
- Title
Matcher - Canonical title matcher backed by either a local Kitsu dump or a remote GraphQL endpoint.
Enums§
- Match
Provider - Which backend produced a canonical title match.
- Match
Source - Backend choice for canonical title matching.
Functions§
- default_
kitsu_ dump_ dir - Returns the default dump directory used by
kitsu-sync.