aboutsummaryrefslogtreecommitdiffstats
path: root/skate
diff options
context:
space:
mode:
Diffstat (limited to 'skate')
-rw-r--r--skate/reduce.go9
1 files changed, 5 insertions, 4 deletions
diff --git a/skate/reduce.go b/skate/reduce.go
index 255f281..823255c 100644
--- a/skate/reduce.go
+++ b/skate/reduce.go
@@ -167,9 +167,9 @@ func ZippyExactWiki(releases, wiki io.Reader, mr MatchResult, w io.Writer) error
return err
}
var bref BiblioRef
- // We use base64 w/o padding of the original PageTitle as
- // component for the id. XXX: ok for now?
- key := fmt.Sprintf("%s_%s",
+ // We use lowercase base32 w/o padding of the original
+ // PageTitle as component for the id. XXX: ok for now?
+ key := fmt.Sprintf("wikipedia_%s_%s",
strings.ToLower(b32enc.EncodeToString([]byte(wiki.PageTitle))),
target.Ident)
if seen.Contains(key) {
@@ -177,7 +177,8 @@ func ZippyExactWiki(releases, wiki io.Reader, mr MatchResult, w io.Writer) error
}
seen.Add(key)
bref.Key = key
- bref.SourceWikipediaArticle = wiki.PageTitle
+ // XXX: We currently only use "en" subset.
+ bref.SourceWikipediaArticle = fmt.Sprintf("en:%s", wiki.PageTitle)
bref.TargetReleaseIdent = target.Ident
bref.TargetWorkIdent = target.WorkID
bref.MatchProvenance = "wikipedia"