Designing a one EVERYTHING search box (date+address+keywords) - search

I'm storing information about local "events". They are described by 3 things - address, date, keywords(tags). I want to have only one search box for at least address and keywords. The date might go to a separate field. I'm assuming that most people will search for events that are taking place "today" so this filter won't get that much traffic.
I need those addresses to be correct (because I'm geocoding them afterwards) so I need to validate them before submitting the form and display a list of "did you mean" if a user made a typo there. I can't do life search here. I can do a live search on keywords. Keep in mind that a user can make a typo there too and I want to catch that.
Is there a clever way to design the input's parser in this case to guess which is supposed to be address and which keywords?
OR
Is there a way to actually parse it as user is entering his query? Maybe I should show autocomplete hints for keywords, after 3 first characters are entered, and if user denies to use them then to assume that it's a part of an address he's typing.
What do You think?

Take a look at Document Cloud's Visual search
http://documentcloud.github.com/visualsearch/#demo

Related

Sending specific words to webhook

I'm trying to make an agent that can give me details about movies.
For example, the user says "Tell me about (movie-name)", which sends a post request to my API with the (movie-name) which then returns the response.
However, I don't understand how to grab the movie name from the user's speech without creating a movieName entity with a list of all the movies out there. I just want to grab the next word the user says after "tell me about" and store it as a parameter. How do I go about achieving that?
Yes, you must create a movieName entity, but you do not need to create a list of all movies. Maybe you are experienced with Alexa which requires a list of suggested values, but in api.ai you don't need to do that.
I find that api.ai is not very good at figuring out which words are part of a free-form entity like movieName, but hopefully adding enough user expressions will help it with that.
edit: the entity I was thinking of is '#sys.any' but maybe it would be better to use a list of movie names with the 'automated expansion' feature. I haven't tried that, but it sounds like the way that Alexa's custom slots work, which is actually a lot more flexible (just using the list as a guideline) then people seem to think.

How to build a facebook-like fast search by starting of words?

I have to build a search textbox in a web page similar to facebook search box. Client side there will be ajax calls. The user need to search into around 300.000 elements that have a description of a few words or an alphanumeric code. When user enters the beginning of a word, a call is made to the server which return best match based on the starting of any word or code but also suggest first the elements most recently by the user, then by the group the user belongs to and finally from the entire set. Result can be limited to 10-20 items.
How can I build a fast search by key with the value just the description of the element? We use SQL server but any other DB could be OK.
The implementation at the time was very complex to summarise here but I came across recently to UI-select that solve the front end problem nicely and it's very good component if you are using Angular
https://github.com/angular-ui/ui-select
then backend you can put whatever you have (I did with Redis)

Take data from query string and put into another form value (for both display and posting)

With that said, there is a question that seems to be asked a lot and has answers - but I'm not a programmer 'enough' to understand all the different explanations. I was hoping for something more clear and concise to my very specific example and need.
I have two forms. (I might also add this is being used on Wordpress)
One form is on the first page and will collect age, home value, and debt owed - all in drop down select fields.
The second form is on the next page and will collect other contact information and upon submit - will post all the fields to my CRM.
I have been able to successfully get the data from the first form into a query string on the page of the second form. But try as I might - I just can't figure out how to get the field data from the query string into my field forms. (Both display or pre-populated and as a value ready to be submitted once the rest of the fields are completed.)
Here is an actual query string:
http://example.com/2-form-test-2-of-2/?age=75&value=572%2C500&lien=107%2C500&sendbutton=#.UYSBEKKG2So
I simply need to get "age" - "value" and "lien" from that query string showing in the fields on the 2nd page. Simple is best - even if it's 'hack-ish' as I will most likely just include the code directly on the Wordpress page that includes this form.
One possible solution is to add a piece of javascript that gets fired on page load and:
1) disables form post button
2) populates form fields with values from URL
3) enables form post button
If these values are just suggestions for user, which he could easily change before posting — this should work.
If, on the other hand, these values are internal and unchangeable by user, you should not expose these in editable form and allow user to change those by editing URL or form posting (but including these as read-only page fragments is apparently ok).
This is place for only programmers. To become a programmer, please refer some online resources and ebooks. without knowing basic concepts, you can't understand anything.
even after understanding basics, if you have doubts, you can ask here, providing the code samples you have developed.

