Wednesday, June 8, 2016

6/8

Today I got a lot done but have also started to get stuck. My initial problem this morning was that the recipes were being double counted (each recipe link would print multiple times in a row to the output .txt file). I fixed this by creating a map of my recipe names and URL's, but then I started to get weird error messages and timeouts.

The most common error I'm getting is an IOException about too many redirects from HTTPConnectionResponse. I didn't change my code too much from this morning when everything was working, so I'm pretty confused. I found this stack overflow forum about it, but I'm not sure how to use this to fix my own code, as I'm not explicitly using HTTP. I'm hoping this is more of an internet issue that will disappear tomorrow.

I've decided to cap the recipes I use at 25-30 pages of recipes per category. If I ever stop getting runtime errors, I'll go through all of them, add it to a map, and then print the map keys to a text file. This text file will be used to help build my slots and intent schema. Then, whenever the program is re-run, I simply need to re create a map from the text file. When someone passes in a recipe intent, I'll find that recipe in the map, go to the URL, and create the ingredient, step, and recipe object that are needed for my skill.

No comments:

Post a Comment