Documentation outdated for form recognizer? - microsoft-cognitive

The documentation for the containerized form recognizer refers to the cognitive-services-recognize-text:latest but the link provided goes to cognitive-services-read:latest. Which one is the correct recognize text container?
https://learn.microsoft.com/en-us/azure/cognitive-services/form-recognizer/form-recognizer-container-howto

The "Recognize-Text" API is being deprecated (see doc) and replaced by "Read" (Batch Read) API.
So I guess you are pointing to the right container but Form Recognizer's documentation is outdated yes.
You can edit the doc and submit a PR to fix it. It will be validated by people on Microsoft's side

Related

What are the possible types in the Google Calendar API events/watch request body?

I am experimenting with the Goole Calendar API in Postman and trying to be able to watch events. My problem is that the documentation at https://developers.google.com/calendar/v3/reference/events/watch mentions that the request body has a type property of type string that is "The type of delivery mechanism used for this channel." It does not, however, mention what the various options are. The watch section also does not have on of the API explorers attached to it so I can't use the popup that would be there to figure out the options.
Does anyone know what the various options are? Is there some part of the documentation that I am missing?
The address property is also a bit vague, but I'm fairly certain it needs to be a URL.
Use type="web_hook". I left feedback in the documentation to fix this. Let me know if it works for you.

YouTube IFrame API: get video description

I need to fetch a video description (not a title) directly from a user's browser and the only legal that API provides is to call player.getVideoData() but it doesn't contain it.
I tried to use undocumented call to https://www.youtube.com/get_video_info?video_id={video_id} but it's blocked by CORS.
Also I found the API v3 videos/list call that looks like
https://www.googleapis.com/youtube/v3/videos?key=YOUR_API_KEY&part=snippet&id=VIDEO_ID
But as I understood it's intended to Server to Server calls and I don't want to put my API key here.
From what I googled it looks like previously the player.getVideoData() returned the description but now it seems broken.
So is any way to get the description directly from browser?
You can try read the description using document.querySelector- like:
document.querySelector("#description > yt-formatted-string").innerText
N.B. This querySelector worked for me even if YouTube website has in his URL parameter disable_polymer=11 or not.
or
document.querySelector("#eow-description").innerText
N.B: the last querySelector worked for me with old design. I recommend you use the first option, but have this querySelector just in case.
1 add disable_polymer=1 in the URL as a parameter for load YouTube's old design.

Share On LinkedIn Description field not displayed in new UI

Posts made via the Share on LinkedIn API for users on the new user interface appear on their accounts with at most: a user message/comment, image, title, and link domain. However, the documentation on the Share on LinkedIn API (https://developer.linkedin.com/docs/share-on-linkedin) describes that the request body can also contain a "description" field with text up to 256 characters. When the description and all the post fields are provided explicitly to the API (as in the example in the documentation), the description field does not appear for users on the new UI. The description field did appear for users when they were on the old UI.
The Share on LinkedIn API provides an additional option for sharing by omitting the post details fields (title, image, description), and allowing LinkedIn to generate the post based on the Open Graph data it finds at the link URL. However, the result is the same as above for users on the new UI.
Is this a bug, or is the documentation out-of-date?
These are your only options. Choose one:
Share image.
Share description.
If you try to share both, you will only see an image.
I argued with LinkedIn support about this for two weeks I've also directly contacted many of the developers. They have agreed that this is the logic and this is how it is designed to work. I tested this theory out on Wikipedia (has a description, no image) and GitHub (has both description and image). Results:
Wikipedia: Description ONLY -- Works (but no image)!
GitHub: Image ONLY -- Works (but no description)!
I made test site, with only description, to verify this, and it appears confirmed.
Sure, the Official Microsoft LinkedIn Share Documentation makes no mention whatsoever of this, but once again, reality is in direct conflict with Microsoft's understanding.

Customizing email notifications when someone added a comment to a file

I'd like to customize the text sent from the default Comment action of Plone, especially the link sent when someone comments on a file. Current behavior is that the link launches the file itself. The behavior I'd like to see is to take the reader to be able to see the comment entered.
I've been trying to find the template script for the message via both ZMI and the Zope file system but couldn't locate the message template.
.... Example of Default Message ....
Someone added a comment on your File:
Test.
If you are the author of this item, we recommend that you read the comment,
and update the documentation accordingly if required - then remove the comment.
If further clarification is needed, reply to the comment, and the person who
made the comment will get a notification like this, and will likely give you
more details.
To view the new comment, visit:
http://bestkey.middlewaygroup.com/products/Test.ppt
--
Site Administrator
You might want to have a look at plone.app.discussion which is the new commenting system for Plone 4.1 and also available as an add-on product for Plone 3.3.
With p.a.discussion you can register a custom event subscriber that is fired when a new comment is added:
<subscriber
for="plone.app.discussion.interfaces.IComment
zope.app.container.interfaces.IObjectAddedEvent"
handler=".mycustomsubscriber.notify_user"
/>
You have to put a "notify_user" function inside a "mycustomsubscriber.py" file which can contain arbitrary Python code that sends a custom email.
See http://svn.plone.org/svn/plone/plone.app.discussion/trunk/plone/app/discussion/notifications.zcml and http://svn.plone.org/svn/plone/plone.app.discussion/trunk/plone/app/discussion/comment.py for examples.
If the old Plone commenting system comments provide an interface like IComment it should work similarly. Though, I think it does not provide such an interface, but I'm not 100% sure.
The module you are looking for is:
Products.PloneHelpCenter.skins.plone_help_center.discussion_notify_template.pt
which you can override with z3c.jbot. Or in the ZMI, customize:
portal_skins/plone_help_center/discussion_notify_template.pt
(And, you must have at least one add-on installed, Products.PloneHelpCenter because this message is from that add-on).

API for word definitions

i'm trying to implement a little app which basically only hs a label, textbox and a button and when the user enters a word, i want to connect to some online api to retrieve the word's definition and display it in the label. is this possible? all i keep finding is api's related to other stuff on google/other se's. but i have seen this in practice before so i know they are out there, i just don't know where.
I suggest you try WordNet. It has got an API that you can use over the web.
Check it out here: http://wordnet.princeton.edu/wordnet/related-projects/#web
If you search more probably you will find, but let me give you a hint:
You can make a http web request to any website who handles word definitions. You can even search for "define: " + word in google and get the response.

Resources