Look for unique ID pattern which easy indexed by search engines

Like from Microsoft - "KB2756872" or from National Vulnerability
Database - "CVE-2010-1428" or from Red Hat - "RHSA-2010:0376" or
from OIDs - "1.3.6.1.4.1.311" or from UUID/GUID
- "550e8400-e29b-41d4-a716-446655440000".
I want to put several jobs to UIDs. See next...
I develop blog software and have idea to put unique ID in body of
each post so can easily identify that copy from local storage is
correspond to remote published copy.
Also I want to post to many different blogging services so if one
is down articles will be accessible from another. So link can
dead but if I add UID - anyone can try web-search to find post on
another service!
Also this allow to gather some article spreading
statistics. Many sites just replicate content (copy-writing and
rewriting bots and people) to broke search engines. With UID I
easily can identify such sites...
So my question how is to make UIDs (in which form) so it would be
easily indexed by search engines (web, like Google/Yahoo, and
corporate, like Lucene/Solr/Sphinx/Xapian/etc).
I know about some limitation of search engine like:
only >= 3 chars for each search part
it was not indexed dust like gfh6wytrh6wu56he5gahj763
so this task s not easy...
Any advice is appreciated (books/blog articles/etc).
You could use Tag URIs, as defined by RFC 4151.
They are globally unique, and everyone who owned a domain name or an email address for at least a day can mint them.
Note that these URIs only identify, they don’t locate. So a Tag URI doesn’t say anything about where something is published.
Let’s say your site’s domain is "example.com". If you create a blog post, you could create the following Tag URI:
tag:example.com,2012-12:cute-cat
Note that the date in this URI is not a publication date! It must be a (past) date on which you owned the domain (resp. email address). If you registered your domain in 2003, you could always use Tag URIs starting with tag:example.com,2004: (not "2003", because "2003" would mean "2003-01-01", which might be a time where you didn’t own the domain yet), followed by a (unique) string under your control. However, if you like you could always use the publication date, of course. But don’t use future dates.
You can use year and number based article identifier just like CVE identifiers. Since you need revisions as well, you can append dot after the identifier to clarify the version. For example, for an AWesome Blog Service, AWBS-2012-1.0 would refer to original document, AWBS-2012-1.1 would refer to first revision etc.
However, you need to make sure that AWBSs are unique before you use them. CVEs are assigned manually from the pool. You would probably need some kind of service that assigns AWBS from pool. It could be a simple database query.

NameLookup does not pull Phone number

I have 2 fields that looks for username, the gets the email address and phone number from user's person document.
Creator_Email: #NameLookup([NoUpdate]; #UserName; "OfficePhoneNumber")
Creator_Ext: #NameLookup([NoUpdate]; #UserName; "OfficePhoneNumber")
The problem is there is one user reported that the extension did not pull out. It came out blank
I have checked on the person document and the phone number is there
the email address pull out correctly, but when I tested changing the first letter of first and last name to lower case (ie. Test.User#domain.com to test.user#domain.com), the field that pulls the email address still show up with Upper case.
I have tried to take the user.id and test it on a different PC and the problem persists.
Any idea why this happens? I know there are 2 address books set up in the company and that is not ideal but I have checked the 2 address books and make sure all the needed information are there.
The #NameLookup formula does a look up to a hidden view on the database, and sometimes you run into a situation where the index for that view isn't up-to-date. You can go to the database and press CTRL+SHIFT+F9 to rebuild all the views, or you can try to use the FORCEUPDATE flag in your formula.
I think you'll find that the #NameLookup call is finding people who have created entries for themselves in their personal address books. If those entries are incomplete, the lookups will fail to find the missing fields.
The #NameLookup will use the parameter...
Go to /File/Preferences/Location then is the current location find the Server Tab and check that you defined Domino Directory server (if empty user search on local)
Check also in the Mail tab, Recipient Name lookup that could "stop after first march" or exhaustively search ALL the names known on the client.
In #NameLookup you can also use [NoUpdate]:[Exhaustive]
be aware as mention before that view may be not up to date, that caching can occurs in the #NameLookup.
In place of this, I suggest to use:
#DbLookup("":"";YourServer:"names.nsf" ; "($VIMPeople)" ; #Name([ABBREVIATE] ;#UserName) ; "OfficePhoneNumber");

Resources