Comments (4)
I got it working by wrapping only the nearest neighbour search in brackets, i.e.
response = app.query(body={
"yql": 'select * from sources * where value=100 and ([{"targetNumHits":100}]nearestNeighbor(embedding_image,embedding_text));',
"hits": 100,
"ranking.features.query(embedding_text)": [0.632, -0.987, ..., 0.534],
"ranking.profile": "embedding_similarity"
})
I'll work on a minimal notebook example and share it
from pyvespa.
Hi @TTitcombe, this should work. Do you have code and sample data so that I can try to reproduce and understand the error?
from pyvespa.
Note that you don't need [] or to quote targetHit , many examples in https://docs.vespa.ai/en/nearest-neighbor-search-guide.html
select title, artist from track where {targetHits:10}nearestNeighbor(embedding,q)
from pyvespa.
Great that you got it to work @TTitcombe.
from pyvespa.
Related Issues (20)
- pyvespa assumes vespaengine/vespa is pulled HOT 2
- Replace old logos with new in notebooks
- Async data operations does not apply retry strategy
- Improve user feedback on error from container logs
- Generate application packages from existing Vespa applications HOT 5
- Can't feed result of get operation into feed delete/update HOT 1
- Convert notebooks to use new prepend syntax
- Make docker dependency optional HOT 6
- Deploy the Vespa application with docker for bge-m3 HOT 1
- Refine retry-strategy (429-errors) for VespaSync
- Make VespaCloud (optionally) create key/cert with `vespacli` HOT 1
- Make it more obvious how to retrieve a reference to `Vespa` without redeploying HOT 1
- deploy_to_prod return value should be Vespa HOT 1
- Prod deployment strategy: Support polling for deployment status HOT 4
- Adding `clusters` to an `ApplicationPackage` makes `auth_clients` disappear from `services.to_text`
- Add support for defining `instance` in `DeploymentConfiguration` for VespaCloud
- Bump requests from 2.26.0 to 2.32.2 HOT 4
- Lock main dependencies in CI
- How does Vespa handle ColBERT type queries? HOT 1
- Expose URL in VespaDocker
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pyvespa.