Coder Social home page Coder Social logo

Comments (4)

thigm85 avatar thigm85 commented on June 23, 2024 1

You need to specify id, e.g.:

batch_feed = [
    {
        "id": idx,
        "fields": sentence
    }
    for idx, sentence in enumerate(sentence_data)
]

Maybe you have duplicate id`s?

from pyvespa.

neo-anderson avatar neo-anderson commented on June 23, 2024 1

That's it! Generated ids were not unique and resulted in documents getting overwritten in the index. Thanks for the pointer.

from pyvespa.

thigm85 avatar thigm85 commented on June 23, 2024

There are likely schema issues with the documents that are failing. You can inspect the results and see the error messages, for ex.:

results = app.feed_batch()
failed_docs = [x for x in results if x.status_code != 200]
failed_docs[0].json # inspect the error message

from pyvespa.

neo-anderson avatar neo-anderson commented on June 23, 2024

I tried on a more powerful machine.

In [9]: failed_docs = [x for x in response if x.status_code != 200]
In [10]: len(failed_docs)
Out[10]: 0

No failed feed this time.
The number of documents in the data store is still 735.1k instead of 1M+.

For context,

# command used to ingest data
response = app.feed_batch(schema="coso", batch=data, batch_size=1000, total_timeout=200, asynchronous=True, connections=100)
len(data)
#1093460

I tried ingesting data into prod and see the same number of documents in the prod store as well - 735.1k.

What else can I do to check what went wrong?

from pyvespa.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.