0

Filtering item.description

Hello, I am trying to create a super feed based on a bunch of other feeds. I am filtering on item description but am unsure as to what comprises an item description. So far my keyword searching is not returning the results that I would like to see. Thanks

by
6 Replies
  • Hello,

    here is the sticky of the forum: Before posting a question, please include a link to your Pipe in question.

    There is neither a general question nor your pipe link in your message, I really don't know how anyone could help you in this state...

    0
  • My question is based on the item.description filter rule. What is the "item description" being filtered ? Is it the description tag in the xml rss feed? If so is there a way to filter keywords based on content in the stories contained within the rss feed? Item title and descriptions tags are essentially the same content from what I have seem within the xml documents I have checked. Here is a link to my ://pipes.yahoo.com/pipes/pipe.edit?_id=18f96a2196cd1a0eda87eafefc7cb58c Thanks

    0
  • questions:

    - "What is the "item description" being filtered ?"

    the description of the item (hence the news article) embedded along with the title, the date of publication etc.

    - "Is it the description tag in the xml rss feed?"

    no and yes. No, because a RSS feed usually includes a description tag of the feed itself. however this feed->description is not mandatory, and actually, you don't care about it. And yes, because every item/article of most if not all feeds one could find contains a description tag, but of the item/article. so feed->item->description. Also, we should use the words markup or field instead of 'tag' because it has other uses.

    - "If so is there a way to filter keywords based on content in the stories contained within the rss feed?"

    Always. If the feed is well thought, you might have a <tag> or <tags> markup containing a list of interest of the story, else you can check the description as you do, the title, or even the story itself!

    comments:

    • Do the date filtering first, as it's computation-wise cheaper, and pipe runtimes are limited.
    • Partly for the previous motive, but also to avoid trouble at the conversion, do the sorting process on y:published.utime instead. utime is an integer representative of the date (number of seconds since EPOCH, ie January 1st, 1970). Easier to compare 2 integers than stuff including text etc.
    • Add a Unique module, based on either the guid, the title or a customised markup because your sources are sometime similar hence duplication.

    To go further:

    If you want to get stories where one of your keyword is used, you can fetch the whole article in the item, and do your filtering on that text. To do that you'll have to use a loop module with a XPath fetch module or a fetch page module embedded. However, the fetching will take some time and you might face the runtime limit, so, again, do the date filtering before.

    enjoy ;)

    0
  • "If you want to get stories where one of your keyword is used, you can fetch the whole article in the item, and do your filtering on that text. To do that you'll have to use a loop module with a XPath fetch module or a fetch page module embedded. However, the fetching will take some time and you might face the runtime limit, so, again, do the date filtering before."

    Hello, and thanks. Can you point me to an example that I can use for this?

    0
  • I am not sure that Xpath fetch module will work as I have 50+ feeds that I am filtering on. Does each feed need it owns Xpath fetch module? thanks

    0
  • Quantity of feeds doesn't matter, if you place it after the feed merging and basic filtering like so: http://pipes.yahoo.com/pipes/pipe.info?_id=8dc1af27119d1dba380911733ea8fa57

    Of course here the xpath expressions are dummy ones, you need to work on them to extract what you want. Also, do not hesitate to use the 'Layout' button, top left ;)

    0

Recent Posts

in Pipes