summaryrefslogtreecommitdiffstats
path: root/config-model/src/test/cfg
diff options
context:
space:
mode:
authorJon Bratseth <bratseth@gmail.com>2022-08-23 11:12:39 +0200
committerJon Bratseth <bratseth@gmail.com>2022-08-23 11:12:39 +0200
commit207f2963125c9094d65f50f5ea41d98cf3ba8524 (patch)
tree2011e1e3cfddc4eed10411af02eb728526e12e31 /config-model/src/test/cfg
parent7e290cd7574f69071490dbfb78da9e2773a863e7 (diff)
Simplify and generalize
Let embedder rewrites simply always change <x path="y" url="z"> to <xPath>y</xPath> <xUrl>z</xUrl>, as well as translating the id attirebute to the corresponding path if on hosted. This means that the current built-in embedder accepting "vocab" and "model" is broken as these names are different from the names in the config model, but this isn't documented yet so should be okay. The effect of this is that our built-in models can be used in any embedder and config, and the embedder syntax can be used in application specific embedders.
Diffstat (limited to 'config-model/src/test/cfg')
-rw-r--r--config-model/src/test/cfg/application/embed/services.xml4
-rw-r--r--config-model/src/test/cfg/application/embed_generic/configdefinitions/sentence-embedder.def3
2 files changed, 4 insertions, 3 deletions
diff --git a/config-model/src/test/cfg/application/embed/services.xml b/config-model/src/test/cfg/application/embed/services.xml
index f319d875ed9..9a05337f954 100644
--- a/config-model/src/test/cfg/application/embed/services.xml
+++ b/config-model/src/test/cfg/application/embed/services.xml
@@ -11,8 +11,8 @@
<embedder id="transformer" class="ai.vespa.embedding.BertBaseEmbedder">
<!-- model specifics -->
- <model id="test-model-id" url="test-model-url"/>
- <vocab path="files/vocab.txt"/>
+ <transformerModel id="test-model-id" url="test-model-url"/>
+ <tokenizerVocab path="files/vocab.txt"/>
<!-- tunable parameters: number of threads etc -->
<onnxIntraOpThreads>4</onnxIntraOpThreads>
diff --git a/config-model/src/test/cfg/application/embed_generic/configdefinitions/sentence-embedder.def b/config-model/src/test/cfg/application/embed_generic/configdefinitions/sentence-embedder.def
index f62e2019189..ac5c79d2714 100644
--- a/config-model/src/test/cfg/application/embed_generic/configdefinitions/sentence-embedder.def
+++ b/config-model/src/test/cfg/application/embed_generic/configdefinitions/sentence-embedder.def
@@ -4,7 +4,8 @@ package=ai.vespa.example.paragraph
vocab path
# Transformer model settings
-model path
+modelPath path
+modelUrl string
# Max length of token sequence model can handle
transforerMaxTokens int default=128