'json' query does not return expected results from 'application/json'
See original GitHub issueHi 👋 I’m a bit stumped by the behaviour I’m seeing in this implementation. For some reason the term json
doesn’t return pages with API documentation in it, but application/json
does. Is it related to the tokeniser?
I’ve created a jsfiddle here with the same content and the default pipeline functions turned off: https://jsfiddle.net/f3sbrtq2/25/
Issue Analytics
- State:
- Created 5 years ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
c# - Json.NET JSONPath query not returning expected results
would work, but I obviously don't understand the syntax well enough. This returns an empty list: var test1 = json.SelectTokens("$.projects[*].
Read more >Solve common issues with JSON in SQL Server
It seems that the text returned by the FOR JSON query is escaped as plain text. This happens only if WITHOUT_ARRAY_WRAPPER is specified....
Read more >Parsing json outputs not returning expected results.
I am trying to parse JSON output and use it as a variable in a playbook. Whilst the JSON query works perfectly fine...
Read more >The JSON query results does not return the full path - Ask TOM
The JSON query results does not return the full path Hi, I'm try to evaluate the Json query. e.g I have following json...
Read more >Request and Response JSON Reference | Alexa Skills Kit
Your code must be resilient to these types of changes. For example, your code for deserializing a JSON request must not break when...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@lewisnyman Hi! Your suspicions about the tokenizer are spot on; it only splits tokens on
-
characters and whitespace by default. lunr uses full tokens to consult its inverted index - it doesn’t find all documents containingapplication/json
under the set of documents with the standalonejson
token, hence the “missing” results.Another thing I noticed about your example; you remove everything from the builder pipeline, but you leave the search pipeline alone - you might want to
this.searchPipeline.remove(lunr.stemmer)
as well.Out of curiosity, what are you trying to use lunr to accomplish? By removing all of the processing functions from the pipeline you’re removing a lot of the value of what lunr provides! Or was that just for the purposes of your example?
We’re using middleman-search which helpfully prebuilds the index but is not actively maintained manastech/middleman-search#29